Mem: Reclaim some request flags used by MIPS for alignment checking.
[gem5.git] / src / arch / arm / predecoder.cc
index 20c7058b0d5bd4aeb81255c2172f311a3557c00c..04cec59b91fe0f933167293df971ab3819cd048b 100644 (file)
@@ -43,6 +43,7 @@
 
 #include "arch/arm/isa_traits.hh"
 #include "arch/arm/predecoder.hh"
+#include "arch/arm/utility.hh"
 #include "base/trace.hh"
 #include "cpu/thread_context.hh"
 
@@ -151,7 +152,7 @@ Predecoder::moreBytes(Addr pc, Addr fetchPC, MachInst inst)
 {
     data = inst;
     offset = (fetchPC >= pc) ? 0 : pc - fetchPC;
-    emi.thumb = (pc & (ULL(1) << PcTBitShift)) ? 1 : 0;
+    emi.thumb = isThumb(pc);
     FPSCR fpscr = tc->readMiscReg(MISCREG_FPSCR);
     emi.fpscrLen = fpscr.len;
     emi.fpscrStride = fpscr.stride;