https://llvm.org/bugs/show_bug.cgi?id=30543
Bug ID: 30543 Summary: 4.0 Regression in llvm.powi.f64 lowering on ARM Product: libraries Version: trunk Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: Backend: ARM Assignee: unassignedb...@nondot.org Reporter: yyc1...@gmail.com CC: llvm-bugs@lists.llvm.org Classification: Unclassified Compiling the following IR on arm ``` target datalayout = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64" target triple = "armv7l-unknown-linux-gnueabihf" @.str = private unnamed_addr constant [4 x i8] c"%f\0A\00", align 1 ; Function Attrs: noinline norecurse nounwind readnone define double @f(double, i32) #0 { top: %2 = tail call double @llvm.powi.f64(double %0, i32 %1) ret double %2 } ; Function Attrs: nounwind readnone declare double @llvm.powi.f64(double, i32) ; Function Attrs: nounwind define i32 @main() { %1 = tail call double @f(double 2.000000e+00, i32 62) %2 = tail call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i32 0, i32 0), double %1) ret i32 0 } ; Function Attrs: nounwind declare i32 @printf(i8* nocapture readonly, ...) attributes #0 = { noinline } ``` prints 2.0 instead of what 2^62 should be. This is a regression in llvm 4.0 and is causing a lot of test failures in julia. Difference in the assembly ``` - .save {r11, lr} - push {r11, lr} - mov r2, r0 - vmov r0, r1, d0 - bl __powidf2 - vmov d0, r0, r1 - pop {r11, pc} + b __powidf2 ``` GDB confirmed that the input value to `__powidf2` is wrong. Currently bisecting. -- You are receiving this mail because: You are on the CC list for the bug.
_______________________________________________ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs