RFR: 8274379: Allow process of unsafe access errors in check_special_condition_for_native_trans [v3]

Patricio Chilano Mateo pchilanomate at openjdk.java.net
Wed Oct 6 19:27:30 UTC 2021


> Hi,
> 
> 
> Please review the following patch to allow processing of unsafe access errors in check_special_condition_for_native_trans().
> 
> Today we special case unsafe access errors from other async exceptions in that we don't process them when transitioning from native back to Java. Code comments in check_special_condition_for_native_trans() mention that unsafe access errors should not be handled because that may block while creating the exception. But that should not be an issue since we can always make sure we call process_if_requested_with_exit_check() after the call to throw_unsafe_access_internal_error() to process any pending operations not already handled in a ThreadBlockInVM wrapper (today that only means suspend requests and object reallocation operations).
> 
> By removing this special treatment for unsafe access errors we can also simplify the async exception support API. For instance we can remove _async_exception_condition and simplify some of the supporting methods. I also removed the _thread_in_native case from the switch statement in check_and_handle_async_exceptions() since we never call that method in that state.
> 
> Testing by running tiers1-6 in mach5. 
> 
> Thanks,
> Patricio

Patricio Chilano Mateo has updated the pull request incrementally with one additional commit since the last revision:

  address David comments

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

Changes:
  - all: https://git.openjdk.java.net/jdk/pull/5741/files
  - new: https://git.openjdk.java.net/jdk/pull/5741/files/1dbbca98..2d4bace6

Webrevs:
 - full: https://webrevs.openjdk.java.net/?repo=jdk&pr=5741&range=02
 - incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=5741&range=01-02

  Stats: 11 lines in 3 files changed: 6 ins; 2 del; 3 mod
  Patch: https://git.openjdk.java.net/jdk/pull/5741.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/5741/head:pull/5741

PR: https://git.openjdk.java.net/jdk/pull/5741


More information about the hotspot-runtime-dev mailing list