#3571: Bizzarely bloated binaries
---------------------------------+------------------------------------------
    Reporter:  guest             |        Owner:              
        Type:  bug               |       Status:  new         
    Priority:  low               |    Milestone:  7.0.1       
   Component:  Compiler          |      Version:  6.10.4      
    Keywords:                    |     Testcase:              
   Blockedby:                    |   Difficulty:  Unknown     
          Os:  Unknown/Multiple  |     Blocking:              
Architecture:  Unknown/Multiple  |      Failure:  None/Unknown
---------------------------------+------------------------------------------

Comment(by michalt):

 Looking at the PE spec:
 {{{
 The .debug Section

 [snip]

 The next section describes the format of the debug directory, which can be
 anywhere in the image. Subsequent sections describe the "groups" in object
 files
 that contain debug information.

 The default for the linker is that debug information is not mapped into
 the
 address space of the image. A .debug section exists only when debug
 information
 is mapped in the address space.

 Debug Directory (Image Only)

 Image files contain an optional debug directory that indicates what form
 of
 debug information is present and where it is. This directory consists of
 an
 array of debug directory entries whose location and size are indicated in
 the
 image optional header.

 The debug directory can be in a discardable .debug section (if one
 exists), or
 it can be included in any other section in the image file, or not be in a
 section at all.

 Each debug directory entry identifies the location and size of a block of
 debug
 information. The specified RVA can be zero if the debug information is not
 covered by a section header (that is, it resides in the image file and is
 not
 mapped into the run-time address space). If it is mapped, the RVA is its
 address.
 }}}

 So if the debugging stuff is not mapped into memory, then I don't think it
 is
 going to be included in the size_of_image.

 Does that make any sense, or did I misunderstand the problem?

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/3571#comment:9>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler

_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to