Giacomo Travaglini merged this change by Giacomo Travaglini. ( https://gem5-review.googlesource.com/8369 )

Change subject: arch-arm: HLT using immediate when checking for semihosting
......................................................................

arch-arm: HLT using immediate when checking for semihosting

HLT can use the immediate field when checking for semihosting,
rather than re-parsing it from the machInst variable.

Change-Id: I072cb100029da34d129b90c5d17e1728f9016c88
Signed-off-by: Giacomo Travaglini <[email protected]>
Reviewed-by: Andreas Sandberg <[email protected]>
Reviewed-on: https://gem5-review.googlesource.com/8369
Maintainer: Andreas Sandberg <[email protected]>
---
M src/arch/arm/isa/insts/misc64.isa
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/src/arch/arm/isa/insts/misc64.isa b/src/arch/arm/isa/insts/misc64.isa
index cf82ea3..17d8df1 100644
--- a/src/arch/arm/isa/insts/misc64.isa
+++ b/src/arch/arm/isa/insts/misc64.isa
@@ -177,7 +177,7 @@

     hltCode = '''
     ThreadContext *tc = xc->tcBase();
- if (ArmSystem::haveSemihosting(tc) && bits(machInst, 20, 5) == 0xF000) {
+    if (ArmSystem::haveSemihosting(tc) && imm == 0xF000) {
         X0 = ArmSystem::callSemihosting64(tc, X0 & mask(32), X1);
     } else {
         // HLT instructions aren't implemented, so treat them as undefined

--
To view, visit https://gem5-review.googlesource.com/8369
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I072cb100029da34d129b90c5d17e1728f9016c88
Gerrit-Change-Number: 8369
Gerrit-PatchSet: 2
Gerrit-Owner: Giacomo Travaglini <[email protected]>
Gerrit-Reviewer: Andreas Sandberg <[email protected]>
Gerrit-Reviewer: Giacomo Travaglini <[email protected]>
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev

Reply via email to