mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-12 22:26:14 +00:00
Fix CodeGen/Generic/fpowi-promote.ll and PR1239
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34893 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
4f263a00bf
commit
8b2d42c949
@ -3328,6 +3328,18 @@ SDOperand SelectionDAGLegalize::PromoteOp(SDOperand Op) {
|
||||
DAG.getValueType(VT));
|
||||
break;
|
||||
|
||||
case ISD::FPOWI: {
|
||||
// Promote f32 powi to f64 powi. Note that this could insert a libcall
|
||||
// directly as well, which may be better.
|
||||
Tmp1 = PromoteOp(Node->getOperand(0));
|
||||
assert(Tmp1.getValueType() == NVT);
|
||||
Result = DAG.getNode(ISD::FPOWI, NVT, Tmp1, Node->getOperand(1));
|
||||
if (NoExcessFPPrecision)
|
||||
Result = DAG.getNode(ISD::FP_ROUND_INREG, NVT, Result,
|
||||
DAG.getValueType(VT));
|
||||
break;
|
||||
}
|
||||
|
||||
case ISD::AND:
|
||||
case ISD::OR:
|
||||
case ISD::XOR:
|
||||
|
Loading…
Reference in New Issue
Block a user