review (S) for 6951190: assert(!klass_is_exact(), "only non-exact klass") while building JDK

Tom Rodriguez tom.rodriguez at oracle.com
Mon May 10 11:01:52 PDT 2010


http://cr.openjdk.java.net/~never/6951190

6951190: assert(!klass_is_exact(),"only non-exact klass") while building JDK
Reviewed-by:

This looks to be a long standing issue with the String.equals
intrinsic.  The code checks that the argument is a String but it never
actually casts it to be a String.  Later on when we're processing
types for the AddP for the String.count field we're looking for a
field at +20 in Object which of course doesn't exist so we hit that
assert.  The fix is to perform a real checkcast which includes to
required cast to String.  I also added an assert to check the contract
with gen_checkcast that it always returns non-null failure_control.
Tested by hand with failing JDK build.


More information about the hotspot-dev mailing list