Skip to content

Commit 5dbd495

Browse files
caizixianshipilev
authored andcommittedOct 18, 2022
8295457: Make the signatures of write barrier methods consistent
Reviewed-by: tschatzl, shade
1 parent 7b2e83b commit 5dbd495

7 files changed

+23
-23
lines changed
 

‎src/hotspot/cpu/aarch64/macroAssembler_aarch64.cpp

+5-5
Original file line numberDiff line numberDiff line change
@@ -4393,15 +4393,15 @@ void MacroAssembler::access_load_at(BasicType type, DecoratorSet decorators,
43934393
}
43944394

43954395
void MacroAssembler::access_store_at(BasicType type, DecoratorSet decorators,
4396-
Address dst, Register src,
4396+
Address dst, Register val,
43974397
Register tmp1, Register tmp2, Register tmp3) {
43984398
BarrierSetAssembler *bs = BarrierSet::barrier_set()->barrier_set_assembler();
43994399
decorators = AccessInternal::decorator_fixup(decorators);
44004400
bool as_raw = (decorators & AS_RAW) != 0;
44014401
if (as_raw) {
4402-
bs->BarrierSetAssembler::store_at(this, decorators, type, dst, src, tmp1, tmp2, tmp3);
4402+
bs->BarrierSetAssembler::store_at(this, decorators, type, dst, val, tmp1, tmp2, tmp3);
44034403
} else {
4404-
bs->store_at(this, decorators, type, dst, src, tmp1, tmp2, tmp3);
4404+
bs->store_at(this, decorators, type, dst, val, tmp1, tmp2, tmp3);
44054405
}
44064406
}
44074407

@@ -4415,9 +4415,9 @@ void MacroAssembler::load_heap_oop_not_null(Register dst, Address src, Register
44154415
access_load_at(T_OBJECT, IN_HEAP | IS_NOT_NULL | decorators, dst, src, tmp1, tmp2);
44164416
}
44174417

