Integrated: 8311932: Suboptimal compiled code of nested loop over memory segment

Roland Westrelin roland at openjdk.org
Fri Nov 17 07:57:44 UTC 2023


On Tue, 14 Nov 2023 09:03:56 GMT, Roland Westrelin <roland at openjdk.org> wrote:

> To enable the elimination of long range checks, the loop that contains
> the range checks is transformed into a loop nest and the range checks
> are changed to operate on int values computed before the loop is
> entered. This causes extra overhead out of loop and once, the range
> checks are eliminated, can only pay off if the loop is executed for
> long enough. This change disable the transformation if the trip count
> computed from profile data is too low. This came up with a
> MemorySegment API micro benchmarks and improves performance
> significantly.

This pull request has now been integrated.

Changeset: 129c4708
Author:    Roland Westrelin <roland at openjdk.org>
URL:       https://git.openjdk.org/jdk/commit/129c4708b428bd98c5e8b1f43819bc31c3c9cb0b
Stats:     80 lines in 2 files changed: 76 ins; 0 del; 4 mod

8311932: Suboptimal compiled code of nested loop over memory segment

Reviewed-by: thartmann, chagedorn

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

PR: https://git.openjdk.org/jdk/pull/16650


More information about the hotspot-compiler-dev mailing list