[squeak-dev] The Inbox: Monticello-topa.585.mcz

Tobias Pape Das.Linux at gmx.de
Sat Jan 25 21:11:40 UTC 2014


I’m late to the 4.5 wagon, I know.
Probably this is not much but who knows:

This was hinted by Stephan Eggermont.
In one image that saved me 100k, but I think in images with much more
versions loaded (seaside, magma, devel images) this could actually save a bunch.

Best
	-Tobias
PS: ignore 584, i had my changes file corrupted.


On 25.01.2014, at 21:08, commits at source.squeak.org wrote:

> A new version of Monticello was added to project The Inbox:
> http://source.squeak.org/inbox/Monticello-topa.585.mcz
> 
> ==================== Summary ====================
> 
> Name: Monticello-topa.585
> Author: topa
> Time: 25 January 2014, 10:08:51.15 pm
> UUID: ff122640-845a-402a-bd97-9fc79daea119
> Ancestors: Monticello-cmm.583
> 
> The number of distinct authors in the image is low:
> (MCVersionInfo allInstances collect: [ :each | each author ]) asIdentitySet size. "13336"
> (MCVersionInfo allInstances collect: [ :each | each author ]) asSet size. "128"
> 
> Hence, we can safely store them as symbols.
> This does not save much memory in a small image but should in
> production images.
> 
> =============== Diff against Monticello-cmm.583 ===============
> 
> Item was changed:
>  ----- Method: MCVersionInfo>>asDictionary (in category 'converting') -----
>  asDictionary
>  	^ Dictionary new
>  		at: #name put: name;
>  		at: #id put: id asString;
>  		at: #message put: message;
>  		at: #date put: date;
>  		at: #time put: time;
> + 		at: #author put: self author;
> - 		at: #author put: author;
>  		at: #ancestors put: (self ancestors collect: [:a | a asDictionary]);
>  		yourself!
> 
> Item was changed:
>  ----- Method: MCVersionInfo>>author (in category 'pillaging') -----
>  author
> + 	^ author asString!
> - 	^ author!
> 
> Item was changed:
>  ----- Method: MCVersionInfo>>initializeWithName:id:message:date:time:author:ancestors:stepChildren: (in category 'initialize-release') -----
>  initializeWithName: vName id: aUUID message: aString date: aDate time: aTime author: initials ancestors: aCollection stepChildren: stepCollection
>  	name := vName asString asMCVersionName.
>  	id := aUUID.
>  	message := aString.
>  	date := aDate.
>  	time := aTime.
> + 	author := initials ifNotNil: [:str | str asSymbol].
> - 	author := initials.
>  	ancestors :=  aCollection.
>  	stepChildren := stepCollection!
> 
> Item was changed:
>  ----- Method: MCVersionInfo>>summaryHeader (in category 'accessing') -----
>  summaryHeader
>  	^ String streamContents:
>  		[:s |
>  		s
>  			nextPutAll: 'Name: '; nextPutAll: self name; cr.
>  		date ifNotNil:
>  			[s
> + 				nextPutAll: 'Author: '; nextPutAll: self author; cr;
> - 				nextPutAll: 'Author: '; nextPutAll: author; cr;
>  				nextPutAll: 'Time: '; nextPutAll:  date asString, ', ', time asString; cr].
>  		id ifNotNil:
>  			[s nextPutAll: 'UUID: '; nextPutAll: id asString; cr].
>  		s
>  			nextPutAll: 'Ancestors: '; nextPutAll: self ancestorString.
>  		self stepChildren isEmpty ifFalse:
>  			[s cr; nextPutAll: 'Backported From: '; nextPutAll: self stepChildrenString].
>  		]!
> 
> Item was added:
> + (PackageInfo named: 'Monticello') postscript: '(MCVersionInfo allInstances select: [ :ea | (ea instVarNamed: ''author'') isSymbol not ])
> + do: [ :ea | ea instVarNamed: ''author'' put: (ea instVarNamed: ''author'') asSymbol]
> + '!
> 
> 

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 1665 bytes
Desc: Message signed with OpenPGP using GPGMail
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20140125/5720b7dc/signature.pgp


More information about the Squeak-dev mailing list