diff options
author | Benjamin Kramer <benny.kra@googlemail.com> | 2012-08-18 22:04:34 +0000 |
---|---|---|
committer | Benjamin Kramer <benny.kra@googlemail.com> | 2012-08-18 22:04:34 +0000 |
commit | a4b5717ea7ea09afeb5cda2683f6e91a802f5906 (patch) | |
tree | 0b728979e25757dca9af9aec599aa38e61d68f3b /test | |
parent | 0a8f8980000b753ef77dfc64cc7d9803d5dcc8ce (diff) | |
download | external_llvm-a4b5717ea7ea09afeb5cda2683f6e91a802f5906.zip external_llvm-a4b5717ea7ea09afeb5cda2683f6e91a802f5906.tar.gz external_llvm-a4b5717ea7ea09afeb5cda2683f6e91a802f5906.tar.bz2 |
InstCombine: Fix a crasher when encountering a function pointer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162180 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r-- | test/Transforms/InstCombine/fcmp.ll | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/Transforms/InstCombine/fcmp.ll b/test/Transforms/InstCombine/fcmp.ll index 82fef48..fc1ced0 100644 --- a/test/Transforms/InstCombine/fcmp.ll +++ b/test/Transforms/InstCombine/fcmp.ll @@ -151,3 +151,11 @@ define i32 @test16(double %a) nounwind { ; CHECK-NOT: fabs ; CHECK: fcmp ueq double %a, 0.000000e+00 } + +; Don't crash. +define i32 @test17(double %a, double (double)* %p) nounwind { + %call = tail call double %p(double %a) nounwind + %cmp = fcmp ueq double %call, 0.000000e+00 + %conv = zext i1 %cmp to i32 + ret i32 %conv +} |