Hacker News new | ask | show | jobs
by dathinab 965 days ago
luckily many of the things which caused bugs on ARM where related to the weaker memory ordering and code having (invalid) implicit assumptions about stuff like memory barriers

luckily because this has mostly been fixed and is also the biggest stumbling block when going from x86 => RISC-V

Through there was something about the specific LR/SC definition which I found quite problematic when it comes to implementing certain atomic patterns. But that was 2?? years or so ago and I don't remember the details at all.

Eitherway theoretically if you have a correct C++ standard compatible program without UB it should "just work" on RISK-V by now, but then I don't think such a thing exists (/s/j).

3 comments

> if you have a correct C++ standard compatible program without UB it should "just work" on RISK-V by now, but then I don't think such a thing exists

Fortunately, what does exist is programs that have been ported to work on arm64 (or are native there), which will Just Work on RISC-V which has a slightly stronger memory model than Arm.

Related, Debian initial RISC-V official port sid build status[0] and overall[1].

0. https://buildd.debian.org/status/architecture.php?a=riscv64&...

1. https://buildd.debian.org/stats/

Why is this downvoted? Is it technically wrong?