[squeak-dev] The Trunk: Kernel-eem.926.mcz

commits at source.squeak.org commits at source.squeak.org
Fri May 29 19:03:12 UTC 2015


Eliot Miranda uploaded a new version of Kernel to project The Trunk:
http://source.squeak.org/trunk/Kernel-eem.926.mcz

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

Name: Kernel-eem.926
Author: eem
Time: 29 May 2015, 12:02:32.361 pm
UUID: b5d090c6-115c-427d-92ca-0e02afa2908d
Ancestors: Kernel-cmm.925

Make markerOrNil multiple-bytecode-sets aware

=============== Diff against Kernel-cmm.925 ===============

Item was changed:
  ----- Method: CompiledMethod>>markerOrNil (in category 'private') -----
  markerOrNil
  	"If I am a marker method, answer the symbol used to mark me.  Otherwise
+ 	 answer nil. What is a marker method?  It is method with body like 
- 	answer nil.
- 
- 	What is a marker method?  It is method with body like 
  		'self subclassResponsibility' or '^ self subclassResponsibility' 
+ 	used to indicate ('mark') a special property."
- 	used to indicate ('mark') a special property.
  
+ 	^self encoderClass markerOrNilFor: self!
- 	Marker methods compile to bytecode like:
- 
- 		9 <70> self
- 		10 <D0> send: <literal 1>
- 		11 <87> pop
- 		12 <78> returnSelf
- 
- 	for the first form, or 
- 
- 		9 <70> self
- 		10 <D0> send: <literal 1>
- 		11 <7C> returnTop
- 
- 	for the second form."
- 
- 	| e |
- 	((e := self endPC) = 19 or: [e = 20]) ifFalse: [^ nil].
- 	(self numLiterals = 3) ifFalse:[^ nil].
- 	(self at: 17) =  16r70 ifFalse:[^ nil].		"push self"
- 	(self at: 18) = 16rD0 ifFalse:[^ nil].		"send <literal 1>"
- 	"If we reach this point, we have a marker method that sends self <literal 1>"
- 	^ self literalAt: 1
- !

Item was added:
+ ----- Method: InstructionPrinter>>callPrimitive: (in category 'instruction decoding') -----
+ callPrimitive: index
+ 	"Print the callPrimitive bytecode."
+ 
+ 	self print: 'callPrimitive: ' , index printString!



More information about the Squeak-dev mailing list