summaryrefslogtreecommitdiffstats
path: root/llvm/test/Transforms
diff options
context:
space:
mode:
authorJohannes Doerfert <jdoerfert@anl.gov>2019-10-11 01:45:32 +0000
committerJohannes Doerfert <jdoerfert@anl.gov>2019-10-11 01:45:32 +0000
commit8fa56c49dfc7c219ba37281145d73fd724941715 (patch)
tree541b0da95eedda37f85d8dd152330cdfb27c28f2 /llvm/test/Transforms
parente90cc03a85ea3b4da1462c83960aa996b359ed32 (diff)
downloadbcm5719-llvm-8fa56c49dfc7c219ba37281145d73fd724941715.tar.gz
bcm5719-llvm-8fa56c49dfc7c219ba37281145d73fd724941715.zip
[Attributor][FIX] Do not replace musstail calls with constant
llvm-svn: 374498
Diffstat (limited to 'llvm/test/Transforms')
-rw-r--r--llvm/test/Transforms/FunctionAttrs/arg_returned.ll5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/test/Transforms/FunctionAttrs/arg_returned.ll b/llvm/test/Transforms/FunctionAttrs/arg_returned.ll
index e9cf2d81f11..99b6762a5c8 100644
--- a/llvm/test/Transforms/FunctionAttrs/arg_returned.ll
+++ b/llvm/test/Transforms/FunctionAttrs/arg_returned.ll
@@ -830,6 +830,11 @@ define i32* @use_const() #0 {
; CHECK: ret i32* bitcast (i8* @G to i32*)
ret i32* %c
}
+define i32* @dont_use_const() #0 {
+ %c = musttail call i32* @ret_const()
+ ; CHECK: ret i32* %c
+ ret i32* %c
+}
attributes #0 = { noinline nounwind uwtable }
OpenPOWER on IntegriCloud