RFR: 8365991: AArch64: Ignore BlockZeroingLowLimit when UseBlockZeroing is false [v7]

Patrick Zhang qpzhang at openjdk.org
Mon Dec 15 11:20:44 UTC 2025


On Mon, 15 Dec 2025 11:15:14 GMT, Patrick Zhang <qpzhang at openjdk.org> wrote:

>> [PR 4919](https://github.com/openjdk/jdk/pull/4919/files#diff-0f4150a9c607ccd590bf256daa800c0276144682a92bc6bdced5e8bc1bb81f3aL4737) for [8270947: AArch64: C1: use zero_words to initialize all objects](https://bugs.openjdk.org/browse/JDK-8270947) changed the loop unroll length from 4 STPs (clearing 8 words) to 8 STPs (clearing 16 words) within the loop. In fact, before that PR, it seems the value 16 was from the `SmallArraySize` (`18 * BytesPerLong`).
>> 
>> For the current code snippet, I think, using `2 * WordSize` to the constant is not ideal, as it suggests the size of the unroll length and can be confusing. A better choice might be `2 * MacroAssembler::zero_words_block_size`, which more accurately reflects the intended meaning. Is this acceptable?
>
> Please see the latest commit. I renamed the var name to `unroll_words` in `address MacroAssembler::zero_words(Register base, uint64_t cnt)` and `address generate_zero_blocks()` and have them aligned, one for 16 words and the other for 8 words to do unrolling for block clearing.

Resolved this on the old code. Any further comments, please feel free to reopen.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/26917#discussion_r2618994635


More information about the hotspot-dev mailing list