Skip to content

Commit

Permalink
CogVM source as per VMMaker.oscog-eem.2880
Browse files Browse the repository at this point in the history
linux doesn't pick up sys/types.h in core vm so use usqIntptr_t not uintptr_t.
  • Loading branch information
eliotmiranda committed Nov 12, 2020
1 parent 9d27ce4 commit 7308cca
Show file tree
Hide file tree
Showing 85 changed files with 692 additions and 692 deletions.
2 changes: 1 addition & 1 deletion nsspur64src/vm/cogit.h
@@ -1,5 +1,5 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.2879 uuid: d024a598-2be9-4f62-a1fa-dd832d57dfd0
CCodeGenerator VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
*/


Expand Down
18 changes: 9 additions & 9 deletions nsspur64src/vm/cogitARMv8.c
@@ -1,11 +1,11 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.2879 uuid: d024a598-2be9-4f62-a1fa-dd832d57dfd0
CCodeGenerator VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
from
StackToRegisterMappingCogit VMMaker.oscog-eem.2879 uuid: d024a598-2be9-4f62-a1fa-dd832d57dfd0
CogARMv8Compiler ClosedVMMaker-eem.109 uuid: 546907d1-5fff-4bb3-819c-0a9a5e11210e
StackToRegisterMappingCogit VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
CogARMv8Compiler * ClosedVMMaker-eem.109 uuid: 546907d1-5fff-4bb3-819c-0a9a5e11210e
*/
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.2879 uuid: d024a598-2be9-4f62-a1fa-dd832d57dfd0\n\
CogARMv8Compiler ClosedVMMaker-eem.109 uuid: 546907d1-5fff-4bb3-819c-0a9a5e11210e " __DATE__ ;
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a\n\
CogARMv8Compiler * ClosedVMMaker-eem.109 uuid: 546907d1-5fff-4bb3-819c-0a9a5e11210e " __DATE__ ;
char *__cogitBuildInfo = __buildInfo;


