RFR: 8330185: Potential uncaught unsafe memory copy exception
Vladimir Kozlov
kvn at openjdk.org
Fri Apr 12 22:21:51 UTC 2024
On Fri, 12 Apr 2024 20:00:35 GMT, Scott Gibbons <sgibbons at openjdk.org> wrote:
> Adding an `UnsafeCopyMemoryMark` in `generate_disjoint_copy_avx3_masked()` to protect against SIGBUS in `arraycopy_avx3_large()`. I discovered this by code inspection, and the missing memory mark is inconsistent with all other generators. I do not have a testcase to generate such an exception. I think this may have been a copy/paste error by the original contributor as evidenced by the variable `ucme_exit_pc` having been set but never used.
>
> I have not seen a VM crash that can be attributed to this, but adding the mark is the correct behavior for its prevention.
Yes, it looks like it was oversight during these two avx512 arraycopy methods implementation: [#61](https://github.com/openjdk/jdk/pull/61)
-------------
PR Comment: https://git.openjdk.org/jdk/pull/18766#issuecomment-2052631928
More information about the hotspot-compiler-dev
mailing list