mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-21 06:30:16 +00:00
Handle expanding arguments to ISD::TRUNCATE. This happens on PowerPC when
you have something like i16 = truncate i64. This fixes Regression/C/casts git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21073 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
06098e0e9b
commit
79e46acd35
@ -1126,7 +1126,9 @@ SDOperand SelectionDAGLegalize::PromoteOp(SDOperand Op) {
|
||||
Result = PromoteOp(Node->getOperand(0));
|
||||
break;
|
||||
case Expand:
|
||||
assert(0 && "Cannot handle expand yet");
|
||||
ExpandOp(Node->getOperand(0), Tmp1, Tmp2);
|
||||
// Truncate the low part of the expanded value to the result type
|
||||
Result = DAG.getNode(ISD::TRUNCATE, VT, Tmp1);
|
||||
}
|
||||
break;
|
||||
case ISD::SIGN_EXTEND:
|
||||
|
Loading…
x
Reference in New Issue
Block a user