mirror of
https://github.com/RPCS3/llvm.git
synced 2024-11-26 21:20:29 +00:00
Don't select binary instructions with illegal types.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@55383 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
a843b8d391
commit
b71fea248f
@ -30,6 +30,12 @@ bool FastISel::SelectBinaryOp(Instruction *I, ISD::NodeType ISDOpcode,
|
||||
if (VT == MVT::Other || !VT.isSimple())
|
||||
// Unhandled type. Halt "fast" selection and bail.
|
||||
return false;
|
||||
// We only handle legal types. For example, on x86-32 the instruction
|
||||
// selector contains all of the 64-bit instructions from x86-64,
|
||||
// under the assumption that i64 won't be used if the target doesn't
|
||||
// support it.
|
||||
if (!TLI.isTypeLegal(VT))
|
||||
return false;
|
||||
|
||||
unsigned Op0 = ValueMap[I->getOperand(0)];
|
||||
if (Op0 == 0)
|
||||
|
Loading…
Reference in New Issue
Block a user