[PATCH] D79956: [InstCombine] Teach PromoteCastOfAllocation to not insert a bitcast into the middle of a group of allocas
Johannes Doerfert via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu May 14 13:36:16 PDT 2020
jdoerfert added a comment.
In D79956#2037134 <https://reviews.llvm.org/D79956#2037134>, @craig.topper wrote:
> FWIW, there's another place in InstCombine that does something like this, simplifyAllocaArraySize in InstCombineLoadStoreAlloca.cpp So I thought maybe this was desired behavior.
I saw multiple places over the years. I also heard from people they think there is some kind of guarantee or canonical form that the allocas are in the beginning and grouped. I don't think there is, e.g., I checked the other day and SROA scans the entire entry block.
Personally, I'd say we need to fix the passes to deal with this. But I do not have a strong opinion.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D79956/new/
https://reviews.llvm.org/D79956
More information about the llvm-commits
mailing list