[Vm-dev] [commit][3397] CogVM source as per VMMaker.oscog-eem.1405

commits at squeakvm.org commits at squeakvm.org
Mon Jul 6 18:56:42 UTC 2015


Revision: 3397
Author:   eliot
Date:     2015-07-06 11:56:39 -0700 (Mon, 06 Jul 2015)
Log Message:
-----------
CogVM source as per VMMaker.oscog-eem.1405

Spur:
Make sure the post become action unforwards the Process in the activeProcess inst var up to date.  Add some more asserts to check.Also follow the specialObjectsArray after a pin become.

Generically use storePointerUnchecked: when storing nils into the process lists.

Modified Paths:
--------------
    branches/Cog/nsspursrc/vm/cointerp.c
    branches/Cog/nsspursrc/vm/cointerp.h
    branches/Cog/nsspursrc/vm/gcc3x-cointerp.c
    branches/Cog/nsspurstack64src/vm/gcc3x-interp.c
    branches/Cog/nsspurstack64src/vm/interp.c
    branches/Cog/nsspurstacksrc/vm/gcc3x-interp.c
    branches/Cog/nsspurstacksrc/vm/interp.c
    branches/Cog/spursistasrc/vm/cogitARMv5.c
    branches/Cog/spursistasrc/vm/cogitIA32.c
    branches/Cog/spursistasrc/vm/cointerp.c
    branches/Cog/spursistasrc/vm/cointerp.h
    branches/Cog/spursistasrc/vm/gcc3x-cointerp.c
    branches/Cog/spursrc/vm/cointerp.c
    branches/Cog/spursrc/vm/cointerp.h
    branches/Cog/spursrc/vm/gcc3x-cointerp.c
    branches/Cog/spurstack64src/vm/gcc3x-interp.c
    branches/Cog/spurstack64src/vm/interp.c
    branches/Cog/spurstacksrc/vm/gcc3x-interp.c
    branches/Cog/spurstacksrc/vm/interp.c
    branches/Cog/src/vm/cointerp.c
    branches/Cog/src/vm/cointerp.h
    branches/Cog/src/vm/cointerpmt.c
    branches/Cog/src/vm/cointerpmt.h
    branches/Cog/src/vm/gcc3x-cointerp.c
    branches/Cog/src/vm/gcc3x-cointerpmt.c
    branches/Cog/stacksrc/vm/gcc3x-interp.c
    branches/Cog/stacksrc/vm/interp.c

Property Changed:
----------------
    branches/Cog/platforms/Cross/vm/sqSCCSVersion.h

Modified: branches/Cog/nsspursrc/vm/cointerp.c
===================================================================
--- branches/Cog/nsspursrc/vm/cointerp.c	2015-07-04 16:09:13 UTC (rev 3396)
+++ branches/Cog/nsspursrc/vm/cointerp.c	2015-07-06 18:56:39 UTC (rev 3397)
@@ -1,9 +1,9 @@
 /* Automatically generated by
-	CCodeGeneratorGlobalStructure VMMaker.oscog-eem.1403 uuid: 66fdf690-416b-4359-be28-c0387023baa6
+	CCodeGeneratorGlobalStructure VMMaker.oscog-eem.1405 uuid: 7aff388a-73ba-4202-bb5a-72b0759ff46b
    from
-	CoInterpreter VMMaker.oscog-eem.1403 uuid: 66fdf690-416b-4359-be28-c0387023baa6
+	CoInterpreter VMMaker.oscog-eem.1405 uuid: 7aff388a-73ba-4202-bb5a-72b0759ff46b
  */
-static char __buildInfo[] = "CoInterpreter VMMaker.oscog-eem.1403 uuid: 66fdf690-416b-4359-be28-c0387023baa6 " __DATE__ ;
+static char __buildInfo[] = "CoInterpreter VMMaker.oscog-eem.1405 uuid: 7aff388a-73ba-4202-bb5a-72b0759ff46b " __DATE__ ;
 char *__interpBuildInfo = __buildInfo;
 
 
@@ -1207,7 +1207,7 @@
 static sqInt storeImageSegmentIntooutPointersroots(sqInt segmentWordArray, sqInt outPointerArray, sqInt arrayOfRoots) NoDbgRegParms;
 extern sqInt storePointerUncheckedofObjectwithValue(sqInt fieldIndex, sqInt objOop, sqInt valuePointer);
 extern sqInt storePointerofObjectwithValue(sqInt fieldIndex, sqInt objOop, sqInt valuePointer);
-extern sqInt stringForCString(const char *aCString);
+extern usqInt stringForCString(const char *aCString);
 static sqInt sufficientSpaceAfterGC(sqInt numBytes) NoDbgRegParms;
 static sqInt swizzleObjStackAt(sqInt objStackRootIndex) NoDbgRegParms;
 extern void tenuringIncrementalGC(void);
@@ -2410,7 +2410,7 @@
 /*560*/	-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, 0, 0, 0,-1,-1
 	};
 char expensiveAsserts = 0;
-const char *interpreterVersion = "Newspeak Virtual Machine CoInterpreterPrimitives_VMMaker.oscog-eem.1403";
+const char *interpreterVersion = "Newspeak Virtual Machine CoInterpreterPrimitives_VMMaker.oscog-eem.1405";
 sqInt minBackwardJumpCountForCompile = MinBackwardJumpCountForCompile /* 40 */;
 volatile int sendTrace;
 
@@ -28740,11 +28740,15 @@
 		longAtput((process + BaseHeaderSize) + (MyListIndex << (shiftForWord())), myList);
 	}
 	/* begin removeProcess:fromList: */
-	assert(!(isForwarded(myList)));
+	assert(!((isForwarded(process))));
+	assert(!((isForwarded(myList))));
 	firstLink = longAt((myList + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())));
 	lastLink = longAt((myList + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())));
+	assert(!((isForwarded(firstLink))));
+	assert(!((isForwarded(lastLink))));
 	if (process == firstLink) {
 		nextLink = longAt((process + BaseHeaderSize) + (NextLinkIndex << (shiftForWord())));
+		assert(!((isForwarded(nextLink))));
 		/* begin storePointer:ofObject:withValue: */
 		assert(!(isForwarded(myList)));
 		if (isOldObject(myList)) {
@@ -28761,36 +28765,20 @@
 		}
 		longAtput((myList + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())), nextLink);
 		if (process == lastLink) {
-			/* begin storePointer:ofObject:withValue: */
+			/* begin storePointerUnchecked:ofObject:withValue: */
 			assert(!(isForwarded(myList)));
-			if (isOldObject(myList)) {
-
-				/* most stores into young objects */
-
-				if (((GIV(nilObj) & 3) == 0)
-				 && (oopisLessThan(GIV(nilObj), GIV(newSpaceLimit)))) {
-					/* begin possibleRootStoreInto: */
-					if (!(((((usqInt) (longAt(myList))) >> 29) & 1) != 0)) {
-						remember(myList);
-					}
-				}
-			}
 			longAtput((myList + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())), GIV(nilObj));
 		}
 	}
 	else {
 		tempLink = firstLink;
 		while (1) {
+			assert(!((isForwarded(tempLink))));
 			if (tempLink == GIV(nilObj)) {
-				/* begin success: */
-				
-				/* Don't overwrite an error code that has already been set. */
-
+				/* begin primitiveFail */
 				if (!GIV(primFailCode)) {
 					GIV(primFailCode) = 1;
 				}
-
-				null;
 				goto l1;
 			}
 			nextLink = longAt((tempLink + BaseHeaderSize) + (NextLinkIndex << (shiftForWord())));
@@ -32444,7 +32432,7 @@
     usqInt newObj;
     usqInt numBytes;
     sqInt numSlots;
-    sqInt s;
+    usqInt s;
     char *sp;
     sqInt sz;
 
@@ -38121,7 +38109,7 @@
     sqInt err;
     sqInt hash;
     sqInt instSpec;
-    sqInt newObj;
+    usqInt newObj;
     usqInt newObj1;
     usqInt numBytes;
     sqInt numSlots;
@@ -38246,7 +38234,7 @@
     sqInt i;
     usqInt instSpec;
     sqInt literalCount;
-    sqInt newObj;
+    usqInt newObj;
     usqInt newObj1;
     usqInt numBytes;
     sqInt numSlots;
@@ -44162,7 +44150,7 @@
     sqInt fillValue;
     sqInt hash;
     usqInt instSpec;
-    sqInt newObj;
+    usqInt newObj;
     usqInt newObj1;
     usqInt numBytes;
     usqInt numSlots;
@@ -46294,7 +46282,7 @@
     sqInt entry;
     sqInt expectedIndex;
     sqInt expectedIndex1;
-    sqInt freeChunk;
+    usqInt freeChunk;
     sqInt i;
     sqInt i1;
     sqInt index;
@@ -46333,8 +46321,8 @@
     sqInt ptr1;
     sqInt ptr2;
     sqInt slotBytes;
-    sqInt smallObj;
-    sqInt start;
+    usqInt smallObj;
+    usqInt start;
 
 	classIndex = (long32At(aClass + 4)) & 0x3FFFFF;
 	if (classIndex == 0) {
@@ -49275,7 +49263,7 @@
     sqInt fmt;
     sqInt hasYoung;
     sqInt i;
-    sqInt newObj;
+    usqInt newObj;
     usqInt newObj1;
     usqInt numBytes;
     usqInt numSlots;
@@ -60603,7 +60591,7 @@
     usqInt prevFree;
     usqInt prevFreeChunk;
     usqInt prevPrevFree;
-    usqInt prevPrevFreeChunk;
+    sqInt prevPrevFreeChunk;
     sqInt slotBytes;
     sqInt slotBytes1;
     usqInt there;
@@ -61712,6 +61700,7 @@
 {   DECL_MAYBE_SQ_GLOBAL_STRUCT
     sqInt i;
     sqInt oldClone;
+    sqInt referent;
     SpurSegmentInfo *seg;
 
 	assert(isNonImmediate(objOop));
@@ -61771,6 +61760,18 @@
 		if ((byteAt(objOop + 7)) == 0) {
 			byteAtput(objOop + 7, 1);
 		}
+		/* begin followSpecialObjectsOop */
+		if (((longAt(GIV(specialObjectsOop))) & (0x3FFFFF - 8)) == 0) {
+			/* begin followForwarded: */
+			assert(isUnambiguouslyForwarder(GIV(specialObjectsOop)));
+			referent = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (0 << (shiftForWord())));
+			while (((referent & 3) == 0)
+			 && (((longAt(referent)) & 0x3FFFFF) == 8)) {
+				referent = longAt((referent + BaseHeaderSize) + (0 << (shiftForWord())));
+			}
+			GIV(specialObjectsOop) = referent;
+		}
+		followForwardedObjectFieldstoDepth(GIV(specialObjectsOop), 0);
 		/* begin postBecomeAction: */
 		spurPostBecomeAction(GIV(becomeEffectsFlags));
 
@@ -63949,8 +63950,8 @@
     sqInt prevPrevObj;
     sqInt prevPrevObj1;
     sqInt ptr;
-    sqInt savedInHashes;
-    sqInt savedOutHashes;
+    usqInt savedInHashes;
+    usqInt savedOutHashes;
     sqInt segAddr;
     sqInt segStart;
     sqInt slotBytes;
@@ -64420,13 +64421,13 @@
 	or nil if out of memory. */
 
 	/* SpurMemoryManager>>#stringForCString: */
-sqInt
+usqInt
 stringForCString(const char *aCString)
 {   DECL_MAYBE_SQ_GLOBAL_STRUCT
     sqInt formatField;
     sqInt len;
     usqInt newObj;
-    sqInt newString;
+    usqInt newString;
     usqInt numBytes;
     sqInt numSlots;
 
@@ -65697,7 +65698,7 @@
     usqLong firstSavedBridgeWord;
     sqInt nWritten;
     usqInt pier1;
-    sqInt pier2;
+    usqInt pier2;
     usqLong secondSavedBridgeWord;
 
 	pier1 = (((segment->segSize)) + ((segment->segStart))) - (2 * BaseHeaderSize);
@@ -65782,7 +65783,8 @@
 {   DECL_MAYBE_SQ_GLOBAL_STRUCT
     sqInt lastLink;
 
-	assert(!(isForwarded(aList)));
+	assert(!((isForwarded(proc))));
+	assert(!((isForwarded(aList))));
 	assert((fetchPointerofObject(NextLinkIndex, proc)) == (nilObject()));
 	if (isEmptyList(aList)) {
 		/* begin storePointer:ofObject:withValue: */
@@ -76390,39 +76392,17 @@
     sqInt last;
     sqInt next;
 
-	assert(!(isForwarded(aList)));
+	assert(!((isForwarded(aList))));
 	first = longAt((aList + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())));
 	last = longAt((aList + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())));
+	assert(!((isForwarded(first))));
+	assert(!((isForwarded(last))));
 	if (first == last) {
-		/* begin storePointer:ofObject:withValue: */
+		/* begin storePointerUnchecked:ofObject:withValue: */
 		assert(!(isForwarded(aList)));
-		if (isOldObject(aList)) {
-
-			/* most stores into young objects */
-
-			if (((GIV(nilObj) & 3) == 0)
-			 && (oopisLessThan(GIV(nilObj), GIV(newSpaceLimit)))) {
-				/* begin possibleRootStoreInto: */
-				if (!(((((usqInt) (longAt(aList))) >> 29) & 1) != 0)) {
-					remember(aList);
-				}
-			}
-		}
 		longAtput((aList + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())), GIV(nilObj));
-		/* begin storePointer:ofObject:withValue: */
+		/* begin storePointerUnchecked:ofObject:withValue: */
 		assert(!(isForwarded(aList)));
-		if (isOldObject(aList)) {
-
-			/* most stores into young objects */
-
-			if (((GIV(nilObj) & 3) == 0)
-			 && (oopisLessThan(GIV(nilObj), GIV(newSpaceLimit)))) {
-				/* begin possibleRootStoreInto: */
-				if (!(((((usqInt) (longAt(aList))) >> 29) & 1) != 0)) {
-					remember(aList);
-				}
-			}
-		}
 		longAtput((aList + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())), GIV(nilObj));
 	}
 	else {
@@ -76443,20 +76423,8 @@
 		}
 		longAtput((aList + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())), next);
 	}
-	/* begin storePointer:ofObject:withValue: */
+	/* begin storePointerUnchecked:ofObject:withValue: */
 	assert(!(isForwarded(first)));
-	if (isOldObject(first)) {
-
-		/* most stores into young objects */
-
-		if (((GIV(nilObj) & 3) == 0)
-		 && (oopisLessThan(GIV(nilObj), GIV(newSpaceLimit)))) {
-			/* begin possibleRootStoreInto: */
-			if (!(((((usqInt) (longAt(first))) >> 29) & 1) != 0)) {
-				remember(first);
-			}
-		}
-	}
 	longAtput((first + BaseHeaderSize) + (NextLinkIndex << (shiftForWord())), GIV(nilObj));
 	return first;
 }
@@ -77595,7 +77563,6 @@
     sqInt objOop2;
     sqInt objOop3;
     sqInt objOop4;
-    sqInt objOop5;
     sqInt procLists;
     sqInt referent;
     sqInt referent1;
@@ -77662,254 +77629,253 @@
 			/* begin flushBecommedClassesInMethodZone */
 			unlinkSendsLinkedForInvalidClasses();
 		}
-		/* begin followForwardingPointersInScheduler */
+		if (theBecomeEffectsFlags & BecamePointerObjectFlag) {
+			/* begin followForwardingPointersInScheduler */
 
-		/* the GC follows pointers in the special objects array for us. */
+			/* the GC follows pointers in the special objects array for us. */
 
-		schedAssoc = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (SchedulerAssociation << (shiftForWord())));
-		assert(!(isForwarded(schedAssoc)));
-		/* begin followObjField:ofObject: */
-		objOop4 = longAt((schedAssoc + BaseHeaderSize) + (ValueIndex << (shiftForWord())));
-		assert(isNonImmediate(objOop4));
-		if (((longAt(objOop4)) & (0x3FFFFF - 8)) == 0) {
-			objOop4 = fixFollowedFieldofObjectwithInitialValue(ValueIndex, schedAssoc, objOop4);
-		}
-		sched = objOop4;
-		/* begin followObjField:ofObject: */
-		objOop5 = longAt((sched + BaseHeaderSize) + (ProcessListsIndex << (shiftForWord())));
-		assert(isNonImmediate(objOop5));
-		if (((longAt(objOop5)) & (0x3FFFFF - 8)) == 0) {
-			objOop5 = fixFollowedFieldofObjectwithInitialValue(ProcessListsIndex, sched, objOop5);
-		}
-		procLists = objOop5;
-		for (i3 = 0, iLimiT = ((numSlotsOf(procLists)) - 1); i3 <= iLimiT; i3 += 1) {
+			schedAssoc = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (SchedulerAssociation << (shiftForWord())));
+			assert(!(isForwarded(schedAssoc)));
+			followForwardedObjectFieldstoDepth(schedAssoc, 1);
+			sched = longAt((schedAssoc + BaseHeaderSize) + (ValueIndex << (shiftForWord())));
 			/* begin followObjField:ofObject: */
