mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 22:34:27 +02:00
8152470: Add COMPILER2_OR_JVMCI definition
Defined(COMPILER2) || INCLUDE_JVMCI changed replaced with COMPILER2_OR_JVMCI Reviewed-by: kvn
This commit is contained in:
parent
c8aacd3972
commit
10a1edcc22
33 changed files with 88 additions and 89 deletions
|
@ -431,11 +431,11 @@ frame frame::sender_for_interpreter_frame(RegisterMap* map) const {
|
||||||
// This is the sp before any possible extension (adapter/locals).
|
// This is the sp before any possible extension (adapter/locals).
|
||||||
intptr_t* unextended_sp = interpreter_frame_sender_sp();
|
intptr_t* unextended_sp = interpreter_frame_sender_sp();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
if (map->update_map()) {
|
if (map->update_map()) {
|
||||||
update_map_with_saved_link(map, (intptr_t**) addr_at(link_offset));
|
update_map_with_saved_link(map, (intptr_t**) addr_at(link_offset));
|
||||||
}
|
}
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
return frame(sender_sp, unextended_sp, link(), sender_pc());
|
return frame(sender_sp, unextended_sp, link(), sender_pc());
|
||||||
}
|
}
|
||||||
|
|
|
@ -41,7 +41,7 @@
|
||||||
#ifdef COMPILER1
|
#ifdef COMPILER1
|
||||||
#include "c1/c1_Runtime1.hpp"
|
#include "c1/c1_Runtime1.hpp"
|
||||||
#endif
|
#endif
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
#include "adfiles/ad_aarch64.hpp"
|
#include "adfiles/ad_aarch64.hpp"
|
||||||
#include "opto/runtime.hpp"
|
#include "opto/runtime.hpp"
|
||||||
#endif
|
#endif
|
||||||
|
@ -114,7 +114,7 @@ class RegisterSaver {
|
||||||
};
|
};
|
||||||
|
|
||||||
OopMap* RegisterSaver::save_live_registers(MacroAssembler* masm, int additional_frame_words, int* total_frame_words, bool save_vectors) {
|
OopMap* RegisterSaver::save_live_registers(MacroAssembler* masm, int additional_frame_words, int* total_frame_words, bool save_vectors) {
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
if (save_vectors) {
|
if (save_vectors) {
|
||||||
// Save upper half of vector registers
|
// Save upper half of vector registers
|
||||||
int vect_words = 32 * 8 / wordSize;
|
int vect_words = 32 * 8 / wordSize;
|
||||||
|
@ -2688,7 +2688,7 @@ uint SharedRuntime::out_preserve_stack_slots() {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
//------------------------------generate_uncommon_trap_blob--------------------
|
//------------------------------generate_uncommon_trap_blob--------------------
|
||||||
void SharedRuntime::generate_uncommon_trap_blob() {
|
void SharedRuntime::generate_uncommon_trap_blob() {
|
||||||
// Allocate space for the code
|
// Allocate space for the code
|
||||||
|
@ -2894,7 +2894,7 @@ void SharedRuntime::generate_uncommon_trap_blob() {
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
#endif // COMPILER2
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
|
|
||||||
//------------------------------generate_handler_blob------
|
//------------------------------generate_handler_blob------
|
||||||
|
@ -3070,8 +3070,7 @@ RuntimeStub* SharedRuntime::generate_resolve_blob(address destination, const cha
|
||||||
return RuntimeStub::new_runtime_stub(name, &buffer, frame_complete, frame_size_in_words, oop_maps, true);
|
return RuntimeStub::new_runtime_stub(name, &buffer, frame_complete, frame_size_in_words, oop_maps, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if COMPILER2_OR_JVMCI
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
|
||||||
// This is here instead of runtime_x86_64.cpp because it uses SimpleRuntimeFrame
|
// This is here instead of runtime_x86_64.cpp because it uses SimpleRuntimeFrame
|
||||||
//
|
//
|
||||||
//------------------------------generate_exception_blob---------------------------
|
//------------------------------generate_exception_blob---------------------------
|
||||||
|
@ -3200,4 +3199,4 @@ void OptoRuntime::generate_exception_blob() {
|
||||||
// Set exception blob
|
// Set exception blob
|
||||||
_exception_blob = ExceptionBlob::create(&buffer, oop_maps, SimpleRuntimeFrame::framesize >> 1);
|
_exception_blob = ExceptionBlob::create(&buffer, oop_maps, SimpleRuntimeFrame::framesize >> 1);
|
||||||
}
|
}
|
||||||
#endif // COMPILER2
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
|
@ -33,7 +33,7 @@
|
||||||
#include "runtime/safepoint.hpp"
|
#include "runtime/safepoint.hpp"
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
#define __ _masm.
|
#define __ _masm.
|
||||||
// emit call stub, compiled java to interpreter
|
// emit call stub, compiled java to interpreter
|
||||||
address CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf, address mark) {
|
address CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf, address mark) {
|
||||||
|
@ -89,7 +89,7 @@ address CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf, address mark)
|
||||||
int CompiledStaticCall::reloc_to_interp_stub() {
|
int CompiledStaticCall::reloc_to_interp_stub() {
|
||||||
return 10; // 4 in emit_to_interp_stub + 1 in Java_Static_Call
|
return 10; // 4 in emit_to_interp_stub + 1 in Java_Static_Call
|
||||||
}
|
}
|
||||||
#endif // COMPILER2 || JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
// size of C2 call stub, compiled java to interpretor
|
// size of C2 call stub, compiled java to interpretor
|
||||||
int CompiledStaticCall::to_interp_stub_size() {
|
int CompiledStaticCall::to_interp_stub_size() {
|
||||||
|
|
|
@ -436,11 +436,11 @@ frame frame::sender_for_interpreter_frame(RegisterMap* map) const {
|
||||||
// This is the sp before any possible extension (adapter/locals).
|
// This is the sp before any possible extension (adapter/locals).
|
||||||
intptr_t* unextended_sp = interpreter_frame_sender_sp();
|
intptr_t* unextended_sp = interpreter_frame_sender_sp();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
if (map->update_map()) {
|
if (map->update_map()) {
|
||||||
update_map_with_saved_link(map, (intptr_t**) addr_at(link_offset));
|
update_map_with_saved_link(map, (intptr_t**) addr_at(link_offset));
|
||||||
}
|
}
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
return frame(sender_sp, unextended_sp, link(), sender_pc());
|
return frame(sender_sp, unextended_sp, link(), sender_pc());
|
||||||
}
|
}
|
||||||
|
|
|
@ -46,11 +46,11 @@ define_pd_global(uintx, CodeCacheSegmentSize, 64 TIERED_ONLY(+64)); // Tiered
|
||||||
// the the vep is aligned at CodeEntryAlignment whereas c2 only aligns
|
// the the vep is aligned at CodeEntryAlignment whereas c2 only aligns
|
||||||
// the uep and the vep doesn't get real alignment but just slops on by
|
// the uep and the vep doesn't get real alignment but just slops on by
|
||||||
// only assured that the entry instruction meets the 5 byte size requirement.
|
// only assured that the entry instruction meets the 5 byte size requirement.
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
define_pd_global(intx, CodeEntryAlignment, 32);
|
define_pd_global(intx, CodeEntryAlignment, 32);
|
||||||
#else
|
#else
|
||||||
define_pd_global(intx, CodeEntryAlignment, 16);
|
define_pd_global(intx, CodeEntryAlignment, 16);
|
||||||
#endif // COMPILER2
|
#endif // COMPILER2_OR_JVMCI
|
||||||
define_pd_global(intx, OptoLoopAlignment, 16);
|
define_pd_global(intx, OptoLoopAlignment, 16);
|
||||||
define_pd_global(intx, InlineFrequencyCount, 100);
|
define_pd_global(intx, InlineFrequencyCount, 100);
|
||||||
define_pd_global(intx, InlineSmallCode, 1000);
|
define_pd_global(intx, InlineSmallCode, 1000);
|
||||||
|
|
|
@ -151,7 +151,7 @@ OopMap* RegisterSaver::save_live_registers(MacroAssembler* masm, int additional_
|
||||||
if (UseAVX < 3) {
|
if (UseAVX < 3) {
|
||||||
num_xmm_regs = num_xmm_regs/2;
|
num_xmm_regs = num_xmm_regs/2;
|
||||||
}
|
}
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
if (save_vectors) {
|
if (save_vectors) {
|
||||||
assert(UseAVX > 0, "Vectors larger than 16 byte long are supported only with AVX");
|
assert(UseAVX > 0, "Vectors larger than 16 byte long are supported only with AVX");
|
||||||
assert(MaxVectorSize <= 64, "Only up to 64 byte long vectors are supported");
|
assert(MaxVectorSize <= 64, "Only up to 64 byte long vectors are supported");
|
||||||
|
@ -260,7 +260,7 @@ OopMap* RegisterSaver::save_live_registers(MacroAssembler* masm, int additional_
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
if (save_vectors) {
|
if (save_vectors) {
|
||||||
off = ymm0_off;
|
off = ymm0_off;
|
||||||
int delta = ymm1_off - off;
|
int delta = ymm1_off - off;
|
||||||
|
@ -270,7 +270,7 @@ OopMap* RegisterSaver::save_live_registers(MacroAssembler* masm, int additional_
|
||||||
off += delta;
|
off += delta;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
// %%% These should all be a waste but we'll keep things as they were for now
|
// %%% These should all be a waste but we'll keep things as they were for now
|
||||||
if (true) {
|
if (true) {
|
||||||
|
@ -323,7 +323,7 @@ void RegisterSaver::restore_live_registers(MacroAssembler* masm, bool restore_ve
|
||||||
__ addptr(rsp, frame::arg_reg_save_area_bytes);
|
__ addptr(rsp, frame::arg_reg_save_area_bytes);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
if (restore_vectors) {
|
if (restore_vectors) {
|
||||||
assert(UseAVX > 0, "Vectors larger than 16 byte long are supported only with AVX");
|
assert(UseAVX > 0, "Vectors larger than 16 byte long are supported only with AVX");
|
||||||
assert(MaxVectorSize <= 64, "Only up to 64 byte long vectors are supported");
|
assert(MaxVectorSize <= 64, "Only up to 64 byte long vectors are supported");
|
||||||
|
|
|
@ -944,7 +944,7 @@ void VM_Version::get_processor_features() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
if (MaxVectorSize > 0) {
|
if (MaxVectorSize > 0) {
|
||||||
if (!is_power_of_2(MaxVectorSize)) {
|
if (!is_power_of_2(MaxVectorSize)) {
|
||||||
warning("MaxVectorSize must be a power of 2");
|
warning("MaxVectorSize must be a power of 2");
|
||||||
|
@ -996,7 +996,7 @@ void VM_Version::get_processor_features() {
|
||||||
}
|
}
|
||||||
#endif // COMPILER2 && ASSERT
|
#endif // COMPILER2 && ASSERT
|
||||||
}
|
}
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
#ifdef COMPILER2
|
#ifdef COMPILER2
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
|
|
|
@ -73,7 +73,7 @@ bool JavaThread::pd_get_top_frame(frame* fr_addr, void* ucontext, bool isInJava)
|
||||||
|
|
||||||
frame ret_frame(ret_sp, ret_fp, addr.pc());
|
frame ret_frame(ret_sp, ret_fp, addr.pc());
|
||||||
if (!ret_frame.safe_for_sender(jt)) {
|
if (!ret_frame.safe_for_sender(jt)) {
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
// C2 and JVMCI use ebp as a general register see if NULL fp helps
|
// C2 and JVMCI use ebp as a general register see if NULL fp helps
|
||||||
frame ret_frame2(ret_sp, NULL, addr.pc());
|
frame ret_frame2(ret_sp, NULL, addr.pc());
|
||||||
if (!ret_frame2.safe_for_sender(jt)) {
|
if (!ret_frame2.safe_for_sender(jt)) {
|
||||||
|
@ -84,7 +84,7 @@ bool JavaThread::pd_get_top_frame(frame* fr_addr, void* ucontext, bool isInJava)
|
||||||
#else
|
#else
|
||||||
// nothing else to try if the frame isn't good
|
// nothing else to try if the frame isn't good
|
||||||
return false;
|
return false;
|
||||||
#endif /* COMPILER2 || INCLUDE_JVMCI */
|
#endif // COMPILER2_OR_JVMCI
|
||||||
}
|
}
|
||||||
*fr_addr = ret_frame;
|
*fr_addr = ret_frame;
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -74,7 +74,7 @@ bool JavaThread::pd_get_top_frame(frame* fr_addr, void* ucontext, bool isInJava)
|
||||||
|
|
||||||
frame ret_frame(ret_sp, ret_fp, addr.pc());
|
frame ret_frame(ret_sp, ret_fp, addr.pc());
|
||||||
if (!ret_frame.safe_for_sender(jt)) {
|
if (!ret_frame.safe_for_sender(jt)) {
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
// C2 and JVMCI use ebp as a general register see if NULL fp helps
|
// C2 and JVMCI use ebp as a general register see if NULL fp helps
|
||||||
frame ret_frame2(ret_sp, NULL, addr.pc());
|
frame ret_frame2(ret_sp, NULL, addr.pc());
|
||||||
if (!ret_frame2.safe_for_sender(jt)) {
|
if (!ret_frame2.safe_for_sender(jt)) {
|
||||||
|
@ -85,7 +85,7 @@ bool JavaThread::pd_get_top_frame(frame* fr_addr, void* ucontext, bool isInJava)
|
||||||
#else
|
#else
|
||||||
// nothing else to try if the frame isn't good
|
// nothing else to try if the frame isn't good
|
||||||
return false;
|
return false;
|
||||||
#endif /* COMPILER2 || INCLUDE_JVMCI */
|
#endif // COMPILER2_OR_JVMCI
|
||||||
}
|
}
|
||||||
*fr_addr = ret_frame;
|
*fr_addr = ret_frame;
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -81,7 +81,7 @@ bool JavaThread::pd_get_top_frame(frame* fr_addr, void* ucontext, bool isInJava)
|
||||||
|
|
||||||
frame ret_frame(ret_sp, ret_fp, addr.pc());
|
frame ret_frame(ret_sp, ret_fp, addr.pc());
|
||||||
if (!ret_frame.safe_for_sender(jt)) {
|
if (!ret_frame.safe_for_sender(jt)) {
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
// C2 and JVMCI use ebp as a general register see if NULL fp helps
|
// C2 and JVMCI use ebp as a general register see if NULL fp helps
|
||||||
frame ret_frame2(ret_sp, NULL, addr.pc());
|
frame ret_frame2(ret_sp, NULL, addr.pc());
|
||||||
if (!ret_frame2.safe_for_sender(jt)) {
|
if (!ret_frame2.safe_for_sender(jt)) {
|
||||||
|
@ -92,7 +92,7 @@ bool JavaThread::pd_get_top_frame(frame* fr_addr, void* ucontext, bool isInJava)
|
||||||
#else
|
#else
|
||||||
// nothing else to try if the frame isn't good
|
// nothing else to try if the frame isn't good
|
||||||
return false;
|
return false;
|
||||||
#endif /* COMPILER2 || INCLUDE_JVMCI */
|
#endif // COMPILER2_OR_JVMCI
|
||||||
}
|
}
|
||||||
*fr_addr = ret_frame;
|
*fr_addr = ret_frame;
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -228,7 +228,7 @@ void ScopeDesc::print_on(outputStream* st, PcDesc* pd) const {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
if (NOT_JVMCI(DoEscapeAnalysis &&) is_top() && _objects != NULL) {
|
if (NOT_JVMCI(DoEscapeAnalysis &&) is_top() && _objects != NULL) {
|
||||||
st->print_cr(" Objects");
|
st->print_cr(" Objects");
|
||||||
for (int i = 0; i < _objects->length(); i++) {
|
for (int i = 0; i < _objects->length(); i++) {
|
||||||
|
@ -239,7 +239,7 @@ void ScopeDesc::print_on(outputStream* st, PcDesc* pd) const {
|
||||||
st->cr();
|
st->cr();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -268,9 +268,9 @@ static void add_derived_oop(oop* base, oop* derived) {
|
||||||
#if !defined(TIERED) && !defined(INCLUDE_JVMCI)
|
#if !defined(TIERED) && !defined(INCLUDE_JVMCI)
|
||||||
COMPILER1_PRESENT(ShouldNotReachHere();)
|
COMPILER1_PRESENT(ShouldNotReachHere();)
|
||||||
#endif // !defined(TIERED) && !defined(INCLUDE_JVMCI)
|
#endif // !defined(TIERED) && !defined(INCLUDE_JVMCI)
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTable::add(derived, base);
|
DerivedPointerTable::add(derived, base);
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -461,12 +461,12 @@ bool ImmutableOopMap::has_derived_pointer() const {
|
||||||
#if !defined(TIERED) && !defined(INCLUDE_JVMCI)
|
#if !defined(TIERED) && !defined(INCLUDE_JVMCI)
|
||||||
COMPILER1_PRESENT(return false);
|
COMPILER1_PRESENT(return false);
|
||||||
#endif // !TIERED
|
#endif // !TIERED
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
OopMapStream oms(this,OopMapValue::derived_oop_value);
|
OopMapStream oms(this,OopMapValue::derived_oop_value);
|
||||||
return oms.is_done();
|
return oms.is_done();
|
||||||
#else
|
#else
|
||||||
return false;
|
return false;
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif //PRODUCT
|
#endif //PRODUCT
|
||||||
|
@ -726,7 +726,7 @@ ImmutableOopMapSet* ImmutableOopMapSet::build_from(const OopMapSet* oopmap_set)
|
||||||
|
|
||||||
//------------------------------DerivedPointerTable---------------------------
|
//------------------------------DerivedPointerTable---------------------------
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
class DerivedPointerEntry : public CHeapObj<mtCompiler> {
|
class DerivedPointerEntry : public CHeapObj<mtCompiler> {
|
||||||
private:
|
private:
|
||||||
|
@ -819,4 +819,4 @@ void DerivedPointerTable::update_pointers() {
|
||||||
_active = false;
|
_active = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
|
@ -427,7 +427,7 @@ private:
|
||||||
// oops, it is filled in with references to all locations that contains a
|
// oops, it is filled in with references to all locations that contains a
|
||||||
// derived oop (assumed to be very few). When the GC is complete, the derived
|
// derived oop (assumed to be very few). When the GC is complete, the derived
|
||||||
// pointers are updated based on their base pointers new value and an offset.
|
// pointers are updated based on their base pointers new value and an offset.
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
class DerivedPointerTable : public AllStatic {
|
class DerivedPointerTable : public AllStatic {
|
||||||
friend class VMStructs;
|
friend class VMStructs;
|
||||||
private:
|
private:
|
||||||
|
@ -463,6 +463,6 @@ class DerivedPointerTableDeactivate: public StackObj {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
#endif // SHARE_VM_COMPILER_OOPMAP_HPP
|
#endif // SHARE_VM_COMPILER_OOPMAP_HPP
|
||||||
|
|
|
@ -2296,7 +2296,7 @@ bool CMSCollector::verify_after_remark() {
|
||||||
// way with the marking information used by GC.
|
// way with the marking information used by GC.
|
||||||
NoRefDiscovery no_discovery(ref_processor());
|
NoRefDiscovery no_discovery(ref_processor());
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTableDeactivate dpt_deact;
|
DerivedPointerTableDeactivate dpt_deact;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -2869,7 +2869,7 @@ void CMSCollector::checkpointRootsInitialWork() {
|
||||||
print_eden_and_survivor_chunk_arrays();
|
print_eden_and_survivor_chunk_arrays();
|
||||||
|
|
||||||
{
|
{
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTableDeactivate dpt_deact;
|
DerivedPointerTableDeactivate dpt_deact;
|
||||||
#endif
|
#endif
|
||||||
if (CMSParallelInitialMarkEnabled) {
|
if (CMSParallelInitialMarkEnabled) {
|
||||||
|
@ -4171,7 +4171,7 @@ void CMSCollector::checkpointRootsFinalWork() {
|
||||||
print_eden_and_survivor_chunk_arrays();
|
print_eden_and_survivor_chunk_arrays();
|
||||||
|
|
||||||
{
|
{
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTableDeactivate dpt_deact;
|
DerivedPointerTableDeactivate dpt_deact;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -2597,7 +2597,7 @@ void G1CollectedHeap::gc_epilogue(bool full) {
|
||||||
// FIXME: what is this about?
|
// FIXME: what is this about?
|
||||||
// I'm ignoring the "fill_newgen()" call if "alloc_event_enabled"
|
// I'm ignoring the "fill_newgen()" call if "alloc_event_enabled"
|
||||||
// is set.
|
// is set.
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
assert(DerivedPointerTable::is_empty(), "derived pointer present");
|
assert(DerivedPointerTable::is_empty(), "derived pointer present");
|
||||||
#endif
|
#endif
|
||||||
// always_do_update_barrier = true;
|
// always_do_update_barrier = true;
|
||||||
|
@ -3010,7 +3010,7 @@ G1CollectedHeap::do_collection_pause_at_safepoint(double target_pause_time_ms) {
|
||||||
|
|
||||||
_verifier->check_bitmaps("GC Start");
|
_verifier->check_bitmaps("GC Start");
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTable::clear();
|
DerivedPointerTable::clear();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -4439,7 +4439,7 @@ void G1CollectedHeap::post_evacuate_collection_set(EvacuationInfo& evacuation_in
|
||||||
purge_code_root_memory();
|
purge_code_root_memory();
|
||||||
|
|
||||||
redirty_logged_cards();
|
redirty_logged_cards();
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
double start = os::elapsedTime();
|
double start = os::elapsedTime();
|
||||||
DerivedPointerTable::update_pointers();
|
DerivedPointerTable::update_pointers();
|
||||||
g1_policy()->phase_times()->record_derived_pointer_table_update_time((os::elapsedTime() - start) * 1000.0);
|
g1_policy()->phase_times()->record_derived_pointer_table_update_time((os::elapsedTime() - start) * 1000.0);
|
||||||
|
|
|
@ -414,7 +414,7 @@ double G1GCPhaseTimes::print_post_evacuate_collection_set() const {
|
||||||
|
|
||||||
debug_time("Redirty Cards", _recorded_redirty_logged_cards_time_ms);
|
debug_time("Redirty Cards", _recorded_redirty_logged_cards_time_ms);
|
||||||
trace_phase(_gc_par_phases[RedirtyCards]);
|
trace_phase(_gc_par_phases[RedirtyCards]);
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
debug_time("DerivedPointerTable Update", _cur_derived_pointer_table_update_time_ms);
|
debug_time("DerivedPointerTable Update", _cur_derived_pointer_table_update_time_ms);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -62,7 +62,7 @@ void G1MarkSweep::invoke_at_safepoint(ReferenceProcessor* rp,
|
||||||
assert(SafepointSynchronize::is_at_safepoint(), "must be at a safepoint");
|
assert(SafepointSynchronize::is_at_safepoint(), "must be at a safepoint");
|
||||||
HandleMark hm; // Discard invalid handles created during gc
|
HandleMark hm; // Discard invalid handles created during gc
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTable::clear();
|
DerivedPointerTable::clear();
|
||||||
#endif
|
#endif
|
||||||
#ifdef ASSERT
|
#ifdef ASSERT
|
||||||
|
@ -96,7 +96,7 @@ void G1MarkSweep::invoke_at_safepoint(ReferenceProcessor* rp,
|
||||||
// Prepare compaction.
|
// Prepare compaction.
|
||||||
mark_sweep_phase2();
|
mark_sweep_phase2();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
// Don't add any more derived pointers during phase3
|
// Don't add any more derived pointers during phase3
|
||||||
DerivedPointerTable::set_active(false);
|
DerivedPointerTable::set_active(false);
|
||||||
#endif
|
#endif
|
||||||
|
@ -111,7 +111,7 @@ void G1MarkSweep::invoke_at_safepoint(ReferenceProcessor* rp,
|
||||||
BiasedLocking::restore_marks();
|
BiasedLocking::restore_marks();
|
||||||
GenMarkSweep::deallocate_stacks();
|
GenMarkSweep::deallocate_stacks();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
// Now update the derived pointers.
|
// Now update the derived pointers.
|
||||||
DerivedPointerTable::update_pointers();
|
DerivedPointerTable::update_pointers();
|
||||||
#endif
|
#endif
|
||||||
|
@ -204,7 +204,7 @@ void G1MarkSweep::mark_sweep_phase1(bool& marked_for_unloading,
|
||||||
|
|
||||||
if (VerifyDuringGC) {
|
if (VerifyDuringGC) {
|
||||||
HandleMark hm; // handle scope
|
HandleMark hm; // handle scope
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTableDeactivate dpt_deact;
|
DerivedPointerTableDeactivate dpt_deact;
|
||||||
#endif
|
#endif
|
||||||
g1h->prepare_for_verify();
|
g1h->prepare_for_verify();
|
||||||
|
|
|
@ -192,7 +192,7 @@ bool PSMarkSweep::invoke_no_policy(bool clear_all_softrefs) {
|
||||||
|
|
||||||
allocate_stacks();
|
allocate_stacks();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTable::clear();
|
DerivedPointerTable::clear();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -203,7 +203,7 @@ bool PSMarkSweep::invoke_no_policy(bool clear_all_softrefs) {
|
||||||
|
|
||||||
mark_sweep_phase2();
|
mark_sweep_phase2();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
// Don't add any more derived pointers during phase3
|
// Don't add any more derived pointers during phase3
|
||||||
assert(DerivedPointerTable::is_active(), "Sanity");
|
assert(DerivedPointerTable::is_active(), "Sanity");
|
||||||
DerivedPointerTable::set_active(false);
|
DerivedPointerTable::set_active(false);
|
||||||
|
@ -252,7 +252,7 @@ bool PSMarkSweep::invoke_no_policy(bool clear_all_softrefs) {
|
||||||
CodeCache::gc_epilogue();
|
CodeCache::gc_epilogue();
|
||||||
JvmtiExport::gc_epilogue();
|
JvmtiExport::gc_epilogue();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTable::update_pointers();
|
DerivedPointerTable::update_pointers();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -1032,7 +1032,7 @@ void PSParallelCompact::post_compact()
|
||||||
CodeCache::gc_epilogue();
|
CodeCache::gc_epilogue();
|
||||||
JvmtiExport::gc_epilogue();
|
JvmtiExport::gc_epilogue();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTable::update_pointers();
|
DerivedPointerTable::update_pointers();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -1783,7 +1783,7 @@ bool PSParallelCompact::invoke_no_policy(bool maximum_heap_compaction) {
|
||||||
|
|
||||||
CodeCache::gc_prologue();
|
CodeCache::gc_prologue();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTable::clear();
|
DerivedPointerTable::clear();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -1799,7 +1799,7 @@ bool PSParallelCompact::invoke_no_policy(bool maximum_heap_compaction) {
|
||||||
&& GCCause::is_user_requested_gc(gc_cause);
|
&& GCCause::is_user_requested_gc(gc_cause);
|
||||||
summary_phase(vmthread_cm, maximum_heap_compaction || max_on_system_gc);
|
summary_phase(vmthread_cm, maximum_heap_compaction || max_on_system_gc);
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
assert(DerivedPointerTable::is_active(), "Sanity");
|
assert(DerivedPointerTable::is_active(), "Sanity");
|
||||||
DerivedPointerTable::set_active(false);
|
DerivedPointerTable::set_active(false);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -331,7 +331,7 @@ bool PSScavenge::invoke_no_policy() {
|
||||||
|
|
||||||
save_to_space_top_before_gc();
|
save_to_space_top_before_gc();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTable::clear();
|
DerivedPointerTable::clear();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -601,7 +601,7 @@ bool PSScavenge::invoke_no_policy() {
|
||||||
assert(young_gen->to_space()->is_empty(), "to space should be empty now");
|
assert(young_gen->to_space()->is_empty(), "to space should be empty now");
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
DerivedPointerTable::update_pointers();
|
DerivedPointerTable::update_pointers();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -92,7 +92,7 @@ void GenMarkSweep::invoke_at_safepoint(ReferenceProcessor* rp, bool clear_all_so
|
||||||
mark_sweep_phase2();
|
mark_sweep_phase2();
|
||||||
|
|
||||||
// Don't add any more derived pointers during phase3
|
// Don't add any more derived pointers during phase3
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
assert(DerivedPointerTable::is_active(), "Sanity");
|
assert(DerivedPointerTable::is_active(), "Sanity");
|
||||||
DerivedPointerTable::set_active(false);
|
DerivedPointerTable::set_active(false);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -241,7 +241,7 @@ void CollectedHeap::set_barrier_set(BarrierSet* barrier_set) {
|
||||||
void CollectedHeap::pre_initialize() {
|
void CollectedHeap::pre_initialize() {
|
||||||
// Used for ReduceInitialCardMarks (when COMPILER2 is used);
|
// Used for ReduceInitialCardMarks (when COMPILER2 is used);
|
||||||
// otherwise remains unused.
|
// otherwise remains unused.
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
_defer_initial_card_mark = is_server_compilation_mode_vm() && ReduceInitialCardMarks && can_elide_tlab_store_barriers()
|
_defer_initial_card_mark = is_server_compilation_mode_vm() && ReduceInitialCardMarks && can_elide_tlab_store_barriers()
|
||||||
&& (DeferInitialCardMark || card_mark_must_follow_store());
|
&& (DeferInitialCardMark || card_mark_must_follow_store());
|
||||||
#else
|
#else
|
||||||
|
@ -545,7 +545,7 @@ void CollectedHeap::ensure_parsability(bool retire_tlabs) {
|
||||||
" to threads list is doomed to failure!");
|
" to threads list is doomed to failure!");
|
||||||
for (JavaThread *thread = Threads::first(); thread; thread = thread->next()) {
|
for (JavaThread *thread = Threads::first(); thread; thread = thread->next()) {
|
||||||
if (use_tlab) thread->tlab().make_parsable(retire_tlabs);
|
if (use_tlab) thread->tlab().make_parsable(retire_tlabs);
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
// The deferred store barriers must all have been flushed to the
|
// The deferred store barriers must all have been flushed to the
|
||||||
// card-table (or other remembered set structure) before GC starts
|
// card-table (or other remembered set structure) before GC starts
|
||||||
// processing the card-table (or other remembered set).
|
// processing the card-table (or other remembered set).
|
||||||
|
|
|
@ -1067,11 +1067,11 @@ class GenGCEpilogueClosure: public GenCollectedHeap::GenClosure {
|
||||||
};
|
};
|
||||||
|
|
||||||
void GenCollectedHeap::gc_epilogue(bool full) {
|
void GenCollectedHeap::gc_epilogue(bool full) {
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
assert(DerivedPointerTable::is_empty(), "derived pointer present");
|
assert(DerivedPointerTable::is_empty(), "derived pointer present");
|
||||||
size_t actual_gap = pointer_delta((HeapWord*) (max_uintx-3), *(end_addr()));
|
size_t actual_gap = pointer_delta((HeapWord*) (max_uintx-3), *(end_addr()));
|
||||||
guarantee(is_client_compilation_mode_vm() || actual_gap > (size_t)FastAllocateSizeLimit, "inline allocation wraps");
|
guarantee(is_client_compilation_mode_vm() || actual_gap > (size_t)FastAllocateSizeLimit, "inline allocation wraps");
|
||||||
#endif /* COMPILER2 || INCLUDE_JVMCI */
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
resize_all_tlabs();
|
resize_all_tlabs();
|
||||||
|
|
||||||
|
|
|
@ -271,7 +271,7 @@ class Method : public Metadata {
|
||||||
int highest_osr_comp_level() const;
|
int highest_osr_comp_level() const;
|
||||||
void set_highest_osr_comp_level(int level);
|
void set_highest_osr_comp_level(int level);
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
// Count of times method was exited via exception while interpreting
|
// Count of times method was exited via exception while interpreting
|
||||||
void interpreter_throwout_increment(TRAPS) {
|
void interpreter_throwout_increment(TRAPS) {
|
||||||
MethodCounters* mcs = get_method_counters(CHECK);
|
MethodCounters* mcs = get_method_counters(CHECK);
|
||||||
|
@ -426,7 +426,7 @@ class Method : public Metadata {
|
||||||
return (mcs == NULL) ? 0 : mcs->interpreter_invocation_count();
|
return (mcs == NULL) ? 0 : mcs->interpreter_invocation_count();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
int increment_interpreter_invocation_count(TRAPS) {
|
int increment_interpreter_invocation_count(TRAPS) {
|
||||||
if (TieredCompilation) ShouldNotReachHere();
|
if (TieredCompilation) ShouldNotReachHere();
|
||||||
MethodCounters* mcs = get_method_counters(CHECK_0);
|
MethodCounters* mcs = get_method_counters(CHECK_0);
|
||||||
|
|
|
@ -40,7 +40,7 @@ class MethodCounters : public Metadata {
|
||||||
#if INCLUDE_AOT
|
#if INCLUDE_AOT
|
||||||
Method* _method; // Back link to Method
|
Method* _method; // Back link to Method
|
||||||
#endif
|
#endif
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
int _interpreter_invocation_count; // Count of times invoked (reused as prev_event_count in tiered)
|
int _interpreter_invocation_count; // Count of times invoked (reused as prev_event_count in tiered)
|
||||||
u2 _interpreter_throwout_count; // Count of times method was exited via exception while interpreting
|
u2 _interpreter_throwout_count; // Count of times method was exited via exception while interpreting
|
||||||
#endif
|
#endif
|
||||||
|
@ -130,7 +130,7 @@ class MethodCounters : public Metadata {
|
||||||
MetaspaceObj::Type type() const { return MethodCountersType; }
|
MetaspaceObj::Type type() const { return MethodCountersType; }
|
||||||
void clear_counters();
|
void clear_counters();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
int interpreter_invocation_count() {
|
int interpreter_invocation_count() {
|
||||||
return _interpreter_invocation_count;
|
return _interpreter_invocation_count;
|
||||||
|
@ -154,7 +154,7 @@ class MethodCounters : public Metadata {
|
||||||
_interpreter_throwout_count = count;
|
_interpreter_throwout_count = count;
|
||||||
}
|
}
|
||||||
|
|
||||||
#else // defined(COMPILER2) || INCLUDE_JVMCI
|
#else // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
int interpreter_invocation_count() {
|
int interpreter_invocation_count() {
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -170,7 +170,7 @@ class MethodCounters : public Metadata {
|
||||||
assert(count == 0, "count must be 0");
|
assert(count == 0, "count must be 0");
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // defined(COMPILER2) || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
#if INCLUDE_JVMTI
|
#if INCLUDE_JVMTI
|
||||||
u2 number_of_breakpoints() const { return _number_of_breakpoints; }
|
u2 number_of_breakpoints() const { return _number_of_breakpoints; }
|
||||||
|
@ -213,7 +213,7 @@ class MethodCounters : public Metadata {
|
||||||
return byte_offset_of(MethodCounters, _nmethod_age);
|
return byte_offset_of(MethodCounters, _nmethod_age);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
static ByteSize interpreter_invocation_counter_offset() {
|
static ByteSize interpreter_invocation_counter_offset() {
|
||||||
return byte_offset_of(MethodCounters, _interpreter_invocation_count);
|
return byte_offset_of(MethodCounters, _interpreter_invocation_count);
|
||||||
|
@ -223,14 +223,14 @@ class MethodCounters : public Metadata {
|
||||||
return offset_of(MethodCounters, _interpreter_invocation_count);
|
return offset_of(MethodCounters, _interpreter_invocation_count);
|
||||||
}
|
}
|
||||||
|
|
||||||
#else // defined(COMPILER2) || INCLUDE_JVMCI
|
#else // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
static ByteSize interpreter_invocation_counter_offset() {
|
static ByteSize interpreter_invocation_counter_offset() {
|
||||||
ShouldNotReachHere();
|
ShouldNotReachHere();
|
||||||
return in_ByteSize(0);
|
return in_ByteSize(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // defined(COMPILER2) || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
static ByteSize invocation_counter_offset() {
|
static ByteSize invocation_counter_offset() {
|
||||||
return byte_offset_of(MethodCounters, _invocation_counter);
|
return byte_offset_of(MethodCounters, _invocation_counter);
|
||||||
|
|
|
@ -1860,7 +1860,7 @@ void Arguments::set_ergonomics_flags() {
|
||||||
#endif
|
#endif
|
||||||
select_gc();
|
select_gc();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
// Shared spaces work fine with other GCs but causes bytecode rewriting
|
// Shared spaces work fine with other GCs but causes bytecode rewriting
|
||||||
// to be disabled, which hurts interpreter performance and decreases
|
// to be disabled, which hurts interpreter performance and decreases
|
||||||
// server performance. When -server is specified, keep the default off
|
// server performance. When -server is specified, keep the default off
|
||||||
|
|
|
@ -192,7 +192,7 @@ Deoptimization::UnrollBlock* Deoptimization::fetch_unroll_info_helper(JavaThread
|
||||||
|
|
||||||
bool realloc_failures = false;
|
bool realloc_failures = false;
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
// Reallocate the non-escaping objects and restore their fields. Then
|
// Reallocate the non-escaping objects and restore their fields. Then
|
||||||
// relock objects if synchronization on them was eliminated.
|
// relock objects if synchronization on them was eliminated.
|
||||||
#ifndef INCLUDE_JVMCI
|
#ifndef INCLUDE_JVMCI
|
||||||
|
@ -282,7 +282,7 @@ Deoptimization::UnrollBlock* Deoptimization::fetch_unroll_info_helper(JavaThread
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif // INCLUDE_JVMCI
|
#endif // INCLUDE_JVMCI
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
ScopeDesc* trap_scope = chunk->at(0)->scope();
|
ScopeDesc* trap_scope = chunk->at(0)->scope();
|
||||||
Handle exceptionObject;
|
Handle exceptionObject;
|
||||||
|
@ -303,7 +303,7 @@ Deoptimization::UnrollBlock* Deoptimization::fetch_unroll_info_helper(JavaThread
|
||||||
NoSafepointVerifier no_safepoint;
|
NoSafepointVerifier no_safepoint;
|
||||||
|
|
||||||
vframeArray* array = create_vframeArray(thread, deoptee, &map, chunk, realloc_failures);
|
vframeArray* array = create_vframeArray(thread, deoptee, &map, chunk, realloc_failures);
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
if (realloc_failures) {
|
if (realloc_failures) {
|
||||||
pop_frames_failed_reallocs(thread, array);
|
pop_frames_failed_reallocs(thread, array);
|
||||||
}
|
}
|
||||||
|
@ -792,7 +792,7 @@ int Deoptimization::deoptimize_dependents() {
|
||||||
Deoptimization::DeoptAction Deoptimization::_unloaded_action
|
Deoptimization::DeoptAction Deoptimization::_unloaded_action
|
||||||
= Deoptimization::Action_reinterpret;
|
= Deoptimization::Action_reinterpret;
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
bool Deoptimization::realloc_objects(JavaThread* thread, frame* fr, GrowableArray<ScopeValue*>* objects, TRAPS) {
|
bool Deoptimization::realloc_objects(JavaThread* thread, frame* fr, GrowableArray<ScopeValue*>* objects, TRAPS) {
|
||||||
Handle pending_exception(THREAD, thread->pending_exception());
|
Handle pending_exception(THREAD, thread->pending_exception());
|
||||||
const char* exception_file = thread->exception_file();
|
const char* exception_file = thread->exception_file();
|
||||||
|
@ -1151,7 +1151,7 @@ void Deoptimization::print_objects(GrowableArray<ScopeValue*>* objects, bool rea
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
vframeArray* Deoptimization::create_vframeArray(JavaThread* thread, frame fr, RegisterMap *reg_map, GrowableArray<compiledVFrame*>* chunk, bool realloc_failures) {
|
vframeArray* Deoptimization::create_vframeArray(JavaThread* thread, frame fr, RegisterMap *reg_map, GrowableArray<compiledVFrame*>* chunk, bool realloc_failures) {
|
||||||
Events::log(thread, "DEOPT PACKING pc=" INTPTR_FORMAT " sp=" INTPTR_FORMAT, p2i(fr.pc()), p2i(fr.sp()));
|
Events::log(thread, "DEOPT PACKING pc=" INTPTR_FORMAT " sp=" INTPTR_FORMAT, p2i(fr.pc()), p2i(fr.sp()));
|
||||||
|
@ -1211,7 +1211,7 @@ vframeArray* Deoptimization::create_vframeArray(JavaThread* thread, frame fr, Re
|
||||||
return array;
|
return array;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
void Deoptimization::pop_frames_failed_reallocs(JavaThread* thread, vframeArray* array) {
|
void Deoptimization::pop_frames_failed_reallocs(JavaThread* thread, vframeArray* array) {
|
||||||
// Reallocation of some scalar replaced objects failed. Record
|
// Reallocation of some scalar replaced objects failed. Record
|
||||||
// that we need to pop all the interpreter frames for the
|
// that we need to pop all the interpreter frames for the
|
||||||
|
@ -1443,7 +1443,7 @@ Deoptimization::get_method_data(JavaThread* thread, const methodHandle& m,
|
||||||
return mdo;
|
return mdo;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
void Deoptimization::load_class_by_index(const constantPoolHandle& constant_pool, int index, TRAPS) {
|
void Deoptimization::load_class_by_index(const constantPoolHandle& constant_pool, int index, TRAPS) {
|
||||||
// in case of an unresolved klass entry, load the class.
|
// in case of an unresolved klass entry, load the class.
|
||||||
if (constant_pool->tag_at(index).is_unresolved_klass()) {
|
if (constant_pool->tag_at(index).is_unresolved_klass()) {
|
||||||
|
@ -2350,7 +2350,7 @@ void Deoptimization::print_statistics() {
|
||||||
if (xtty != NULL) xtty->tail("statistics");
|
if (xtty != NULL) xtty->tail("statistics");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#else // COMPILER2 || INCLUDE_JVMCI
|
#else // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
|
|
||||||
// Stubs for C1 only system.
|
// Stubs for C1 only system.
|
||||||
|
@ -2386,4 +2386,4 @@ const char* Deoptimization::format_trap_state(char* buf, size_t buflen,
|
||||||
return buf;
|
return buf;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
|
@ -151,7 +151,7 @@ class Deoptimization : AllStatic {
|
||||||
// executing in a particular CodeBlob if UseBiasedLocking is enabled
|
// executing in a particular CodeBlob if UseBiasedLocking is enabled
|
||||||
static void revoke_biases_of_monitors(CodeBlob* cb);
|
static void revoke_biases_of_monitors(CodeBlob* cb);
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
JVMCI_ONLY(public:)
|
JVMCI_ONLY(public:)
|
||||||
|
|
||||||
// Support for restoring non-escaping objects
|
// Support for restoring non-escaping objects
|
||||||
|
@ -162,7 +162,7 @@ JVMCI_ONLY(public:)
|
||||||
static void relock_objects(GrowableArray<MonitorInfo*>* monitors, JavaThread* thread, bool realloc_failures);
|
static void relock_objects(GrowableArray<MonitorInfo*>* monitors, JavaThread* thread, bool realloc_failures);
|
||||||
static void pop_frames_failed_reallocs(JavaThread* thread, vframeArray* array);
|
static void pop_frames_failed_reallocs(JavaThread* thread, vframeArray* array);
|
||||||
NOT_PRODUCT(static void print_objects(GrowableArray<ScopeValue*>* objects, bool realloc_failures);)
|
NOT_PRODUCT(static void print_objects(GrowableArray<ScopeValue*>* objects, bool realloc_failures);)
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
public:
|
public:
|
||||||
static vframeArray* create_vframeArray(JavaThread* thread, frame fr, RegisterMap *reg_map, GrowableArray<compiledVFrame*>* chunk, bool realloc_failures);
|
static vframeArray* create_vframeArray(JavaThread* thread, frame fr, RegisterMap *reg_map, GrowableArray<compiledVFrame*>* chunk, bool realloc_failures);
|
||||||
|
|
|
@ -1148,7 +1148,7 @@ void frame::verify(const RegisterMap* map) {
|
||||||
// make sure we have the right receiver type
|
// make sure we have the right receiver type
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
assert(DerivedPointerTable::is_empty(), "must be empty before verify");
|
assert(DerivedPointerTable::is_empty(), "must be empty before verify");
|
||||||
#endif
|
#endif
|
||||||
oops_do_internal(&VerifyOopClosure::verify_oop, NULL, (RegisterMap*)map, false);
|
oops_do_internal(&VerifyOopClosure::verify_oop, NULL, (RegisterMap*)map, false);
|
||||||
|
|
|
@ -99,11 +99,11 @@ define_pd_global(uint64_t,MaxRAM, 1ULL*G);
|
||||||
#define CI_COMPILER_COUNT 0
|
#define CI_COMPILER_COUNT 0
|
||||||
#else
|
#else
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
#define CI_COMPILER_COUNT 2
|
#define CI_COMPILER_COUNT 2
|
||||||
#else
|
#else
|
||||||
#define CI_COMPILER_COUNT 1
|
#define CI_COMPILER_COUNT 1
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
|
|
||||||
#endif // no compilers
|
#endif // no compilers
|
||||||
|
|
||||||
|
|
|
@ -155,7 +155,7 @@ void InterpretedRFrame::init() {
|
||||||
|
|
||||||
void RFrame::print(const char* kind) {
|
void RFrame::print(const char* kind) {
|
||||||
#ifndef PRODUCT
|
#ifndef PRODUCT
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
int cnt = top_method()->interpreter_invocation_count();
|
int cnt = top_method()->interpreter_invocation_count();
|
||||||
#else
|
#else
|
||||||
int cnt = top_method()->invocation_count();
|
int cnt = top_method()->invocation_count();
|
||||||
|
|
|
@ -102,13 +102,13 @@ void SharedRuntime::generate_stubs() {
|
||||||
_resolve_static_call_blob = generate_resolve_blob(CAST_FROM_FN_PTR(address, SharedRuntime::resolve_static_call_C), "resolve_static_call");
|
_resolve_static_call_blob = generate_resolve_blob(CAST_FROM_FN_PTR(address, SharedRuntime::resolve_static_call_C), "resolve_static_call");
|
||||||
_resolve_static_call_entry = _resolve_static_call_blob->entry_point();
|
_resolve_static_call_entry = _resolve_static_call_blob->entry_point();
|
||||||
|
|
||||||
#if defined(COMPILER2) || INCLUDE_JVMCI
|
#if COMPILER2_OR_JVMCI
|
||||||
// Vectors are generated only by C2 and JVMCI.
|
// Vectors are generated only by C2 and JVMCI.
|
||||||
bool support_wide = is_wide_vector(MaxVectorSize);
|
bool support_wide = is_wide_vector(MaxVectorSize);
|
||||||
if (support_wide) {
|
if (support_wide) {
|
||||||
_polling_page_vectors_safepoint_handler_blob = generate_handler_blob(CAST_FROM_FN_PTR(address, SafepointSynchronize::handle_polling_page_exception), POLL_AT_VECTOR_LOOP);
|
_polling_page_vectors_safepoint_handler_blob = generate_handler_blob(CAST_FROM_FN_PTR(address, SafepointSynchronize::handle_polling_page_exception), POLL_AT_VECTOR_LOOP);
|
||||||
}
|
}
|
||||||
#endif // COMPILER2 || INCLUDE_JVMCI
|
#endif // COMPILER2_OR_JVMCI
|
||||||
_polling_page_safepoint_handler_blob = generate_handler_blob(CAST_FROM_FN_PTR(address, SafepointSynchronize::handle_polling_page_exception), POLL_AT_LOOP);
|
_polling_page_safepoint_handler_blob = generate_handler_blob(CAST_FROM_FN_PTR(address, SafepointSynchronize::handle_polling_page_exception), POLL_AT_LOOP);
|
||||||
_polling_page_return_handler_blob = generate_handler_blob(CAST_FROM_FN_PTR(address, SafepointSynchronize::handle_polling_page_exception), POLL_AT_RETURN);
|
_polling_page_return_handler_blob = generate_handler_blob(CAST_FROM_FN_PTR(address, SafepointSynchronize::handle_polling_page_exception), POLL_AT_RETURN);
|
||||||
|
|
||||||
|
|
|
@ -3724,7 +3724,7 @@ jint Threads::create_vm(JavaVMInitArgs* args, bool* canTryAgain) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// initialize compiler(s)
|
// initialize compiler(s)
|
||||||
#if defined(COMPILER1) || defined(COMPILER2) || INCLUDE_JVMCI
|
#if defined(COMPILER1) || COMPILER2_OR_JVMCI
|
||||||
CompileBroker::compilation_init(CHECK_JNI_ERR);
|
CompileBroker::compilation_init(CHECK_JNI_ERR);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue