8309878: Reduce inclusion of resolvedIndyEntry.hpp
Reviewed-by: coleenp, sspitsyn, matsaave
This commit is contained in:
parent
8aad881e80
commit
5d193193a3
@ -36,6 +36,7 @@
|
||||
#include "oops/markWord.hpp"
|
||||
#include "oops/method.hpp"
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "runtime/basicLock.hpp"
|
||||
|
@ -40,6 +40,7 @@
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/method.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "runtime/arguments.hpp"
|
||||
|
@ -38,6 +38,7 @@
|
||||
#include "oops/method.hpp"
|
||||
#include "oops/objArrayKlass.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
#include "runtime/frame.inline.hpp"
|
||||
|
@ -37,6 +37,7 @@
|
||||
#include "oops/markWord.hpp"
|
||||
#include "oops/method.hpp"
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "runtime/basicLock.hpp"
|
||||
|
@ -36,6 +36,7 @@
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/method.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
|
@ -37,6 +37,7 @@
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/objArrayKlass.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
#include "runtime/frame.inline.hpp"
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include "interp_masm_ppc.hpp"
|
||||
#include "interpreter/interpreterRuntime.hpp"
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "runtime/frame.inline.hpp"
|
||||
|
@ -38,6 +38,7 @@
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/method.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "runtime/arguments.hpp"
|
||||
|
@ -38,6 +38,7 @@
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/objArrayKlass.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
#include "runtime/frame.inline.hpp"
|
||||
|
@ -36,6 +36,7 @@
|
||||
#include "oops/markWord.hpp"
|
||||
#include "oops/method.hpp"
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "runtime/basicLock.hpp"
|
||||
|
@ -40,6 +40,7 @@
|
||||
#include "oops/method.hpp"
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "runtime/arguments.hpp"
|
||||
|
@ -38,6 +38,7 @@
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/objArrayKlass.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
#include "runtime/frame.inline.hpp"
|
||||
|
@ -35,6 +35,7 @@
|
||||
#include "oops/arrayOop.hpp"
|
||||
#include "oops/markWord.hpp"
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "runtime/basicLock.hpp"
|
||||
|
@ -38,6 +38,7 @@
|
||||
#include "oops/arrayOop.hpp"
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "runtime/arguments.hpp"
|
||||
|
@ -37,6 +37,7 @@
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/objArrayKlass.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
#include "runtime/frame.inline.hpp"
|
||||
|
@ -32,6 +32,7 @@
|
||||
#include "oops/markWord.hpp"
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/method.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "runtime/basicLock.hpp"
|
||||
|
@ -38,6 +38,7 @@
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/method.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
#include "runtime/continuation.hpp"
|
||||
|
@ -36,6 +36,7 @@
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/objArrayKlass.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
#include "runtime/frame.inline.hpp"
|
||||
|
@ -43,7 +43,7 @@
|
||||
#include "logging/log.hpp"
|
||||
#include "logging/logTag.hpp"
|
||||
#include "memory/resourceArea.hpp"
|
||||
#include "oops/constantPool.hpp"
|
||||
#include "oops/constantPool.inline.hpp"
|
||||
#include "runtime/atomic.hpp"
|
||||
#include "runtime/handles.inline.hpp"
|
||||
#include "runtime/java.hpp"
|
||||
|
@ -64,6 +64,7 @@
|
||||
#include "oops/objArrayKlass.hpp"
|
||||
#include "oops/objArrayOop.inline.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "oops/symbolHandle.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
|
@ -39,12 +39,13 @@
|
||||
#include "memory/allocation.inline.hpp"
|
||||
#include "memory/oopFactory.hpp"
|
||||
#include "memory/resourceArea.hpp"
|
||||
#include "oops/constantPool.hpp"
|
||||
#include "oops/constantPool.inline.hpp"
|
||||
#include "oops/cpCache.inline.hpp"
|
||||
#include "oops/fieldStreams.inline.hpp"
|
||||
#include "oops/klass.inline.hpp"
|
||||
#include "oops/method.inline.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
#include "runtime/fieldDescriptor.inline.hpp"
|
||||
|
@ -36,7 +36,7 @@
|
||||
#include "memory/allocation.inline.hpp"
|
||||
#include "memory/resourceArea.hpp"
|
||||
#include "oops/arrayOop.hpp"
|
||||
#include "oops/constantPool.hpp"
|
||||
#include "oops/constantPool.inline.hpp"
|
||||
#include "oops/cpCache.inline.hpp"
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/method.inline.hpp"
|
||||
|
@ -34,8 +34,10 @@
|
||||
#include "logging/logStream.hpp"
|
||||
#include "memory/oopFactory.hpp"
|
||||
#include "memory/resourceArea.hpp"
|
||||
#include "oops/constantPool.inline.hpp"
|
||||
#include "oops/cpCache.inline.hpp"
|
||||
#include "oops/objArrayOop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "oops/typeArrayOop.inline.hpp"
|
||||
#include "runtime/handles.inline.hpp"
|
||||
#include "runtime/javaThread.hpp"
|
||||
|
@ -32,6 +32,7 @@
|
||||
#include "utilities/bytes.hpp"
|
||||
|
||||
class ciBytecodeStream;
|
||||
class ResolvedIndyEntry;
|
||||
|
||||
// The base class for different kinds of bytecode abstractions.
|
||||
// Provides the primitive operations to manipulate code relative
|
||||
|
@ -35,6 +35,7 @@
|
||||
#include "oops/constantPool.inline.hpp"
|
||||
#include "oops/methodData.hpp"
|
||||
#include "oops/method.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "runtime/handles.inline.hpp"
|
||||
#include "runtime/mutexLocker.hpp"
|
||||
#include "runtime/osThread.hpp"
|
||||
|
@ -40,7 +40,7 @@
|
||||
#include "logging/log.hpp"
|
||||
#include "logging/logStream.hpp"
|
||||
#include "memory/resourceArea.hpp"
|
||||
#include "oops/constantPool.hpp"
|
||||
#include "oops/constantPool.inline.hpp"
|
||||
#include "oops/cpCache.inline.hpp"
|
||||
#include "oops/instanceKlass.inline.hpp"
|
||||
#include "oops/klass.inline.hpp"
|
||||
@ -48,6 +48,7 @@
|
||||
#include "oops/objArrayKlass.hpp"
|
||||
#include "oops/objArrayOop.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "oops/symbolHandle.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
#include "runtime/fieldDescriptor.inline.hpp"
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include "memory/metadataFactory.hpp"
|
||||
#include "memory/resourceArea.hpp"
|
||||
#include "oops/generateOopMap.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
#include "runtime/arguments.hpp"
|
||||
#include "runtime/fieldDescriptor.inline.hpp"
|
||||
|
@ -45,6 +45,7 @@
|
||||
#include "oops/objArrayKlass.hpp"
|
||||
#include "oops/objArrayOop.inline.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "oops/typeArrayOop.inline.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "prims/jvmtiThreadState.hpp"
|
||||
|
@ -259,9 +259,7 @@ class ConstantPool : public Metadata {
|
||||
// Given the per-instruction index of an indy instruction, report the
|
||||
// main constant pool entry for its bootstrap specifier.
|
||||
// From there, uncached_name/signature_ref_at will get the name/type.
|
||||
u2 invokedynamic_bootstrap_ref_index_at(int indy_index) const {
|
||||
return cache()->resolved_indy_entry_at(decode_invokedynamic_index(indy_index))->constant_pool_index();
|
||||
}
|
||||
inline u2 invokedynamic_bootstrap_ref_index_at(int indy_index) const;
|
||||
|
||||
// Assembly code support
|
||||
static ByteSize tags_offset() { return byte_offset_of(ConstantPool, _tags); }
|
||||
@ -922,15 +920,9 @@ class ConstantPool : public Metadata {
|
||||
const char* internal_name() const { return "{constant pool}"; }
|
||||
|
||||
// ResolvedIndyEntry getters
|
||||
ResolvedIndyEntry* resolved_indy_entry_at(int index) {
|
||||
return cache()->resolved_indy_entry_at(index);
|
||||
}
|
||||
int resolved_indy_entries_length() {
|
||||
return cache()->resolved_indy_entries_length();
|
||||
}
|
||||
oop resolved_reference_from_indy(int index) {
|
||||
return resolved_references()->obj_at(cache()->resolved_indy_entry_at(index)->resolved_references_index());
|
||||
}
|
||||
inline ResolvedIndyEntry* resolved_indy_entry_at(int index);
|
||||
inline int resolved_indy_entries_length() const;
|
||||
inline oop resolved_reference_from_indy(int index) const;
|
||||
};
|
||||
|
||||
#endif // SHARE_OOPS_CONSTANTPOOL_HPP
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2018, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2018, 2023, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -28,6 +28,7 @@
|
||||
#include "oops/constantPool.hpp"
|
||||
|
||||
#include "oops/cpCache.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "runtime/atomic.hpp"
|
||||
|
||||
inline Klass* ConstantPool::resolved_klass_at(int which) const { // Used by Compiler
|
||||
@ -41,4 +42,19 @@ inline Klass* ConstantPool::resolved_klass_at(int which) const { // Used by Com
|
||||
return Atomic::load_acquire(adr);
|
||||
}
|
||||
|
||||
inline u2 ConstantPool::invokedynamic_bootstrap_ref_index_at(int indy_index) const {
|
||||
return cache()->resolved_indy_entry_at(decode_invokedynamic_index(indy_index))->constant_pool_index();
|
||||
}
|
||||
|
||||
inline ResolvedIndyEntry* ConstantPool::resolved_indy_entry_at(int index) {
|
||||
return cache()->resolved_indy_entry_at(index);
|
||||
}
|
||||
|
||||
inline int ConstantPool::resolved_indy_entries_length() const {
|
||||
return cache()->resolved_indy_entries_length();
|
||||
}
|
||||
|
||||
inline oop ConstantPool::resolved_reference_from_indy(int index) const {
|
||||
return resolved_references()->obj_at(cache()->resolved_indy_entry_at(index)->resolved_references_index());
|
||||
}
|
||||
#endif // SHARE_OOPS_CONSTANTPOOL_INLINE_HPP
|
||||
|
@ -46,6 +46,7 @@
|
||||
#include "oops/cpCache.inline.hpp"
|
||||
#include "oops/objArrayOop.inline.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "prims/methodHandles.hpp"
|
||||
#include "runtime/arguments.hpp"
|
||||
#include "runtime/atomic.hpp"
|
||||
@ -941,6 +942,12 @@ void ConstantPoolCache::print_value_on(outputStream* st) const {
|
||||
}
|
||||
|
||||
|
||||
void ConstantPoolCache::print_resolved_indy_entries(outputStream* st) const {
|
||||
for (int i = 0; i < _resolved_indy_entries->length(); i++) {
|
||||
_resolved_indy_entries->at(i).print_on(st);
|
||||
}
|
||||
}
|
||||
|
||||
// Verification
|
||||
|
||||
void ConstantPoolCache::verify_on(outputStream* st) {
|
||||
|
@ -29,7 +29,6 @@
|
||||
#include "memory/allocation.hpp"
|
||||
#include "oops/array.hpp"
|
||||
#include "oops/oopHandle.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "runtime/handles.hpp"
|
||||
#include "utilities/align.hpp"
|
||||
#include "utilities/constantTag.hpp"
|
||||
@ -129,6 +128,7 @@
|
||||
// source code. The _indices field with the bytecode must be written last.
|
||||
|
||||
class CallInfo;
|
||||
class ResolvedIndyEntry;
|
||||
|
||||
class ConstantPoolCacheEntry {
|
||||
friend class VMStructs;
|
||||
@ -443,13 +443,9 @@ class ConstantPoolCache: public MetaspaceObj {
|
||||
void set_reference_map(Array<u2>* o) { _reference_map = o; }
|
||||
|
||||
Array<ResolvedIndyEntry>* resolved_indy_entries() { return _resolved_indy_entries; }
|
||||
ResolvedIndyEntry* resolved_indy_entry_at(int index) const { return _resolved_indy_entries->adr_at(index); }
|
||||
int resolved_indy_entries_length() const { return _resolved_indy_entries->length(); }
|
||||
void print_resolved_indy_entries(outputStream* st) const {
|
||||
for (int i = 0; i < _resolved_indy_entries->length(); i++) {
|
||||
_resolved_indy_entries->at(i).print_on(st);
|
||||
}
|
||||
}
|
||||
inline ResolvedIndyEntry* resolved_indy_entry_at(int index) const;
|
||||
inline int resolved_indy_entries_length() const;
|
||||
void print_resolved_indy_entries(outputStream* st) const;
|
||||
|
||||
// Assembly code support
|
||||
static ByteSize resolved_references_offset() { return byte_offset_of(ConstantPoolCache, _resolved_references); }
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include "oops/cpCache.hpp"
|
||||
|
||||
#include "oops/oopHandle.inline.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "runtime/atomic.hpp"
|
||||
|
||||
inline intx ConstantPoolCacheEntry::indices_ord() const { return Atomic::load_acquire(&_indices); }
|
||||
@ -106,4 +107,11 @@ inline objArrayOop ConstantPoolCache::resolved_references() {
|
||||
return (objArrayOop)obj;
|
||||
}
|
||||
|
||||
inline ResolvedIndyEntry* ConstantPoolCache::resolved_indy_entry_at(int index) const {
|
||||
return _resolved_indy_entries->adr_at(index);
|
||||
}
|
||||
|
||||
inline int ConstantPoolCache::resolved_indy_entries_length() const {
|
||||
return _resolved_indy_entries->length();
|
||||
}
|
||||
#endif // SHARE_OOPS_CPCACHE_INLINE_HPP
|
||||
|
@ -26,6 +26,7 @@
|
||||
#include "classfile/symbolTable.hpp"
|
||||
#include "interpreter/bytecodeStream.hpp"
|
||||
#include "memory/universe.hpp"
|
||||
#include "oops/constantPool.inline.hpp"
|
||||
#include "oops/fieldStreams.inline.hpp"
|
||||
#include "oops/instanceKlass.inline.hpp"
|
||||
#include "oops/recordComponent.hpp"
|
||||
|
@ -83,6 +83,7 @@
|
||||
#include "oops/objArrayOop.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "oops/oopHandle.hpp"
|
||||
#include "oops/resolvedIndyEntry.hpp"
|
||||
#include "oops/symbol.hpp"
|
||||
#include "oops/typeArrayKlass.hpp"
|
||||
#include "oops/typeArrayOop.hpp"
|
||||
|
Loading…
Reference in New Issue
Block a user