Page MenuHomePhabricator

[ValueTracking] don't crash when assumptions conflict (PR36270)
ClosedPublic

Authored by spatel on Feb 7 2018, 4:36 PM.

Details

Summary

The last assume in the test says that %B12 is 0. The first assume says that %and1 is less than %B12. Therefore, %and1 is unsigned less than 0...does not compute.

That means this line:

Known.Zero.setHighBits(RHSKnown.countMinLeadingZeros() + 1);

...tries to set more bits than exist.

Diff Detail

Repository
rL LLVM

Event Timeline

spatel created this revision.Feb 7 2018, 4:36 PM
majnemer accepted this revision.Feb 8 2018, 1:11 AM

LGTM

This revision is now accepted and ready to land.Feb 8 2018, 1:11 AM
This revision was automatically updated to reflect the committed changes.