[PATCH] D72885: [WIP] Add Query API for llvm.assume holding attributes
Tyker via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 17 15:39:54 PST 2020
Tyker added inline comments.
================
Comment at: llvm/lib/Transforms/Utils/KnowledgeRetention.cpp:221
+ *ArgVal = cast<ConstantInt>((Assume.op_begin() + Lookup->Begin + 1)->get())
+ ->getZExtValue();
+ return true;
----------------
jdoerfert wrote:
> The above seems complicated. Can you use helpers or comments to make it easier to read?
i added and used a helper to simplify this and other pieces of code is it enough ?
================
Comment at: llvm/lib/Transforms/Utils/KnowledgeRetention.cpp:239
+ ShouldPreserveAllAttributes.setValue(PreviousValue);
+}
----------------
jdoerfert wrote:
> Where is this used?
this is used for testing ShouldPreserveAllAttributes option from unittests.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D72885/new/
https://reviews.llvm.org/D72885
More information about the llvm-commits
mailing list