[PATCH] D79336: [analyzer] Generalize bitwise OR rules for ranges
Denys Petrov via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon May 4 15:37:26 PDT 2020
ASDenysPetrov added inline comments.
================
Comment at: clang/lib/StaticAnalyzer/Core/RangeConstraintManager.cpp:77
+ assert(!isEmpty());
+ // NOTE: It's a shame that we can't implement 'getMaxValue' without scanning
+ // the whole tree to get to the last element.
----------------
vsavchenko wrote:
> xazax.hun wrote:
> > Yeah, this is quite unfortunate. But you might end up calling this a lot for bitwise operations. I wonder if it is worth to solve this problem before commiting this patch. I do not insist though.
> I was even thinking about fixing it myself, this shouldn't be very hard, Also addition of `lower_bound` and `upper_bound` can really help implementing `Includes` for `RangeSet`.
Be aware as D77792 also implements such a method.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D79336/new/
https://reviews.llvm.org/D79336
More information about the cfe-commits
mailing list