Skip to content

Commit 916db07

Browse files
author
Yudi Zheng
committed
8335532: [JVMCI] Export VM_Version::L1_line_size in JVMCI
Reviewed-by: dnsimon
1 parent c0604fb commit 916db07

File tree

3 files changed

+14
-0
lines changed

3 files changed

+14
-0
lines changed

src/hotspot/share/jvmci/jvmciCompilerToVM.hpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,10 @@ class CompilerToVM {
108108
static int sizeof_ZStoreBarrierEntry;
109109
#endif
110110

111+
#ifdef X86
112+
static int L1_line_size;
113+
#endif
114+
111115
static address dsin;
112116
static address dcos;
113117
static address dtan;

src/hotspot/share/jvmci/jvmciCompilerToVMInit.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,10 @@ int CompilerToVM::Data::_fields_annotations_base_offset;
114114
CardTable::CardValue* CompilerToVM::Data::cardtable_start_address;
115115
int CompilerToVM::Data::cardtable_shift;
116116

117+
#ifdef X86
118+
int CompilerToVM::Data::L1_line_size;
119+
#endif
120+
117121
size_t CompilerToVM::Data::vm_page_size;
118122

119123
int CompilerToVM::Data::sizeof_vtableEntry = sizeof(vtableEntry);
@@ -240,6 +244,10 @@ void CompilerToVM::Data::initialize(JVMCI_TRAPS) {
240244
cardtable_shift = 0;
241245
}
242246

247+
#ifdef X86
248+
L1_line_size = VM_Version::L1_line_size();
249+
#endif
250+
243251
vm_page_size = os::vm_page_size();
244252

245253
#define SET_TRIGFUNC(name) \

src/hotspot/share/jvmci/vmStructs_jvmci.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,8 @@
112112
static_field(CompilerToVM::Data, cardtable_start_address, CardTable::CardValue*) \
113113
static_field(CompilerToVM::Data, cardtable_shift, int) \
114114
\
115+
X86_ONLY(static_field(CompilerToVM::Data, L1_line_size, int)) \
116+
\
115117
static_field(CompilerToVM::Data, vm_page_size, size_t) \
116118
\
117119
static_field(CompilerToVM::Data, sizeof_vtableEntry, int) \

0 commit comments

Comments
 (0)