jdoerfert added a subscriber: rnk. jdoerfert added a comment. In D110257#3015712 <https://reviews.llvm.org/D110257#3015712>, @jdoerfert wrote:
> In D110257#3015641 <https://reviews.llvm.org/D110257#3015641>, @hsmhsm wrote: > >> In D110257#3015553 <https://reviews.llvm.org/D110257#3015553>, @arsenm wrote: >> >>> I do think it's cleaner/more canonical IR to cluster these at the top of >>> the block, but I don't understand this comment: >>> >>>> otherwise, inliner's attempt to move static allocas from callee to caller >>>> will fail, >>> >>> The inliner successfully moves allocas to the caller's entry block, even >>> with addrspacecasts interspersed. >> >> The logic at >> https://github.com/llvm/llvm-project/blob/main/llvm/lib/Transforms/Utils/InlineFunction.cpp#L2093 >> assumes that static allocas (within callee) are contiguous. > > True. Even worse. It will bail if a static alloca is used as an `inalloca` > argument. > So, if you now interleave allocas that may be used in `inalloca` you also > break the "canonical form". > I assume this hits mostly windows but still. @rnk This might be of interest to you. Any thoughts? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D110257/new/ https://reviews.llvm.org/D110257 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits