[PATCH] D46227: [islpp] Do not abuse isl::stat::error as early-abort

Philip Pfaffe via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Apr 29 04:11:08 PDT 2018


philip.pfaffe added inline comments.


================
Comment at: lib/Analysis/ScopInfo.cpp:2397
-  return Locations.foreach_set(Lambda) == isl::stat::ok;
+  Locations.foreach_set(Lambda);
+
+  return !Aborted;
 }
 
----------------
grosser wrote:
> Why? We don't do this today either.
> 
> As the global quota state is already set to quota-error anything we will compute inside the quota guard will anyhow discarded. There is no need to communicate on any other pass that things are invalid and we should probably not even try as otherwise we would need to check for compute out's all over the place, if we would like to be consistent. As this is not possible, the intend is always that there is a final check that drops everything, if there was a compute-out error.
We do it today, courtesy of `buildMinMaxAccess` propagating the error.

But if we're dropping that propagation alltogether, then this is ceretainly fine.


================
Comment at: lib/Transform/FlattenAlgo.cpp:61
     if (isVariableDim(BMap))
-      return isl::stat::error;
+      IsVariableDim = true;
     return isl::stat::ok;
----------------
grosser wrote:
> philip.pfaffe wrote:
> > You could check  this condition before testing the BMap's out-dimension to save a little bit of compute.
> I don't get what you have in mind here. Could you provide a mini code snippet?
```
[&](isl::basic_map BMap) -> isl::stat {
    if (IsVariableDim)
        return isl::stat::ok;

    ...
}
```


Repository:
  rPLO Polly

https://reviews.llvm.org/D46227





More information about the llvm-commits mailing list