mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-23 03:02:36 +01:00
[ConstantRange] Add test case showing a case where we pick too large of a range for multiply after r271020.
llvm-svn: 302700
This commit is contained in:
parent
ecf5118408
commit
8ecd061605
@ -443,6 +443,11 @@ TEST_F(ConstantRangeTest, Multiply) {
|
|||||||
EXPECT_EQ(ConstantRange(APInt(8, 254), APInt(8, 255)).multiply(
|
EXPECT_EQ(ConstantRange(APInt(8, 254), APInt(8, 255)).multiply(
|
||||||
ConstantRange(APInt(8, 2), APInt(8, 4))),
|
ConstantRange(APInt(8, 2), APInt(8, 4))),
|
||||||
ConstantRange(APInt(8, 250), APInt(8, 253)));
|
ConstantRange(APInt(8, 250), APInt(8, 253)));
|
||||||
|
|
||||||
|
// TODO: This should be return [-2, 0]
|
||||||
|
EXPECT_EQ(ConstantRange(APInt(8, -2)).multiply(
|
||||||
|
ConstantRange(APInt(8, 0), APInt(8, 2))),
|
||||||
|
ConstantRange(APInt(8, 0), APInt(8, 255)));
|
||||||
}
|
}
|
||||||
|
|
||||||
TEST_F(ConstantRangeTest, UMax) {
|
TEST_F(ConstantRangeTest, UMax) {
|
||||||
|
Loading…
Reference in New Issue
Block a user