diff options
author | Akira Hatanaka <ahatanak@gmail.com> | 2011-07-08 00:42:35 +0000 |
---|---|---|
committer | Akira Hatanaka <ahatanak@gmail.com> | 2011-07-08 00:42:35 +0000 |
commit | 01843361953463519db42e8098dc8b31b45407c8 (patch) | |
tree | 26fd5552a9c24f7630855508292ed27d31419c63 | |
parent | 18dfcb8a2809204e9cd38099a766e3bb101cc249 (diff) | |
download | external_llvm-01843361953463519db42e8098dc8b31b45407c8.zip external_llvm-01843361953463519db42e8098dc8b31b45407c8.tar.gz external_llvm-01843361953463519db42e8098dc8b31b45407c8.tar.bz2 |
Raise assertion when MachineOperand has unexpected target flag.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134671 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/Target/Mips/MipsMCInstLower.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Target/Mips/MipsMCInstLower.cpp b/lib/Target/Mips/MipsMCInstLower.cpp index 73f4aa7..f5cc3aa 100644 --- a/lib/Target/Mips/MipsMCInstLower.cpp +++ b/lib/Target/Mips/MipsMCInstLower.cpp @@ -35,7 +35,8 @@ MCOperand MipsMCInstLower::LowerSymbolOperand(const MachineOperand &MO, int Offset = 0; switch(MO.getTargetFlags()) { - default: Kind = MipsMCSymbolRefExpr::VK_Mips_None; break; + default: assert(0 && "Invalid target flag!"); + case MipsII::MO_NO_FLAG: Kind = MipsMCSymbolRefExpr::VK_Mips_None; break; case MipsII::MO_GPREL: Kind = MipsMCSymbolRefExpr::VK_Mips_GPREL; break; case MipsII::MO_GOT_CALL: Kind = MipsMCSymbolRefExpr::VK_Mips_GOT_CALL; break; case MipsII::MO_GOT: Kind = MipsMCSymbolRefExpr::VK_Mips_GOT; break; |