[PATCH] D68925: [Attributor] Liveness for values
Johannes Doerfert via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Oct 13 01:15:47 PDT 2019
jdoerfert created this revision.
jdoerfert added reviewers: uenoku, sstefan1.
Herald added subscribers: bollu, hiraditya.
Herald added a project: LLVM.
This patch introduces liveness (AAIsDead) for all positions, thus for
all kinds of values. For now, we say an instruction is dead if it would
be removed assuming all users are dead. A call site return is different
as we just look at the users. If all call site returns have been
eliminated, the return values can return undef instead of their original
value, eliminating uses.
We try to recursively delete dead instructions now and we introduce a
simple check-like interface for use-traversal.
More explicit tests will be added.
This is the idea tried out in D68626 <https://reviews.llvm.org/D68626> but implemented in the right way.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D68925
Files:
llvm/include/llvm/Transforms/IPO/Attributor.h
llvm/lib/Transforms/IPO/Attributor.cpp
llvm/test/Transforms/FunctionAttrs/align.ll
llvm/test/Transforms/FunctionAttrs/liveness.ll
llvm/test/Transforms/FunctionAttrs/new_attributes.ll
llvm/test/Transforms/FunctionAttrs/noalias_returned.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D68925.224770.patch
Type: text/x-patch
Size: 28053 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20191013/8c6941cd/attachment-0001.bin>
More information about the llvm-commits
mailing list