Repository : ssh://darcs.haskell.org//srv/darcs/ghc On branch : master
http://hackage.haskell.org/trac/ghc/changeset/45a40bab4aea14ee85375e5f1150f49c6b0b2646 >--------------------------------------------------------------- commit 45a40bab4aea14ee85375e5f1150f49c6b0b2646 Author: Ian Lynagh <[email protected]> Date: Thu Mar 15 15:28:04 2012 +0000 Fix PprC for 64bit platforms with 32bit long's e.g. Win64 >--------------------------------------------------------------- compiler/cmm/PprC.hs | 9 +++++---- includes/HaskellConstants.hs | 6 ++++++ 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/compiler/cmm/PprC.hs b/compiler/cmm/PprC.hs index 9da0059..346b108 100644 --- a/compiler/cmm/PprC.hs +++ b/compiler/cmm/PprC.hs @@ -1107,10 +1107,11 @@ pprHexVal w rep -- times values are unsigned. This also helps eliminate occasional -- warnings about integer overflow from gcc. - -- on 32-bit platforms, add "ULL" to 64-bit literals - repsuffix W64 | wORD_SIZE == 4 = ptext (sLit "ULL") - -- on 64-bit platforms with 32-bit int, add "L" to 64-bit literals - repsuffix W64 | cINT_SIZE == 4 = ptext (sLit "UL") + repsuffix W64 + | cINT_SIZE == 8 = char 'U' + | cLONG_SIZE == 8 = ptext (sLit "UL") + | cLONG_LONG_SIZE == 8 = ptext (sLit "ULL") + | otherwise = panic "pprHexVal: Can't find a 64-bit type" repsuffix _ = char 'U' go 0 = empty diff --git a/includes/HaskellConstants.hs b/includes/HaskellConstants.hs index e38e896..ef38cb5 100644 --- a/includes/HaskellConstants.hs +++ b/includes/HaskellConstants.hs @@ -176,6 +176,12 @@ mAX_PTR_TAG = tAG_MASK cINT_SIZE :: Int cINT_SIZE = SIZEOF_INT +cLONG_SIZE :: Int +cLONG_SIZE = SIZEOF_LONG + +cLONG_LONG_SIZE :: Int +cLONG_LONG_SIZE = SIZEOF_LONG_LONG + -- Size of a storage manager block (in bytes). bLOCK_SIZE :: Int _______________________________________________ Cvs-ghc mailing list [email protected] http://www.haskell.org/mailman/listinfo/cvs-ghc
