[PATCH] D135133: [Sink] Allow sinking of invariant loads across critical edges
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 4 08:55:36 PDT 2022
arsenm added inline comments.
================
Comment at: llvm/lib/Transforms/Scalar/Sink.cpp:83
+ if (Inst->mayReadFromMemory() &&
+ !Inst->hasMetadata(LLVMContext::MD_invariant_load))
return false;
----------------
arsenm wrote:
> Probably should go through the AA query for pointsToConstantMemory instead of directly checking the metadata
I guess that's a bit different since it's on the source operand, so a future possible improvements
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D135133/new/
https://reviews.llvm.org/D135133
More information about the llvm-commits
mailing list