diff options
author | Matt Horsnell <Matt.Horsnell@ARM.com> | 2011-01-18 16:30:05 -0600 |
---|---|---|
committer | Matt Horsnell <Matt.Horsnell@ARM.com> | 2011-01-18 16:30:05 -0600 |
commit | adbd84ab9fffdcdce18f564acffa508c10164c9f (patch) | |
tree | aa6d90545a22e3524e33022176666569a47d83ba /src/arch/arm/insts/pred_inst.hh | |
parent | 11bef2ab3811e5c7a65d33ba86718d8c606be87a (diff) | |
download | gem5-adbd84ab9fffdcdce18f564acffa508c10164c9f.tar.xz |
ARM: The ARM decoder should not panic when decoding undefined holes is arch.
This can abort simulations when the fetch unit runs ahead and speculatively
decodes instructions that are off the execution path.
Diffstat (limited to 'src/arch/arm/insts/pred_inst.hh')
-rw-r--r-- | src/arch/arm/insts/pred_inst.hh | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/arch/arm/insts/pred_inst.hh b/src/arch/arm/insts/pred_inst.hh index f779b46f5..c441d1f32 100644 --- a/src/arch/arm/insts/pred_inst.hh +++ b/src/arch/arm/insts/pred_inst.hh @@ -78,9 +78,10 @@ modified_imm(uint8_t ctrlImm, uint8_t dataImm) } static inline uint64_t -simd_modified_imm(bool op, uint8_t cmode, uint8_t data) +simd_modified_imm(bool op, uint8_t cmode, uint8_t data, bool &immValid) { uint64_t bigData = data; + immValid = true; switch (cmode) { case 0x0: case 0x1: @@ -139,9 +140,10 @@ simd_modified_imm(bool op, uint8_t cmode, uint8_t data) bigData |= (bigData << 32); break; } - // Fall through + // Fall through, immediate encoding is invalid. default: - panic("Illegal modified SIMD immediate parameters.\n"); + immValid = false; + break; } return bigData; } |