search for: xcmp1

Displaying 1 result from an estimated 1 matches for "xcmp1".

Did you mean: cmp1
2010 Sep 03
6
[LLVMdev] Why clang inlines with -O3 flag and opt doesn't?
...dio.h> int fib(int AnArg) { if (AnArg<= 2) return (1); return (fib(AnArg-1)+fib(AnArg-2)); } int main(int argc, char* argv[]) { int n = atoi(argv[1]); printf("fib(%i)=%i\n", n, fib(n)); } --- my handcrafted fib.ll --- define i32 @fib(i32) nounwind readnone { fib.top: %xcmp1 = icmp ugt i32 %0, 1 br i1 %xcmp1, label %maj, label %spec maj: %m1 = add i32 %0, -1 %1 = tail call i32 @fib(i32 %m1) %m2 = add i32 %0, -2 %2 = tail call i32 @fib(i32 %m2) %res = add i32 %2, %1 ret i32 %res spec: %xcmp = icmp eq i32 %0, 1 %mres = zext i1 %xcmp to i32...