[PATCH] D79454: [IR] `byval` arguments cause reads at call sites
Hal Finkel via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed May 6 10:46:55 PDT 2020
hfinkel added a comment.
> I don't think it is preferable to say the copy happens in the callee because the user could reasonably write something like this: https://godbolt.org/z/8vxz7P and we would need to resolve the discrepancy between the pure attribute and the byval passing in Clang.
I think that's a good point. It does introduce a discrepancy where the callsite attributes/properties and those of the callee. This isn't novel, I suppose, because we have that situation with operand bundles too. That all having been said, if we have a situation where a byval argument is never accessed, perhaps we really want the optimizer to just remove the byval attribute?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D79454/new/
https://reviews.llvm.org/D79454
More information about the llvm-commits
mailing list