[commit: ghc] wip/improve-pext-pdep: Dump Cmm with -ddump-cmm when building .cmm files (2880cb9)

git at git.haskell.org git at git.haskell.org
Sun Jan 6 09:26:39 UTC 2019


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

On branch  : wip/improve-pext-pdep
Link       : http://ghc.haskell.org/trac/ghc/changeset/2880cb9840e268fdc33347a87a8276b03c227db8/ghc

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

commit 2880cb9840e268fdc33347a87a8276b03c227db8
Author: Ömer Sinan Ağacan <omeragacan at gmail.com>
Date:   Sat Jan 5 08:40:19 2019 +0300

    Dump Cmm with -ddump-cmm when building .cmm files
    
    Fixes #16131


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

2880cb9840e268fdc33347a87a8276b03c227db8
 compiler/main/HscMain.hs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/compiler/main/HscMain.hs b/compiler/main/HscMain.hs
index c2c9124..2ff2ca0 100644
--- a/compiler/main/HscMain.hs
+++ b/compiler/main/HscMain.hs
@@ -1438,6 +1438,7 @@ hscCompileCmmFile hsc_env filename output_filename = runHsc hsc_env $ do
             mod_name = mkModuleName $ "Cmm$" ++ FilePath.takeFileName filename
             cmm_mod = mkModule (thisPackage dflags) mod_name
         (_, cmmgroup) <- cmmPipeline hsc_env (emptySRT cmm_mod) cmm
+        dumpIfSet_dyn dflags Opt_D_dump_cmm "Output Cmm" (ppr cmmgroup)
         rawCmms <- cmmToRawCmm dflags (Stream.yield cmmgroup)
         _ <- codeOutput dflags cmm_mod output_filename no_loc NoStubs [] []
              rawCmms



More information about the ghc-commits mailing list