-			objOop1 = longAt((procLists + BaseHeaderSize) + (i3 << (shiftForWord())));
-			assert(isNonImmediate(objOop1));
-			if (((longAt(objOop1)) & (0x3FFFFF - 8)) == 0) {
-				objOop1 = fixFollowedFieldofObjectwithInitialValue(i3, procLists, objOop1);
+			objOop4 = longAt((sched + BaseHeaderSize) + (ProcessListsIndex << (shiftForWord())));
+			assert(isNonImmediate(objOop4));
+			if (((longAt(objOop4)) & (0x3FFFFF - 8)) == 0) {
+				objOop4 = fixFollowedFieldofObjectwithInitialValue(ProcessListsIndex, sched, objOop4);
 			}
-			list = objOop1;
-			/* begin followObjField:ofObject: */
-			objOop2 = longAt((list + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())));
-			assert(isNonImmediate(objOop2));
-			if (((longAt(objOop2)) & (0x3FFFFF - 8)) == 0) {
-				objOop2 = fixFollowedFieldofObjectwithInitialValue(FirstLinkIndex, list, objOop2);
-			}
-			first = objOop2;
-			/* begin followObjField:ofObject: */
-			objOop3 = longAt((list + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())));
-			assert(isNonImmediate(objOop3));
-			if (((longAt(objOop3)) & (0x3FFFFF - 8)) == 0) {
-				objOop3 = fixFollowedFieldofObjectwithInitialValue(LastLinkIndex, list, objOop3);
-			}
-			last = objOop3;
-			while (first != last) {
+			procLists = objOop4;
+			for (i3 = 0, iLimiT = ((numSlotsOf(procLists)) - 1); i3 <= iLimiT; i3 += 1) {
 				/* begin followObjField:ofObject: */
-				objOop = longAt((first + BaseHeaderSize) + (NextLinkIndex << (shiftForWord())));
-				assert(isNonImmediate(objOop));
-				if (((longAt(objOop)) & (0x3FFFFF - 8)) == 0) {
-					objOop = fixFollowedFieldofObjectwithInitialValue(NextLinkIndex, first, objOop);
+				objOop1 = longAt((procLists + BaseHeaderSize) + (i3 << (shiftForWord())));
+				assert(isNonImmediate(objOop1));
+				if (((longAt(objOop1)) & (0x3FFFFF - 8)) == 0) {
+					objOop1 = fixFollowedFieldofObjectwithInitialValue(i3, procLists, objOop1);
 				}
-				next = objOop;
-				first = next;
-			}
-		}
-		/* begin followForwardingPointersInSpecialObjectsArray */
-		/* begin followSemaphoreIn:at: */
-		obj1 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheLowSpaceSemaphore << (shiftForWord())));
-		if (((longAt(obj1)) & (0x3FFFFF - 8)) == 0) {
-			/* begin followForwarded: */
-			assert(isUnambiguouslyForwarder(obj1));
-			referent11 = longAt((obj1 + BaseHeaderSize) + (0 << (shiftForWord())));
-			while (((referent11 & 3) == 0)
-			 && (((longAt(referent11)) & 0x3FFFFF) == 8)) {
-				referent11 = longAt((referent11 + BaseHeaderSize) + (0 << (shiftForWord())));
-			}
-			obj1 = referent11;
-			/* begin storePointer:ofObject:withValue: */
-			assert(!(isForwarded(GIV(specialObjectsOop))));
-			if (isOldObject(GIV(specialObjectsOop))) {
-
-				/* most stores into young objects */
-
-				if (((obj1 & 3) == 0)
-				 && (oopisLessThan(obj1, GIV(newSpaceLimit)))) {
-					/* begin possibleRootStoreInto: */
-					if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
-						remember(GIV(specialObjectsOop));
+				list = objOop1;
+				/* begin followObjField:ofObject: */
+				objOop2 = longAt((list + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())));
+				assert(isNonImmediate(objOop2));
+				if (((longAt(objOop2)) & (0x3FFFFF - 8)) == 0) {
+					objOop2 = fixFollowedFieldofObjectwithInitialValue(FirstLinkIndex, list, objOop2);
+				}
+				first = objOop2;
+				/* begin followObjField:ofObject: */
+				objOop3 = longAt((list + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())));
+				assert(isNonImmediate(objOop3));
+				if (((longAt(objOop3)) & (0x3FFFFF - 8)) == 0) {
+					objOop3 = fixFollowedFieldofObjectwithInitialValue(LastLinkIndex, list, objOop3);
+				}
+				last = objOop3;
+				while (first != last) {
+					/* begin followObjField:ofObject: */
+					objOop = longAt((first + BaseHeaderSize) + (NextLinkIndex << (shiftForWord())));
+					assert(isNonImmediate(objOop));
+					if (((longAt(objOop)) & (0x3FFFFF - 8)) == 0) {
+						objOop = fixFollowedFieldofObjectwithInitialValue(NextLinkIndex, first, objOop);
 					}
+					next = objOop;
+					first = next;
 				}
 			}
-			longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (TheLowSpaceSemaphore << (shiftForWord())), obj1);
-		}
-		/* begin followSemaphoreIn:at: */
-		obj2 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheInterruptSemaphore << (shiftForWord())));
-		if (((longAt(obj2)) & (0x3FFFFF - 8)) == 0) {
-			/* begin followForwarded: */
-			assert(isUnambiguouslyForwarder(obj2));
-			referent21 = longAt((obj2 + BaseHeaderSize) + (0 << (shiftForWord())));
-			while (((referent21 & 3) == 0)
-			 && (((longAt(referent21)) & 0x3FFFFF) == 8)) {
-				referent21 = longAt((referent21 + BaseHeaderSize) + (0 << (shiftForWord())));
-			}
-			obj2 = referent21;
-			/* begin storePointer:ofObject:withValue: */
-			assert(!(isForwarded(GIV(specialObjectsOop))));
-			if (isOldObject(GIV(specialObjectsOop))) {
+			/* begin followForwardingPointersInSpecialObjectsArray */
+			/* begin followSemaphoreIn:at: */
+			obj1 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheLowSpaceSemaphore << (shiftForWord())));
+			if (((longAt(obj1)) & (0x3FFFFF - 8)) == 0) {
+				/* begin followForwarded: */
+				assert(isUnambiguouslyForwarder(obj1));
+				referent11 = longAt((obj1 + BaseHeaderSize) + (0 << (shiftForWord())));
+				while (((referent11 & 3) == 0)
+				 && (((longAt(referent11)) & 0x3FFFFF) == 8)) {
+					referent11 = longAt((referent11 + BaseHeaderSize) + (0 << (shiftForWord())));
+				}
+				obj1 = referent11;
+				/* begin storePointer:ofObject:withValue: */
+				assert(!(isForwarded(GIV(specialObjectsOop))));
+				if (isOldObject(GIV(specialObjectsOop))) {
 
-				/* most stores into young objects */
+					/* most stores into young objects */
 
-				if (((obj2 & 3) == 0)
-				 && (oopisLessThan(obj2, GIV(newSpaceLimit)))) {
-					/* begin possibleRootStoreInto: */
-					if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
-						remember(GIV(specialObjectsOop));
+					if (((obj1 & 3) == 0)
+					 && (oopisLessThan(obj1, GIV(newSpaceLimit)))) {
+						/* begin possibleRootStoreInto: */
+						if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
+							remember(GIV(specialObjectsOop));
+						}
 					}
 				}
+				longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (TheLowSpaceSemaphore << (shiftForWord())), obj1);
 			}
