Eliot Miranda uploaded a new version of VMMaker to project VM Maker:
http://source.squeak.org/VMMaker/VMMaker.oscog-eem.2777.mcz
==================== Summary ====================
Name: VMMaker.oscog-eem.2777
Author: eem
Time: 16 July 2020, 6:29:24.838687 pm
UUID: 6b0b031e-efb5-4b78-af61-94095803d9ea
Ancestors: VMMaker.oscog-eem.2776
Test accessors for the new primitiveCDataModel.
=============== Diff against VMMaker.oscog-eem.2776 ===============
Item was added:
+ ----- Method: ThreadedFFIPlugin class>>primitiveCDataModel (in category 'simulation') -----
+ primitiveCDataModel
+ "Answer the name for the platform C compiler's data model, ILP32, LP64, et al."
+ <primitive: #primitiveCDataModel module: #SqueakFFIPrims error: ec>
+ self primitiveFailed
+
+ "self primitiveCDataModel"!
Item was added:
+ ----- Method: ThreadedFFIPlugin class>>primitiveSizesInto: (in category 'simulation') -----
+ primitiveSizesInto: aByteArrayOfSizeNine
+ "Answer the platform C compiler's sizes for char, short, int, long, long long, wchar_t, float, double, void *."
+ <primitive: #primitiveCDataModel module: #SqueakFFIPrims error: ec>
+ self primitiveFailed
+
+ "(#(char short int long #'long long' wchar_t float double #'void *')
+ with: (self primitiveSizesInto: (ByteArray new: 9))
+ collect: [:n :s| {n. s}]) flatten"!
Branch: refs/heads/Cog
Home: https://github.com/OpenSmalltalk/opensmalltalk-vm
Commit: b90d60fc7119d945591ae3e8d66d2ab0108fefc6
https://github.com/OpenSmalltalk/opensmalltalk-vm/commit/b90d60fc7119d94559…
Author: Eliot Miranda <eliot.miranda(a)gmail.com>
Date: 2020-07-16 (Thu, 16 Jul 2020)
Changed paths:
M nsspur64src/vm/cogit.h
M nsspur64src/vm/cogitARMv8.c
M nsspur64src/vm/cogitX64SysV.c
M nsspur64src/vm/cogitX64WIN64.c
M nsspursrc/vm/cogit.h
M nsspursrc/vm/cogitARMv5.c
M nsspursrc/vm/cogitIA32.c
M nsspursrc/vm/cogitMIPSEL.c
M spur64src/vm/cogit.h
M spur64src/vm/cogitARMv8.c
M spur64src/vm/cogitX64SysV.c
M spur64src/vm/cogitX64WIN64.c
M spurlowcode64src/vm/cogit.h
M spurlowcode64src/vm/cogitARMv8.c
M spurlowcode64src/vm/cogitX64SysV.c
M spurlowcode64src/vm/cogitX64WIN64.c
M spurlowcodesrc/vm/cogit.h
M spurlowcodesrc/vm/cogitARMv5.c
M spurlowcodesrc/vm/cogitIA32.c
M spurlowcodesrc/vm/cogitMIPSEL.c
M spursista64src/vm/cogit.h
M spursista64src/vm/cogitARMv8.c
M spursista64src/vm/cogitX64SysV.c
M spursista64src/vm/cogitX64WIN64.c
M spursistasrc/vm/cogit.h
M spursistasrc/vm/cogitARMv5.c
M spursistasrc/vm/cogitIA32.c
M spursistasrc/vm/cogitMIPSEL.c
M spursrc/vm/cogit.h
M spursrc/vm/cogitARMv5.c
M spursrc/vm/cogitIA32.c
M spursrc/vm/cogitMIPSEL.c
M src/vm/cogit.h
M src/vm/cogitARMv5.c
M src/vm/cogitIA32.c
M src/vm/cogitMIPSEL.c
Log Message:
-----------
CogVM source as per Name: VMMaker.oscog-eem.2776
Oops! Fix a regression from VMMaker.oscog-eem.2774. Slang isn't smart enough
to emit types for C's funky example typing for functions that return pointers
to functions, so we have to manually type genInvokeInterpretTrampoline.
Eliot Miranda uploaded a new version of VMMaker to project VM Maker:
http://source.squeak.org/VMMaker/VMMaker.oscog-eem.2776.mcz
==================== Summary ====================
Name: VMMaker.oscog-eem.2776
Author: eem
Time: 16 July 2020, 4:52:27.299313 pm
UUID: 9f8a0f46-28c8-4139-8366-088e6e75e4cd
Ancestors: VMMaker.oscog-eem.2775
Oops! Fix a regression from VMMaker.oscog-eem.2774. Slang isn't smart enough to emit types for C's funky example typing for functions that return pointers to functions, so we have to manually type genInvokeInterpretTrampoline.
=============== Diff against VMMaker.oscog-eem.2775 ===============
Item was changed:
----- Method: Cogit>>genInvokeInterpretTrampoline (in category 'initialization') -----
genInvokeInterpretTrampoline
"Switch to the C stack (do *not* save the Smalltalk stack pointers;
this is the caller's responsibility), and invoke interpret PDQ."
+ <returnTypeC: 'void (*genInvokeInterpretTrampoline(void))(void)'>
| startAddress |
<inline: false>
startAddress := methodZoneBase.
self zeroOpcodeIndex.
backEnd hasVarBaseRegister ifTrue:
[self MoveCq: self varBaseAddress R: VarBaseReg]. "Must happen first; value may be used in genLoadStackPointers"
cFramePointerInUse
ifTrue: [backEnd genLoadCStackPointers]
ifFalse: [backEnd genLoadCStackPointer].
"Sideways call interpret so that the stack looks correct, for exception handling etc"
backEnd genMarshallNArgs: 0 arg: nil arg: nil arg: nil arg: nil.
backEnd hasLinkRegister
ifTrue:
[self MoveAw: coInterpreter cReturnAddressAddress R: LinkReg]
ifFalse:
[self MoveAw: coInterpreter cReturnAddressAddress R: ABIResultReg.
backEnd genSubstituteReturnAddressR: ABIResultReg].
self JumpFullRT: (self
cCode: [#interpret asUnsignedInteger]
inSmalltalk: [self simulatedTrampolineFor: #interpret]).
self outputInstructionsForGeneratedRuntimeAt: startAddress.
self recordGeneratedRunTime: 'ceInvokeInterpret' address: startAddress.
^self cCoerceSimple: startAddress to: #'void (*)(void)'!
Branch: refs/heads/Cog
Home: https://github.com/OpenSmalltalk/opensmalltalk-vm
Commit: ae724ff77d9af402c15916b529ee10e3a3db7fcf
https://github.com/OpenSmalltalk/opensmalltalk-vm/commit/ae724ff77d9af402c1…
Author: Eliot Miranda <eliot.miranda(a)gmail.com>
Date: 2020-07-16 (Thu, 16 Jul 2020)
Changed paths:
M nsspur64src/vm/cogit.h
M nsspur64src/vm/cogitARMv8.c
M nsspur64src/vm/cogitX64SysV.c
M nsspur64src/vm/cogitX64WIN64.c
M nsspursrc/vm/cogit.h
M nsspursrc/vm/cogitARMv5.c
M nsspursrc/vm/cogitIA32.c
M nsspursrc/vm/cogitMIPSEL.c
M spur64src/vm/cogit.h
M spur64src/vm/cogitARMv8.c
M spur64src/vm/cogitX64SysV.c
M spur64src/vm/cogitX64WIN64.c
M spurlowcode64src/vm/cogit.h
M spurlowcode64src/vm/cogitARMv8.c
M spurlowcode64src/vm/cogitX64SysV.c
M spurlowcode64src/vm/cogitX64WIN64.c
M spurlowcodesrc/vm/cogit.h
M spurlowcodesrc/vm/cogitARMv5.c
M spurlowcodesrc/vm/cogitIA32.c
M spurlowcodesrc/vm/cogitMIPSEL.c
M spursista64src/vm/cogit.h
M spursista64src/vm/cogitARMv8.c
M spursista64src/vm/cogitX64SysV.c
M spursista64src/vm/cogitX64WIN64.c
M spursistasrc/vm/cogit.h
M spursistasrc/vm/cogitARMv5.c
M spursistasrc/vm/cogitIA32.c
M spursistasrc/vm/cogitMIPSEL.c
M spursrc/vm/cogit.h
M spursrc/vm/cogitARMv5.c
M spursrc/vm/cogitIA32.c
M spursrc/vm/cogitMIPSEL.c
M src/plugins/SqueakFFIPrims/ARM32FFIPlugin.c
M src/plugins/SqueakFFIPrims/ARM64FFIPlugin.c
M src/plugins/SqueakFFIPrims/IA32FFIPlugin.c
M src/plugins/SqueakFFIPrims/X64SysVFFIPlugin.c
M src/plugins/SqueakFFIPrims/X64Win64FFIPlugin.c
M src/vm/cogit.h
M src/vm/cogitARMv5.c
M src/vm/cogitIA32.c
M src/vm/cogitMIPSEL.c
Log Message:
-----------
CogVM source as per VMMaker.oscog-eem.2775
Fix a warning from compiling the cogit.
ThreadedFFIPlugin: Add primitiveCDataModel which with 0 args answers the C data
model name (LLP64, ILP32 et al), and with a ByteArray arg of 9 elements, answers
the sizes of char, short, etc, & wchar_t.
Slang:
Allow TMethod>>typeFor:in: to infer tpes for non-integral constants (integral
constants need very special handling, done in the client).
Eliminate unnecessary parentheses in ifNil:.