[PATCH] D109917: [InstCombine] Improve TryToSink for side-effecting calls that would be trivially dead

Nikita Popov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 13 03:15:02 PST 2021


nikic added a comment.

I see that you've added the writeonly argument handling to this patch. I would  prefer to split that off into a separate one, because it's not directly related. Even if it means that this lands without any upstream test changes at first.

I think something that your reasoning on writeonly arguments may be missing is a capture by the call, in which case there might be an indirect read of the alloca later that is not covered by your analysis. Might not matter for the sinking as implemented here, but would make it illegal to drop the call.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D109917/new/

https://reviews.llvm.org/D109917



More information about the llvm-commits mailing list