-			longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (TheInterruptSemaphore << (shiftForWord())), obj2);
-		}
-		/* begin followSemaphoreIn:at: */
-		obj3 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheTimerSemaphore << (shiftForWord())));
-		if (((longAt(obj3)) & (0x3FFFFF - 8)) == 0) {
-			/* begin followForwarded: */
-			assert(isUnambiguouslyForwarder(obj3));
-			referent31 = longAt((obj3 + BaseHeaderSize) + (0 << (shiftForWord())));
-			while (((referent31 & 3) == 0)
-			 && (((longAt(referent31)) & 0x3FFFFF) == 8)) {
-				referent31 = longAt((referent31 + BaseHeaderSize) + (0 << (shiftForWord())));
-			}
-			obj3 = referent31;
-			/* begin storePointer:ofObject:withValue: */
-			assert(!(isForwarded(GIV(specialObjectsOop))));
-			if (isOldObject(GIV(specialObjectsOop))) {
+			/* begin followSemaphoreIn:at: */
+			obj2 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheInterruptSemaphore << (shiftForWord())));
+			if (((longAt(obj2)) & (0x3FFFFF - 8)) == 0) {
+				/* begin followForwarded: */
+				assert(isUnambiguouslyForwarder(obj2));
+				referent21 = longAt((obj2 + BaseHeaderSize) + (0 << (shiftForWord())));
+				while (((referent21 & 3) == 0)
+				 && (((longAt(referent21)) & 0x3FFFFF) == 8)) {
+					referent21 = longAt((referent21 + BaseHeaderSize) + (0 << (shiftForWord())));
+				}
+				obj2 = referent21;
+				/* begin storePointer:ofObject:withValue: */
+				assert(!(isForwarded(GIV(specialObjectsOop))));
+				if (isOldObject(GIV(specialObjectsOop))) {
 
-				/* most stores into young objects */
+					/* most stores into young objects */
 
-				if (((obj3 & 3) == 0)
-				 && (oopisLessThan(obj3, GIV(newSpaceLimit)))) {
-					/* begin possibleRootStoreInto: */
-					if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
-						remember(GIV(specialObjectsOop));
+					if (((obj2 & 3) == 0)
+					 && (oopisLessThan(obj2, GIV(newSpaceLimit)))) {
+						/* begin possibleRootStoreInto: */
+						if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
+							remember(GIV(specialObjectsOop));
+						}
 					}
 				}
+				longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (TheInterruptSemaphore << (shiftForWord())), obj2);
 			}
-			longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (TheTimerSemaphore << (shiftForWord())), obj3);
-		}
-		/* begin followSemaphoreIn:at: */
-		obj4 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheFinalizationSemaphore << (shiftForWord())));
-		if (((longAt(obj4)) & (0x3FFFFF - 8)) == 0) {
-			/* begin followForwarded: */
-			assert(isUnambiguouslyForwarder(obj4));
-			referent4 = longAt((obj4 + BaseHeaderSize) + (0 << (shiftForWord())));
-			while (((referent4 & 3) == 0)
-			 && (((longAt(referent4)) & 0x3FFFFF) == 8)) {
-				referent4 = longAt((referent4 + BaseHeaderSize) + (0 << (shiftForWord())));
-			}
-			obj4 = referent4;
-			/* begin storePointer:ofObject:withValue: */
-			assert(!(isForwarded(GIV(specialObjectsOop))));
-			if (isOldObject(GIV(specialObjectsOop))) {
+			/* begin followSemaphoreIn:at: */
+			obj3 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheTimerSemaphore << (shiftForWord())));
+			if (((longAt(obj3)) & (0x3FFFFF - 8)) == 0) {
+				/* begin followForwarded: */
+				assert(isUnambiguouslyForwarder(obj3));
+				referent31 = longAt((obj3 + BaseHeaderSize) + (0 << (shiftForWord())));
+				while (((referent31 & 3) == 0)
+				 && (((longAt(referent31)) & 0x3FFFFF) == 8)) {
+					referent31 = longAt((referent31 + BaseHeaderSize) + (0 << (shiftForWord())));
+				}
+				obj3 = referent31;
+				/* begin storePointer:ofObject:withValue: */
+				assert(!(isForwarded(GIV(specialObjectsOop))));
+				if (isOldObject(GIV(specialObjectsOop))) {
 
-				/* most stores into young objects */
+					/* most stores into young objects */
 
-				if (((obj4 & 3) == 0)
-				 && (oopisLessThan(obj4, GIV(newSpaceLimit)))) {
-					/* begin possibleRootStoreInto: */
-					if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
-						remember(GIV(specialObjectsOop));
+					if (((obj3 & 3) == 0)
+					 && (oopisLessThan(obj3, GIV(newSpaceLimit)))) {
+						/* begin possibleRootStoreInto: */
+						if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
+							remember(GIV(specialObjectsOop));
+						}
 					}
 				}
+				longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (TheTimerSemaphore << (shiftForWord())), obj3);
 			}
-			longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (TheFinalizationSemaphore << (shiftForWord())), obj4);
-		}
-		xArray = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (ExternalObjectsArray << (shiftForWord())));
-		if (((longAt(xArray)) & (0x3FFFFF - 8)) == 0) {
-			/* begin followForwarded: */
-			assert(isUnambiguouslyForwarder(xArray));
-			referent6 = longAt((xArray + BaseHeaderSize) + (0 << (shiftForWord())));
-			while (((referent6 & 3) == 0)
-			 && (((longAt(referent6)) & 0x3FFFFF) == 8)) {
-				referent6 = longAt((referent6 + BaseHeaderSize) + (0 << (shiftForWord())));
-			}
-			xArray = referent6;
-			/* begin splObj:put: */
-			/* begin storePointer:ofObject:withValue: */
-			assert(!(isForwarded(GIV(specialObjectsOop))));
-			if (isOldObject(GIV(specialObjectsOop))) {
+			/* begin followSemaphoreIn:at: */
+			obj4 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheFinalizationSemaphore << (shiftForWord())));
+			if (((longAt(obj4)) & (0x3FFFFF - 8)) == 0) {
+				/* begin followForwarded: */
+				assert(isUnambiguouslyForwarder(obj4));
+				referent4 = longAt((obj4 + BaseHeaderSize) + (0 << (shiftForWord())));
+				while (((referent4 & 3) == 0)
+				 && (((longAt(referent4)) & 0x3FFFFF) == 8)) {
+					referent4 = longAt((referent4 + BaseHeaderSize) + (0 << (shiftForWord())));
+				}
+				obj4 = referent4;
+				/* begin storePointer:ofObject:withValue: */
+				assert(!(isForwarded(GIV(specialObjectsOop))));
+				if (isOldObject(GIV(specialObjectsOop))) {
 
-				/* most stores into young objects */
+					/* most stores into young objects */
 
-				if (((xArray & 3) == 0)
-				 && (oopisLessThan(xArray, GIV(newSpaceLimit)))) {
-					/* begin possibleRootStoreInto: */
-					if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
-						remember(GIV(specialObjectsOop));
+					if (((obj4 & 3) == 0)
+					 && (oopisLessThan(obj4, GIV(newSpaceLimit)))) {
+						/* begin possibleRootStoreInto: */
+						if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
+							remember(GIV(specialObjectsOop));
+						}
 					}
 				}
+				longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (TheFinalizationSemaphore << (shiftForWord())), obj4);
 			}
