5 ms·
I think assembly is probably a pretty bad choice for a RISC-V emulator. It's not portable, a nightmare to maintain, and not even as fast as binary translation.
by timhh 1y ago
I think assembly is probably a pretty bad choice for a RISC-V emulator. It's not portable, a nightmare to maintain, and not even as fast as binary translation.
What kind of performance do you get?
I guess it would be a great way to learn about the differences between x86 and RISC-V though!
- sylware 1y agoI am not looking for performance (it will run natively on rv64 hardware), I am looking to protect the code against computer language syntax/compiler planned obsolescence (usually cycles of 5-10 years). Have a look a little bit below in the comments where I give a reference to another one, written by the creator of ffmpeg and q-emu.
- timhh 1y agoI'm pretty sure Rust is going to outlast x86! C definitely will.
- jcranmer 1y agoHonestly, assembly language bitrots far faster than other programming languages. In my lifetime, the only thing that really comes close to qualifying as "compiler language syntax/compiler planned obsolescence" is Python 2 to Python 3. In contrast, with x86 alone, there's three separate generations of assembly language to go through in that same timeframe.
- timhh 1y agoPython still doesn't do very well on backwards compatibility & bitrot, even after 3. They're constantly deprecating and removing things. https://docs.python.org/3.12/deprecations/index.html https://docs.python.org/3.12/deprecations/index.html This obviously improves Python, but also it means you absolutely shouldn't choose Python if you are looking for a low maintenance language.
- sylware 1y agoCycles of the planned obsolescence here is long, 5/10 years. Shorter for c++ and similar, than C.
- jcranmer 1y agoLook, I work on compilers, and I have no idea what you're even trying to refer with "planned obsolescence" here. And 5/10 years is a very short time in compiler development planning! Prototypeless-functions in C were deprecated for longer than some committee members were alive before they removed from the standard, and they will remain supported in C compilers probably for longer than I myself will be alive.
- sylware 1y agofeature creeps.
- deleted 1y ago[deleted]