blob: 648dc6f72262e006c228564566b0e1de41365c22 [file] [log] [blame]
Chris Lattner4d5b8cc2008-05-02 22:07:34 +00001// llvm-gcc -O1+ should run simplify libcalls, O0 shouldn't
2// and -fno-builtins shouldn't.
3// RUN: %llvmgcc %s -S -emit-llvm -O0 -o - | grep {call.*exp2f}
4// RUN: %llvmgcc %s -S -emit-llvm -O1 -o - | grep {call.*ldexp}
5// RUN: %llvmgcc %s -S -emit-llvm -O3 -fno-builtin -o - | grep {call.*exp2f}
6
Matthijs Kooijmanb7e103b2008-06-10 14:37:44 +00007float exp2f(float);
8
Chris Lattner4d5b8cc2008-05-02 22:07:34 +00009float t4(unsigned char x) {
10 return exp2f(x);
11}
12