News for hackers. Stuff that matters.
Re:TinyVM: A lightweight, fast virtual machine in < 500 l... by leon_ on Sunday July 03, 2011 @04:06AM (#2723327)
Ah, I love virtual machines/cpus :] Some weeks ago I found out that you can create pointers to goto labels in C (gcc and clang that is - it's a non standard extension afaik).

I then implemented a super small subset of the 6502 to test how messy the code would like:

https://github.com/jsz/6502/blob/master/vm/cpu.c

I don't know if I should like it or not :)

Re:TinyVM: A lightweight, fast virtual machine in < 500 l... by lobster_johnson on Sunday July 03, 2011 @08:09AM (#2723553)
That's neat. I like how your code is so concise and readable. Now all you need to do is to emulate a display, a sound chip and a tape cassette drive. :-)
Re:TinyVM: A lightweight, fast virtual machine in < 500 l... by RodgerTheGreat on Sunday July 03, 2011 @04:17PM (#2724492)
I have a project that's kinda along those lines, but it's not based on the 6502: https://github.com/JohnEarnest/Mako
Re:TinyVM: A lightweight, fast virtual machine in < 500 l... by leon_ on Sunday July 03, 2011 @10:34AM (#2723745)
heh, thanks. but I think I won't have time to work on that project in the near future :(