Skip to content
Browse files
8264016: [JVMCI] add some thread local fields for use by JVMCI
Reviewed-by: dholmes, iklam, coleenp
  • Loading branch information
Tom Rodriguez committed Mar 30, 2021
1 parent 8cf1c62 commit 182b11c31aa1d697ed254042c3350330ca3ac6e4
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 0 deletions.
@@ -182,6 +182,9 @@
nonstatic_field(JavaThread, _pending_failed_speculation, jlong) \
nonstatic_field(JavaThread, _pending_transfer_to_interpreter, bool) \
nonstatic_field(JavaThread, _jvmci_counters, jlong*) \
nonstatic_field(JavaThread, _jvmci_reserved0, intptr_t*) \
nonstatic_field(JavaThread, _jvmci_reserved1, intptr_t*) \
nonstatic_field(JavaThread, _jvmci_reserved_oop0, oop) \
nonstatic_field(JavaThread, _should_post_on_exceptions_flag, int) \
nonstatic_field(JavaThread, _jni_environment, JNIEnv) \
nonstatic_field(JavaThread, _stack_overflow_state._reserved_stack_activation, address) \
@@ -1202,6 +1202,9 @@ JavaThread::JavaThread() :

@@ -2310,6 +2313,9 @@ void JavaThread::oops_do_no_frames(OopClosure* f, CodeBlobClosure* cf) {
f->do_oop((oop*) &_vm_result);
f->do_oop((oop*) &_exception_oop);
f->do_oop((oop*) &_pending_async_exception);
f->do_oop((oop*) &_jvmci_reserved_oop0);

if (jvmti_thread_state() != NULL) {
jvmti_thread_state()->oops_do(f, cf);
@@ -1024,6 +1024,11 @@ class JavaThread: public Thread {
// Support for high precision, thread sensitive counters in JVMCI compiled code.
jlong* _jvmci_counters;

// Fast thread locals for use by JVMCI
intptr_t* _jvmci_reserved0;
intptr_t* _jvmci_reserved1;
oop _jvmci_reserved_oop0;

static jlong* _jvmci_old_thread_counters;
static void collect_counters(jlong* array, int length);

1 comment on commit 182b11c

Copy link

@openjdk-notifier openjdk-notifier bot commented on 182b11c Mar 30, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.