diff options
-rw-r--r-- | lib/Support/ConstantRange.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Support/ConstantRange.cpp b/lib/Support/ConstantRange.cpp index bfee730db1..e9ddffc06b 100644 --- a/lib/Support/ConstantRange.cpp +++ b/lib/Support/ConstantRange.cpp @@ -540,6 +540,9 @@ ConstantRange::add(const ConstantRange &Other) const { ConstantRange ConstantRange::multiply(const ConstantRange &Other) const { + // TODO: If either operand is a single element, round the result min anx + // max value to the appropriate multiple of that element. + if (isEmptySet() || Other.isEmptySet()) return ConstantRange(getBitWidth(), /*isFullSet=*/false); if (isFullSet() || Other.isFullSet()) |