[squeak-dev] The Trunk: System-dtl.1118.mcz

commits at source.squeak.org commits at source.squeak.org
Thu Nov 14 16:44:14 UTC 2019


David T. Lewis uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-dtl.1118.mcz

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

Name: System-dtl.1118
Author: dtl
Time: 14 November 2019, 11:44:09.783497 am
UUID: e1e88bc2-8860-4665-9ac4-af0e01dc258c
Ancestors: System-mt.1117

When reporting VM parameters, enable formatting in the case of a parameter value that is represented as a Float rather than an Integer. This may happen if a VM parameter is defined in units of milliseconds but internally measured to microsecond precision by the VM, in which case the value may be returned as a Float in order to retain full precision. SmalltalkImage>>formatVMParameter: handles the formatting for integer and non-integer values.

Includes recommendations from Marcel and Chris, original System-dtl.1118 submission is moved to treated inbox.

=============== Diff against System-mt.1117 ===============

Item was added:
+ ----- Method: SmalltalkImage>>formatVMParameter: (in category 'vm statistics') -----
+ formatVMParameter: aNumber
+ 	"Format a VM parameter that may have been reported either as a Float or
+ 	an Integer. If a VM parameter is defined in units of milliseconds but internally
+ 	measured to microsecond precision by the VM, the VM may choose to return
+ 	the value as a Float in order to retain full precision. Otther representations
+ 	such as Fraction may seem more natural but are difficult to instantiate in
+ 	the VM, hence the presumption of Float for representation of higher precision
+ 	millisecond values."
+ 
+ 	^ aNumber isFloat
+ 		ifTrue: [ aNumber < 1000
+ 			ifTrue: [ aNumber printShowingMaxDecimalPlaces: 5 ]
+ 			ifFalse: [ aNumber rounded asStringWithCommas ] ]
+ 		ifFalse: [ aNumber asInteger asStringWithCommas ].!

Item was changed:
  ----- Method: SmalltalkImage>>vmStatisticsReportOn: (in category 'vm statistics') -----
(excessive size, no diff calculated)



More information about the Squeak-dev mailing list