diff options
| author | Johannes Doerfert <jdoerfert@anl.gov> | 2019-07-08 23:27:20 +0000 |
|---|---|---|
| committer | Johannes Doerfert <jdoerfert@anl.gov> | 2019-07-08 23:27:20 +0000 |
| commit | accd3e87478eb75d455e016500ef3d2ddbeca82d (patch) | |
| tree | b4f37ef263128fdbfaecc9e7a03a04b6df0125da /llvm/test/Transforms/FunctionAttrs/arg_nocapture.ll | |
| parent | 793231c319f05c476071f0aad5104219be9185f8 (diff) | |
| download | bcm5719-llvm-accd3e87478eb75d455e016500ef3d2ddbeca82d.tar.gz bcm5719-llvm-accd3e87478eb75d455e016500ef3d2ddbeca82d.zip | |
[Attributor] Deduce the "returned" argument attribute
Deduce the "returned" argument attribute by collecting all potentially
returned values.
Not only the unique return value, if any, can be used by subsequent
attributes but also the set of all potentially returned values as well
as the mapping from returned values to return instructions that they
originate from (see AAReturnedValues::checkForallReturnedValues).
Change in statistics (-stats) for LLVM-TS + Spec2006, totaling ~19% more "returned" arguments.
ADDED: attributor NumAttributesManifested n/a -> 637
ADDED: attributor NumAttributesValidFixpoint n/a -> 25545
ADDED: attributor NumFnArgumentReturned n/a -> 637
ADDED: attributor NumFnKnownReturns n/a -> 25545
ADDED: attributor NumFnUniqueReturned n/a -> 14118
CHANGED: deadargelim NumRetValsEliminated 470 -> 449 ( -4.468%)
REMOVED: functionattrs NumReturned 535 -> n/a
CHANGED: indvars NumElimIdentity 138 -> 164 ( +18.841%)
Reviewers: homerdin, hfinkel, fedor.sergeev, sanjoy, spatel, nlopes, nicholas, reames, efriedma, chandlerc
Subscribers: hiraditya, bollu, cfe-commits, llvm-commits
Tags: #clang, #llvm
Differential Revision: https://reviews.llvm.org/D59919
llvm-svn: 365407
Diffstat (limited to 'llvm/test/Transforms/FunctionAttrs/arg_nocapture.ll')
| -rw-r--r-- | llvm/test/Transforms/FunctionAttrs/arg_nocapture.ll | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/llvm/test/Transforms/FunctionAttrs/arg_nocapture.ll b/llvm/test/Transforms/FunctionAttrs/arg_nocapture.ll index 2a41b103619..0bc7053f7ad 100644 --- a/llvm/test/Transforms/FunctionAttrs/arg_nocapture.ll +++ b/llvm/test/Transforms/FunctionAttrs/arg_nocapture.ll @@ -112,18 +112,15 @@ entry: ; TEST SCC with various calls, casts, and comparisons agains NULL ; -; FIXME: returned missing for %a ; FIXME: no-capture missing for %a -; CHECK: define float* @scc_A(i32* readnone %a) +; CHECK: define float* @scc_A(i32* readnone returned %a) ; -; FIXME: returned missing for %a ; FIXME: no-capture missing for %a -; CHECK: define i64* @scc_B(double* readnone %a) +; CHECK: define i64* @scc_B(double* readnone returned %a) ; -; FIXME: returned missing for %a ; FIXME: readnone missing for %s ; FIXME: no-capture missing for %a -; CHECK: define i8* @scc_C(i16* %a) +; CHECK: define i8* @scc_C(i16* returned %a) ; ; float *scc_A(int *a) { ; return (float*)(a ? (int*)scc_A((int*)scc_B((double*)scc_C((short*)a))) : a); |

