[PATCH] D76941: [Module] Track intrinsic IDs in module to skip unnecessary lowering.
Florian Hahn via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 27 15:27:09 PDT 2020
fhahn marked 2 inline comments as done.
fhahn added inline comments.
================
Comment at: llvm/include/llvm/IR/Module.h:196
+ Optional<DenseMap<unsigned, unsigned>> IntrinsicsInModule = None;
+
----------------
efriedma wrote:
> Hmm, this just stores the count, not the actual declarations? I guess that's okay, depending on how you expect to use it.
I am not sure if the list of declarations would be helpful during the actual lowering, because the lowering passes are function passes. And some require lowering/visiting them in a particular oder.
================
Comment at: llvm/lib/IR/Function.cpp:246
+ if (isIntrinsic())
+ getParent()->intrinsicDeclarationRemoved(getIntrinsicID());
getParent()->getFunctionList().erase(getIterator());
----------------
efriedma wrote:
> We should probably try to detect mutation on the list directly. See SymbolTableListTraits.
Thanks I'll take a look
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D76941/new/
https://reviews.llvm.org/D76941
More information about the llvm-commits
mailing list