diff options
author | Chris Lattner <sabre@nondot.org> | 2007-02-25 21:04:39 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2007-02-25 21:04:39 +0000 |
commit | 49c505c6e6b119dd5a7375578bf39cf9a57e18b4 (patch) | |
tree | adde5c1147bf2ac053dd799ecfbb799cc85a73e3 /llvm/test/Transforms/GlobalOpt/constantexpr-dangle.ll | |
parent | b377a7ca11946d4b85747c64b3cc22047d80a0f1 (diff) | |
download | bcm5719-llvm-49c505c6e6b119dd5a7375578bf39cf9a57e18b4.tar.gz bcm5719-llvm-49c505c6e6b119dd5a7375578bf39cf9a57e18b4.zip |
new testcase. @foo should be marked fastcc by globalopt
llvm-svn: 34607
Diffstat (limited to 'llvm/test/Transforms/GlobalOpt/constantexpr-dangle.ll')
-rw-r--r-- | llvm/test/Transforms/GlobalOpt/constantexpr-dangle.ll | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/llvm/test/Transforms/GlobalOpt/constantexpr-dangle.ll b/llvm/test/Transforms/GlobalOpt/constantexpr-dangle.ll new file mode 100644 index 00000000000..89ce1ee0a60 --- /dev/null +++ b/llvm/test/Transforms/GlobalOpt/constantexpr-dangle.ll @@ -0,0 +1,11 @@ +; RUN: llvm-as < %s | opt -instcombine -globalopt | llvm-dis | grep 'internal fastcc float @foo' +define internal float @foo() { + ret float 0.000000e+00 +} + +define float @bar() { + %tmp1 = call float (...)* bitcast (float ()* @foo to float (...)*)( ) + %tmp2 = mul float %tmp1, 1.000000e+01 ; <float> [#uses=1] + ret float %tmp2 +} + |