[aarch64-port-dev ] RFR 8233401: Shenandoah: Refactor/cleanup Shenandoah load barrier code
Andrew Haley
aph at redhat.com
Mon Nov 4 14:32:36 UTC 2019
On 11/4/19 2:08 PM, Zhengyu Gu wrote:
>
>> void ShenandoahBarrierSetAssembler::load_at(MacroAssembler* masm, DecoratorSet decorators, BasicType type,
>> Register dst, Address src, Register tmp1, Register tmp_thread) {
>>
>> tmp1 and tmp_thread are unused? It'd be a good idea, then, to say if they are
>> safe to use or not. Or maybe even better do this if you want to keep the same
>> arg list:
>>
>> void ShenandoahBarrierSetAssembler::load_at(MacroAssembler* masm, DecoratorSet decorators, BasicType type,
>> Register dst, Address src, Register, Register) {
>>
>
> This is an overrode method. What you get for tmp1 and tmp_thread, is
> really platform dependent.
>
> On AArch64, you usually get noreg for tmp1 and tmp_thread. I can not
> tell if you can safely use tmp1 if it is valid.
>
> I don't use tmp1 here, since I don't think it is worth the trouble, as
> we have spare scratch registers. I do use tmp1 in x86 through.
OK, so please just do this for now:
>> void ShenandoahBarrierSetAssembler::load_at(MacroAssembler* masm, DecoratorSet decorators, BasicType type,
>> Register dst, Address src, Register, Register) {
I'm working on a redesign of the way that scratch registers are used in
AArch64, and this code is likely to have to be changed. Accurate information
about register usage is likely to be crucial for that.
--
Andrew Haley (he/him)
Java Platform Lead Engineer
Red Hat UK Ltd. <https://www.redhat.com>
https://keybase.io/andrewhaley
EAC8 43EB D3EF DB98 CC77 2FAD A5CD 6035 332F A671
More information about the aarch64-port-dev
mailing list