[squeak-dev] A UTC based implementation of DateAndTime

David T. Lewis lewis at mail.msen.com
Sun Aug 24 20:11:55 UTC 2014


On Wed, May 28, 2014 at 11:49:08AM +0200, Bert Freudenberg wrote:
> On 25.05.2014, at 19:48, David T. Lewis <lewis at mail.msen.com> wrote:
> 
> > Performance of the UTC based DateAndTime is generally favorable compared to
> > the original. Here is what I see on my system (smaller numbers are better).
> > 
> > LXTestDateAndTimePerformance test results using the original Squeak DateAndTime
> > on an interpreter VM:
> > {
> > 	#testNow->10143 .
> > 	#testEquals->30986 .
> > 	#testGreaterThan->80199 .
> > 	#testLessThan->75912 .
> > 	#testPrintString->10429 .
> > 	#testStringAsDateAndTime->44657
> > }
> > 
> > LXTestDateAndTimePerformance test results using the new UTC based DateAndTime
> > on an interpreter VM:
> > {
> > 	#testNow->6423 .
> > 	#testEquals->31625 .
> > 	#testGreaterThan->22999 .
> > 	#testLessThan->18514 .
> > 	#testPrintString->12502 .
> > 	#testStringAsDateAndTime->32912
> > }
> 
> Hi Dave,
> 
> just curious: did you test the performance without the LargeInt primitives?
> 
> - Bert -
> 

Hi Bert,

Sorry for the extremely late reply. I had never tried the UTC DateAndTime
without a LargeIntegersPlugin, but I realize now that the question might be
important for the SqueakJS VM, so a ran some tests using an interpreter VM
with and without LargeIntegersPlugin.

The results were not at all what I expected. Very surprisingly (at least
to me), the plugin seems to make very little difference in the performance of
the UTC DateAndTime. The UTC DateAndTime seems to be a bit slower on
printString and equality testing (?), and quite a bit faster on the other
measures. But the LargeIntegersPlugin does not seem to make much of a
difference at all.

Here is what I saw on my machine today.

Standard DateAndTime, standard VM:
LXTestDateAndTimePerformance new test. ==>
{
	#testNow->9147 .
	#testEquals->28252 .
	#testGreaterThan->27358 .
	#testLessThan->24664 .
	#testPrintString->10955 .
	#testStringAsDateAndTime->48505
}

Standard DateAndTime, no LargeIntegersPlugin:
LXTestDateAndTimePerformance new test. ==>
{
	#testNow->28324 .
	#testEquals->27985 .
	#testGreaterThan->27837 .
	#testLessThan->23783 .
	#testPrintString->11321 .
	#testStringAsDateAndTime->46679
}

UTC DateAndTime, standard VM:
LXTestDateAndTimePerformance new test. ==>
{
	#testNow->5807 .
	#testEquals->28168 .
	#testGreaterThan->19764 .
	#testLessThan->16117 .
	#testPrintString->13212 .
	#testStringAsDateAndTime->36652
}

UTC DateAndTime, no LargeIntegersPlugin:
LXTestDateAndTimePerformance new test. ==>
{
	#testNow->5759 .
	#testEquals->30079 .
	#testGreaterThan->19934 .
	#testLessThan->16315 .
	#testPrintString->14125 .
	#testStringAsDateAndTime->38208
}




More information about the Squeak-dev mailing list