Missing the Blindingly Obvious
Posted: Fri May 11, 2007 2:58 am
[rant]
I just spent an hour debugging a problem that cause my OS to lock up on programs calling the service interrupt. The cause of the problem? jmp $
I started by doing basic putchar('1'), putchar('2')... debugging. I eventually did an objdump. Bochs even *said* the last instruction was JMP $. It told me which routine contains the bug and I still couldnt see it . The reason. I indent my assembly code:
and I had done:
I just los a *whole hour*. What a prat .
[/rant]
I just spent an hour debugging a problem that cause my OS to lock up on programs calling the service interrupt. The cause of the problem? jmp $
I started by doing basic putchar('1'), putchar('2')... debugging. I eventually did an objdump. Bochs even *said* the last instruction was JMP $. It told me which routine contains the bug and I still couldnt see it . The reason. I indent my assembly code:
Code: Select all
asm_function:
mov x, y
....
ret
Code: Select all
asm_function:
mov x, y
...
jmp $
[/rant]