diff options
| author | Luc Van Oostenryck <luc.vanoostenryck@gmail.com> | 2021-01-22 23:56:05 +0100 |
|---|---|---|
| committer | Luc Van Oostenryck <luc.vanoostenryck@gmail.com> | 2021-01-26 22:49:11 +0100 |
| commit | a5a61b2e345bac65ef1c256daeb7842539ab1262 (patch) | |
| tree | a9b1c51e5d8f2a8e3cf2f33b3cf222ff1bd0d9b4 /validation/empty-file | |
| parent | 54b6c78979c2a131a55c5439937e5e6bd8584b06 (diff) | |
| download | sparse-dev-a5a61b2e345bac65ef1c256daeb7842539ab1262.tar.gz | |
cmps: canonicalize SEL(x {<,<=} y, a, b) --> SEL(x {>=,>} y, b, a)
Both compares and OP_SELECT are anti-symmetrical: swapping
the arguments is equivalent to inversing the condition.
As consequence, when combined, they're symmetrical:
swapping the arguments of the compare (or equivalently reversing
the direction of the compare) and swapping the operand of the
OP_SELECT is a no-op, both forms are equivalent.
So, canonicalize these to always use OP_GT or OP_GE.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Diffstat (limited to 'validation/empty-file')
0 files changed, 0 insertions, 0 deletions
