summaryrefslogtreecommitdiffstats
path: root/polly/lib
diff options
context:
space:
mode:
authorMichael Kruse <llvm@meinersbur.de>2018-05-16 16:39:51 +0000
committerMichael Kruse <llvm@meinersbur.de>2018-05-16 16:39:51 +0000
commitd6c2ca8dd29039a027ebe7e62f292695fbeec8d9 (patch)
tree94424a50942343f8304bfa37be2bd4c7a3d4eb09 /polly/lib
parent12389819381d1eb5b18998951ca3716f57d9d53b (diff)
downloadbcm5719-llvm-d6c2ca8dd29039a027ebe7e62f292695fbeec8d9.tar.gz
bcm5719-llvm-d6c2ca8dd29039a027ebe7e62f292695fbeec8d9.zip
[DeLICM] Avoid assertion on out-of-quota.
An assertion was not prepared to be passed a nullptr because the out-of-quota limit was exceeded. Bail-out before the assertion since the assertion does not apply on out-of-quote. This fixes llvm.org/PR37477. llvm-svn: 332488
Diffstat (limited to 'polly/lib')
-rw-r--r--polly/lib/Support/ISLTools.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/polly/lib/Support/ISLTools.cpp b/polly/lib/Support/ISLTools.cpp
index 07641f43c21..c53f45f099d 100644
--- a/polly/lib/Support/ISLTools.cpp
+++ b/polly/lib/Support/ISLTools.cpp
@@ -47,6 +47,10 @@ isl::multi_aff makeShiftDimAff(isl::space Space, int Pos, int Amount) {
/// @return { [Space1[] -> Space2[]] -> [Space2[] -> Space1[]] }
isl::basic_map makeTupleSwapBasicMap(isl::space FromSpace1,
isl::space FromSpace2) {
+ // Fast-path on out-of-quota.
+ if (!FromSpace1 || !FromSpace2)
+ return {};
+
assert(FromSpace1.is_set());
assert(FromSpace2.is_set());
OpenPOWER on IntegriCloud