summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
authorAlex Lorenz <arphaman@gmail.com>2015-08-05 19:03:42 +0000
committerAlex Lorenz <arphaman@gmail.com>2015-08-05 19:03:42 +0000
commit3f2058da16b6595a97745db43dd705421ce20bca (patch)
treef174927526b9fa539b973f8a72c6403af03d8afe /llvm/lib/CodeGen
parentb6804dbf4392980896dcdad09f502c3c002c0aad (diff)
downloadbcm5719-llvm-3f2058da16b6595a97745db43dd705421ce20bca.tar.gz
bcm5719-llvm-3f2058da16b6595a97745db43dd705421ce20bca.zip
MIR Parser: Report an error when parsing large immediate operands.
llvm-svn: 244100
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r--llvm/lib/CodeGen/MIRParser/MIParser.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/MIRParser/MIParser.cpp b/llvm/lib/CodeGen/MIRParser/MIParser.cpp
index 15f93eea87f..a30a4a9a83f 100644
--- a/llvm/lib/CodeGen/MIRParser/MIParser.cpp
+++ b/llvm/lib/CodeGen/MIRParser/MIParser.cpp
@@ -552,8 +552,7 @@ bool MIParser::parseImmediateOperand(MachineOperand &Dest) {
assert(Token.is(MIToken::IntegerLiteral));
const APSInt &Int = Token.integerValue();
if (Int.getMinSignedBits() > 64)
- // TODO: Replace this with an error when we can parse CIMM Machine Operands.
- llvm_unreachable("Can't parse large integer literals yet!");
+ return error("integer literal is too large to be an immediate operand");
Dest = MachineOperand::CreateImm(Int.getExtValue());
lex();
return false;
OpenPOWER on IntegriCloud