diff options
author | Johannes Doerfert <johannes@jdoerfert.de> | 2019-12-31 00:57:00 -0600 |
---|---|---|
committer | Johannes Doerfert <johannes@jdoerfert.de> | 2019-12-31 01:33:21 -0600 |
commit | 28880198718b51a8d590d6e8194f2932683bdd54 (patch) | |
tree | 38e901bbdfa9e0a4611fdf6c68236d103bce8228 /llvm/test/Transforms/Attributor/nonnull.ll | |
parent | 23a6ae2b0624278646929d5cbed360f79be505ac (diff) | |
download | bcm5719-llvm-28880198718b51a8d590d6e8194f2932683bdd54.tar.gz bcm5719-llvm-28880198718b51a8d590d6e8194f2932683bdd54.zip |
[Attributor] Annotate the memory behavior of call site arguments
Especially for callbacks, annotating the call site arguments is
important. Doing so exposed a too strong dependence of AAMemoryBehavior
on AANoCapture since we handle the case of potentially captured pointers
explicitly.
The changes to the tests are all mechanical.
Diffstat (limited to 'llvm/test/Transforms/Attributor/nonnull.ll')
-rw-r--r-- | llvm/test/Transforms/Attributor/nonnull.ll | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/llvm/test/Transforms/Attributor/nonnull.ll b/llvm/test/Transforms/Attributor/nonnull.ll index 97485b7646a..dee0dcab2f3 100644 --- a/llvm/test/Transforms/Attributor/nonnull.ll +++ b/llvm/test/Transforms/Attributor/nonnull.ll @@ -199,14 +199,14 @@ bb1: ; preds = %bb bb4: ; preds = %bb1 %tmp5 = getelementptr inbounds i32, i32* %arg, i64 1 -; ATTRIBUTOR: %tmp5b = tail call nonnull i32* @f3(i32* nofree nonnull %tmp5) +; ATTRIBUTOR: %tmp5b = tail call nonnull i32* @f3(i32* nofree nonnull readonly %tmp5) %tmp5b = tail call i32* @f3(i32* %tmp5) %tmp5c = getelementptr inbounds i32, i32* %tmp5b, i64 -1 br label %bb9 bb6: ; preds = %bb1 ; FIXME: missing nonnull. It should be @f2(i32* nonnull %arg) -; ATTRIBUTOR: %tmp7 = tail call nonnull i32* @f2(i32* nofree %arg) +; ATTRIBUTOR: %tmp7 = tail call nonnull i32* @f2(i32* nofree readonly %arg) %tmp7 = tail call i32* @f2(i32* %arg) ret i32* %tmp7 @@ -221,7 +221,7 @@ define internal i32* @f2(i32* %arg) { bb: ; FIXME: missing nonnull. It should be @f1(i32* nonnull readonly %arg) -; ATTRIBUTOR: %tmp = tail call nonnull i32* @f1(i32* nofree %arg) +; ATTRIBUTOR: %tmp = tail call nonnull i32* @f1(i32* nofree readonly %arg) %tmp = tail call i32* @f1(i32* %arg) ret i32* %tmp } @@ -231,7 +231,7 @@ define dso_local noalias i32* @f3(i32* %arg) { ; ATTRIBUTOR: define dso_local noalias nonnull i32* @f3(i32* nofree readonly %arg) bb: ; FIXME: missing nonnull. It should be @f1(i32* nonnull readonly %arg) -; ATTRIBUTOR: %tmp = call nonnull i32* @f1(i32* nofree %arg) +; ATTRIBUTOR: %tmp = call nonnull i32* @f1(i32* nofree readonly %arg) %tmp = call i32* @f1(i32* %arg) ret i32* %tmp } @@ -455,7 +455,7 @@ define i8 @parent7(i8* %a) { ; ATTRIBUTOR-LABEL: @parent7(i8* nonnull %a) -; ATTRIBUTOR-NEXT: [[RET:%.*]] = call i8 @use1safecall(i8* nonnull %a) +; ATTRIBUTOR-NEXT: [[RET:%.*]] = call i8 @use1safecall(i8* nonnull readonly %a) ; ATTRIBUTOR-NEXT: call void @use1nonnull(i8* nonnull %a) ; ATTRIBUTOR-NEXT: ret i8 [[RET]] |