RFR (S): Invert matrix index computation

Aleksey Shipilev ashipile at redhat.com
Thu Apr 13 18:38:11 UTC 2017


Hi,

It makes sense to change matrix index computation like this:
  (from*stride + to)  ---> (from + to*stride)

This is because we are most frequently scanning incoming connections for a given
region, so the memory access is denser if we group matrix by "to". Requires
trivial changes in all barrier implementations:
  http://cr.openjdk.java.net/~shade/shenandoah/matrix-invert/webrev.01/

It does improve Partial GC preparation time, and therefore cuts the total pauses:

before:
  Partial GC (net)  =    32.36 s (a =     8859 us) (n =  3653)
    (lvls, us =     1328,     6875,     8809,    10742,    22201)

after:
  Partial GC (net)  =    24.07 s (a =     6009 us) (n =  4005)
    (lvls, us =      928,     4883,     6016,     7031,    39491)

Testing: hotspot_gc_shenandoah, benchmarks with -XX:+VerifyShenandoahMatrix

Thanks,
-Aleksey



More information about the shenandoah-dev mailing list