mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-13 20:32:21 +00:00
LSR, correct fix for rdar://9786536. Silly casting bug.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135654 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
c2c988e5e0
commit
c205a094bd
@ -1480,8 +1480,8 @@ void LSRInstance::OptimizeShadowIV() {
|
||||
ConstantInt *Init = dyn_cast<ConstantInt>(PH->getIncomingValue(Entry));
|
||||
if (!Init) continue;
|
||||
Constant *NewInit = ConstantFP::get(DestTy, IsSigned ?
|
||||
Init->getSExtValue() :
|
||||
Init->getZExtValue());
|
||||
(double)Init->getSExtValue() :
|
||||
(double)Init->getZExtValue());
|
||||
|
||||
BinaryOperator *Incr =
|
||||
dyn_cast<BinaryOperator>(PH->getIncomingValue(Latch));
|
||||
|
@ -25,7 +25,7 @@ for.end:
|
||||
|
||||
; Now check that the computed double constant is correct.
|
||||
; CHECK: @doubleIV
|
||||
; CHECK: phi double [ 0x43F0000000000000, %entry ]
|
||||
; CHECK: phi double [ -3.900000e+01, %entry ]
|
||||
; CHECK: br
|
||||
define void @doubleIV() nounwind {
|
||||
entry:
|
||||
|
Loading…
Reference in New Issue
Block a user