RFR: 8282204: Use lea instructions for arithmetic operations on x86_64 [v5]
Quan Anh Mai
duke at openjdk.java.net
Fri Feb 25 13:37:54 UTC 2022
On Fri, 25 Feb 2022 12:11:43 GMT, Quan Anh Mai <duke at openjdk.java.net> wrote:
>> Hi,
>>
>> This patch adds several matching rules for x86_64 backend to use `lea` instructions for several fused arithmetic operations. Also, `lea`s don't kill flags and allow different `dst` and `src`, so it is preferred over `sll` if possible, too.
>>
>> Thank you very much.
>
> Quan Anh Mai has updated the pull request incrementally with one additional commit since the last revision:
>
> address reviews
You can look up the detailed measurements of each instruction on each architecture generation on [uops.info](https://uops.info/table.html?search=lea&cb_lat=on&cb_tp=on&cb_uops=on&cb_ports=on&cb_SNB=on&cb_ICL=on&cb_measurements=on&cb_doc=on&cb_base=on) or check out on a summary at [Agner's optimization guide](https://www.agner.org/optimize/instruction_tables.pdf).
Thank you very much.
-------------
PR: https://git.openjdk.java.net/jdk/pull/7560
More information about the hotspot-compiler-dev
mailing list