-			longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (ExternalObjectsArray << (shiftForWord())), xArray);
-		}
-		for (i4 = 0, iLimiT1 = ((numSlotsOf(xArray)) - 1); i4 <= iLimiT1; i4 += 1) {
-			/* begin followSemaphoreIn:at: */
-			obj = longAt((xArray + BaseHeaderSize) + (i4 << (shiftForWord())));
-			if (((longAt(obj)) & (0x3FFFFF - 8)) == 0) {
+			xArray = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (ExternalObjectsArray << (shiftForWord())));
+			if (((longAt(xArray)) & (0x3FFFFF - 8)) == 0) {
 				/* begin followForwarded: */
-				assert(isUnambiguouslyForwarder(obj));
-				referent5 = longAt((obj + BaseHeaderSize) + (0 << (shiftForWord())));
-				while (((referent5 & 3) == 0)
-				 && (((longAt(referent5)) & 0x3FFFFF) == 8)) {
-					referent5 = longAt((referent5 + BaseHeaderSize) + (0 << (shiftForWord())));
+				assert(isUnambiguouslyForwarder(xArray));
+				referent6 = longAt((xArray + BaseHeaderSize) + (0 << (shiftForWord())));
+				while (((referent6 & 3) == 0)
+				 && (((longAt(referent6)) & 0x3FFFFF) == 8)) {
+					referent6 = longAt((referent6 + BaseHeaderSize) + (0 << (shiftForWord())));
 				}
-				obj = referent5;
+				xArray = referent6;
+				/* begin splObj:put: */
 				/* begin storePointer:ofObject:withValue: */
-				assert(!(isForwarded(xArray)));
-				if (isOldObject(xArray)) {
+				assert(!(isForwarded(GIV(specialObjectsOop))));
+				if (isOldObject(GIV(specialObjectsOop))) {
 
 					/* most stores into young objects */
 
-					if (((obj & 3) == 0)
-					 && (oopisLessThan(obj, GIV(newSpaceLimit)))) {
+					if (((xArray & 3) == 0)
+					 && (oopisLessThan(xArray, GIV(newSpaceLimit)))) {
 						/* begin possibleRootStoreInto: */
-						if (!(((((usqInt) (longAt(xArray))) >> 29) & 1) != 0)) {
-							remember(xArray);
+						if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
+							remember(GIV(specialObjectsOop));
 						}
 					}
 				}
-				longAtput((xArray + BaseHeaderSize) + (i4 << (shiftForWord())), obj);
+				longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (ExternalObjectsArray << (shiftForWord())), xArray);
 			}
-		}
-		/* begin followForwardingPointersInProfileState */
-		if (((longAt(GIV(profileProcess))) & (0x3FFFFF - 8)) == 0) {
-			/* begin followForwarded: */
-			assert(isUnambiguouslyForwarder(GIV(profileProcess)));
-			referent1 = longAt((GIV(profileProcess) + BaseHeaderSize) + (0 << (shiftForWord())));
-			while (((referent1 & 3) == 0)
-			 && (((longAt(referent1)) & 0x3FFFFF) == 8)) {
-				referent1 = longAt((referent1 + BaseHeaderSize) + (0 << (shiftForWord())));
+			for (i4 = 0, iLimiT1 = ((numSlotsOf(xArray)) - 1); i4 <= iLimiT1; i4 += 1) {
+				/* begin followSemaphoreIn:at: */
+				obj = longAt((xArray + BaseHeaderSize) + (i4 << (shiftForWord())));
+				if (((longAt(obj)) & (0x3FFFFF - 8)) == 0) {
+					/* begin followForwarded: */
+					assert(isUnambiguouslyForwarder(obj));
+					referent5 = longAt((obj + BaseHeaderSize) + (0 << (shiftForWord())));
+					while (((referent5 & 3) == 0)
+					 && (((longAt(referent5)) & 0x3FFFFF) == 8)) {
+						referent5 = longAt((referent5 + BaseHeaderSize) + (0 << (shiftForWord())));
+					}
+					obj = referent5;
+					/* begin storePointer:ofObject:withValue: */
+					assert(!(isForwarded(xArray)));
+					if (isOldObject(xArray)) {
+
+						/* most stores into young objects */
+
+						if (((obj & 3) == 0)
+						 && (oopisLessThan(obj, GIV(newSpaceLimit)))) {
+							/* begin possibleRootStoreInto: */
+							if (!(((((usqInt) (longAt(xArray))) >> 29) & 1) != 0)) {
+								remember(xArray);
+							}
+						}
+					}
+					longAtput((xArray + BaseHeaderSize) + (i4 << (shiftForWord())), obj);
+				}
 			}
-			GIV(profileProcess) = referent1;
 		}
-		if (((longAt(GIV(profileMethod))) & (0x3FFFFF - 8)) == 0) {
-			/* begin followForwarded: */
-			assert(isUnambiguouslyForwarder(GIV(profileMethod)));
-			referent2 = longAt((GIV(profileMethod) + BaseHeaderSize) + (0 << (shiftForWord())));
-			while (((referent2 & 3) == 0)
-			 && (((longAt(referent2)) & 0x3FFFFF) == 8)) {
-				referent2 = longAt((referent2 + BaseHeaderSize) + (0 << (shiftForWord())));
+		if (theBecomeEffectsFlags & (BecamePointerObjectFlag + BecameCompiledMethodFlag)) {
+			/* begin followForwardingPointersInProfileState */
+			if (((longAt(GIV(profileProcess))) & (0x3FFFFF - 8)) == 0) {
+				/* begin followForwarded: */
+				assert(isUnambiguouslyForwarder(GIV(profileProcess)));
+				referent1 = longAt((GIV(profileProcess) + BaseHeaderSize) + (0 << (shiftForWord())));
+				while (((referent1 & 3) == 0)
+				 && (((longAt(referent1)) & 0x3FFFFF) == 8)) {
+					referent1 = longAt((referent1 + BaseHeaderSize) + (0 << (shiftForWord())));
+				}
+				GIV(profileProcess) = referent1;
 			}
-			GIV(profileMethod) = referent2;
-		}
-		if (((longAt(GIV(profileProcess))) & (0x3FFFFF - 8)) == 0) {
-			/* begin followForwarded: */
-			assert(isUnambiguouslyForwarder(GIV(profileSemaphore)));
-			referent3 = longAt((GIV(profileSemaphore) + BaseHeaderSize) + (0 << (shiftForWord())));
-			while (((referent3 & 3) == 0)
-			 && (((longAt(referent3)) & 0x3FFFFF) == 8)) {
-				referent3 = longAt((referent3 + BaseHeaderSize) + (0 << (shiftForWord())));
+			if (((longAt(GIV(profileMethod))) & (0x3FFFFF - 8)) == 0) {
+				/* begin followForwarded: */
+				assert(isUnambiguouslyForwarder(GIV(profileMethod)));
+				referent2 = longAt((GIV(profileMethod) + BaseHeaderSize) + (0 << (shiftForWord())));
+				while (((referent2 & 3) == 0)
+				 && (((longAt(referent2)) & 0x3FFFFF) == 8)) {
+					referent2 = longAt((referent2 + BaseHeaderSize) + (0 << (shiftForWord())));
+				}
+				GIV(profileMethod) = referent2;
 			}
-			GIV(profileSemaphore) = referent3;
+			if (((longAt(GIV(profileProcess))) & (0x3FFFFF - 8)) == 0) {
+				/* begin followForwarded: */
+				assert(isUnambiguouslyForwarder(GIV(profileSemaphore)));
+				referent3 = longAt((GIV(profileSemaphore) + BaseHeaderSize) + (0 << (shiftForWord())));
+				while (((referent3 & 3) == 0)
+				 && (((longAt(referent3)) & 0x3FFFFF) == 8)) {
+					referent3 = longAt((referent3 + BaseHeaderSize) + (0 << (shiftForWord())));
+				}
+				GIV(profileSemaphore) = referent3;
+			}
 		}
 	}
 	followForwardingPointersInStackZone(theBecomeEffectsFlags);

Modified: branches/Cog/nsspursrc/vm/cointerp.h
===================================================================
--- branches/Cog/nsspursrc/vm/cointerp.h	2015-07-04 16:09:13 UTC (rev 3396)
+++ branches/Cog/nsspursrc/vm/cointerp.h	2015-07-06 18:56:39 UTC (rev 3397)
@@ -1,5 +1,5 @@
 /* Automatically generated by
-	CCodeGeneratorGlobalStructure VMMaker.oscog-eem.1403 uuid: 66fdf690-416b-4359-be28-c0387023baa6
+	CCodeGeneratorGlobalStructure VMMaker.oscog-eem.1405 uuid: 7aff388a-73ba-4202-bb5a-72b0759ff46b
  */
 
 
@@ -258,7 +258,7 @@
 extern sqInt splObj(sqInt index);
 extern usqInt storeCheckBoundary(void);
 extern sqInt storePointerUncheckedofObjectwithValue(sqInt fieldIndex, sqInt objOop, sqInt valuePointer);
-extern sqInt stringForCString(const char *aCString);
+extern usqInt stringForCString(const char *aCString);
 extern void tenuringIncrementalGC(void);
 extern sqInt topRemappableOop(void);
 extern sqInt validFreeTree(void);

Modified: branches/Cog/nsspursrc/vm/gcc3x-cointerp.c
===================================================================
--- branches/Cog/nsspursrc/vm/gcc3x-cointerp.c	2015-07-04 16:09:13 UTC (rev 3396)
+++ branches/Cog/nsspursrc/vm/gcc3x-cointerp.c	2015-07-06 18:56:39 UTC (rev 3397)
@@ -2,11 +2,11 @@
 
 
 /* Automatically generated by
-	CCodeGeneratorGlobalStructure VMMaker.oscog-eem.1403 uuid: 66fdf690-416b-4359-be28-c0387023baa6
+	CCodeGeneratorGlobalStructure VMMaker.oscog-eem.1405 uuid: 7aff388a-73ba-4202-bb5a-72b0759ff46b
    from
-	CoInterpreter VMMaker.oscog-eem.1403 uuid: 66fdf690-416b-4359-be28-c0387023baa6
+	CoInterpreter VMMaker.oscog-eem.1405 uuid: 7aff388a-73ba-4202-bb5a-72b0759ff46b
  */
-static char __buildInfo[] = "CoInterpreter VMMaker.oscog-eem.1403 uuid: 66fdf690-416b-4359-be28-c0387023baa6 " __DATE__ ;
+static char __buildInfo[] = "CoInterpreter VMMaker.oscog-eem.1405 uuid: 7aff388a-73ba-4202-bb5a-72b0759ff46b " __DATE__ ;
 char *__interpBuildInfo = __buildInfo;
 
 
@@ -1210,7 +1210,7 @@
 static sqInt storeImageSegmentIntooutPointersroots(sqInt segmentWordArray, sqInt outPointerArray, sqInt arrayOfRoots) NoDbgRegParms;
 extern sqInt storePointerUncheckedofObjectwithValue(sqInt fieldIndex, sqInt objOop, sqInt valuePointer);
 extern sqInt storePointerofObjectwithValue(sqInt fieldIndex, sqInt objOop, sqInt valuePointer);
-extern sqInt stringForCString(const char *aCString);
+extern usqInt stringForCString(const char *aCString);
 static sqInt sufficientSpaceAfterGC(sqInt numBytes) NoDbgRegParms;
 static sqInt swizzleObjStackAt(sqInt objStackRootIndex) NoDbgRegParms;
 extern void tenuringIncrementalGC(void);
@@ -2413,7 +2413,7 @@
 /*560*/	-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, 0, 0, 0,-1,-1
 	};
 char expensiveAsserts = 0;
-const char *interpreterVersion = "Newspeak Virtual Machine CoInterpreterPrimitives_VMMaker.oscog-eem.1403";
+const char *interpreterVersion = "Newspeak Virtual Machine CoInterpreterPrimitives_VMMaker.oscog-eem.1405";
 sqInt minBackwardJumpCountForCompile = MinBackwardJumpCountForCompile /* 40 */;
 volatile int sendTrace;
 
@@ -28749,11 +28749,15 @@
 		longAtput((process + BaseHeaderSize) + (MyListIndex << (shiftForWord())), myList);
 	}
 	/* begin removeProcess:fromList: */
-	assert(!(isForwarded(myList)));
+	assert(!((isForwarded(process))));
+	assert(!((isForwarded(myList))));
 	firstLink = longAt((myList + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())));
 	lastLink = longAt((myList + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())));
+	assert(!((isForwarded(firstLink))));
+	assert(!((isForwarded(lastLink))));
 	if (process == firstLink) {
 		nextLink = longAt((process + BaseHeaderSize) + (NextLinkIndex << (shiftForWord())));
+		assert(!((isForwarded(nextLink))));
 		/* begin storePointer:ofObject:withValue: */
 		assert(!(isForwarded(myList)));
 		if (isOldObject(myList)) {
@@ -28770,36 +28774,20 @@
 		}
 		longAtput((myList + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())), nextLink);
 		if (process == lastLink) {
-			/* begin storePointer:ofObject:withValue: */
+			/* begin storePointerUnchecked:ofObject:withValue: */
 			assert(!(isForwarded(myList)));
-			if (isOldObject(myList)) {
-
-				/* most stores into young objects */
-
-				if (((GIV(nilObj) & 3) == 0)
-				 && (oopisLessThan(GIV(nilObj), GIV(newSpaceLimit)))) {
-					/* begin possibleRootStoreInto: */
-					if (!(((((usqInt) (longAt(myList))) >> 29) & 1) != 0)) {
-						remember(myList);
-					}
-				}
-			}
 			longAtput((myList + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())), GIV(nilObj));
 		}
 	}
 	else {
 		tempLink = firstLink;
 		while (1) {
+			assert(!((isForwarded(tempLink))));
 			if (tempLink == GIV(nilObj)) {
-				/* begin success: */
-				
-				/* Don't overwrite an error code that has already been set. */
-
+				/* begin primitiveFail */
 				if (!GIV(primFailCode)) {
 					GIV(primFailCode) = 1;
 				}
-
-				null;
 				goto l1;
 			}
 			nextLink = longAt((tempLink + BaseHeaderSize) + (NextLinkIndex << (shiftForWord())));
@@ -32453,7 +32441,7 @@
     usqInt newObj;
     usqInt numBytes;
     sqInt numSlots;
-    sqInt s;
+    usqInt s;
     char *sp;
     sqInt sz;
 
@@ -38130,7 +38118,7 @@
     sqInt err;
     sqInt hash;
     sqInt instSpec;
-    sqInt newObj;
+    usqInt newObj;
     usqInt newObj1;
     usqInt numBytes;
     sqInt numSlots;
@@ -38255,7 +38243,7 @@
     sqInt i;
     usqInt instSpec;
     sqInt literalCount;
-    sqInt newObj;
+    usqInt newObj;
     usqInt newObj1;
     usqInt numBytes;
     sqInt numSlots;
@@ -44171,7 +44159,7 @@
     sqInt fillValue;
     sqInt hash;
     usqInt instSpec;
-    sqInt newObj;
+    usqInt newObj;
     usqInt newObj1;
     usqInt numBytes;
     usqInt numSlots;
@@ -46303,7 +46291,7 @@
     sqInt entry;
     sqInt expectedIndex;
     sqInt expectedIndex1;
-    sqInt freeChunk;
+    usqInt freeChunk;
     sqInt i;
     sqInt i1;
     sqInt index;
@@ -46342,8 +46330,8 @@
     sqInt ptr1;
     sqInt ptr2;
     sqInt slotBytes;
-    sqInt smallObj;
-    sqInt start;
+    usqInt smallObj;
+    usqInt start;
 
 	classIndex = (long32At(aClass + 4)) & 0x3FFFFF;
 	if (classIndex == 0) {
@@ -49284,7 +49272,7 @@
     sqInt fmt;
     sqInt hasYoung;
     sqInt i;
-    sqInt newObj;
+    usqInt newObj;
     usqInt newObj1;
     usqInt numBytes;
     usqInt numSlots;
@@ -60612,7 +60600,7 @@
     usqInt prevFree;
     usqInt prevFreeChunk;
     usqInt prevPrevFree;
-    usqInt prevPrevFreeChunk;
+    sqInt prevPrevFreeChunk;
     sqInt slotBytes;
     sqInt slotBytes1;
     usqInt there;
@@ -61721,6 +61709,7 @@
 {   DECL_MAYBE_SQ_GLOBAL_STRUCT
     sqInt i;
     sqInt oldClone;
+    sqInt referent;
     SpurSegmentInfo *seg;
 
 	assert(isNonImmediate(objOop));
@@ -61780,6 +61769,18 @@
 		if ((byteAt(objOop + 7)) == 0) {
 			byteAtput(objOop + 7, 1);
 		}
+		/* begin followSpecialObjectsOop */
+		if (((longAt(GIV(specialObjectsOop))) & (0x3FFFFF - 8)) == 0) {
+			/* begin followForwarded: */
+			assert(isUnambiguouslyForwarder(GIV(specialObjectsOop)));
+			referent = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (0 << (shiftForWord())));
+			while (((referent & 3) == 0)
+			 && (((longAt(referent)) & 0x3FFFFF) == 8)) {
+				referent = longAt((referent + BaseHeaderSize) + (0 << (shiftForWord())));
+			}
+			GIV(specialObjectsOop) = referent;
+		}
+		followForwardedObjectFieldstoDepth(GIV(specialObjectsOop), 0);
 		/* begin postBecomeAction: */
 		spurPostBecomeAction(GIV(becomeEffectsFlags));
 
@@ -63958,8 +63959,8 @@
     sqInt prevPrevObj;
     sqInt prevPrevObj1;
     sqInt ptr;
-    sqInt savedInHashes;
-    sqInt savedOutHashes;
+    usqInt savedInHashes;
+    usqInt savedOutHashes;
     sqInt segAddr;
     sqInt segStart;
     sqInt slotBytes;
@@ -64429,13 +64430,13 @@
 	or nil if out of memory. */
 
 	/* SpurMemoryManager>>#stringForCString: */
-sqInt
+usqInt
 stringForCString(const char *aCString)
 {   DECL_MAYBE_SQ_GLOBAL_STRUCT
     sqInt formatField;
     sqInt len;
     usqInt newObj;
-    sqInt newString;
+    usqInt newString;
     usqInt numBytes;
     sqInt numSlots;
 
@@ -65706,7 +65707,7 @@
     usqLong firstSavedBridgeWord;
     sqInt nWritten;
     usqInt pier1;
-    sqInt pier2;
+    usqInt pier2;
     usqLong secondSavedBridgeWord;
 
 	pier1 = (((segment->segSize)) + ((segment->segStart))) - (2 * BaseHeaderSize);
@@ -65791,7 +65792,8 @@
 {   DECL_MAYBE_SQ_GLOBAL_STRUCT
     sqInt lastLink;
 
-	assert(!(isForwarded(aList)));
+	assert(!((isForwarded(proc))));
+	assert(!((isForwarded(aList))));
 	assert((fetchPointerofObject(NextLinkIndex, proc)) == (nilObject()));
 	if (isEmptyList(aList)) {
 		/* begin storePointer:ofObject:withValue: */
@@ -76399,39 +76401,17 @@
     sqInt last;
     sqInt next;
 
-	assert(!(isForwarded(aList)));
+	assert(!((isForwarded(aList))));
 	first = longAt((aList + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())));
 	last = longAt((aList + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())));
+	assert(!((isForwarded(first))));
+	assert(!((isForwarded(last))));
 	if (first == last) {
-		/* begin storePointer:ofObject:withValue: */
+		/* begin storePointerUnchecked:ofObject:withValue: */
 		assert(!(isForwarded(aList)));
-		if (isOldObject(aList)) {
-
-			/* most stores into young objects */
-
-			if (((GIV(nilObj) & 3) == 0)
-			 && (oopisLessThan(GIV(nilObj), GIV(newSpaceLimit)))) {
-				/* begin possibleRootStoreInto: */
-				if (!(((((usqInt) (longAt(aList))) >> 29) & 1) != 0)) {
-					remember(aList);
-				}
-			}
-		}
 		longAtput((aList + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())), GIV(nilObj));
-		/* begin storePointer:ofObject:withValue: */
+		/* begin storePointerUnchecked:ofObject:withValue: */
 		assert(!(isForwarded(aList)));
-		if (isOldObject(aList)) {
-
-			/* most stores into young objects */
-
-			if (((GIV(nilObj) & 3) == 0)
-			 && (oopisLessThan(GIV(nilObj), GIV(newSpaceLimit)))) {
-				/* begin possibleRootStoreInto: */
-				if (!(((((usqInt) (longAt(aList))) >> 29) & 1) != 0)) {
-					remember(aList);
-				}
-			}
-		}
 		longAtput((aList + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())), GIV(nilObj));
 	}
 	else {
@@ -76452,20 +76432,8 @@
 		}
 		longAtput((aList + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())), next);
 	}
