[PATCH] D139582: [GVN] Improve PRE on load instructions
Guozhi Wei via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 8 16:41:04 PST 2022
Carrot added a comment.
In D139582#3981256 <https://reviews.llvm.org/D139582#3981256>, @mkazantsev wrote:
> Seems like this patch keeps finding values in vectors, and it might be a reason of CT degradation. Maybe refactor them to be maps instead?
Only function ReplaceValuesPerBlockEntry searching values in vector, it is called in the final transformation step. So it is unlikely causing CT issue unless there are a lot of such optimizations actually triggered. I would like to look for CT issues in earlier time.
================
Comment at: llvm/lib/Transforms/Scalar/GVN.cpp:926
+static void ReplaceValuesPerBlockEntry(
+ SmallVectorImpl<AvailableValueInBlock> &ValuesPerBlock, BasicBlock *BB,
+ Value *NewValue) {
----------------
mkazantsev wrote:
> `AvailValInBlkVect` ?
Similar to ConstructSSAForLoadSet, this function is a member of GVNPass, but AvailValInBlkVect is private in GVNPass. So I can't directly use it here.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D139582/new/
https://reviews.llvm.org/D139582
More information about the llvm-commits
mailing list