[vmkit-commits] [vmkit] r69282 - /vmkit/trunk/lib/JnJVM/VMCore/JavaClass.cpp

Nicolas Geoffray nicolas.geoffray at lip6.fr
Thu Apr 16 04:01:30 PDT 2009


Author: geoffray
Date: Thu Apr 16 06:01:21 2009
New Revision: 69282

URL: http://llvm.org/viewvc/llvm-project?rev=69282&view=rev
Log:
Remove obsolete comments.


Modified:
    vmkit/trunk/lib/JnJVM/VMCore/JavaClass.cpp

Modified: vmkit/trunk/lib/JnJVM/VMCore/JavaClass.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/lib/JnJVM/VMCore/JavaClass.cpp?rev=69282&r1=69281&r2=69282&view=diff

==============================================================================
--- vmkit/trunk/lib/JnJVM/VMCore/JavaClass.cpp (original)
+++ vmkit/trunk/lib/JnJVM/VMCore/JavaClass.cpp Thu Apr 16 06:01:21 2009
@@ -724,8 +724,6 @@
 
 void Class::readParents(Reader& reader) {
   uint16 superEntry = reader.readU2();
-  // Use the depth field to store the super entry, to not touch super. The
-  // super field is used during GC scanning and must only be of one type.
   if (superEntry) {
     const UTF8* superUTF8 = ctpInfo->resolveClassName(superEntry);
     super = classLoader->loadName(superUTF8, false, true);
@@ -733,12 +731,11 @@
 
   uint16 nbI = reader.readU2();
 
-  // Use the regular interface array to store the UTF8s. Since this array
-  // is never used before actually loading the interfaces, this is harmless.
-  // During GC scanning, the check is made on super. So the array of
-  // interfaces is not used if super is null.
   interfaces = (Class**)
     classLoader->allocator.Allocate(nbI * sizeof(Class*));
+  
+  // Do not set nbInterfaces yet, we may be interrupted by the GC
+  // in anon-cooperative environment.
   for (int i = 0; i < nbI; i++) {
     const UTF8* name = ctpInfo->resolveClassName(reader.readU2());
     interfaces[i] = classLoader->loadName(name, false, true);





More information about the vmkit-commits mailing list