Index: src/mips64/constants-mips64.cc |
diff --git a/src/mips64/constants-mips64.cc b/src/mips64/constants-mips64.cc |
index 5ebadb338af47984f6c303539a65e0e2384c9eac..fd183a7b018abddaa9a4c31c321ae876c59d7593 100644 |
--- a/src/mips64/constants-mips64.cc |
+++ b/src/mips64/constants-mips64.cc |
@@ -141,6 +141,8 @@ bool Instruction::IsForbiddenInBranchDelay() const { |
case BNEL: |
case BLEZL: |
case BGTZL: |
+ case BC: |
+ case BALC: |
return true; |
case REGIMM: |
switch (RtFieldRaw()) { |
@@ -173,6 +175,11 @@ bool Instruction::IsLinkingInstruction() const { |
switch (op) { |
case JAL: |
return true; |
+ case POP76: |
+ if (RsFieldRawNoAssert() == JIALC) |
+ return true; // JIALC |
+ else |
+ return false; // BNEZC |
case REGIMM: |
switch (RtFieldRaw()) { |
case BGEZAL: |
@@ -290,9 +297,43 @@ Instruction::Type Instruction::InstructionType() const { |
case INS: |
case EXT: |
case DEXT: |
- case BITSWAP: |
- case DBITSWAP: |
return kRegisterType; |
+ case BSHFL: { |
+ int sa = SaFieldRaw() >> kSaShift; |
+ switch (sa) { |
+ case BITSWAP: |
+ return kRegisterType; |
+ case WSBH: |
+ case SEB: |
+ case SEH: |
+ return kUnsupported; |
+ } |
+ sa >>= kBp2Bits; |
+ switch (sa) { |
+ case ALIGN: |
+ return kRegisterType; |
+ default: |
+ return kUnsupported; |
+ } |
+ } |
+ case DBSHFL: { |
+ int sa = SaFieldRaw() >> kSaShift; |
+ switch (sa) { |
+ case DBITSWAP: |
+ return kRegisterType; |
+ case DSBH: |
+ case DSHD: |
+ return kUnsupported; |
+ } |
+ sa = SaFieldRaw() >> kSaShift; |
+ sa >>= kBp3Bits; |
+ switch (sa) { |
+ case DALIGN: |
+ return kRegisterType; |
+ default: |
+ return kUnsupported; |
+ } |
+ } |
default: |
return kUnsupported; |
} |
@@ -329,8 +370,8 @@ Instruction::Type Instruction::InstructionType() const { |
case BNEL: |
case BLEZL: |
case BGTZL: |
- case BEQZC: |
- case BNEZC: |
+ case POP66: |
+ case POP76: |
case LB: |
case LH: |
case LWL: |
@@ -350,6 +391,9 @@ Instruction::Type Instruction::InstructionType() const { |
case LDC1: |
case SWC1: |
case SDC1: |
+ case PCREL: |
+ case BC: |
+ case BALC: |
return kImmediateType; |
// 26 bits immediate type instructions. e.g.: j imm26. |
case J: |