Skip to content

Commit 8d5e090

Browse files
committed
CogVM source as per VMMaker.oscog-eem.3116
StackInterpreter: fix printAllStacks for v3. Do so by changing SpurMemoryManager>>allObjectsDoSafely: to use isNormalObject: (excluding forwarding pointers) rather than allObjectsDo:, which uses isEnumerableObject: (whcih includes forwarding pointers, and all the puns). This is good for allAccessibleObjectsOkay & checkAllAccessibleObjectsOkay which should indeed ignore things like the class table etc. Spur: eliminate duplicate enableObjectEnumerationFrom:'s in both senders of allEntitiesFrom:do:. Cogit: eliminate some C compiler warnings in the 64-bit cogits. Slang: TMethod's writtenToGlobalVarsCache should be voided more agressively to ensure endOfMemory is inlined in allEntitiesFrom:do:.
1 parent c3fd39d commit 8d5e090

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+2863
-5619
lines changed

src/spur32.cog.lowcode/cogit.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/* Automatically generated by
2-
CCodeGenerator VMMaker.oscog-eem.3101 uuid: 343b46dc-8e9f-48c8-bb97-74b76f1d07cc
2+
CCodeGenerator VMMaker.oscog-eem.3116 uuid: d757936e-c3f3-48be-9435-9a3a60b14615
33
*/
44

55

src/spur32.cog.lowcode/cogitARMv5.c

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
/* Automatically generated by
2-
CCodeGenerator VMMaker.oscog-eem.3109 uuid: 28141cc3-6a57-4a86-b9c2-383d8563851b
2+
CCodeGenerator VMMaker.oscog-eem.3115 uuid: e71c2bb2-05b8-4d1e-a837-c31a9bcc2148
33
from
4-
StackToRegisterMappingCogit VMMaker.oscog-eem.3109 uuid: 28141cc3-6a57-4a86-b9c2-383d8563851b
4+
StackToRegisterMappingCogit VMMaker.oscog-eem.3115 uuid: e71c2bb2-05b8-4d1e-a837-c31a9bcc2148
55
*/
6-
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3109 uuid: 28141cc3-6a57-4a86-b9c2-383d8563851b " __DATE__ ;
6+
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3115 uuid: e71c2bb2-05b8-4d1e-a837-c31a9bcc2148 " __DATE__ ;
77
char *__cogitBuildInfo = __buildInfo;
88

99

