[Vm-dev] VM Maker: BytecodeSets.spur-cb.57.mcz

commits at source.squeak.org commits at source.squeak.org
Wed Aug 31 11:24:32 UTC 2016


ClementBera uploaded a new version of BytecodeSets to project VM Maker:
http://source.squeak.org/VMMaker/BytecodeSets.spur-cb.57.mcz

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

Name: BytecodeSets.spur-cb.57
Author: cb
Time: 31 August 2016, 1:24:23.877084 pm
UUID: 78a8e61c-ebef-4698-9e53-8a3d40cc2ca7
Ancestors: BytecodeSets.spur-eem.56

As there is a single form for instance variable store, I added an annotation so that the JIt knows if the inst var store is with a maybe context object or not.

=============== Diff against BytecodeSets.spur-eem.56 ===============

Item was removed:
- ----- Method: EncoderForSistaV1>>genStoreFlagExtensionIgnoreStoreCheck:maybeContext: (in category 'extended bytecode generation') -----
- genStoreFlagExtensionIgnoreStoreCheck: ignoreStoreCheck maybeContext: maybeContext
- 	"ignoreStoreCheck: 
- 	Can be applied to the long form of store and store pop of literal variable, remote inst var, remote temp, receiver inst var.
- 	If present, the VM does not generate the GC store check. 
- 	The main reasons the compiler can ignore the store check are one of these two:
- 	- the mutated object is always young
- 	- the object stored is immediate
- 	Currently the store check is for the remembered table, but we may have it for tri color marking later. So the compiler cannot really remove the store check if the object stored is old.
- 
- 	maybeContext:
- 	Can be used only with remote instance variable stores. If marked, the object can be a context and hence needs specific VM code. Receiver inst var have a separate encoding, temp vectors and literal variable can't be contexts"
- 	self genUnsignedSingleExtendB: ignoreStoreCheck asBit + (maybeContext asBit << 1)!

Item was added:
+ ----- Method: EncoderForSistaV1>>genStoreFlagExtensionIgnoreStoreCheck:maybeContext:ignoreReadOnlyCheck: (in category 'extended bytecode generation') -----
+ genStoreFlagExtensionIgnoreStoreCheck: ignoreStoreCheck maybeContext: maybeContext ignoreReadOnlyCheck: ignoreReadOnlyCheck
+ 	"ignoreStoreCheck: 
+ 	Can be applied to the long form of store and store pop of literal variable, remote inst var, remote temp, receiver inst var.
+ 	If present, the VM does not generate the GC store check. 
+ 	The main reasons the compiler can ignore the store check are one of these two:
+ 	- the mutated object is always young
+ 	- the object stored is immediate
+ 	Currently the store check is for the remembered table, but we may have it for tri color marking later. So the compiler cannot really remove the store check if the object stored is old.
+ 
+ 	maybeContext:
+ 	Can be used only with remote instance variable stores and receiver variable stores. If marked, the object can be a context and hence needs specific VM code. Receiver inst var have a separate encoding, temp vectors and literal variable can't be contexts
+ 	
+ 	ignoreReadOnlyCheck:
+ 	no read-only check will be performed by the VM. Normally each store has a read-only check.
+ 	"
+ 	self genUnsignedSingleExtendB: ignoreStoreCheck asBit + (maybeContext asBit << 1) + (ignoreReadOnlyCheck asBit << 2)!

Item was changed:
  ----- Method: EncoderForSistaV1>>genStoreInstVar: (in category 'bytecode generation') -----
  genStoreInstVar: instVarIndex
  	"243		11110011	iiiiiiii		Store Receiver Variable #iiiiiii (+ Extend A * 256)"
+ 	self genStoreInstVarLong: instVarIndex maybeContext: false!
- 	self genStoreInstVarLong: instVarIndex!

Item was changed:
  ----- Method: EncoderForSistaV1>>genStoreInstVarLong: (in category 'bytecode generation') -----
  genStoreInstVarLong: instVarIndex
  	"243		11110011	iiiiiiii		Store Receiver Variable #iiiiiii (+ Extend A * 256)"
+ 	^self genStoreInstVarLong: instVarIndex maybeContext: instVarIndex < MethodContext instSize!
- 	(instVarIndex < 0 or: [instVarIndex > 65535]) ifTrue:
- 		[^self outOfRangeError: 'index' index: instVarIndex range: 0 to: 65535].
- 	instVarIndex > 255 ifTrue:
- 		[self genUnsignedSingleExtendA: instVarIndex // 256].
- 	stream
- 		nextPut: 243;
- 		nextPut: instVarIndex \\ 256!

Item was added:
+ ----- Method: EncoderForSistaV1>>genStoreInstVarLong:maybeContext: (in category 'bytecode generation') -----
+ genStoreInstVarLong: instVarIndex maybeContext: maybeContext
+ 	"243		11110011	iiiiiiii		Store Receiver Variable #iiiiiii (+ Extend A * 256)"
+ 	(instVarIndex < 0 or: [instVarIndex > 65535]) ifTrue:
+ 		[^self outOfRangeError: 'index' index: instVarIndex range: 0 to: 65535].
+ 	maybeContext ifTrue:
+ 		[self genStoreFlagExtensionIgnoreStoreCheck: false maybeContext: maybeContext ignoreReadOnlyCheck: false].
+ 	instVarIndex > 255 ifTrue:
+ 		[self genUnsignedSingleExtendA: instVarIndex // 256].
+ 	stream
+ 		nextPut: 243;
+ 		nextPut: instVarIndex \\ 256!



More information about the Vm-dev mailing list