RFR: 8313796: AsyncGetCallTrace crash on unreadable interpreter method pointer [v2]

Richard Startin duke at openjdk.org
Mon Aug 7 21:15:30 UTC 2023


On Mon, 7 Aug 2023 20:54:45 GMT, Andrei Pangin <apangin at openjdk.org> wrote:

>> Richard Startin has refreshed the contents of this pull request, and previous commits have been removed. The incremental views will show differences compared to the previous content of the PR. The pull request contains one new commit since the last revision:
>> 
>>   JDK-8313796: AsyncGetCallTrace crash on unreadable interpreter method pointer
>
> src/hotspot/cpu/aarch64/frame_aarch64.cpp line 511:
> 
>> 509:   // first the method
>> 510:   Method** m_addr = interpreter_frame_method_addr();
>> 511:   if (m_addr == nullptr || !os::is_readable_pointer(m_addr)) {
> 
> Just wondering, why checking `is_readable_pointer` + dereference instead of `SafeFetch` which does both in one shot? Especially since `os::is_readable_pointer` is implemented with `SafeFetch` anyway.

Thanks for the question. I've just removed the `is_readable_pointer` check since it's not necessary. We only observed a null pointer so the null check is sufficient.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/15178#discussion_r1286387497


More information about the hotspot-dev mailing list