diff options
author | Guozhi Wei <carrot@google.com> | 2016-08-03 21:43:51 +0000 |
---|---|---|
committer | Guozhi Wei <carrot@google.com> | 2016-08-03 21:43:51 +0000 |
commit | dfe91b47a82dab66327c8f85f003a8bb54916c8c (patch) | |
tree | 3e938dcda396f8a7a71e728bfc16624198f0704e /test/CodeGen/PowerPC/BoolRetToIntTest.ll | |
parent | 9de637b693010cc5b0a78374f552ddb38a5a25f9 (diff) |
[PPC] Handling CallInst in PPCBoolRetToInt
This patch fixes pr25548.
Current implementation of PPCBoolRetToInt doesn't handle CallInst correctly, so it failed to do the intended optimization when there is a CallInst with parameters. This patch fixed that.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@277655 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/PowerPC/BoolRetToIntTest.ll')
-rw-r--r-- | test/CodeGen/PowerPC/BoolRetToIntTest.ll | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/CodeGen/PowerPC/BoolRetToIntTest.ll b/test/CodeGen/PowerPC/BoolRetToIntTest.ll index a7b79789b4c..4a0966b2859 100644 --- a/test/CodeGen/PowerPC/BoolRetToIntTest.ll +++ b/test/CodeGen/PowerPC/BoolRetToIntTest.ll @@ -198,6 +198,8 @@ declare zeroext i1 @return_i1() define zeroext i1 @call_test() { ; CHECK: [[REG:%.+]] = call i1 %result = call i1 @return_i1() +; CHECK: [[REG:%.+]] = zext i1 {{%.+}} to i32 +; CHECK: [[REG:%.+]] = trunc i32 {{%.+}} to i1 ; CHECK: ret i1 [[REG]] ret i1 %result -}
\ No newline at end of file +} |