millisecondClockValue

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

millisecondClockValue

Pharo Smalltalk Developers mailing list
Hello,

Is there any reason why we do not use microsecondClockValue to compute millisecondClockValue ?
Other that "because someone has to do it" I mean.
I’ve changed Time>>millisecondClockValue to be computed from microsecondClockValue
and modulo change of the event stamp initialization, it seems to work normally.

Cheers
Alain


Reply | Threaded
Open this post in threaded view
|

Re: millisecondClockValue

Eliot Miranda-2
Hi Alain,

   that's actually a good question.  The issue is whether the millisecond clock should start from zero or not.  Clearly deriving it from the 64-bit microsecond clock is a win.  It won't wrap (not for 50,000 years at least).  But the current clock starts at 0 when the image starts up.  If one were to continue to zero the millisecond clock on image startup won't overflow into large integers for 12.4 days, but it isn't really a clock.  Personally my preference is to indeed implement millisecondClockValue as microsecondClockValue // 1000, and simply live with the fact that its always a large integer.

On Sat, Jul 18, 2015 at 6:51 AM, Alain Plantec via Pharo-dev <[hidden email]> wrote:


---------- Forwarded message ----------
From: Alain Plantec <[hidden email]>
To: Pharo Development List <[hidden email]>
Cc: 
Date: Sat, 18 Jul 2015 15:50:46 +0200
Subject: millisecondClockValue
Hello,

Is there any reason why we do not use microsecondClockValue to compute millisecondClockValue ?
Other that "because someone has to do it" I mean.
I’ve changed Time>>millisecondClockValue to be computed from microsecondClockValue
and modulo change of the event stamp initialization, it seems to work normally.

Cheers
Alain






--
_,,,^..^,,,_
best, Eliot