Re:Welcome to C-- (2008)
by bradrn on Sunday January 23, 2022 @08:11AM
(#30045893)
Though this page doesn’t seem to mention it, the Glasgow Haskell Compiler still uses Cmm as its backend [0]. (Cmm is a close relative of C--, though I’m not sure exactly what the differences are.) In fact, if you pass -ddump-cmm to GHC (or any other one of the -ddump-cmm-* options, [1]) you should be able to see the Cmm code output for any given Haskell program. Alas, it doesn’t seem to work in the REPL, though at least -ddump-simpl (dumping the Core intermediate language) does.
[0] https://gitlab.haskell.org/ghc/ghc/-/wikis/commentary/rts/cm...
[1] https://downloads.haskell.org/ghc/latest/docs/html/users_gui...