[PATCH] D59749: [ConstantRange] Fix isWrappedSet()

Nikita Popov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Mar 24 13:41:48 PDT 2019


nikic marked an inline comment as done.
nikic added inline comments.


================
Comment at: llvm/lib/IR/ConstantRange.cpp:463
 
-  if (!isWrappedSet() && CR.isWrappedSet())
+  if (!isUpperWrapped() && CR.isUpperWrapped())
     return CR.intersectWith(*this);
----------------
I should note that the use of isUpperWrapped() in this function is incorrect, I'm just using it to preserve the existing behavior. This function should be using isWrappedSet() and work on an inclusive upper bound. Right now it handles ranges with Upper=0 suboptimally. I will submit a followup for that.


Repository:
  rL LLVM

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

https://reviews.llvm.org/D59749





More information about the llvm-commits mailing list