[PATCH] D68925: [Attributor] Liveness for values

Stefan Stipanovic via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 14 09:57:17 PDT 2019


sstefan1 added a comment.

Some comments



================
Comment at: llvm/lib/Transforms/IPO/Attributor.cpp:2204
+
+  /// See AAIsDead::isAssumed(Instruction *I).
+  bool isAssumedDead(const Instruction *I) const override {
----------------
nit: `isAssumedDead()`


================
Comment at: llvm/lib/Transforms/IPO/Attributor.cpp:3641
       return Changed;
+    Value &V = getAssociatedValue();
+    if (isa<Constant>(V))
----------------
Should this still be here, considering changes from D68934?


================
Comment at: llvm/lib/Transforms/IPO/Attributor.cpp:4519
+  const IRPosition &IRP = QueryingAA.getIRPosition();
+  const Value &AssociatedValue = IRP.getAssociatedValue();
+  SmallVector<const Use *, 16> Worklist;
----------------
Can we have a value parameter here that maybe defaults to nullptr. In the default case we take `AssociatedValue` and in others the value parameter? Maybe this is not the best solution, but for example, h2s doesn't work with `AssociatedValue`.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D68925





More information about the llvm-commits mailing list