Page MenuHomePhabricator

[PredicateInfo] Generalize processing of conditions
Needs ReviewPublic

Authored by nikic on Mon, Jan 11, 1:44 PM.



Branch/assume conditions in PredicateInfo are currently handle in a rather ad-hoc manner, with some arbitrary limitations. For example, an and of two icmps will be handled, but an and of an icmp and some other condition will not. That also includes the case where more than two conditions and and'ed together.

This patch makes the handling more general by looking through an arbitrary number of ands/ors and considering all kinds of conditions (though operands will only be taken for cmps of course).

Diff Detail

Event Timeline

nikic created this revision.Mon, Jan 11, 1:44 PM
nikic requested review of this revision.Mon, Jan 11, 1:44 PM
Herald added a project: Restricted Project. · View Herald TranscriptMon, Jan 11, 1:44 PM
nikic added a comment.Tue, Jan 12, 9:22 AM

The thought that the current limitations are compile-time related crossed my mind, but that doesn't seem to be a concern: