RFR: 8145096: Undefined behaviour in HotSpot
kim.barrett at oracle.com
Thu Dec 17 17:13:01 UTC 2015
On Dec 17, 2015, at 8:37 AM, Andrew Haley <aph at redhat.com> wrote:
> OK. I think this change addresses all of your points.
> The complex (and incorrect)
> ((jlong)CONST64(1) << (jlong)(BitsPerJavaLong - con)) - CONST64(1);
> is merely a difficult way to write
> jlong((~ UCONST64(0)) >> con)
There's another that looks like that here:
577 jlong t1_support = java_subtract(((jlong)1 << (1 + log2_long(t1->_hi))), (jlong)1);
Everything else looks good.
More information about the hotspot-dev