-	/* begin storePointer:ofObject:withValue: */
+	/* begin storePointerUnchecked:ofObject:withValue: */
 	assert(!(isForwarded(first)));
-	if (isOldObject(first)) {
-
-		/* most stores into young objects */
-
-		if (((GIV(nilObj) & 3) == 0)
-		 && (oopisLessThan(GIV(nilObj), GIV(newSpaceLimit)))) {
-			/* begin possibleRootStoreInto: */
-			if (!(((((usqInt) (longAt(first))) >> 29) & 1) != 0)) {
-				remember(first);
-			}
-		}
-	}
 	longAtput((first + BaseHeaderSize) + (NextLinkIndex << (shiftForWord())), GIV(nilObj));
 	return first;
 }
@@ -77604,7 +77572,6 @@
     sqInt objOop2;
     sqInt objOop3;
     sqInt objOop4;
-    sqInt objOop5;
     sqInt procLists;
     sqInt referent;
     sqInt referent1;
@@ -77671,254 +77638,253 @@
 			/* begin flushBecommedClassesInMethodZone */
 			unlinkSendsLinkedForInvalidClasses();
 		}
-		/* begin followForwardingPointersInScheduler */
+		if (theBecomeEffectsFlags & BecamePointerObjectFlag) {
+			/* begin followForwardingPointersInScheduler */
 
-		/* the GC follows pointers in the special objects array for us. */
+			/* the GC follows pointers in the special objects array for us. */
 
-		schedAssoc = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (SchedulerAssociation << (shiftForWord())));
-		assert(!(isForwarded(schedAssoc)));
-		/* begin followObjField:ofObject: */
-		objOop4 = longAt((schedAssoc + BaseHeaderSize) + (ValueIndex << (shiftForWord())));
-		assert(isNonImmediate(objOop4));
-		if (((longAt(objOop4)) & (0x3FFFFF - 8)) == 0) {
-			objOop4 = fixFollowedFieldofObjectwithInitialValue(ValueIndex, schedAssoc, objOop4);
-		}
-		sched = objOop4;
-		/* begin followObjField:ofObject: */
-		objOop5 = longAt((sched + BaseHeaderSize) + (ProcessListsIndex << (shiftForWord())));
-		assert(isNonImmediate(objOop5));
-		if (((longAt(objOop5)) & (0x3FFFFF - 8)) == 0) {
-			objOop5 = fixFollowedFieldofObjectwithInitialValue(ProcessListsIndex, sched, objOop5);
-		}
-		procLists = objOop5;
-		for (i3 = 0, iLimiT = ((numSlotsOf(procLists)) - 1); i3 <= iLimiT; i3 += 1) {
+			schedAssoc = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (SchedulerAssociation << (shiftForWord())));
+			assert(!(isForwarded(schedAssoc)));
+			followForwardedObjectFieldstoDepth(schedAssoc, 1);
+			sched = longAt((schedAssoc + BaseHeaderSize) + (ValueIndex << (shiftForWord())));
 			/* begin followObjField:ofObject: */
