mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-08-18 12:29:21 +00:00
Teach Legalize how to expand an EXTRACT_ELEMENT.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47656 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
b3564aa836
commit
1953ecb0a6
@ -5739,6 +5739,12 @@ void SelectionDAGLegalize::ExpandOp(SDOperand Op, SDOperand &Lo, SDOperand &Hi){
|
||||
#endif
|
||||
assert(0 && "Do not know how to expand this operator!");
|
||||
abort();
|
||||
case ISD::EXTRACT_ELEMENT:
|
||||
ExpandOp(Node->getOperand(0), Lo, Hi);
|
||||
if (cast<ConstantSDNode>(Node->getOperand(1))->getValue())
|
||||
return ExpandOp(Hi, Lo, Hi);
|
||||
else
|
||||
return ExpandOp(Lo, Lo, Hi);
|
||||
case ISD::EXTRACT_VECTOR_ELT:
|
||||
assert(VT==MVT::i64 && "Do not know how to expand this operator!");
|
||||
// ExpandEXTRACT_VECTOR_ELT tolerates invalid result types.
|
||||
|
Loading…
Reference in New Issue
Block a user