BIOS test 2 fail
Closed this issue · 2 comments
I was running the test against my own emulator, and couldn't figure out why it would go wrong. I checked the registers, and the value in R1 was not the value it was supposed to read, but it was 1 instead. First I thought the m_word
macro might not have worked, but it did.
When checking out what happens in the SQRT SWI I found that it jumped to 0x404
in the BIOS, and ran these instructions right after the handler:
the SWI changes the value in R1!
It fails on some other emulators as well, and probably passes on mGBA because it HLEs the BIOS. You can probably simply fix the test by using R0 instead of R1, or some other register that is not changed.
+1 the test fails with the real BIOS. verified in mGBA and NBA using a real BIOS.
Thanks for this. I am kinda mad because I read the GBATEK documentation and it never mentioned r1
. Now the only things left which don't work on real hardware are the 32k memory mirrors.