-			objOop1 = longAt((procLists + BaseHeaderSize) + (i3 << (shiftForWord())));
-			assert(isNonImmediate(objOop1));
-			if (((longAt(objOop1)) & (0x3FFFFF - 8)) == 0) {
-				objOop1 = fixFollowedFieldofObjectwithInitialValue(i3, procLists, objOop1);
+			objOop4 = longAt((sched + BaseHeaderSize) + (ProcessListsIndex << (shiftForWord())));
+			assert(isNonImmediate(objOop4));
+			if (((longAt(objOop4)) & (0x3FFFFF - 8)) == 0) {
+				objOop4 = fixFollowedFieldofObjectwithInitialValue(ProcessListsIndex, sched, objOop4);
 			}
-			list = objOop1;
-			/* begin followObjField:ofObject: */
-			objOop2 = longAt((list + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())));
-			assert(isNonImmediate(objOop2));
-			if (((longAt(objOop2)) & (0x3FFFFF - 8)) == 0) {
-				objOop2 = fixFollowedFieldofObjectwithInitialValue(FirstLinkIndex, list, objOop2);
-			}
-			first = objOop2;
-			/* begin followObjField:ofObject: */
-			objOop3 = longAt((list + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())));
-			assert(isNonImmediate(objOop3));
-			if (((longAt(objOop3)) & (0x3FFFFF - 8)) == 0) {
-				objOop3 = fixFollowedFieldofObjectwithInitialValue(LastLinkIndex, list, objOop3);
-			}
-			last = objOop3;
-			while (first != last) {
+			procLists = objOop4;
+			for (i3 = 0, iLimiT = ((numSlotsOf(procLists)) - 1); i3 <= iLimiT; i3 += 1) {
 				/* begin followObjField:ofObject: */
-				objOop = longAt((first + BaseHeaderSize) + (NextLinkIndex << (shiftForWord())));
-				assert(isNonImmediate(objOop));
-				if (((longAt(objOop)) & (0x3FFFFF - 8)) == 0) {
-					objOop = fixFollowedFieldofObjectwithInitialValue(NextLinkIndex, first, objOop);
+				objOop1 = longAt((procLists + BaseHeaderSize) + (i3 << (shiftForWord())));
+				assert(isNonImmediate(objOop1));
+				if (((longAt(objOop1)) & (0x3FFFFF - 8)) == 0) {
+					objOop1 = fixFollowedFieldofObjectwithInitialValue(i3, procLists, objOop1);
 				}
-				next = objOop;
-				first = next;
-			}
-		}
-		/* begin followForwardingPointersInSpecialObjectsArray */
-		/* begin followSemaphoreIn:at: */
-		obj1 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheLowSpaceSemaphore << (shiftForWord())));
-		if (((longAt(obj1)) & (0x3FFFFF - 8)) == 0) {
-			/* begin followForwarded: */
-			assert(isUnambiguouslyForwarder(obj1));
-			referent11 = longAt((obj1 + BaseHeaderSize) + (0 << (shiftForWord())));
-			while (((referent11 & 3) == 0)
-			 && (((longAt(referent11)) & 0x3FFFFF) == 8)) {
-				referent11 = longAt((referent11 + BaseHeaderSize) + (0 << (shiftForWord())));
-			}
-			obj1 = referent11;
-			/* begin storePointer:ofObject:withValue: */
-			assert(!(isForwarded(GIV(specialObjectsOop))));
-			if (isOldObject(GIV(specialObjectsOop))) {
-
-				/* most stores into young objects */
-
-				if (((obj1 & 3) == 0)
-				 && (oopisLessThan(obj1, GIV(newSpaceLimit)))) {
-					/* begin possibleRootStoreInto: */
-					if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
-						remember(GIV(specialObjectsOop));
+				list = objOop1;
+				/* begin followObjField:ofObject: */
+				objOop2 = longAt((list + BaseHeaderSize) + (FirstLinkIndex << (shiftForWord())));
+				assert(isNonImmediate(objOop2));
+				if (((longAt(objOop2)) & (0x3FFFFF - 8)) == 0) {
+					objOop2 = fixFollowedFieldofObjectwithInitialValue(FirstLinkIndex, list, objOop2);
+				}
+				first = objOop2;
+				/* begin followObjField:ofObject: */
+				objOop3 = longAt((list + BaseHeaderSize) + (LastLinkIndex << (shiftForWord())));
+				assert(isNonImmediate(objOop3));
+				if (((longAt(objOop3)) & (0x3FFFFF - 8)) == 0) {
+					objOop3 = fixFollowedFieldofObjectwithInitialValue(LastLinkIndex, list, objOop3);
+				}
+				last = objOop3;
+				while (first != last) {
+					/* begin followObjField:ofObject: */
+					objOop = longAt((first + BaseHeaderSize) + (NextLinkIndex << (shiftForWord())));
+					assert(isNonImmediate(objOop));
+					if (((longAt(objOop)) & (0x3FFFFF - 8)) == 0) {
+						objOop = fixFollowedFieldofObjectwithInitialValue(NextLinkIndex, first, objOop);
 					}
+					next = objOop;
+					first = next;
 				}
 			}
-			longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (TheLowSpaceSemaphore << (shiftForWord())), obj1);
-		}
-		/* begin followSemaphoreIn:at: */
-		obj2 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheInterruptSemaphore << (shiftForWord())));
-		if (((longAt(obj2)) & (0x3FFFFF - 8)) == 0) {
-			/* begin followForwarded: */
-			assert(isUnambiguouslyForwarder(obj2));
-			referent21 = longAt((obj2 + BaseHeaderSize) + (0 << (shiftForWord())));
-			while (((referent21 & 3) == 0)
-			 && (((longAt(referent21)) & 0x3FFFFF) == 8)) {
-				referent21 = longAt((referent21 + BaseHeaderSize) + (0 << (shiftForWord())));
-			}
-			obj2 = referent21;
-			/* begin storePointer:ofObject:withValue: */
-			assert(!(isForwarded(GIV(specialObjectsOop))));
-			if (isOldObject(GIV(specialObjectsOop))) {
+			/* begin followForwardingPointersInSpecialObjectsArray */
+			/* begin followSemaphoreIn:at: */
+			obj1 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheLowSpaceSemaphore << (shiftForWord())));
+			if (((longAt(obj1)) & (0x3FFFFF - 8)) == 0) {
+				/* begin followForwarded: */
+				assert(isUnambiguouslyForwarder(obj1));
+				referent11 = longAt((obj1 + BaseHeaderSize) + (0 << (shiftForWord())));
+				while (((referent11 & 3) == 0)
+				 && (((longAt(referent11)) & 0x3FFFFF) == 8)) {
+					referent11 = longAt((referent11 + BaseHeaderSize) + (0 << (shiftForWord())));
+				}
+				obj1 = referent11;
+				/* begin storePointer:ofObject:withValue: */
+				assert(!(isForwarded(GIV(specialObjectsOop))));
+				if (isOldObject(GIV(specialObjectsOop))) {
 
-				/* most stores into young objects */
+					/* most stores into young objects */
 
-				if (((obj2 & 3) == 0)
-				 && (oopisLessThan(obj2, GIV(newSpaceLimit)))) {
-					/* begin possibleRootStoreInto: */
-					if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
-						remember(GIV(specialObjectsOop));
+					if (((obj1 & 3) == 0)
+					 && (oopisLessThan(obj1, GIV(newSpaceLimit)))) {
+						/* begin possibleRootStoreInto: */
+						if (!(((((usqInt) (longAt(GIV(specialObjectsOop)))) >> 29) & 1) != 0)) {
+							remember(GIV(specialObjectsOop));
+						}
 					}
 				}
+				longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (TheLowSpaceSemaphore << (shiftForWord())), obj1);
 			}
