[GHC] #9186: GHC panic when compiling compdata

GHC ghc-devs at haskell.org
Fri Oct 17 07:45:52 UTC 2014


#9186: GHC panic when compiling compdata
-------------------------------------+-------------------------------------
              Reporter:  snoyberg    |            Owner:  simonmar
                  Type:  bug         |           Status:  new
              Priority:  high        |        Milestone:  7.10.1
             Component:  Compiler    |          Version:  7.8.2
            Resolution:              |         Keywords:
      Operating System:              |     Architecture:  Unknown/Multiple
  Unknown/Multiple                   |       Difficulty:  Unknown
       Type of failure:              |       Blocked By:
  None/Unknown                       |  Related Tickets:  #8935
             Test Case:              |
              Blocking:              |
Differential Revisions:              |
-------------------------------------+-------------------------------------

Comment (by trommler):

 Replying to [comment:24 trommler]:
 > > I rebased the patch for #8935 and cannot reproduce the issue for
 compdata version 0.8.1.0 and 0.9.
 > I also built Haskell Platform
 [https://build.opensuse.org/project/show/devel:languages:haskell:platform]
 and pandoc
 [https://build.opensuse.org/project/show/devel:languages:haskell:pandoc]
 on OBS and did not see the issue.
 Setting environment variable `SUSE_ASNEEDED=1` I can reproduce the bug.
 That environment variable changes the behaviour of the link editor to
 include the flag `--as-neeeded` in the link command.

 From man ld(1):
        --as-needed
        --no-as-needed
            This option affects ELF DT_NEEDED tags for dynamic libraries
            mentioned on the command line after the --as-needed option.
            Normally the linker will add a DT_NEEDED tag for each dynamic
            library mentioned on the command line, regardless of whether
 the
            library is actually needed or not.  --as-needed causes a
 DT_NEEDED
            tag to only be emitted for a library that satisfies an
 undefined
            symbol reference from a regular object file or, if the library
 is
            not found in the DT_NEEDED lists of other libraries linked up
 to
            that point, an undefined symbol reference from another dynamic
            library.  --no-as-needed restores the default behaviour.

 The important point here is: The order of the linker arguments does
 matter!

 I do not understand, however, what adding -v3 changes (see [comment:13
 @rwbarton's comment]) to make the build go through.

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


More information about the ghc-tickets mailing list