[svn:parrot] r42937 - trunk/src/pmc

chromatic at svn.parrot.org chromatic at svn.parrot.org
Tue Dec 8 05:15:46 UTC 2009


Author: chromatic
Date: Tue Dec  8 05:15:45 2009
New Revision: 42937
URL: https://trac.parrot.org/parrot/changeset/42937

Log:
[PMC] Replaced a SUPER() call from NameSpace's mark() with a direct marking of
the contained hash, for a minor performance improvement.

Modified:
   trunk/src/pmc/namespace.pmc

Modified: trunk/src/pmc/namespace.pmc
==============================================================================
--- trunk/src/pmc/namespace.pmc	Tue Dec  8 05:15:36 2009	(r42936)
+++ trunk/src/pmc/namespace.pmc	Tue Dec  8 05:15:45 2009	(r42937)
@@ -219,12 +219,15 @@
 */
     VTABLE void mark() {
         Parrot_NameSpace_attributes * const nsinfo = PARROT_NAMESPACE(SELF);
-        SUPER();
-        Parrot_gc_mark_PMC_alive(INTERP, nsinfo->parent);
-        Parrot_gc_mark_STRING_alive(INTERP, nsinfo->name);
-        Parrot_gc_mark_PMC_alive(INTERP, nsinfo->_class);
-        Parrot_gc_mark_PMC_alive(INTERP, nsinfo->vtable);
-        Parrot_gc_mark_PMC_alive(INTERP, nsinfo->methods);
+
+        if (nsinfo->hash)
+            parrot_mark_hash(interp, nsinfo->hash);
+
+        Parrot_gc_mark_PMC_alive(interp, nsinfo->parent);
+        Parrot_gc_mark_PMC_alive(interp, nsinfo->_class);
+        Parrot_gc_mark_PMC_alive(interp, nsinfo->vtable);
+        Parrot_gc_mark_PMC_alive(interp, nsinfo->methods);
+        Parrot_gc_mark_STRING_alive(interp, nsinfo->name);
     }
 
 /*


More information about the parrot-commits mailing list