On Wed, 10 Jul 2024 06:19:52 GMT, David Holmes <dhol...@openjdk.org> wrote:

>> Though I see this is inconsistent with `Exceptions::_throw_msg_cause`
>
> Okay I think I see how the logic works. If we were going to abort we would 
> never reach `_throw_cause` as the initial `_throw` would have exited. But for 
> the `!thread->can_call_Java()` case the original `_throw` would replace the 
> intended real exception with the dummy `VM_exception()`, which is then 
> "caught" and we try to replace with a more specific exception to be thrown 
> via `throw_cause`, which will again replace whichever exception is requested 
> with the dummy `VM_exception()` - so the end result is we will throw the 
> dummy regardless of whether the cause or wrapping exception is specified. So 
> your fix here makes sense.

Great. Would you mind approving this PR as this is the only non-JVMCI file 
changed.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/20083#discussion_r1672520461

Reply via email to