Integrated: 8275286: Check current thread when calling JRT methods that expect it

Aleksey Shipilev shade at openjdk.java.net
Fri Oct 15 11:18:52 UTC 2021


On Thu, 14 Oct 2021 13:49:11 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:

> I found this oddity when porting Loom to x86_32. There are JRT entries that have `JavaThread* current` in their signature, and I believe that sets the expectation that JRT entry is to be called with the current thread as the argument. But, that is not mechanically checked, unless we call into some other class like `ThreadInVMfromJava`, etc. To simplify debugging, we should check current thread explicitly.
> 
> Additional testing:
>  - [x] Linux x86_64 fastdebug `tier1`
>  - [x] Linux x86_64 fastdebug `tier2`

This pull request has now been integrated.

Changeset: ced79091
Author:    Aleksey Shipilev <shade at openjdk.org>
URL:       https://git.openjdk.java.net/jdk/commit/ced79091f6ce1791f33c3e5e153eb0535c4d53db
Stats:     5 lines in 1 file changed: 5 ins; 0 del; 0 mod

8275286: Check current thread when calling JRT methods that expect it

Reviewed-by: zgu, coleenp, dholmes

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

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


More information about the hotspot-runtime-dev mailing list