[PATCH] D76550: [Attributor] Improve the alignment of the loads

Johannes Doerfert via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 2 09:44:22 PDT 2020


jdoerfert added a comment.

In D76550#1955639 <https://reviews.llvm.org/D76550#1955639>, @omarahmed wrote:

> and i think the base (i32* B) is wrong and it is a base that's because sometimes ACSRepairCB is invoked before FnRepairCB so the alloca instructions are not yet added so it gets the value of the base from the argument itself and not the alloca so isn't we should make sure that FnRepairCB is invoked before ACSRepairCB to make sure that not happens ?


So we privatize twice in this test. Apparently in non-deterministic order, which is bad and needs to be addressed. The question is, is one order "broken", if so why. I think what you can do is to precompute the `AAAlign` in manifest instead of doing this
` Value *Base = ACS.getCallArgOperand(ARI.getReplacedArg().getArgNo());` which is order dependent.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D76550





More information about the llvm-commits mailing list