Viewing blog post

Return to blog

Thu 21 of Sep., 2006 21:04 PDT Posted by nkeynes
The move is mostly done now, other than a dozen or so boxes still to be unpacked (mostly miscellaneous crud), and I'm slowly getting used to the earlier start (darn commute). On the bright side, I've been able to use the half-hour or so each way to write some more test cases...

Started working through the CPU core tests, which, at a current rate of about 0.6/day I should be finished sometime next year. Hopefully it'll get faster though now that I've got some more infrastructure in place (and most of them can be made more-or-less data driven). Unfortunately there's still over 100 instructions to get through, without even counting all the variants.

The main driver for doing these now is actually so I have a ready-made test set for the recompiler, although it tests the emu quite nicely too. I've already picked up one unimplemented instruction that I'd completely forgotten about (ADDV - add w/ overflow check) which apparently noone has ever used...[0]

[0] The core has a "halt and catch fire" routine built in for any unimplemented instructions, which tends to make them hard to miss. Admittedly it's no real surprise that noone has used it though - most programming languages don't have any constructs that would compile down to it, and I honestly can't think of any real reason you'd want to use it in practice except in constructs like
        addv r1, r2
        bf normal
        mov.l exception_handler_k, r3
        jsr @r3

(In other words, converting the check into an exception of some kind)

Permalink: tiki-view_blog_post.php?blogId=1&postId=341