[Vm-dev] primitiveUtcWithOffset broken in Spur VM, works in (older?) Cog

David T. Lewis lewis at mail.msen.com
Sun May 24 16:38:56 UTC 2015


After loading UTCDateAndTime (*) into my Spur image, I see a recurrence of
an old epoch bug. The error is in primitiveUtcWithOffset.

  DateAndTime now ==> 2084-05-23T12:11:16.131115-04:00


My Spur VM is:

Virtual Machine
---------------
/usr/local/lib/squeak/5.0-3312/squeak
Croquet Closure Cog VM [CoInterpreterPrimitives VMMaker.oscog-eem.1207]
Unix built on Apr 17 2015 12:45:25 Compiler: 4.4.7 20120313 (Red Hat 4.4.7-4)
platform sources revision VM: r3312 http://www.squeakvm.org/svn/squeak/branches/Cog Date: 2015-04-17 12:34:25 -0700 Plugins: r3275 http://squeakvm.org/svn/squeak/trunk/platforms/Cross/plugins
CoInterpreter VMMaker.oscog-eem.1207 uuid: 4a338677-029f-42ac-b38d-2bc5ecc213f1 Apr 17 2015
StackToRegisterMappingCogit VMMaker.oscog-eem.1207 uuid: 4a338677-029f-42ac-b38d-2bc5ecc213f1 Apr 17 2015

I think we fixed this in Cog a few years ago, and I do not see the problem
in this version of Cog:

Virtual Machine
---------------
/usr/local/lib/squeak/4.0-3003/squeak
Croquet Closure Cog VM [CoInterpreter VMMaker.oscog-eem.746]
Unix built on Jun 15 2014 15:31:52 Compiler: 4.1.2 20080704 (Red Hat 4.1.2-48)
platform sources revision VM: r3003 http://www.squeakvm.org/svn/squeak/branches/Cog Date: 2014-06-15 15:17:31 -0700 Plugins: r2954 http://squeakvm.org/svn/squeak/trunk/platforms/Cross/plugins
CoInterpreter VMMaker.oscog-eem.746 uuid: cc4961d3-e629-4e28-b308-88eab314a8c9 Jun 15 2014
StackToRegisterMappingCogit VMMaker.oscog-eem.774 uuid: 665ef9a5-4139-4f97-85c0-0d0df9eea422 Jun 15 2014

Note, there is a cleaner implemention of the primitive in SVN trunk which
does the time+offset inquiry as an atomic operation. The difference is academic,
but it would be nice if we could use this in Cog/Spur too.

Dave

* http://wiki.squeak.org/squeak/6197



More information about the Vm-dev mailing list