[commit: ghc] wip/kavon-nosplit-llvm: fix build due to the removal of Hoopl.Unique (54321d5)

git at git.haskell.org git at git.haskell.org
Thu Mar 8 03:58:24 UTC 2018


Repository : ssh://git@git.haskell.org/ghc

On branch  : wip/kavon-nosplit-llvm
Link       : http://ghc.haskell.org/trac/ghc/changeset/54321d57aa315046b7690d1d6aa9cf08750f1ef3/ghc

>---------------------------------------------------------------

commit 54321d57aa315046b7690d1d6aa9cf08750f1ef3
Author: Kavon Farvardin <kavon at farvard.in>
Date:   Wed Mar 7 20:27:43 2018 -0600

    fix build due to the removal of Hoopl.Unique


>---------------------------------------------------------------

54321d57aa315046b7690d1d6aa9cf08750f1ef3
 compiler/llvmGen/LlvmMangler.hs | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/compiler/llvmGen/LlvmMangler.hs b/compiler/llvmGen/LlvmMangler.hs
index e905fe0..4d2d461 100644
--- a/compiler/llvmGen/LlvmMangler.hs
+++ b/compiler/llvmGen/LlvmMangler.hs
@@ -23,7 +23,6 @@ import qualified Data.ByteString.Char8 as B
 import System.IO
 import Hoopl.Label
 import Hoopl.Collections
-import Hoopl.Unique ( intToUnique )
 import Data.Maybe ( fromMaybe )
 
 -- note [mangler string func]
@@ -85,7 +84,7 @@ addInfoTable :: LabelMap ManglerStr -> LabRewrite
 addInfoTable info FirstLabel dflags line = do
         retPt <- stripPrefix labPrefix line
         (i, _) <- B.readInt retPt
-        statics <- mapLookup (toKey i) info
+        statics <- mapLookup (mkHooplLabel i) info
         fullName <- stripSuffix colon line
         return $ B.concat $ (map (\f -> f fullName) statics) ++ [line]
     where
@@ -99,7 +98,6 @@ addInfoTable info FirstLabel dflags line = do
                         otherwise -> panic "Please update LLVM Mangler for this OS."
                         
         colon = B.pack ":"
-        toKey = uniqueToLbl . intToUnique
         
         -- TODO(kavon): on Travis CI, it seems the bytestring package is out of date, and
         -- we're missing B.stripSuffix and B.stripPrefix. I've reimplemented them here.



More information about the ghc-commits mailing list