Closed tkchia closed 1 year ago
I realize that this PR is rather intrusive; let me know if it may need a redo. Thank you!
Hello @tkchia,
Wow! Very nice. Does this work then complete the implementation of the x86 "unreal" mode, where real mode execution of instructions with 32-bit addresses (i.e. 16-bit instructions with addr32 prefix) will use the previously set via protected-mode GDT hidden base address of the referenced segment register for the address calculation?
Thank you!
@ghaerr : I would say that this patch is more about filling in the implementation of good old protected mode.
This patch changes the internal implementation of the emulated segment registers, so that each segment register comprises
mov
,push
, etc.This makes the implementation closer to what is described in the Intel SDM Volume 3A, §3.4.3 (Segment Registers).
This patch allows the third stage bootloader of "Game of Life" (https://github.com/glitzflitz/gameoflife) to run.
The Blinkenlights register display formatting is also changed: if any segment register bases are non-zero, Blinkenlights displays the visible segment value and the segment base for each segment register, e.g.