Revision: 3303 Author: eliot Date: 2015-04-02 10:48:13 -0700 (Thu, 02 Apr 2015) Log Message: ----------- Emergency patch for stupid slip in followForwardingPointersInStackZone.
Modified Paths: -------------- branches/Cog/nsspursrc/vm/gcc3x-cointerp.c branches/Cog/platforms/unix/vm/sqUnixHeartbeat.c branches/Cog/platforms/unix/vm/sqUnixITimerHeartbeat.c branches/Cog/platforms/unix/vm/sqUnixITimerTickerHeartbeat.c branches/Cog/platforms/win32/vm/sqWin32Heartbeat.c branches/Cog/spursistasrc/vm/gcc3x-cointerp.c branches/Cog/spursrc/vm/gcc3x-cointerp.c
Modified: branches/Cog/nsspursrc/vm/gcc3x-cointerp.c =================================================================== --- branches/Cog/nsspursrc/vm/gcc3x-cointerp.c 2015-04-02 17:02:47 UTC (rev 3302) +++ branches/Cog/nsspursrc/vm/gcc3x-cointerp.c 2015-04-02 17:48:13 UTC (rev 3303) @@ -17438,9 +17438,7 @@ assert(addressIsInPage(thePage, theFP)); assert((theIPPtr == 0) || (addressIsInPage(thePage, ((void *)theIPPtr)))); - offset = theFP + (frameStackedReceiverOffsetNumArgs(((((usqInt)(longAt(theFP + FoxMethod)))) < (startOfMemory()) - ? ((mframeCogMethod(theFP))->cmNumArgs) - : byteAt((theFP + FoxIFrameFlags) + 1)))); + offset = frameReceiverOffset(theFP); while (theSP <= offset) { oop = longAt(theSP); if (((oop & 3) == 0)
Modified: branches/Cog/platforms/unix/vm/sqUnixHeartbeat.c =================================================================== --- branches/Cog/platforms/unix/vm/sqUnixHeartbeat.c 2015-04-02 17:02:47 UTC (rev 3302) +++ branches/Cog/platforms/unix/vm/sqUnixHeartbeat.c 2015-04-02 17:48:13 UTC (rev 3303) @@ -148,11 +148,21 @@ void ioUpdateVMTimezone() { + updateMicrosecondClock(); +#ifdef HAVE_TM_GMTOFF time_t utctt; - updateMicrosecondClock(); utctt = (get64(utcMicrosecondClock) - MicrosecondsFrom1901To1970) / MicrosecondsPerSecond; vmGMTOffset = localtime(&utctt)->tm_gmtoff * MicrosecondsPerSecond; +#else +# ifdef HAVE_TIMEZONE + extern time_t timezone, altzone; + extern int daylight; + vmGMTOffset = -1 * (daylight ? altzone : timezone) * MicrosecondsPerSecond; +# else +# error: cannot determine timezone correction +# endif +#endif }
sqLong
Modified: branches/Cog/platforms/unix/vm/sqUnixITimerHeartbeat.c =================================================================== --- branches/Cog/platforms/unix/vm/sqUnixITimerHeartbeat.c 2015-04-02 17:02:47 UTC (rev 3302) +++ branches/Cog/platforms/unix/vm/sqUnixITimerHeartbeat.c 2015-04-02 17:48:13 UTC (rev 3303) @@ -138,9 +138,9 @@ void ioUpdateVMTimezone() { + updateMicrosecondClock(); #ifdef HAVE_TM_GMTOFF time_t utctt; - updateMicrosecondClock(); utctt = (get64(utcMicrosecondClock) - MicrosecondsFrom1901To1970) / MicrosecondsPerSecond; vmGMTOffset = localtime(&utctt)->tm_gmtoff * MicrosecondsPerSecond;
Modified: branches/Cog/platforms/unix/vm/sqUnixITimerTickerHeartbeat.c =================================================================== --- branches/Cog/platforms/unix/vm/sqUnixITimerTickerHeartbeat.c 2015-04-02 17:02:47 UTC (rev 3302) +++ branches/Cog/platforms/unix/vm/sqUnixITimerTickerHeartbeat.c 2015-04-02 17:48:13 UTC (rev 3303) @@ -141,11 +141,21 @@ void ioUpdateVMTimezone() { + updateMicrosecondClock(); +#ifdef HAVE_TM_GMTOFF time_t utctt; - updateMicrosecondClock(); utctt = (get64(utcMicrosecondClock) - MicrosecondsFrom1901To1970) / MicrosecondsPerSecond; vmGMTOffset = localtime(&utctt)->tm_gmtoff * MicrosecondsPerSecond; +#else +# ifdef HAVE_TIMEZONE + extern time_t timezone, altzone; + extern int daylight; + vmGMTOffset = -1 * (daylight ? altzone : timezone) * MicrosecondsPerSecond; +# else +# error: cannot determine timezone correction +# endif +#endif }
sqLong
Modified: branches/Cog/platforms/win32/vm/sqWin32Heartbeat.c =================================================================== --- branches/Cog/platforms/win32/vm/sqWin32Heartbeat.c 2015-04-02 17:02:47 UTC (rev 3302) +++ branches/Cog/platforms/win32/vm/sqWin32Heartbeat.c 2015-04-02 17:48:13 UTC (rev 3303) @@ -215,6 +215,7 @@ { __int64 utcNow, localNow;
+ updateMicrosecondClock(); GetSystemTimeAsFileTime((FILETIME *)&utcNow); FileTimeToLocalFileTime((FILETIME *)&utcNow,(FILETIME *)&localNow); vmGMTOffset = (localNow - utcNow) / (__int64)TocksPerMicrosecond;
Modified: branches/Cog/spursistasrc/vm/gcc3x-cointerp.c =================================================================== --- branches/Cog/spursistasrc/vm/gcc3x-cointerp.c 2015-04-02 17:02:47 UTC (rev 3302) +++ branches/Cog/spursistasrc/vm/gcc3x-cointerp.c 2015-04-02 17:48:13 UTC (rev 3303) @@ -17884,9 +17884,7 @@ assert(addressIsInPage(thePage, theFP)); assert((theIPPtr == 0) || (addressIsInPage(thePage, ((void *)theIPPtr)))); - offset = theFP + (frameStackedReceiverOffsetNumArgs(((((usqInt)(longAt(theFP + FoxMethod)))) < (startOfMemory()) - ? ((mframeCogMethod(theFP))->cmNumArgs) - : byteAt((theFP + FoxIFrameFlags) + 1)))); + offset = frameReceiverOffset(theFP); while (theSP <= offset) { oop = longAt(theSP); if (((oop & 3) == 0)
Modified: branches/Cog/spursrc/vm/gcc3x-cointerp.c =================================================================== --- branches/Cog/spursrc/vm/gcc3x-cointerp.c 2015-04-02 17:02:47 UTC (rev 3302) +++ branches/Cog/spursrc/vm/gcc3x-cointerp.c 2015-04-02 17:48:13 UTC (rev 3303) @@ -13062,9 +13062,7 @@ assert(addressIsInPage(thePage, theFP)); assert((theIPPtr == 0) || (addressIsInPage(thePage, ((void *)theIPPtr)))); - offset = theFP + (frameStackedReceiverOffsetNumArgs(((((usqInt)(longAt(theFP + FoxMethod)))) < (startOfMemory()) - ? ((mframeCogMethod(theFP))->cmNumArgs) - : byteAt((theFP + FoxIFrameFlags) + 1)))); + offset = frameReceiverOffset(theFP); while (theSP <= offset) { oop = longAt(theSP); if (((oop & 3) == 0)
vm-dev@lists.squeakfoundation.org