[foreign-memaccess+abi] RFR: 8267989: Exceptions thrown during upcalls should be handled [v2]

Jorn Vernee jvernee at openjdk.java.net
Mon May 31 18:43:18 UTC 2021


On Mon, 31 May 2021 17:58:49 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:

>> Jorn Vernee has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Address review comments:
>>   - tweak documentation
>>   - remove system property
>>   - simplify test & check stderr for stack trace message
>
> src/jdk.incubator.foreign/share/classes/jdk/incubator/foreign/CLinker.java line 239:
> 
>> 237:      * the corresponding native stub will be deallocated.
>> 238:      * <p>
>> 239:      * Any exceptions that occur during an upcall should be handled during the upcall. The target method handle
> 
> I think it is best to drop the first sentence, and go straight to the point, which is "The target method handle shoud not...".
> 
> Which reminds me, do we want to apply same logic we do for var handle combinators to detect if a method handle contains exceptions in its guts (by looking at signature of direct MH, or by looking for certain combinators).

Dropped the first sentence, I'll see about adding a check for exceptions.

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

PR: https://git.openjdk.java.net/panama-foreign/pull/543


More information about the panama-dev mailing list