[Vm-dev] VM Maker: VMMaker.oscog-eem.963.mcz
commits at source.squeak.org
commits at source.squeak.org
Thu Dec 4 20:03:08 UTC 2014
Eliot Miranda uploaded a new version of VMMaker to project VM Maker:
http://source.squeak.org/VMMaker/VMMaker.oscog-eem.963.mcz
==================== Summary ====================
Name: VMMaker.oscog-eem.963
Author: eem
Time: 4 December 2014, 12:00:39.246 pm
UUID: 9df56221-18fd-4dcd-b93f-ae000bef62e5
Ancestors: VMMaker.oscog-eem.962
Fix SmartSyntaxPlugin code generation for Spur of
- asOop: old code assumed 4 byte oops & headers
- Unsigned old code assumed 32-bit oops
Fix Float class>>ccgCanConvertFrom: to use isFloat
Avoid duplication of effort in special selector send
forwarding fault handling.
=============== Diff against VMMaker.oscog-eem.962 ===============
Item was changed:
----- Method: Float class>>ccgCanConvertFrom: (in category '*VMMaker-plugin generation') -----
ccgCanConvertFrom: anObject
+ ^anObject isFloat!
- ^anObject class == self!
Item was changed:
----- Method: SmartSyntaxPluginCodeGenerator>>ccgLoad:expr:asUnsignedValueFrom: (in category 'coercing') -----
ccgLoad: aBlock expr: aString asUnsignedValueFrom: anInteger
"Answer a codestring for positive integer coercion (with validating side-effect) of oop, as described in comment to ccgLoad:expr:asRawOopFrom:"
+ ^aBlock value: (String streamContents: [:aStream |
+ aStream
+ nextPutAll: '(interpreterProxy bytesPerOop = 4';
+ crtab: 2;
+ nextPutAll: 'ifTrue: [interpreterProxy positive32BitValueOf:';
+ crtab: 4;
+ nextPutAll: '(interpreterProxy stackValue:';
+ print: anInteger;
+ nextPutAll: ')]';
+ crtab: 2;
+ nextPutAll: 'ifFalse: [interpreterProxy positive64BitValueOf:';
+ crtab: 4;
+ nextPutAll: '(interpreterProxy stackValue:';
+ print: anInteger;
+ nextPutAll: ')])'])!
- ^aBlock value: (String streamContents: [:aStream | aStream
- nextPutAll: 'interpreterProxy positive32BitValueOf:';
- crtab: 2;
- nextPutAll: '(interpreterProxy stackValue:';
- nextPutAll: anInteger asString;
- nextPutAll: ')'])!
Item was changed:
----- Method: SmartSyntaxPluginCodeGenerator>>generateCoerceToObjectFromPtr:on: (in category 'asOop:/asValue:') -----
generateCoerceToObjectFromPtr: aNode on: aStream
"This code assumes no named instance variables"
+ aStream nextPutAll: '((sqInt)(('.
- aStream nextPutAll: '((int) '.
self emitCExpression: aNode on: aStream.
+ aStream nextPutAll: ') - BaseHeaderSize))'!
- aStream nextPutAll: ') - 4'!
Item was changed:
----- Method: StackInterpreter>>handleSpecialSelectorSendFaultFor:fp:sp: (in category 'message sending') -----
handleSpecialSelectorSendFaultFor: obj fp: theFP sp: theSP
"Handle a special send fault that may be due to a special selector
+ send accessing a forwarded object. obj is forwarded.
+ Unforward stack contents and and inst vars and answer obj's target."
- send accessing a forwarded object.
- Unforward the object on the stack and in inst vars and answer its target."
<inline: false>
<var: #theFP type: #'char *'>
<var: #theSP type: #'char *'>
+ | rcvr |
self assert: (objectMemory isOopForwarded: obj).
-
self followForwardedFrameContents: theFP stackPointer: theSP.
+ rcvr := self frameReceiver: theFP.
+ (objectMemory isPointers: rcvr) ifTrue:
- (objectMemory isPointers: (self frameReceiver: theFP)) ifTrue:
[objectMemory
+ followForwardedObjectFields: rcvr
- followForwardedObjectFields: (self frameReceiver: theFP)
toDepth: 0].
^objectMemory followForwarded: obj!
More information about the Vm-dev
mailing list