Expand Down Expand Up @@ -1987,6 +1987,7 @@ static sqInt methodOrBlockNumArgs;
static sqInt methodOrBlockNumTemps;
static usqInt methodZoneBase;
static usqIntptr_t minValidCallAddress;
static usqIntptr_t mrsCtrEl0;
static usqInt mzFreeStart;
static sqInt nextLiteralIndex;
static AbstractInstruction * noCheckEntry;
Expand Down Expand Up @@ -2629,7 +2630,6 @@ static sqInt codeToDataDelta;
# define codeToDataDelta 0
#endif
static AbstractInstruction * const methodLabel = &aMethodLabel;
static uintptr_t mrsCtrEl0;
static void (*postCompileHook)(CogMethod *);
sqInt blockNoContextSwitchOffset;
sqInt breakPC;
Expand Down Expand Up @@ -4201,7 +4201,7 @@ static AbstractInstruction * NoDbgRegParms
detectFeatures(AbstractInstruction * self_in_detectFeatures)
{
sqInt fixupSize;
uintptr_t (*getMrsCtrEl0)(void);
usqIntptr_t (*getMrsCtrEl0)(void);
sqInt opcodeSize;
usqInt startAddress;

Expand All @@ -4217,7 +4217,7 @@ detectFeatures(AbstractInstruction * self_in_detectFeatures)
labelCounter = 0;

/* Return the value of CTR_EL0; that's the control register that defines the vital statistics of the processor's caches. */
getMrsCtrEl0 = ((uintptr_t (*)(void)) startAddress);
getMrsCtrEl0 = ((usqIntptr_t (*)(void)) startAddress);
genoperand(MRS_CTR_EL0, ABIResultReg);
genoperand(RetN, 0);
outputInstructionsForGeneratedRuntimeAt(startAddress);
Expand Down Expand Up @@ -12882,7 +12882,7 @@ initializeCodeZoneFromupTo(sqInt startAddress, sqInt endAddress)
l3: /* end generateLowLevelTryLock: */;
outputInstructionsForGeneratedRuntimeAt(startAddress2);
recordGeneratedRunTimeaddress("ceTryLockVMOwner", startAddress2);
ceTryLockVMOwner = ((uintptr_t (*)(uintptr_t)) startAddress2);
ceTryLockVMOwner = ((usqIntptr_t (*)(usqIntptr_t)) startAddress2);
# endif /* COGMTVM */
genGetLeafCallStackPointers();
generateStackPointerCapture();
Expand Down
14 changes: 7 additions & 7 deletions nsspur64src/vm/cogitX64SysV.c
@@ -1,9 +1,9 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.2879 uuid: d024a598-2be9-4f62-a1fa-dd832d57dfd0
CCodeGenerator VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
from
StackToRegisterMappingCogit VMMaker.oscog-eem.2879 uuid: d024a598-2be9-4f62-a1fa-dd832d57dfd0
StackToRegisterMappingCogit VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
*/
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.2879 uuid: d024a598-2be9-4f62-a1fa-dd832d57dfd0 " __DATE__ ;
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a " __DATE__ ;
char *__cogitBuildInfo = __buildInfo;


Expand Down Expand Up @@ -1366,6 +1366,7 @@ static sqInt cPICCaseSize;
static sqInt cPICEndOfCodeOffset;
static sqInt cPICEndSize;
static CogMethod * cPICPrototype;
static usqIntptr_t cpuidWord1;
static sqInt currentCallCleanUpSize;
static sqInt deadCode;
static sqInt debugBytecodePointers;
Expand Down Expand Up @@ -2563,7 +2564,6 @@ static sqInt codeToDataDelta;
#else
# define codeToDataDelta 0
#endif
static uintptr_t cpuidWord1;
static AbstractInstruction * const methodLabel = &aMethodLabel;
static void (*postCompileHook)(CogMethod *);
sqInt blockNoContextSwitchOffset;
Expand Down Expand Up @@ -8596,7 +8596,7 @@ initializeCodeZoneFromupTo(sqInt startAddress, sqInt endAddress)
l6: /* end generateLowLevelTryLock: */;
outputInstructionsForGeneratedRuntimeAt(startAddress2);
recordGeneratedRunTimeaddress("ceTryLockVMOwner", startAddress2);
ceTryLockVMOwner = ((uintptr_t (*)(uintptr_t)) startAddress2);
ceTryLockVMOwner = ((usqIntptr_t (*)(usqIntptr_t)) startAddress2);
# endif /* COGMTVM */
genGetLeafCallStackPointers();
generateStackPointerCapture();
Expand Down Expand Up @@ -21024,7 +21024,7 @@ static AbstractInstruction * NoDbgRegParms
detectFeatures(AbstractInstruction * self_in_detectFeatures)
{
AbstractInstruction *anInstruction;
uintptr_t (*cpuid)(void);
usqIntptr_t (*cpuid)(void);
sqInt fixupSize;
sqInt opcodeSize;
usqInt startAddress;
Expand All @@ -21039,7 +21039,7 @@ detectFeatures(AbstractInstruction * self_in_detectFeatures)
fixups = ((void *)((((usqInt)abstractOpcodes)) + opcodeSize));
zeroOpcodeIndexForNewOpcodes();
labelCounter = 0;
cpuid = ((uintptr_t (*)(void)) startAddress);
cpuid = ((usqIntptr_t (*)(void)) startAddress);
/* begin PushR: */
genoperand(PushR, RDX);
/* begin PushR: */
Expand Down
14 changes: 7 additions & 7 deletions nsspur64src/vm/cogitX64WIN64.c
@@ -1,9 +1,9 @@
/* Automatically generated by
CCodeGenerator VMMaker.oscog-eem.2879 uuid: d024a598-2be9-4f62-a1fa-dd832d57dfd0
CCodeGenerator VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
from
StackToRegisterMappingCogit VMMaker.oscog-eem.2879 uuid: d024a598-2be9-4f62-a1fa-dd832d57dfd0
StackToRegisterMappingCogit VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
*/
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.2879 uuid: d024a598-2be9-4f62-a1fa-dd832d57dfd0 " __DATE__ ;
static char __buildInfo[] = "StackToRegisterMappingCogit VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a " __DATE__ ;
char *__cogitBuildInfo = __buildInfo;


Expand Down Expand Up @@ -1366,6 +1366,7 @@ static sqInt cPICCaseSize;
static sqInt cPICEndOfCodeOffset;
static sqInt cPICEndSize;
static CogMethod * cPICPrototype;
static usqIntptr_t cpuidWord1;
static sqInt currentCallCleanUpSize;
static sqInt deadCode;
static sqInt debugBytecodePointers;
Expand Down Expand Up @@ -2563,7 +2564,6 @@ static sqInt codeToDataDelta;
#else
# define codeToDataDelta 0
#endif
static uintptr_t cpuidWord1;
static AbstractInstruction * const methodLabel = &aMethodLabel;
static void (*postCompileHook)(CogMethod *);
sqInt blockNoContextSwitchOffset;
Expand Down Expand Up @@ -8614,7 +8614,7 @@ initializeCodeZoneFromupTo(sqInt startAddress, sqInt endAddress)
l6: /* end generateLowLevelTryLock: */;
outputInstructionsForGeneratedRuntimeAt(startAddress2);
recordGeneratedRunTimeaddress("ceTryLockVMOwner", startAddress2);
ceTryLockVMOwner = ((uintptr_t (*)(uintptr_t)) startAddress2);
ceTryLockVMOwner = ((usqIntptr_t (*)(usqIntptr_t)) startAddress2);
# endif /* COGMTVM */
genGetLeafCallStackPointers();
generateStackPointerCapture();
Expand Down Expand Up @@ -21042,7 +21042,7 @@ static AbstractInstruction * NoDbgRegParms
detectFeatures(AbstractInstruction * self_in_detectFeatures)
{
AbstractInstruction *anInstruction;
uintptr_t (*cpuid)(void);
usqIntptr_t (*cpuid)(void);
sqInt fixupSize;
sqInt opcodeSize;
usqInt startAddress;
Expand All @@ -21057,7 +21057,7 @@ detectFeatures(AbstractInstruction * self_in_detectFeatures)
fixups = ((void *)((((usqInt)abstractOpcodes)) + opcodeSize));
zeroOpcodeIndexForNewOpcodes();
labelCounter = 0;
cpuid = ((uintptr_t (*)(void)) startAddress);
cpuid = ((usqIntptr_t (*)(void)) startAddress);
/* begin PushR: */
genoperand(PushR, RDX);
/* begin PushR: */
Expand Down
30 changes: 15 additions & 15 deletions nsspur64src/vm/cointerp.c
@@ -1,9 +1,9 @@
/* Automatically generated by
CCodeGeneratorGlobalStructure VMMaker.oscog-eem.2876 uuid: e5dba4f0-62a2-4385-a1aa-67c8617b9fd2
CCodeGeneratorGlobalStructure VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
from
CoInterpreter VMMaker.oscog-eem.2876 uuid: e5dba4f0-62a2-4385-a1aa-67c8617b9fd2
CoInterpreter VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
*/
static char __buildInfo[] = "CoInterpreter VMMaker.oscog-eem.2876 uuid: e5dba4f0-62a2-4385-a1aa-67c8617b9fd2 " __DATE__ ;
static char __buildInfo[] = "CoInterpreter VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a " __DATE__ ;
char *__interpBuildInfo = __buildInfo;


Expand Down Expand Up @@ -1268,7 +1268,7 @@ extern sqInt nonIndexablePointerFormat(void);
static sqInt noUnscannedEphemerons(void);
static sqInt NoDbgRegParms numBytesOfBytes(sqInt objOop);
extern sqInt numBytesOf(sqInt objOop);
extern sqInt numPointerSlotsOf(sqInt objOop);
extern usqInt numPointerSlotsOf(sqInt objOop);
static usqInt NoDbgRegParms numSlotsOfAny(sqInt objOop);
extern usqInt numSlotsOf(sqInt objOop);
static sqInt NoDbgRegParms numStrongSlotsOfInephemeral(sqInt objOop);
Expand Down Expand Up @@ -2628,7 +2628,7 @@ sqInt debugCallbackInvokes;
sqInt debugCallbackReturns;
sqInt ffiExceptionResponse;
sqInt checkedPluginName;
const char *interpreterVersion = "Newspeak Virtual Machine [ Open Smalltalk, Spur] CoInterpreterPrimitives_VMMaker.oscog-eem.2876";
const char *interpreterVersion = "Newspeak Virtual Machine [ Open Smalltalk, Spur] CoInterpreterPrimitives_VMMaker.oscog-eem.2880";
sqInt minBackwardJumpCountForCompile = MinBackwardJumpCountForCompile /* 40 */;
int displayWidth;
int displayDepth;
Expand Down Expand Up @@ -41491,7 +41491,7 @@ followForwardedObjectFieldstoDepth(sqInt objOop, sqInt depth)
sqInt header1;
sqInt i;
sqInt numLiterals;
sqInt numSlots;
usqInt numSlots;
usqInt numSlots1;
sqInt oop;
sqInt referent;
Expand Down Expand Up @@ -49113,7 +49113,7 @@ copyObjtoAddrstopAtsavedFirstFieldsindex(sqInt objOop, sqInt segAddr, sqInt endS
sqInt iLimiT;
sqInt methodHeader;
sqInt numLiterals;
sqInt numMediatedSlots;
usqInt numMediatedSlots;
usqInt numSlots;
usqInt numSlots1;
sqInt oop;
Expand Down Expand Up @@ -55369,7 +55369,7 @@ numBytesOf(sqInt objOop)
Works with CompiledMethods, as well as ordinary objects. */

/* SpurMemoryManager>>#numPointerSlotsOf: */
sqInt
usqInt
numPointerSlotsOf(sqInt objOop)
{ DECL_MAYBE_SQ_GLOBAL_STRUCT
sqInt contextSize;
Expand Down Expand Up @@ -58364,7 +58364,7 @@ printReferencesTo(sqInt anOop)
assert((ReceiverIndex + ((sp >> 3))) < (lengthOf(objOop1)));
contextSize = (sp >> 3);
l9: /* end fetchStackPointerOf: */;
i = CtxtTempFrameStart + contextSize;
i = ((usqInt) (CtxtTempFrameStart + contextSize));
goto l10;
}
/* begin numSlotsOf: */
Expand Down Expand Up @@ -58397,7 +58397,7 @@ printReferencesTo(sqInt anOop)
/* begin literalCountOfMethodHeader: */
assert((((header) & 7) == 1));
numLiterals = ((header >> 3)) & AlternateHeaderNumLiteralsMask;
i = numLiterals + LiteralStart;
i = ((usqInt) (numLiterals + LiteralStart));
l10: /* end numPointerSlotsOf: */;
while (((i -= 1)) >= 0) {
if (anOop == (longAt((objOop1 + BaseHeaderSize) + (((sqInt)((usqInt)(i) << (shiftForWord()))))))) {
Expand Down Expand Up @@ -61545,10 +61545,10 @@ updatePointers(void)
sqInt numLiterals1;
sqInt numLiterals2;
sqInt numLiterals3;
sqInt numPointerSlots;
sqInt numPointerSlots1;
sqInt numPointerSlots2;
sqInt numPointerSlots3;
usqInt numPointerSlots;
usqInt numPointerSlots1;
usqInt numPointerSlots2;
usqInt numPointerSlots3;
usqInt numSlots;
usqInt numSlots1;
usqInt numSlots11;
Expand Down Expand Up @@ -62704,7 +62704,7 @@ prepareForSnapshot(void)
sqInt limit;
sqInt newEndOfMemory;
sqInt next;
usqInt node;
sqInt node;
SpurSegmentInfo *seg;
sqInt smallChild;
sqInt treeNode;
Expand Down
4 changes: 2 additions & 2 deletions nsspur64src/vm/cointerp.h
@@ -1,5 +1,5 @@
/* Automatically generated by
CCodeGeneratorGlobalStructure VMMaker.oscog-eem.2876 uuid: e5dba4f0-62a2-4385-a1aa-67c8617b9fd2
CCodeGeneratorGlobalStructure VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
*/


Expand Down Expand Up @@ -255,7 +255,7 @@ extern sqInt minSlotsForShortening(void);
extern sqInt nilObject(void);
extern sqInt nonIndexablePointerFormat(void);
extern sqInt numBytesOf(sqInt objOop);
extern sqInt numPointerSlotsOf(sqInt objOop);
extern usqInt numPointerSlotsOf(sqInt objOop);
extern usqInt numSlotsOf(sqInt objOop);
extern sqInt numStrongSlotsOfWeakling(sqInt objOop);
extern sqInt objectAfter(sqInt objOop);
Expand Down
30 changes: 15 additions & 15 deletions nsspur64src/vm/gcc3x-cointerp.c
Expand Up @@ -2,11 +2,11 @@


/* Automatically generated by
CCodeGeneratorGlobalStructure VMMaker.oscog-eem.2876 uuid: e5dba4f0-62a2-4385-a1aa-67c8617b9fd2
CCodeGeneratorGlobalStructure VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
from
CoInterpreter VMMaker.oscog-eem.2876 uuid: e5dba4f0-62a2-4385-a1aa-67c8617b9fd2
CoInterpreter VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a
*/
static char __buildInfo[] = "CoInterpreter VMMaker.oscog-eem.2876 uuid: e5dba4f0-62a2-4385-a1aa-67c8617b9fd2 " __DATE__ ;
static char __buildInfo[] = "CoInterpreter VMMaker.oscog-eem.2880 uuid: 6baaab83-7f09-434a-9db1-affff34cc15a " __DATE__ ;
char *__interpBuildInfo = __buildInfo;


Expand Down Expand Up @@ -1271,7 +1271,7 @@ extern sqInt nonIndexablePointerFormat(void);
static sqInt noUnscannedEphemerons(void);
static sqInt NoDbgRegParms numBytesOfBytes(sqInt objOop);
extern sqInt numBytesOf(sqInt objOop);
extern sqInt numPointerSlotsOf(sqInt objOop);
extern usqInt numPointerSlotsOf(sqInt objOop);
static usqInt NoDbgRegParms numSlotsOfAny(sqInt objOop);
extern usqInt numSlotsOf(sqInt objOop);
static sqInt NoDbgRegParms numStrongSlotsOfInephemeral(sqInt objOop);
Expand Down Expand Up @@ -2631,7 +2631,7 @@ sqInt debugCallbackInvokes;
sqInt debugCallbackReturns;
sqInt ffiExceptionResponse;
sqInt checkedPluginName;
const char *interpreterVersion = "Newspeak Virtual Machine [ Open Smalltalk, Spur] CoInterpreterPrimitives_VMMaker.oscog-eem.2876";
const char *interpreterVersion = "Newspeak Virtual Machine [ Open Smalltalk, Spur] CoInterpreterPrimitives_VMMaker.oscog-eem.2880";
sqInt minBackwardJumpCountForCompile = MinBackwardJumpCountForCompile /* 40 */;
int displayWidth;
int displayDepth;
Expand Down Expand Up @@ -41500,7 +41500,7 @@ followForwardedObjectFieldstoDepth(sqInt objOop, sqInt depth)
sqInt header1;
sqInt i;
sqInt numLiterals;
sqInt numSlots;
usqInt numSlots;
usqInt numSlots1;
sqInt oop;
sqInt referent;
Expand Down Expand Up @@ -49122,7 +49122,7 @@ copyObjtoAddrstopAtsavedFirstFieldsindex(sqInt objOop, sqInt segAddr, sqInt endS
sqInt iLimiT;
sqInt methodHeader;
sqInt numLiterals;
sqInt numMediatedSlots;
usqInt numMediatedSlots;
usqInt numSlots;
usqInt numSlots1;
sqInt oop;
Expand Down Expand Up @@ -55378,7 +55378,7 @@ numBytesOf(sqInt objOop)
Works with CompiledMethods, as well as ordinary objects. */

/* SpurMemoryManager>>#numPointerSlotsOf: */
sqInt
usqInt
numPointerSlotsOf(sqInt objOop)
{ DECL_MAYBE_SQ_GLOBAL_STRUCT
sqInt contextSize;
Expand Down Expand Up @@ -58373,7 +58373,7 @@ printReferencesTo(sqInt anOop)
assert((ReceiverIndex + ((sp >> 3))) < (lengthOf(objOop1)));
contextSize = (sp >> 3);
l9: /* end fetchStackPointerOf: */;
i = CtxtTempFrameStart + contextSize;
i = ((usqInt) (CtxtTempFrameStart + contextSize));
goto l10;
}
/* begin numSlotsOf: */
Expand Down Expand Up @@ -58406,7 +58406,7 @@ printReferencesTo(sqInt anOop)
/* begin literalCountOfMethodHeader: */
assert((((header) & 7) == 1));
numLiterals = ((header >> 3)) & AlternateHeaderNumLiteralsMask;
i = numLiterals + LiteralStart;
i = ((usqInt) (numLiterals + LiteralStart));
l10: /* end numPointerSlotsOf: */;
while (((i -= 1)) >= 0) {
if (anOop == (longAt((objOop1 + BaseHeaderSize) + (((sqInt)((usqInt)(i) << (shiftForWord()))))))) {
Expand Down Expand Up @@ -61554,10 +61554,10 @@ updatePointers(void)
sqInt numLiterals1;
sqInt numLiterals2;
sqInt numLiterals3;
sqInt numPointerSlots;
sqInt numPointerSlots1;
sqInt numPointerSlots2;
sqInt numPointerSlots3;
usqInt numPointerSlots;
usqInt numPointerSlots1;
usqInt numPointerSlots2;
usqInt numPointerSlots3;
usqInt numSlots;
usqInt numSlots1;
usqInt numSlots11;
Expand Down Expand Up @@ -62713,7 +62713,7 @@ prepareForSnapshot(void)
sqInt limit;
sqInt newEndOfMemory;
sqInt next;
usqInt node;
sqInt node;
SpurSegmentInfo *seg;
sqInt smallChild;
sqInt treeNode;
Expand Down

0 comments on commit 7308cca

Please sign in to comment.