RFR: 8319115: GrowableArray: Do not initialize up to capacity
Thomas Stuefe
stuefe at openjdk.org
Mon Oct 30 15:11:34 UTC 2023
On Mon, 30 Oct 2023 14:49:25 GMT, Johan Sjölen <jsjolen at openjdk.org> wrote:
> Hi,
>
> There's no reason to initialize the memory for the elements in the range `[_len, _capacity)` on resize, so let's not do it.
>
> Currently running testing tier1-3.
Makes sense, but it may make sense to poison them in debug builds (we poison in os::realloc, but only if NMT is enabled).
-------------
PR Comment: https://git.openjdk.org/jdk/pull/16418#issuecomment-1785425811
More information about the hotspot-dev
mailing list