Retains information when two constant ranges are xor'd together. This is
only possible if both constant ranges do not range over signage.
Details
Details
Diff Detail
Diff Detail
Unit Tests
Unit Tests
Event Timeline
Comment Actions
Add exhaustive correctness test.
Also remove signage test in binaryXor, as the common bits would be 0 anyway, thus creating a full set regardless.
llvm/lib/IR/ConstantRange.cpp | ||
---|---|---|
1428 | The call to getSignedMin/Max includes a check of isFullSet and isUpperSignWrapped, which is relevant here, otherwise Upper-1 would not work. |
I don't understand how signedness is relevant here. Can't you use Lower and Upper-1 here, independent of signedness?