diff options
Diffstat (limited to 'src/arch/arm/types.hh')
-rw-r--r-- | src/arch/arm/types.hh | 27 |
1 files changed, 23 insertions, 4 deletions
diff --git a/src/arch/arm/types.hh b/src/arch/arm/types.hh index 84887a1ca..07cdfadc8 100644 --- a/src/arch/arm/types.hh +++ b/src/arch/arm/types.hh @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2012-2013, 2017 ARM Limited + * Copyright (c) 2010, 2012-2013, 2017-2018 ARM Limited * All rights reserved * * The license below extends only to copyright in the software and shall @@ -70,6 +70,7 @@ namespace ArmISA BitUnion64(ExtMachInst) // Decoder state Bitfield<63, 62> decoderFault; // See DecoderFault + Bitfield<61> illegalExecution; // ITSTATE bits Bitfield<55, 48> itstate; @@ -218,14 +219,16 @@ namespace ArmISA JazelleBit = (1 << 1), AArch64Bit = (1 << 2) }; + uint8_t flags; uint8_t nextFlags; uint8_t _itstate; uint8_t _nextItstate; uint8_t _size; + bool _illegalExec; public: PCState() : flags(0), nextFlags(0), _itstate(0), _nextItstate(0), - _size(0) + _size(0), _illegalExec(false) {} void @@ -236,10 +239,22 @@ namespace ArmISA } PCState(Addr val) : flags(0), nextFlags(0), _itstate(0), - _nextItstate(0), _size(0) + _nextItstate(0), _size(0), _illegalExec(false) { set(val); } bool + illegalExec() const + { + return _illegalExec; + } + + void + illegalExec(bool val) + { + _illegalExec = val; + } + + bool thumb() const { return flags & ThumbBit; @@ -472,7 +487,9 @@ namespace ArmISA { return Base::operator == (opc) && flags == opc.flags && nextFlags == opc.nextFlags && - _itstate == opc._itstate && _nextItstate == opc._nextItstate; + _itstate == opc._itstate && + _nextItstate == opc._nextItstate && + _illegalExec == opc._illegalExec; } bool @@ -490,6 +507,7 @@ namespace ArmISA SERIALIZE_SCALAR(nextFlags); SERIALIZE_SCALAR(_itstate); SERIALIZE_SCALAR(_nextItstate); + SERIALIZE_SCALAR(_illegalExec); } void @@ -501,6 +519,7 @@ namespace ArmISA UNSERIALIZE_SCALAR(nextFlags); UNSERIALIZE_SCALAR(_itstate); UNSERIALIZE_SCALAR(_nextItstate); + UNSERIALIZE_SCALAR(_illegalExec); } }; |