4418-
void MacroAssembler::store_heap_oop(Address dst, Register src, Register tmp1,
4418+
void MacroAssembler::store_heap_oop(Address dst, Register val, Register tmp1,
44194419
Register tmp2, Register tmp3, DecoratorSet decorators) {
4420-
access_store_at(T_OBJECT, IN_HEAP | decorators, dst, src, tmp1, tmp2, tmp3);
4420+
access_store_at(T_OBJECT, IN_HEAP | decorators, dst, val, tmp1, tmp2, tmp3);
44214421
}
44224422

44234423
// Used for storing NULLs.

‎src/hotspot/cpu/aarch64/macroAssembler_aarch64.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -843,15 +843,15 @@ class MacroAssembler: public Assembler {
843843
void access_load_at(BasicType type, DecoratorSet decorators, Register dst, Address src,
844844
Register tmp1, Register tmp2);
845845

846-
void access_store_at(BasicType type, DecoratorSet decorators, Address dst, Register src,
846+
void access_store_at(BasicType type, DecoratorSet decorators, Address dst, Register val,
847847
Register tmp1, Register tmp2, Register tmp3);
848848

849849
void load_heap_oop(Register dst, Address src, Register tmp1,
850850
Register tmp2, DecoratorSet decorators = 0);
851851

852852
void load_heap_oop_not_null(Register dst, Address src, Register tmp1,
853853
Register tmp2, DecoratorSet decorators = 0);
854-
void store_heap_oop(Address dst, Register src, Register tmp1,
854+
void store_heap_oop(Address dst, Register val, Register tmp1,
855855
Register tmp2, Register tmp3, DecoratorSet decorators = 0);
856856

857857
// currently unimplemented

‎src/hotspot/cpu/ppc/macroAssembler_ppc.inline.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -398,11 +398,11 @@ inline void MacroAssembler::load_heap_oop(Register d, RegisterOrConstant offs, R
398398
preservation_level, L_handle_null);
399399
}
400400

401-
inline void MacroAssembler::store_heap_oop(Register d, RegisterOrConstant offs, Register s1,
401+
inline void MacroAssembler::store_heap_oop(Register val, RegisterOrConstant offs, Register base,
402402
Register tmp1, Register tmp2, Register tmp3,
403403
MacroAssembler::PreservationLevel preservation_level,
404404
DecoratorSet decorators) {
405-
access_store_at(T_OBJECT, decorators | IN_HEAP, s1, offs, d, tmp1, tmp2, tmp3, preservation_level);
405+
access_store_at(T_OBJECT, decorators | IN_HEAP, base, offs, val, tmp1, tmp2, tmp3, preservation_level);
406406
}
407407

408408
inline Register MacroAssembler::encode_heap_oop_not_null(Register d, Register src) {

‎src/hotspot/cpu/riscv/macroAssembler_riscv.cpp

+5-5
Original file line numberDiff line numberDiff line change
@@ -2094,15 +2094,15 @@ void MacroAssembler::null_check(Register reg, int offset) {
20942094
}
20952095

20962096
void MacroAssembler::access_store_at(BasicType type, DecoratorSet decorators,
2097-
Address dst, Register src,
2097+
Address dst, Register val,
20982098
Register tmp1, Register tmp2, Register tmp3) {
20992099
BarrierSetAssembler *bs = BarrierSet::barrier_set()->barrier_set_assembler();
21002100
decorators = AccessInternal::decorator_fixup(decorators);
21012101
bool as_raw = (decorators & AS_RAW) != 0;
21022102
if (as_raw) {
2103-
bs->BarrierSetAssembler::store_at(this, decorators, type, dst, src, tmp1, tmp2, tmp3);
2103+
bs->BarrierSetAssembler::store_at(this, decorators, type, dst, val, tmp1, tmp2, tmp3);
21042104
} else {
2105-
bs->store_at(this, decorators, type, dst, src, tmp1, tmp2, tmp3);
2105+
bs->store_at(this, decorators, type, dst, val, tmp1, tmp2, tmp3);
21062106
}
21072107
}
21082108

@@ -2269,9 +2269,9 @@ void MacroAssembler::decode_heap_oop(Register d, Register s) {
22692269
verify_oop_msg(d, "broken oop in decode_heap_oop");
22702270
}
22712271

2272-
void MacroAssembler::store_heap_oop(Address dst, Register src, Register tmp1,
2272+
void MacroAssembler::store_heap_oop(Address dst, Register val, Register tmp1,
22732273
Register tmp2, Register tmp3, DecoratorSet decorators) {
2274-
access_store_at(T_OBJECT, IN_HEAP | decorators, dst, src, tmp1, tmp2, tmp3);
2274+
access_store_at(T_OBJECT, IN_HEAP | decorators, dst, val, tmp1, tmp2, tmp3);
22752275
}
22762276

22772277
void MacroAssembler::load_heap_oop(Register dst, Address src, Register tmp1,

‎src/hotspot/cpu/riscv/macroAssembler_riscv.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ class MacroAssembler: public Assembler {
191191
void access_load_at(BasicType type, DecoratorSet decorators, Register dst,
192192
Address src, Register tmp1, Register tmp2);
193193
void access_store_at(BasicType type, DecoratorSet decorators, Address dst,
194-
Register src, Register tmp1, Register tmp2, Register tmp3);
194+
Register val, Register tmp1, Register tmp2, Register tmp3);
195195
void load_klass(Register dst, Register src);
196196
void store_klass(Register dst, Register src);
197197
void cmp_klass(Register oop, Register trial_klass, Register tmp, Label &L);
@@ -210,7 +210,7 @@ class MacroAssembler: public Assembler {
210210
Register tmp2 = noreg, DecoratorSet decorators = 0);
211211
void load_heap_oop_not_null(Register dst, Address src, Register tmp1 = noreg,
212212
Register tmp2 = noreg, DecoratorSet decorators = 0);
213-
void store_heap_oop(Address dst, Register src, Register tmp1 = noreg,
213+
void store_heap_oop(Address dst, Register val, Register tmp1 = noreg,
214214
Register tmp2 = noreg, Register tmp3 = noreg, DecoratorSet decorators = 0);
215215

216216
void store_klass_gap(Register dst, Register src);

‎src/hotspot/cpu/x86/macroAssembler_x86.cpp

+5-5
Original file line numberDiff line numberDiff line change
@@ -5104,15 +5104,15 @@ void MacroAssembler::access_load_at(BasicType type, DecoratorSet decorators, Reg
51045104
}
51055105
}
51065106

5107-
void MacroAssembler::access_store_at(BasicType type, DecoratorSet decorators, Address dst, Register src,
5107+
void MacroAssembler::access_store_at(BasicType type, DecoratorSet decorators, Address dst, Register val,
51085108
Register tmp1, Register tmp2, Register tmp3) {
51095109
BarrierSetAssembler* bs = BarrierSet::barrier_set()->barrier_set_assembler();
51105110
decorators = AccessInternal::decorator_fixup(decorators);
51115111
bool as_raw = (decorators & AS_RAW) != 0;
51125112
if (as_raw) {
5113-
bs->BarrierSetAssembler::store_at(this, decorators, type, dst, src, tmp1, tmp2, tmp3);
5113+
bs->BarrierSetAssembler::store_at(this, decorators, type, dst, val, tmp1, tmp2, tmp3);
51145114
} else {
5115-
bs->store_at(this, decorators, type, dst, src, tmp1, tmp2, tmp3);
5115+
bs->store_at(this, decorators, type, dst, val, tmp1, tmp2, tmp3);
51165116
}
51175117
}
51185118

@@ -5127,9 +5127,9 @@ void MacroAssembler::load_heap_oop_not_null(Register dst, Address src, Register
51275127
access_load_at(T_OBJECT, IN_HEAP | IS_NOT_NULL | decorators, dst, src, tmp1, thread_tmp);
51285128
}
51295129

5130-
void MacroAssembler::store_heap_oop(Address dst, Register src, Register tmp1,
5130+
void MacroAssembler::store_heap_oop(Address dst, Register val, Register tmp1,
51315131
Register tmp2, Register tmp3, DecoratorSet decorators) {
5132-
access_store_at(T_OBJECT, IN_HEAP | decorators, dst, src, tmp1, tmp2, tmp3);
5132+
access_store_at(T_OBJECT, IN_HEAP | decorators, dst, val, tmp1, tmp2, tmp3);
51335133
}
51345134

51355135
// Used for storing NULLs.

‎src/hotspot/cpu/x86/macroAssembler_x86.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -352,14 +352,14 @@ class MacroAssembler: public Assembler {
352352

353353
void access_load_at(BasicType type, DecoratorSet decorators, Register dst, Address src,
354354
Register tmp1, Register thread_tmp);
355-
void access_store_at(BasicType type, DecoratorSet decorators, Address dst, Register src,
355+
void access_store_at(BasicType type, DecoratorSet decorators, Address dst, Register val,
356356
Register tmp1, Register tmp2, Register tmp3);
357357

358358
void load_heap_oop(Register dst, Address src, Register tmp1 = noreg,
359359
Register thread_tmp = noreg, DecoratorSet decorators = 0);
360360
void load_heap_oop_not_null(Register dst, Address src, Register tmp1 = noreg,
361361
Register thread_tmp = noreg, DecoratorSet decorators = 0);
362-
void store_heap_oop(Address dst, Register src, Register tmp1 = noreg,
362+
void store_heap_oop(Address dst, Register val, Register tmp1 = noreg,
363363
Register tmp2 = noreg, Register tmp3 = noreg, DecoratorSet decorators = 0);
364364

365365
// Used for storing NULL. All other oop constants should be

0 commit comments

Comments
 (0)
Please sign in to comment.