[GHC] #11502: Scrutinize use of 'long' in rts/

GHC ghc-devs at haskell.org
Wed Jan 27 22:22:00 UTC 2016


#11502: Scrutinize use of 'long' in rts/
-------------------------------------+-------------------------------------
           Reporter:  thomie         |             Owner:
               Type:  task           |            Status:  new
           Priority:  normal         |         Milestone:
          Component:  Runtime        |           Version:  7.10.3
  System                             |
           Keywords:                 |  Operating System:  Unknown/Multiple
       Architecture:                 |   Type of failure:  None/Unknown
  Unknown/Multiple                   |
          Test Case:                 |        Blocked By:
           Blocking:                 |   Related Tickets:
Differential Rev(s):                 |         Wiki Page:
-------------------------------------+-------------------------------------
 In commit 53055bb5023e8cc145ad8a9cd36ac56cee4695b0 (#5656), several uses
 of `int` in the rts were replaced by `long`, to avoid potential overflows
 for some calculations. On Windows though, `int` and `long` have the same
 size (4 bytes).

 Carefully go through all uses of `long` in `rts/`, and replace by one of
 the types from `includes/stg/Types.h`:

 * `long` -> `StgInt` or `StgInt64`
 * `unsigned long` -> `StgWord` or `StgWord64`

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11502>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list