[Vm-dev] VM Maker: VMMaker.oscog-eem.3059.mcz

commits at source.squeak.org commits at source.squeak.org
Mon Sep 6 22:42:52 UTC 2021


Eliot Miranda uploaded a new version of VMMaker to project VM Maker:
http://source.squeak.org/VMMaker/VMMaker.oscog-eem.3059.mcz

==================== Summary ====================

Name: VMMaker.oscog-eem.3059
Author: eem
Time: 6 September 2021, 3:42:38.06696 pm
UUID: 354a3efc-f2c9-4e08-b6ba-e7a3ed35effd
Ancestors: VMMaker.oscog-eem.3058

Fix a regression in simulation of external primitives introduced by VMMaker.oscog-eem.2994.  When flushing the externalPrimitiveTable none of the simulation state (pluginList, mappedPluginEntries et al) need be flushed.  Doing so blows away plugins with persistent state such as the FilePluginSimulator and SocketPluginSimulator (open files/sockets).

Fix a speeling rorre.

=============== Diff against VMMaker.oscog-eem.3058 ===============

Item was changed:
  ----- Method: CogVMSimulator>>initializePluginEntries (in category 'plugin support') -----
  initializePluginEntries
  	mappedPluginEntries := OrderedCollection new.
  	objectMemory hasSpurMemoryManagerAPI
  		ifTrue:
  			[primitiveAccessorDepthTable := Array new: primitiveTable size.
  			 pluginList := {}.
  			 self loadNewPlugin: '']
  		ifFalse:
+ 			[pluginList := {'' -> self }]!
- 			[pluginList := {'' -> self }].
- 	cogit flushPluginEntriesFor: #tryLoadNewPlugin:pluginEntries:!

Item was removed:
- ----- Method: Cogit>>flushPluginEntriesFor: (in category 'simulation only') -----
- flushPluginEntriesFor: aSelector
- 	(simulatedTrampolines keys select:
- 		[:k|
- 		(simulatedTrampolines at: k) isBlock
- 		 and: [(simulatedTrampolines at: k) home selector == aSelector]]) do:
- 		[:k| simulatedTrampolines removeKey: k]!

Item was removed:
- ----- Method: InterpreterProxy>>ioLoadFunction:From:MetadataIntoInto: (in category 'FFI support') -----
- ioLoadFunction: functionName From: moduleName MetadataIntoInto: metadataPtr
- 	<returnTypeC: #'void *'>
- 	<var: #functionName type: #'char *'>
- 	<var: #moduleName type: #'char *'>
- 	<var: #metadataPtr type: #'sqInt *'>
- 	"Dummy - provided by support code"
- 	^0!

Item was changed:
  ----- Method: StackInterpreter>>ensureCallerContext: (in category 'frame access') -----
  ensureCallerContext: theFP
+ 	"Answer the caller context for a frame.  If the frame has a caller
- 	"Answerr the caller context for a frame.  If the frame has a caller
  	 frame that doesn't have a context, then marry the caller frame."
  	| callerFP |
  	<inline: true>
  	<var: #theFP type: #'char *'>
  	<var: #callerFP type: #'char *'>
  	callerFP := self frameCallerFP: theFP.
  	callerFP = 0 ifTrue: "base frame, context in saved ip slot (or base of stack in Cog)"
  		[^self frameCallerContext: theFP].
  	^self ensureFrameIsMarried: callerFP SP: (self frameCallerStackPointer: theFP)!

Item was changed:
  ----- Method: StackInterpreter>>flushExternalPrimitiveTable (in category 'plugin primitive support') -----
  flushExternalPrimitiveTable
  	"Flush the external primitive table"
+ 	0 to: MaxExternalPrimitiveTableSize-1 do:[:i|
+ 		externalPrimitiveTable at: i put: 0].
+ 	externalPrimitiveTableFirstFreeIndex := 0!
- 	0 to: MaxExternalPrimitiveTableSize - 1 do:
- 		[:i| externalPrimitiveTable at: i put: 0].
- 	externalPrimitiveTableFirstFreeIndex := 0.
- 	self cCode: '' inSmalltalk: [self initializePluginEntries]!



More information about the Vm-dev mailing list