RFR: 8282204: Use lea instructions for arithmetic operations on x86_64 [v2]

Tobias Hartmann thartmann at openjdk.java.net
Wed Feb 23 08:02:48 UTC 2022


On Tue, 22 Feb 2022 17:15:33 GMT, Vladimir Kozlov <kvn at openjdk.org> wrote:

> But last time I was told that lea instruction has larger latency than shift instruction because it uses addressing module in CPU. I am not sure it is fine to replace it.

FWIW, other compilers don't seem to do that either and emit shift instructions (you can check via https://godbolt.org/).

-------------

PR: https://git.openjdk.java.net/jdk/pull/7560


More information about the hotspot-compiler-dev mailing list