#5865: threadDelay is disrupted by system clock changes
---------------------------------+------------------------------------------
    Reporter:  joeyadams         |       Owner:  pcapriotti                 
        Type:  bug               |      Status:  patch                      
    Priority:  high              |   Milestone:  7.4.2                      
   Component:  Runtime System    |     Version:  7.4.1                      
    Keywords:                    |          Os:  Unknown/Multiple           
Architecture:  Unknown/Multiple  |     Failure:  Incorrect result at runtime
  Difficulty:  Unknown           |    Testcase:                             
   Blockedby:                    |    Blocking:                             
     Related:                    |  
---------------------------------+------------------------------------------

Comment(by pcapriotti):

 Updated win32 patch so that it falls back to `GetTickCount` (with a 64-bit
 accumulator). Using `GetTickCount` should be perfectly safe, since it's
 impossible to delay more than 2^31 μs (less than 6 hours), because
 `threadDelay` takes an `Int`.

 Incidentally, `GetTickCount` also seems unaffected by changes in the
 system clock, so the only difference would be in accuracy.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/5865#comment:16>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler

_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to