HomePhabricator

[AArch64] Add pass to enable additional comparison optimizations by CSE.

Description

[AArch64] Add pass to enable additional comparison optimizations by CSE.

Patched by Sergey Dmitrouk.

This pass tries to make consecutive compares of values use same operands to
allow CSE pass to remove duplicated instructions. For this it analyzes
branches and adjusts comparisons with immediate values by converting:

GE -> GT
GT -> GE
LT -> LE
LE -> LT

and adjusting immediate values appropriately. It basically corrects two
immediate values towards each other to make them equal.

Details

Committed
JiangningSep 4 2014, 7:55 PM
Parents
rL217219: [PECOFF] Run lib.exe with /machine:x64.
Branches
Unknown
Tags
Unknown

Event Timeline