Gedare Bloom has submitted this change and it was merged. ( https://gem5-review.googlesource.com/3520 )

Change subject: arch-arm: fix ldm of pc interswitching branch
......................................................................

arch-arm: fix ldm of pc interswitching branch

The LDM instruction that loads to the PC causes a branch to the
instruction. In ARMv5T+ the branch can interswitch Thumb and ARM modes.
The interswitch is broken prior to this commit, with LDM to the PC
ignoring the switch.

Change-Id: I6aad073206743f3435c9923e3e2218bfe32c7e05
Reviewed-on: https://gem5-review.googlesource.com/3520
Maintainer: Andreas Sandberg <[email protected]>
Reviewed-by: Andreas Sandberg <[email protected]>
---
M src/arch/arm/isa/insts/macromem.isa
M src/arch/arm/isa/operands.isa
2 files changed, 3 insertions(+), 1 deletion(-)

Approvals:
  Andreas Sandberg: Looks good to me, approved; Looks good to me, approved



diff --git a/src/arch/arm/isa/insts/macromem.isa b/src/arch/arm/isa/insts/macromem.isa
index cc7366e..6a33d1b 100644
--- a/src/arch/arm/isa/insts/macromem.isa
+++ b/src/arch/arm/isa/insts/macromem.isa
@@ -58,7 +58,8 @@
     microLdr2UopCode = '''
                         uint64_t data = Mem_ud;
                         Dest = cSwap((uint32_t) data, ((CPSR)Cpsr).e);
- Dest2 = cSwap((uint32_t) (data >> 32), ((CPSR)Cpsr).e);
+                        IWDest2 = cSwap((uint32_t) (data >> 32),
+                                        ((CPSR)Cpsr).e);
                         '''
     microLdr2UopIop = InstObjParams('ldr2_uop', 'MicroLdr2Uop',
                                    'MicroMemPairOp',
diff --git a/src/arch/arm/isa/operands.isa b/src/arch/arm/isa/operands.isa
index 5898075..2e2955a 100644
--- a/src/arch/arm/isa/operands.isa
+++ b/src/arch/arm/isa/operands.isa
@@ -193,6 +193,7 @@
     'Dest2': intReg('dest2'),
     'XDest2': intRegX64('dest2'),
     'FDest2': floatReg('dest2'),
+    'IWDest2': intRegIWPC('dest2'),
     'Result': intReg('result'),
     'XResult': intRegX64('result'),
     'XBase': intRegX64('base', id = srtBase),

--
To view, visit https://gem5-review.googlesource.com/3520
To unsubscribe, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I6aad073206743f3435c9923e3e2218bfe32c7e05
Gerrit-Change-Number: 3520
Gerrit-PatchSet: 6
Gerrit-Owner: Gedare Bloom <[email protected]>
Gerrit-Reviewer: Andreas Sandberg <[email protected]>
Gerrit-Reviewer: Gedare Bloom <[email protected]>
Gerrit-CC: Jason Lowe-Power <[email protected]>
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev

Reply via email to