RFR: 8338912: CDS: Segmented roots array [v5]

Aleksey Shipilev shade at openjdk.org
Tue Sep 10 09:20:08 UTC 2024


On Tue, 10 Sep 2024 09:01:34 GMT, Ioi Lam <iklam at openjdk.org> wrote:

> `segments` is passed in by value on the stack. Apparently VC++ will not zero-out the unused bits when pushing `segments` onto the stack, but will insist copying the unused bits when doing the assignment.
>
> Maybe you can add overload the assignment operator to copy the fields individually. This will stop VC++ from copying the garbage, so it will leave the unused slot in its original (zeroed) state.

Hrmpf. I thought implicit copy constructors do this right. Apparently not. Let me try and define the explicit copy constructor...

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

PR Comment: https://git.openjdk.org/jdk/pull/20858#issuecomment-2340119087


More information about the hotspot-runtime-dev mailing list