Re: [SeaBIOS] [PATCH 1/3] vgabios: Add config option for assembler fixups

2015-04-11 Thread Paul Menzel
Dear Kevin, Am Freitag, den 10.04.2015, 11:07 -0400 schrieb Kevin O'Connor: Add a kconfig build option (CONFIG_VGA_FIXUP_ASM) to allow users to build the vgabios without the complex assembler fixups that work around emulator bugs. Signed-off-by: Kevin O'Connor ke...@koconnor.net ---

Re: [SeaBIOS] [PATCH 1/3] vgabios: Add config option for assembler fixups

2015-04-11 Thread Kevin O'Connor
On Sat, Apr 11, 2015 at 08:58:20AM +0200, Paul Menzel wrote: Am Freitag, den 10.04.2015, 11:07 -0400 schrieb Kevin O'Connor: Add a kconfig build option (CONFIG_VGA_FIXUP_ASM) to allow users to build the vgabios without the complex assembler fixups that work around emulator bugs.

Re: [SeaBIOS] [PATCHv3 0/2] Emulate leal instruction to workaround x86emu bugs

2015-04-11 Thread Michael Tokarev
11.04.2015 18:08, Kevin O'Connor wrote: With a few additional checks it's possible to emulate all the leal cases without requiring a function call. Although this makes the vgafixup.py code a little more complex it eliminates the need for the emulate_leal function and it produces better code.

Re: [SeaBIOS] [PATCH 1/2] vgabios: Add config option for assembler fixups

2015-04-11 Thread Kevin O'Connor
On Sat, Apr 11, 2015 at 05:36:53PM +0200, Peter Stuge wrote: Kevin O'Connor wrote: +++ b/vgasrc/vgaentry.S @@ -64,6 +64,7 @@ x86emu_fault: // This macro implements a call while avoiding instructions // that old versions of x86emu have problems with. .macro

Re: [SeaBIOS] [PATCH 1/2] vgabios: Add config option for assembler fixups

2015-04-11 Thread Peter Stuge
Kevin O'Connor wrote: +++ b/vgasrc/vgaentry.S @@ -64,6 +64,7 @@ x86emu_fault: // This macro implements a call while avoiding instructions // that old versions of x86emu have problems with. .macro VGA_CALLL cfunc +#if CONFIG_VGA_FIXUP_ASM // Make sure leal

Re: [SeaBIOS] [PATCH 1/2] vgabios: Add config option for assembler fixups

2015-04-11 Thread Peter Stuge
Kevin O'Connor wrote: +++ b/vgasrc/vgaentry.S @@ -64,6 +64,7 @@ x86emu_fault: // This macro implements a call while avoiding instructions // that old versions of x86emu have problems with. .macro VGA_CALLL cfunc +#if CONFIG_VGA_FIXUP_ASM //

Re: [SeaBIOS] [PATCHv3 0/2] Emulate leal instruction to workaround x86emu bugs

2015-04-11 Thread Kevin O'Connor
On Sat, Apr 11, 2015 at 08:28:06PM +0300, Michael Tokarev wrote: 11.04.2015 18:08, Kevin O'Connor wrote: With a few additional checks it's possible to emulate all the leal cases without requiring a function call. Although this makes the vgafixup.py code a little more complex it eliminates

[SeaBIOS] [PATCH 1/2] vgabios: Add config option for assembler fixups

2015-04-11 Thread Kevin O'Connor
Add a kconfig build option (CONFIG_VGA_FIXUP_ASM) to allow users to build the vgabios without the complex assembler fixups that work around emulator bugs. Signed-off-by: Kevin O'Connor ke...@koconnor.net --- Makefile | 21 +++-- vgasrc/Kconfig| 10 ++

[SeaBIOS] [PATCH 2/2] vgabios: Emulate leal instruction

2015-04-11 Thread Kevin O'Connor
Emulate the leal instruction so that the vgabios can run on older versions of x86emu. (This removes the previous leal trap.) Signed-off-by: Kevin O'Connor ke...@koconnor.net --- scripts/vgafixup.py | 64 ++--- vgasrc/vgaentry.S | 24

[SeaBIOS] [PATCHv3 0/2] Emulate leal instruction to workaround x86emu bugs

2015-04-11 Thread Kevin O'Connor
With a few additional checks it's possible to emulate all the leal cases without requiring a function call. Although this makes the vgafixup.py code a little more complex it eliminates the need for the emulate_leal function and it produces better code. In my tests, almost all leal instructions