RFR 8058927: ATG throws ClassNotFoundException

David Holmes david.holmes at oracle.com
Sat Sep 27 01:22:53 UTC 2014


Sorry Coleen but I don't quite get the changes.

javaClasses.cpp:

  639     assert(class_loader() == k->class_loader(), "should be same");

I can't quite get my head around the different things that k may be by 
the time we get to the assert, and its relation to the current class.
---

arrayKlass.cpp

   java_lang_Class::create_mirror(k, Handle(THREAD, k->class_loader()), 
Handle(NULL), CHECK);

I expected to see something extracting the classloader of the element 
type here - but perhaps I'm misunderstanding what k represents.
---

test/runtime/LoadClass/ShowClassLoader.java

Sorry, my little 'test' program was really a demo. The actual test 
should be checking that for an array 'a':

a.getClass().getClassLoader() ==
    a.getClass().getComponentType().getClassLoader()

and for completeness it should test a primitive array, object array for 
a boot class, and object array for a non-boot class. So the test name 
should then be CheckArrayClassLoader.

Thanks,
David

On 26/09/2014 12:05 PM, Coleen Phillimore wrote:
>
> Thanks for pointing out I cut/pasted the wrong webrevs.  Here they are:
>
> open webrev at http://cr.openjdk.java.net/~coleenp/8058927/
> bug link https://bugs.openjdk.java.net/browse/JDK-8058927
>
> Thanks,
> Coleen
>
> On 9/25/14, 7:33 PM, Coleen Phillimore wrote:
>> Summary: ClassLoader for array klass was set to null and not the class
>> loader of the component type.
>>
>> open webrev at http://cr.openjdk.java.net/~coleenp/8058843
>> bug link https://bugs.openjdk.java.net/browse/JDK-8058843
>>
>> See bug for more details.
>>
>> Ran testbase, jtreg and jck tests, not that they found this bug in the
>> first place.  Boris verified the fix with ATG.
>>
>> Thank you to David Holmes for finding it through visual inspection of
>> the original change.
>>
>> Thanks,
>> Coleen
>


More information about the hotspot-runtime-dev mailing list