Skip to content

Commit

Permalink
Update (2023.12.11, 3rd)
Browse files Browse the repository at this point in the history
33126: LA port of 8315801: [PPC64] JNI code should be more similar to the Panama implementation
33125: LA port of 8320272: Make method_entry_barrier address shared
  • Loading branch information
loongson-jvm authored Dec 11, 2023
1 parent dc2a89f commit f542478
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 12 deletions.
2 changes: 1 addition & 1 deletion src/hotspot/cpu/loongarch/c2_CodeStubs_loongarch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ int C2EntryBarrierStub::max_size() const {

void C2EntryBarrierStub::emit(C2_MacroAssembler& masm) {
__ bind(entry());
__ call_long(StubRoutines::la::method_entry_barrier());
__ call_long(StubRoutines::method_entry_barrier());
__ b(continuation());

__ bind(guard());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,7 @@ void BarrierSetAssembler::nmethod_entry_barrier(MacroAssembler* masm, Label* slo
Label skip_barrier;
__ beq(SCR1, SCR2, skip_barrier);

__ call_long(StubRoutines::la::method_entry_barrier());
__ call_long(StubRoutines::method_entry_barrier());
__ b(skip_barrier);

__ bind(local_guard);
Expand Down
4 changes: 1 addition & 3 deletions src/hotspot/cpu/loongarch/sharedRuntime_loongarch_64.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -752,9 +752,7 @@ int SharedRuntime::vector_calling_convention(VMRegPair *regs,

int SharedRuntime::c_calling_convention(const BasicType *sig_bt,
VMRegPair *regs,
VMRegPair *regs2,
int total_args_passed) {
assert(regs2 == nullptr, "not needed on LA");

// We return the amount of VMRegImpl stack slots we need to reserve for all
// the arguments NOT counting out_preserve_stack_slots.
Expand Down Expand Up @@ -1394,7 +1392,7 @@ nmethod *SharedRuntime::generate_native_wrapper(MacroAssembler* masm,
// the 1st six register arguments). It's weird see int_stk_helper.
//
int out_arg_slots;
out_arg_slots = c_calling_convention(out_sig_bt, out_regs, nullptr, total_c_args);
out_arg_slots = c_calling_convention(out_sig_bt, out_regs, total_c_args);

// Compute framesize for the wrapper. We need to handlize all oops in
// registers. We must create space for them here that is disjoint from
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/cpu/loongarch/stubGenerator_loongarch_64.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5648,7 +5648,7 @@ class StubGenerator: public StubCodeGenerator {

BarrierSetNMethod* bs_nm = BarrierSet::barrier_set()->barrier_set_nmethod();
if (bs_nm != nullptr) {
StubRoutines::la::_method_entry_barrier = generate_method_entry_barrier();
StubRoutines::_method_entry_barrier = generate_method_entry_barrier();
}

StubRoutines::_upcall_stub_exception_handler = generate_upcall_stub_exception_handler();
Expand Down
5 changes: 0 additions & 5 deletions src/hotspot/cpu/loongarch/stubRoutines_loongarch.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ class la {
// stack. The variable holds that location.
static address _vector_iota_indices;
static juint _crc_table[];
static address _method_entry_barrier;

static address _string_indexof_linear_ll;
static address _string_indexof_linear_uu;
Expand All @@ -78,10 +77,6 @@ class la {
// Call back points for traps in compiled code
static address vector_iota_indices() { return _vector_iota_indices; }

static address method_entry_barrier() {
return _method_entry_barrier;
}

static address string_indexof_linear_ul() {
return _string_indexof_linear_ul;
}
Expand Down
1 change: 0 additions & 1 deletion src/hotspot/cpu/loongarch/stubRoutines_loongarch_64.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
// a description of how to extend it, see the stubRoutines.hpp file.

//find the last fp value
address StubRoutines::la::_method_entry_barrier = nullptr;
address StubRoutines::la::_vector_iota_indices = nullptr;
address StubRoutines::la::_string_indexof_linear_ll = nullptr;
address StubRoutines::la::_string_indexof_linear_uu = nullptr;
Expand Down

0 comments on commit f542478

Please sign in to comment.