RFR: Simpler obj equals barrier for C2

Roland Westrelin rwestrel at redhat.com
Tue Sep 11 14:36:57 UTC 2018


> Ok. But how would I notice? The test suite works ok. I'll also run some
> other stuff (e.g. specjvm/jbb).

The test suite must not test those intrinsics then.

> Also, the WB code only produces memory in the Shenandoah brooks pointer
> slice(s), and it takes care of producing the memphis as needed. Maybe
> this is good enough?

It doesn't take care of producing memphis.

if (some_condition) {
  a = wb(a);
  b = wb(b);
  if (a == b) {
    // do something
  }
} // need a mem phi here

A way around this is to do this, instead:

a = wb(a);
b = wb(b);

if (some_condition) {
  if (a == b) {
    // do something
  }
}

The library_call.cpp code either adds the required mem phis or adds the
barrier so there's no need for phis (they are in some cases tricky to
add because of the way the code is structured).

Can we go back to what we had before?

Roland.


More information about the shenandoah-dev mailing list