RFR: 8260368: [PPC64] GC interface needs enhancement to support GCs with load barriers

Roman Kennke rkennke at openjdk.java.net
Mon Feb 1 19:50:43 UTC 2021


On Mon, 1 Feb 2021 19:33:21 GMT, Martin Doerr <mdoerr at openjdk.org> wrote:

>> src/hotspot/cpu/ppc/gc/g1/g1BarrierSetAssembler_ppc.cpp line 111:
>> 
>>> 109: 
>>> 110: void G1BarrierSetAssembler::g1_write_barrier_pre(MacroAssembler* masm, DecoratorSet decorators, Register obj, RegisterOrConstant ind_or_offs, Register pre_val,
>>> 111:                                                  Register tmp1, Register tmp2, unsigned int preservation_level) {
>> 
>> Wouldn't it make sense to use an enum type here? Or is this something that the PPC toolchain doesn't like? Applies to all occurances of similar change all over the place.
>
> Hi Roman,
> enum type works. We only don't want to use C++11 features like enum class or typed enums because we will probably backport this change to 11u.

IOW, can we write MacroAssembler::RuntimeInvocationPreservationLevel instead of unsigned int there or not? I believe this should be possible (even though it'll still only be treated by the compiler as an int)

-------------

PR: https://git.openjdk.java.net/jdk/pull/2302


More information about the hotspot-dev mailing list