HomePhabricator

[ConstantRange] Add isWrappedSet() and isUpperSignWrapped()

Description

[ConstantRange] Add isWrappedSet() and isUpperSignWrapped()

Split off from D59749. This adds isWrappedSet() and
isUpperSignWrapped() set with the same behavior as isSignWrappedSet()
and isUpperWrapped() for the respectively other domain.

The methods isWrappedSet() and isSignWrappedSet() will not consider
ranges of the form [X, Max] == [X, 0) and [X, SignedMax] == [X, SignedMin)
to be wrapping, while isUpperWrapped() and isUpperSignWrapped() will.

Also replace the checks in getUnsignedMin() and friends with method
calls that implement the same logic.

Details

Committed
nikicMar 27 2019, 12:12 PM
Parents
rL357111: [CGP] Reset DT when optimizing select instructions
Branches
Unknown
Tags
Unknown