[GHC] #9952: Add -g<level>

GHC ghc-devs at haskell.org
Fri Jan 2 23:02:01 UTC 2015


#9952: Add -g<level>
-------------------------------------+-------------------------------------
              Reporter:  tibbe       |             Owner:
                  Type:  bug         |            Status:  new
              Priority:  normal      |         Milestone:
             Component:  Compiler    |           Version:  7.8.4
              Keywords:              |  Operating System:  Unknown/Multiple
          Architecture:              |   Type of failure:  None/Unknown
  Unknown/Multiple                   |        Blocked By:
             Test Case:              |   Related Tickets:
              Blocking:              |
Differential Revisions:              |
-------------------------------------+-------------------------------------
 We should add debug info levels, just like GCC and LLVM has. In
 particular, I'd like to have -g1 which has (from
 https://gcc.gnu.org/onlinedocs/gcc/Debugging-Options.html)

 > minimal information, enough for making backtraces in parts of the
 program that you don't plan to debug. This includes descriptions of
 functions and external variables, and line number tables, but no
 information about local variables.

 This should let us have -g1 turned on even in production code, as it
 should grow binary sizes by much. This in turn should be a boon for
 debugability of programs. It should also allow us to offer some for of
 stack traces without any runtime cost (except when an exception with a
 stack trace is actually raised.)

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


More information about the ghc-tickets mailing list