harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Geir Magnusson Jr." <g...@pobox.com>
Subject Re: svn commit: r477583 - in /harmony/enhanced/drlvm/trunk/vm: tests/kernel/java/lang/ClassLoaderTest.java vmcore/src/kernel_classes/javasrc/java/lang/ClassLoader.java
Date Wed, 22 Nov 2006 05:22:10 GMT
More than that, things just don't break by themselves.

Alexey, please explain why you think this happened...

geir



Nathan Beyer wrote:
> Yeah, I'd like to hear about what's going on here. The classloader
> pieces of DRLVM are not quite obvious, at least not to me, from my
> cursory look.
> 
> -Nathan
> 
> On 11/21/06, Geir Magnusson Jr. <geir@pobox.com> wrote:
>> Hang on - where did this come from and why?  I'd like to understand this
>> before we accept it.
>>
>> geir
>>
>>
>> varlax@apache.org wrote:
>> > Author: varlax
>> > Date: Tue Nov 21 00:57:13 2006
>> > New Revision: 477583
>> >
>> > URL: http://svn.apache.org/viewvc?view=rev&rev=477583
>> > Log:
>> > Fixed Eclipse launching. The reason was in dangling remainders of 
>> Java class registry.
>> > Tested on SUSE9, Win2003
>> >
>> > Modified:
>> >     
>> harmony/enhanced/drlvm/trunk/vm/tests/kernel/java/lang/ClassLoaderTest.java 
>>
>> >     
>> harmony/enhanced/drlvm/trunk/vm/vmcore/src/kernel_classes/javasrc/java/lang/ClassLoader.java

>>
>> >
>> > Modified: 
>> harmony/enhanced/drlvm/trunk/vm/tests/kernel/java/lang/ClassLoaderTest.java 
>>
>> > URL: 
>> http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/tests/kernel/java/lang/ClassLoaderTest.java?view=diff&rev=477583&r1=477582&r2=477583

>>
>> > 
>> ============================================================================== 
>>
>> > --- 
>> harmony/enhanced/drlvm/trunk/vm/tests/kernel/java/lang/ClassLoaderTest.java 
>> (original)
>> > +++ 
>> harmony/enhanced/drlvm/trunk/vm/tests/kernel/java/lang/ClassLoaderTest.java 
>> Tue Nov 21 00:57:13 2006
>> > @@ -706,9 +706,9 @@
>> >      }
>> >
>> >      /**
>> > -     *
>> > +     * FIXME invalid test: only VM can initiate loading class
>> >       */
>> > -    public void test_findLoadedClass_Str_2() {
>> > +    public void te_st_findLoadedClass_Str_2() {
>> >          // TEST CASE #4:
>> >          try {
>> >              Class c = 
>> Class.forName("java.lang.ClassLoaderTest$7LCL", true,
>> > @@ -915,7 +915,8 @@
>> >                  return 104;
>> >              }
>> >          }
>> > -        new a3().main(new String[] { "" });
>> > +        // FIXME invalid test: only VM can initiate loading class
>> > +        //new a3().main(new String[] { "" });
>> >      }
>> >
>> >
>> >
>> > Modified: 
>> harmony/enhanced/drlvm/trunk/vm/vmcore/src/kernel_classes/javasrc/java/lang/ClassLoader.java

>>
>> > URL: 
>> http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/vmcore/src/kernel_classes/javasrc/java/lang/ClassLoader.java?view=diff&rev=477583&r1=477582&r2=477583

>>
>> > 
>> ============================================================================== 
>>
>> > --- 
>> harmony/enhanced/drlvm/trunk/vm/vmcore/src/kernel_classes/javasrc/java/lang/ClassLoader.java

>> (original)
>> > +++ 
>> harmony/enhanced/drlvm/trunk/vm/vmcore/src/kernel_classes/javasrc/java/lang/ClassLoader.java

>> Tue Nov 21 00:57:13 2006
>> > @@ -107,12 +107,6 @@
>> >      private final HashMap<String, Package> definedPackages;
>> >
>> >      /**
>> > -     * The following mapping is used <String binaryClassName, Class 
>> clazz>, where binaryClassName - class name,
>> > -     * clazz - corresponding class.
>> > -     */
>> > -    private Hashtable<String, Class<?>> initiatedClasses = new

>> Hashtable<String, Class<?>>();
>> > -
>> > -    /**
>> >       * package private to access from the java.lang.Class class. 
>> The following
>> >       * mapping is used <String name, Certificate[] certificates>, 
>> where name -
>> >       * the name of a package, certificates - array of certificates.
>> > @@ -461,7 +455,7 @@
>> >       * @com.intel.drl.spec_ref
>> >       */
>> >      protected final Class<?> findLoadedClass(String name) {
>> > -        return initiatedClasses.get(name);
>> > +        return VMClassRegistry.findLoadedClass(name, this);
>> >      }
>> >
>> >      /**
>> > @@ -547,7 +541,6 @@
>> >          if (resolve) {
>> >              resolveClass(clazz);
>> >          }
>> > -        initiatedClasses.put(clazz.getName(), clazz);
>> >          return clazz;
>> >      }
>> >
>> >
>> >
>> >
>>

Mime
View raw message