From: Gabe Black Date: Mon, 17 Nov 2014 09:00:53 +0000 (-0800) Subject: x86: Fix setting segment bases in real mode. X-Git-Tag: stable_2015_04_15~123 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=aceeecb1925afff455d9355d3379d393993192ab;p=gem5.git x86: Fix setting segment bases in real mode. The data size used for actually writing the base value for the segment was the default size, but really it should set the entire value without any possible truncation. --- diff --git a/src/arch/x86/isa/insts/general_purpose/control_transfer/jump.py b/src/arch/x86/isa/insts/general_purpose/control_transfer/jump.py index 6999b913d..3bb2d3e87 100644 --- a/src/arch/x86/isa/insts/general_purpose/control_transfer/jump.py +++ b/src/arch/x86/isa/insts/general_purpose/control_transfer/jump.py @@ -145,7 +145,7 @@ def macroop JMP_FAR_REAL_M zexti t3, t1, 15, dataSize=8 slli t3, t3, 4, dataSize=8 wrsel cs, t1, dataSize=2 - wrbase cs, t3 + wrbase cs, t3, dataSize=8 wrip t0, t2, dataSize=asz }; @@ -168,7 +168,7 @@ def macroop JMP_FAR_REAL_I mov t2, t0, t2 slli t3, t1, 4, dataSize=8 wrsel cs, t1, dataSize=2 - wrbase cs, t3 + wrbase cs, t3, dataSize=8 wrip t0, t2, dataSize=asz }; ''' diff --git a/src/arch/x86/isa/insts/general_purpose/data_transfer/move.py b/src/arch/x86/isa/insts/general_purpose/data_transfer/move.py index 3f5c2d303..75a20ffbd 100644 --- a/src/arch/x86/isa/insts/general_purpose/data_transfer/move.py +++ b/src/arch/x86/isa/insts/general_purpose/data_transfer/move.py @@ -215,7 +215,7 @@ def macroop MOV_REAL_S_R { zexti t2, regm, 15, dataSize=8 slli t3, t2, 4, dataSize=8 wrsel reg, regm - wrbase reg, t3 + wrbase reg, t3, dataSize=8 }; def macroop MOV_REAL_S_M { @@ -223,7 +223,7 @@ def macroop MOV_REAL_S_M { zexti t2, t1, 15, dataSize=8 slli t3, t2, 4, dataSize=8 wrsel reg, t1 - wrbase reg, t3 + wrbase reg, t3, dataSize=8 }; def macroop MOV_REAL_S_P {