[PATCH] D86018: [Attributor] fix AAValueConstantRange and IntegerRangeState implementation

Shinji Okumura via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Aug 16 03:48:24 PDT 2020


okura added inline comments.


================
Comment at: llvm/lib/Transforms/IPO/AttributorAttributes.cpp:6964
+      auto &OpAA =
+          A.getAAFor<AAValueConstantRange>(*this, IRPosition::value(OpV));
+      intersectKnown(
----------------
uenoku wrote:
> I'm not sure this propagation is necessary in `initialize` but at least, we need `TrackDpencdence = false` here. 
For example, we can get [0,2) as a known range for `%a` instead of [0,inf) in the following case. And this propagation is needed for a value simplification in the case of `@potential_test3` in `potential.ll`.
```
%a = zext i1 %bool to i32
```

> but at least, we need TrackDpencdence = false here.
I'll fix that.


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

https://reviews.llvm.org/D86018



More information about the llvm-commits mailing list