1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 07:48:11 +00:00

UserspaceEmulator: XLAT BX should not check full EBX shadow bits

Thanks to Rick van Schijndel for pointing this out. :^)
This commit is contained in:
Andreas Kling 2020-07-22 00:03:48 +02:00
parent 201cc1bfcc
commit 9fc00d5d12

View file

@ -2484,7 +2484,7 @@ void SoftCPU::XLAT(const X86::Instruction& insn)
if (insn.a32())
warn_if_uninitialized(ebx(), "xlat ebx");
else
warn_if_uninitialized(ebx(), "xlat bx");
warn_if_uninitialized(bx(), "xlat bx");
warn_if_uninitialized(al(), "xlat al");
u32 offset = (insn.a32() ? ebx().value() : bx().value()) + al().value();
set_al(read_memory8({ segment(insn.segment_prefix().value_or(X86::SegmentRegister::DS)), offset }));