[PATCH] D141381: [codegen] Store address of indirect arguments on the stack
Felipe de Azevedo Piovezan via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Jan 10 09:30:35 PST 2023
fdeazeve added a comment.
In D141381#4040314 <https://reviews.llvm.org/D141381#4040314>, @dblaikie wrote:
> Ah, so the intent is that this causes these indirect args to be handled the same way as other arguments at -O0 - placed in an alloca, eg:
Yup, that's correct!
> Though I guess it doesn't change the codegen so that the alloca is used to load the value like with other values. Maybe it'd be worth changing the codegen to be more similar in that way?
Note that the situation here is slightly different: loading this new alloca would _not_ produce the value, it would produce the address of the value (because the argument is indirect). In that way, I'm not sure we would gain anything by loading from the alloca. Does that make sense?
> though the impact on -O0 will be a question
Indeed. I'm not exactly sure what the right tradeoffs here are, but will think about this some more.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D141381/new/
https://reviews.llvm.org/D141381
More information about the cfe-commits
mailing list