-			longAtput((GIV(specialObjectsOop) + BaseHeaderSize) + (TheInterruptSemaphore << (shiftForWord())), obj2);
-		}
-		/* begin followSemaphoreIn:at: */
-		obj3 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheTimerSemaphore << (shiftForWord())));
-		if (((longAt(obj3)) & (0x3FFFFF - 8)) == 0) {
-			/* begin followForwarded: */
-			assert(isUnambiguouslyForwarder(obj3));
-			referent31 = longAt((obj3 + BaseHeaderSize) + (0 << (shiftForWord())));
-			while (((referent31 & 3) == 0)
-			 && (((longAt(referent31)) & 0x3FFFFF) == 8)) {
-				referent31 = longAt((referent31 + BaseHeaderSize) + (0 << (shiftForWord())));
-			}
-			obj3 = referent31;
-			/* begin storePointer:ofObject:withValue: */
-			assert(!(isForwarded(GIV(specialObjectsOop))));
-			if (isOldObject(GIV(specialObjectsOop))) {
+			/* begin followSemaphoreIn:at: */
+			obj2 = longAt((GIV(specialObjectsOop) + BaseHeaderSize) + (TheInterruptSemaphore << (shiftForWord())));
+			if (((longAt(obj2)) & (0x3FFFFF - 8)) == 0) {
+				/* begin followForwarded: */
+				assert(isUnambiguouslyForwarder(obj2));
+				referent21 = longAt((obj2 + BaseHeaderSize) + (0 << (shiftForWord())));
+				while (((referent21 & 3) == 0)
+				 && (((longAt(referent21)) & 0x3FFFFF) == 8)) {
+					referent21 = longAt((referent21 + BaseHeaderSize) + (0 << (shiftForWord())));

@@ Diff output truncated at 50000 characters. @@


More information about the Vm-dev mailing list