[Vm-dev] VM Maker: Cog-eem.190.mcz

commits at source.squeak.org commits at source.squeak.org
Wed Aug 13 13:44:19 UTC 2014


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

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

Name: Cog-eem.190
Author: eem
Time: 13 August 2014, 6:44:02.327 am
UUID: f2adad4d-3bc8-4fa2-b450-3f1f9a267eec
Ancestors: Cog-eem.189

Doh!  The newMethod:header: prototypes should be class-side.

=============== Diff against Cog-eem.189 ===============

Item was removed:
- ----- Method: SpurBootstrap class>>CompiledMethodPROTOTYPEhandleFailingFailingNewMethod:header: (in category 'method prototypes') -----
- CompiledMethodPROTOTYPEhandleFailingFailingNewMethod: numberOfBytes header: headerWord
- 	"This newMethod:header: gets sent after handleFailingBasicNew: has done a full
- 	 garbage collection and possibly grown memory.  If this basicNew: fails then the
- 	 system really is low on space, so raise the OutOfMemory signal.
- 
- 	 Primitive. Answer an instance of this class with the number of indexable variables
- 	 specified by the argument, headerWord, and the number of bytecodes specified
- 	 by numberOfBytes.  Fail if this if the arguments are not Integers, or if numberOfBytes
- 	 is negative, or if the receiver is not a CompiledMethod class, or if there is not enough
- 	 memory available. Essential. See Object documentation whatIsAPrimitive."
- 
- 	<primitive: 79>
- 	"space must be low."
- 	OutOfMemory signal.
- 	"retry if user proceeds"
- 	^self newMethod: numberOfBytes header: headerWord!

Item was removed:
- ----- Method: SpurBootstrap class>>CompiledMethodPROTOTYPEhandleFailingNewMethod:header: (in category 'method prototypes') -----
- CompiledMethodPROTOTYPEhandleFailingNewMethod: numberOfBytes header: headerWord
- 	"This newMethod:header: gets sent after newMethod:header: has failed
- 	 and allowed a scavenging garbage collection to occur.  The scavenging
- 	 collection will have happened as the VM is activating the (failing) basicNew:.
- 	 If handleFailingBasicNew: fails then the scavenge failed to reclaim sufficient
- 	 space and a global garbage collection is required.  Retry after garbage
- 	 collecting and growing memory if necessary.
- 
- 	 Primitive. Answer an instance of this class with the number of indexable variables
- 	 specified by the argument, headerWord, and the number of bytecodes specified
- 	 by numberOfBytes.  Fail if this if the arguments are not Integers, or if numberOfBytes
- 	 is negative, or if the receiver is not a CompiledMethod class, or if there is not enough
- 	 memory available. Essential. See Object documentation whatIsAPrimitive."
- 
- 	<primitive: 79>
- 	| bytesRequested |
- 	bytesRequested := (headerWord bitAnd: 16rFFFF) + 1 * Smalltalk wordSize + numberOfBytes + 16.
- 	Smalltalk garbageCollect < bytesRequested ifTrue:
- 		[Smalltalk growMemoryByAtLeast: bytesRequested].
- 	"retry after global garbage collect and possible grow"
- 	^self handleFailingFailingNewMethod: numberOfBytes header: headerWord!

Item was removed:
- ----- Method: SpurBootstrap class>>CompiledMethodPROTOTYPEnewMethod:header: (in category 'method prototypes') -----
- CompiledMethodPROTOTYPEnewMethod: numberOfBytes header: headerWord
- 	"Primitive. Answer an instance of me. The number of literals (and other 
- 	 information) is specified by the headerWord (see my class comment).
- 	 The first argument specifies the number of fields for bytecodes in the
- 	 method. Fail if either argument is not a SmallInteger, or if numberOfBytes
- 	 is negative, or if memory is low. Once the header of a method is set by
- 	 this primitive, it cannot be changed to change the number of literals.
- 	 Essential. See Object documentation whatIsAPrimitive."
- 
- 	<primitive: 79 error: ec>
- 	ec == #'insufficient object memory' ifTrue:
- 		[^self handleFailingNewMethod: numberOfBytes header: headerWord].
- 	^self primitiveFailed!

