Expand shenandoah write barrier as C2 IR

Roland Westrelin rwestrel at redhat.com
Fri Oct 28 14:23:02 UTC 2016


> I'm slightly baffled by all the
>
>
> +      if (!c_abi) {
> +        __ mov(rscratch1, obj);
> +        __ pop_call_clobbered_registers();
> +        __ mov(obj, rscratch1);
> +      } else {
> +        __ pop_call_clobbered_fp_registers();
> +      }
>
> stuff.  What has the C ABI to do with this?  And why does the C ABI
> only save floating-point registers?

The stub generated with c_abi = true is called directly from compiled
code (i.e. C2 CallLeafNoFP node) and the stub should stick to the C
abi: no need to save r1-r4 or other caller save registers. It's a
CallLeafNoFP and not a CallLeaf so the caller doesn't take care of
saving fp registers (the rational being that it's an uncommon code
path). Anyway, the plan is to move more of the stub into the compiled
method itself so the stub will see further changes.

Roland.


More information about the shenandoah-dev mailing list