@@ -841,7 +841,7 @@ extern void markAndTraceMachineCodeOfMarkedMethods(void);
841841
static void markAndTraceObjectReferencesInGeneratedRuntime(void);
842842
static sqInt NoDbgRegParms markAndTraceOrFreeCogMethodfirstVisit(CogMethod *cogMethod, sqInt firstVisit);
843843
static sqInt NoDbgRegParms markAndTraceOrFreePICTargetin(sqInt entryPoint, CogMethod *cPIC);
844-
static sqInt NoDbgRegParms markLiteralsAndUnlinkIfUnmarkedSendpcmethod(sqInt annotation, char *mcpc, sqInt cogMethod);
844+
static sqInt NoDbgRegParms markLiteralsAndUnlinkIfUnmarkedSendpcmethod(sqInt annotation, char *mcpc, CogMethod *cogMethod);
845845
static sqInt NoDbgRegParms markLiteralspcmethod(sqInt annotation, char *mcpc, CogMethod *cogMethod);
846846
extern void markMethodAndReferents(CogBlockMethod *aCogMethod);
847847
extern usqInt maxCogMethodAddress(void);
@@ -903,7 +903,7 @@ static sqInt NoDbgRegParms unlinkIfInvalidClassSendpcignored(sqInt annotation, c
903903
static sqInt NoDbgRegParms unlinkIfLinkedSendToFreepcignored(sqInt annotation, char *mcpc, sqInt superfluity);
904904
static sqInt NoDbgRegParms unlinkIfLinkedSendpcif(sqInt annotation, char *mcpc, CogMethod *criterionArg);
905905
static sqInt NoDbgRegParms unlinkIfLinkedSendpcignored(sqInt annotation, char *mcpc, sqInt superfluity);
906-
static sqInt NoDbgRegParms unlinkIfLinkedSendpcto(sqInt annotation, char *mcpc, sqInt theCogMethod);
906+
static sqInt NoDbgRegParms unlinkIfLinkedSendpcto(sqInt annotation, char *mcpc, CogMethod *theCogMethod);
907907
extern void unlinkSendsLinkedForInvalidClasses(void);
908908
extern void unlinkSendsOfisMNUSelector(sqInt selector, sqInt isMNUSelector);
909909
extern void unlinkSendsToFree(void);
@@ -4235,7 +4235,7 @@ dispatchConcretize(AbstractInstruction * self_in_dispatchConcretize)
42354235
sqInt offset17;
42364236
sqInt offset18;
42374237
sqInt offset19;
4238-
sqInt offset2;
4238+
int offset2;
42394239
sqInt offset20;
42404240
sqInt offset21;
42414241
sqInt offset22;
@@ -14672,7 +14672,7 @@ markAndTraceOrFreePICTargetin(sqInt entryPoint, CogMethod *cPIC)
1467214672

1467314673
/* Cogit>>#markLiteralsAndUnlinkIfUnmarkedSend:pc:method: */
1467414674
static sqInt NoDbgRegParms
14675-
markLiteralsAndUnlinkIfUnmarkedSendpcmethod(sqInt annotation, char *mcpc, sqInt cogMethod)
14675+
markLiteralsAndUnlinkIfUnmarkedSendpcmethod(sqInt annotation, char *mcpc, CogMethod *cogMethod)
1467614676
{
1467714677
sqInt cacheTag1;
1467814678
sqInt cacheTagMarked;
@@ -16399,7 +16399,7 @@ unlinkIfLinkedSendpcignored(sqInt annotation, char *mcpc, sqInt superfluity)
1639916399

1640016400
/* Cogit>>#unlinkIfLinkedSend:pc:to: */
1640116401
static sqInt NoDbgRegParms
16402-
unlinkIfLinkedSendpcto(sqInt annotation, char *mcpc, sqInt theCogMethod)
16402+
unlinkIfLinkedSendpcto(sqInt annotation, char *mcpc, CogMethod *theCogMethod)
1640316403
{
1640416404
sqInt entryPoint;
1640516405
sqInt offset1;
@@ -16435,7 +16435,7 @@ unlinkIfLinkedSendpcto(sqInt annotation, char *mcpc, sqInt theCogMethod)
1643516435
}
1643616436
}
1643716437
targetMethod1 = ((CogMethod *) (entryPoint - offset1));
16438-
if ((((sqInt)targetMethod1)) == theCogMethod) {
16438+
if (targetMethod1 == theCogMethod) {
1643916439
/* begin unlinkSendAt:targetMethod:sendTable: */
1644016440
unlinkedRoutine = sendTable1[((((targetMethod1->cmNumArgs)) < (NumSendTrampolines - 1)) ? ((targetMethod1->cmNumArgs)) : (NumSendTrampolines - 1))];
1644116441
/* begin setCodeModified */

src/spur32.cog.lowcode/cogitIA32.c

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
/* Automatically generated by
2-
CCodeGenerator VMMaker.oscog-eem.3109 uuid: 28141cc3-6a57-4a86-b9c2-383d8563851b
2+
CCodeGenerator VMMaker.oscog-eem.3115 uuid: e71c2bb2-05b8-4d1e-a837-c31a9bcc2148
33
from
4-
StackToRegisterMappingCogit VMMaker.oscog-eem.3109 uuid: 28141cc3-6a57-4a86-b9c2-383d8563851b
4+
StackToRegisterMappingCogit VMMaker.oscog-eem.3115 uuid: e71c2bb2-05b8-4d1e-a837-c31a9bcc2148
55
*/
6-
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3109 uuid: 28141cc3-6a57-4a86-b9c2-383d8563851b " __DATE__ ;
6+
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.3115 uuid: e71c2bb2-05b8-4d1e-a837-c31a9bcc2148 " __DATE__ ;
77
char *__cogitBuildInfo = __buildInfo;
88

99

@@ -803,7 +803,7 @@ extern void markAndTraceMachineCodeOfMarkedMethods(void);
803803
static void markAndTraceObjectReferencesInGeneratedRuntime(void);
804804
static sqInt NoDbgRegParms markAndTraceOrFreeCogMethodfirstVisit(CogMethod *cogMethod, sqInt firstVisit);
805805
static sqInt NoDbgRegParms markAndTraceOrFreePICTargetin(sqInt entryPoint, CogMethod *cPIC);
806-
static sqInt NoDbgRegParms markLiteralsAndUnlinkIfUnmarkedSendpcmethod(sqInt annotation, char *mcpc, sqInt cogMethod);
806+
static sqInt NoDbgRegParms markLiteralsAndUnlinkIfUnmarkedSendpcmethod(sqInt annotation, char *mcpc, CogMethod *cogMethod);
807807
static sqInt NoDbgRegParms markLiteralspcmethod(sqInt annotation, char *mcpc, CogMethod *cogMethod);
808808
extern void markMethodAndReferents(CogBlockMethod *aCogMethod);
809809
extern usqInt maxCogMethodAddress(void);
@@ -865,7 +865,7 @@ static sqInt NoDbgRegParms unlinkIfInvalidClassSendpcignored(sqInt annotation, c
865865
static sqInt NoDbgRegParms unlinkIfLinkedSendToFreepcignored(sqInt annotation, char *mcpc, sqInt superfluity);
866866
static sqInt NoDbgRegParms unlinkIfLinkedSendpcif(sqInt annotation, char *mcpc, CogMethod *criterionArg);
867867
static sqInt NoDbgRegParms unlinkIfLinkedSendpcignored(sqInt annotation, char *mcpc, sqInt superfluity);
868-
static sqInt NoDbgRegParms unlinkIfLinkedSendpcto(sqInt annotation, char *mcpc, sqInt theCogMethod);
868+
static sqInt NoDbgRegParms unlinkIfLinkedSendpcto(sqInt annotation, char *mcpc, CogMethod *theCogMethod);
869869
extern void unlinkSendsLinkedForInvalidClasses(void);
870870
extern void unlinkSendsOfisMNUSelector(sqInt selector, sqInt isMNUSelector);
871871
extern void unlinkSendsToFree(void);
@@ -3991,8 +3991,8 @@ dispatchConcretize(AbstractInstruction * self_in_dispatchConcretize)
39913991
usqInt mask2;
39923992
usqInt maskReg;
39933993
sqInt mcIdx;
3994-
sqInt offset;
3995-
sqInt offset1;
3994+
int offset;
3995+
int offset1;
39963996
usqInt offset10;
39973997
usqInt offset11;
39983998
sqInt offset110;
@@ -4017,7 +4017,7 @@ dispatchConcretize(AbstractInstruction * self_in_dispatchConcretize)
40174017
sqInt offset17;
40184018
sqInt offset18;
40194019
sqInt offset19;
4020-
sqInt offset2;
4020+
int offset2;
40214021
sqInt offset20;
40224022
sqInt offset21;
40234023
sqInt offset22;
@@ -14344,7 +14344,7 @@ markAndTraceOrFreePICTargetin(sqInt entryPoint, CogMethod *cPIC)
1434414344

1434514345
/* Cogit>>#markLiteralsAndUnlinkIfUnmarkedSend:pc:method: */
1434614346
static sqInt NoDbgRegParms
14347-
markLiteralsAndUnlinkIfUnmarkedSendpcmethod(sqInt annotation, char *mcpc, sqInt cogMethod)
14347+
markLiteralsAndUnlinkIfUnmarkedSendpcmethod(sqInt annotation, char *mcpc, CogMethod *cogMethod)
1434814348
{
1434914349
sqInt cacheTag1;
1435014350
sqInt cacheTagMarked;
@@ -16062,7 +16062,7 @@ unlinkIfLinkedSendpcignored(sqInt annotation, char *mcpc, sqInt superfluity)
1606216062

1606316063
/* Cogit>>#unlinkIfLinkedSend:pc:to: */
1606416064
static sqInt NoDbgRegParms
16065-
unlinkIfLinkedSendpcto(sqInt annotation, char *mcpc, sqInt theCogMethod)
16065+
unlinkIfLinkedSendpcto(sqInt annotation, char *mcpc, CogMethod *theCogMethod)
1606616066
{
1606716067
sqInt entryPoint;
1606816068
sqInt offset1;
@@ -16098,7 +16098,7 @@ unlinkIfLinkedSendpcto(sqInt annotation, char *mcpc, sqInt theCogMethod)
1609816098
}
1609916099
}
1610016100
targetMethod1 = ((CogMethod *) (entryPoint - offset1));
16101-
if ((((sqInt)targetMethod1)) == theCogMethod) {
16101+
if (targetMethod1 == theCogMethod) {
1610216102
/* begin unlinkSendAt:targetMethod:sendTable: */
1610316103
unlinkedRoutine = sendTable1[((((targetMethod1->cmNumArgs)) < (NumSendTrampolines - 1)) ? ((targetMethod1->cmNumArgs)) : (NumSendTrampolines - 1))];
1610416104
/* begin setCodeModified */

0 commit comments

Comments
 (0)