Item was added:
+ ----- Method: SpurBootstrap class>>CompiledMethodclassPROTOTYPEhandleFailingFailingNewMethod:header: (in category 'method prototypes') -----
+ CompiledMethodclassPROTOTYPEhandleFailingFailingNewMethod: numberOfBytes header: headerWord
+ 	"This newMethod:header: gets sent after handleFailingBasicNew: has done a full
+ 	 garbage collection and possibly grown memory.  If this basicNew: fails then the
+ 	 system really is low on space, so raise the OutOfMemory signal.
+ 
+ 	 Primitive. Answer an instance of this class with the number of indexable variables
+ 	 specified by the argument, headerWord, and the number of bytecodes specified
+ 	 by numberOfBytes.  Fail if this if the arguments are not Integers, or if numberOfBytes
+ 	 is negative, or if the receiver is not a CompiledMethod class, or if there is not enough
+ 	 memory available. Essential. See Object documentation whatIsAPrimitive."
+ 
+ 	<primitive: 79>
+ 	"space must be low."
+ 	OutOfMemory signal.
+ 	"retry if user proceeds"
+ 	^self newMethod: numberOfBytes header: headerWord!

Item was added:
+ ----- Method: SpurBootstrap class>>CompiledMethodclassPROTOTYPEhandleFailingNewMethod:header: (in category 'method prototypes') -----
+ CompiledMethodclassPROTOTYPEhandleFailingNewMethod: numberOfBytes header: headerWord
+ 	"This newMethod:header: gets sent after newMethod:header: has failed
+ 	 and allowed a scavenging garbage collection to occur.  The scavenging
+ 	 collection will have happened as the VM is activating the (failing) basicNew:.
+ 	 If handleFailingBasicNew: fails then the scavenge failed to reclaim sufficient
+ 	 space and a global garbage collection is required.  Retry after garbage
+ 	 collecting and growing memory if necessary.
+ 
+ 	 Primitive. Answer an instance of this class with the number of indexable variables
+ 	 specified by the argument, headerWord, and the number of bytecodes specified
+ 	 by numberOfBytes.  Fail if this if the arguments are not Integers, or if numberOfBytes
+ 	 is negative, or if the receiver is not a CompiledMethod class, or if there is not enough
+ 	 memory available. Essential. See Object documentation whatIsAPrimitive."
+ 
+ 	<primitive: 79>
+ 	| bytesRequested |
+ 	bytesRequested := (headerWord bitAnd: 16rFFFF) + 1 * Smalltalk wordSize + numberOfBytes + 16.
+ 	Smalltalk garbageCollect < bytesRequested ifTrue:
+ 		[Smalltalk growMemoryByAtLeast: bytesRequested].
+ 	"retry after global garbage collect and possible grow"
+ 	^self handleFailingFailingNewMethod: numberOfBytes header: headerWord!

Item was added:
+ ----- Method: SpurBootstrap class>>CompiledMethodclassPROTOTYPEnewMethod:header: (in category 'method prototypes') -----
+ CompiledMethodclassPROTOTYPEnewMethod: numberOfBytes header: headerWord
+ 	"Primitive. Answer an instance of me. The number of literals (and other 
+ 	 information) is specified by the headerWord (see my class comment).
+ 	 The first argument specifies the number of fields for bytecodes in the
+ 	 method. Fail if either argument is not a SmallInteger, or if numberOfBytes
+ 	 is negative, or if memory is low. Once the header of a method is set by
+ 	 this primitive, it cannot be changed to change the number of literals.
+ 	 Essential. See Object documentation whatIsAPrimitive."
+ 
+ 	<primitive: 79 error: ec>
+ 	ec == #'insufficient object memory' ifTrue:
+ 		[^self handleFailingNewMethod: numberOfBytes header: headerWord].
+ 	^self primitiveFailed!



More information about the Vm-dev mailing list