2 ms·
This post has been hanging out with no comments for ages. I was like, I'll skim it later. > It's almost burying the lede to announce that, though, because the
by sitkack 2y ago
This post has been hanging out with no comments for ages. I was like, I'll skim it later.
> It's almost burying the lede to announce that, though, because the real meat in this entry is how the Commodore 64 manages to emulate a very different 6502-based system. That piece is "6o6," for "6502-on-6502," and is a full virtualized software NMOS 6502 CPU that runs on a 6502 CPU — which I've open-sourced too. It has full control of guest code execution, including trapping undocumented and jam opcodes, and completely abstracts all memory access, making it possible to remap addresses, intercept illegal reads or writes, or even run entirely from virtual memory. On top of that, it's complete enough to not only pass a full functional test but also virtualize itself virtualizing itself:
This is incredible! Not just from a 6502 perspective, but from an everything perspective! Amazing work.
Also, it reminded me of this "The Zilog Z80 has a Protected Mode" https://www.youtube.com/watch?v=DLSUAVPKeYk https://www.youtube.com/watch?v=DLSUAVPKeYk posted to hn, but got no discussion.
- deleted 2y ago[deleted]
- FLT8 2y agoAlso related: C64 booting Linux by emulating a RISC-V processor: https://hackaday.com/2023/08/27/linux-on-a-commodore-64/ https://hackaday.com/2023/08/27/linux-on-a-commodore-64/
- sitkack 2y agoWow! > There is a catch (rather: a couple) of course: It runs extremely slowly and it needs a RAM Expansion Unit (REU), as there is no chance to fit it all into just 64KiB. > It even emulates virtual memory with an MMU. https://github.com/onnokort/semu-c64 https://github.com/onnokort/semu-c64
- userbinator 2y agoThat reminds me of this similar project using an ARM emulator instead: https://news.ycombinator.com/item?id=5581851 https://news.ycombinator.com/item?id=5581851
- elvis70 2y ago> Also, it reminded me of this "The Zilog Z80 has a Protected Mode" https://www.youtube.com/watch?v=DLSUAVPKeYk https://www.youtube.com/watch?v=DLSUAVPKeYk posted to hn, but got no discussion. Here is a thread with 138 comments: https://news.ycombinator.com/item?id=33229526 https://news.ycombinator.com/item?id=33229526