[GHC] #16063: ghc-8.6.3 + Mac OSX + FFI dependency causes 'impossible happened' compiler failure

GHC ghc-devs at haskell.org
Wed Jan 16 05:52:08 UTC 2019


#16063: ghc-8.6.3 + Mac OSX +  FFI dependency causes 'impossible happened' compiler
failure
-------------------------------------+-------------------------------------
        Reporter:  benselfridge      |                Owner:  (none)
            Type:  bug               |               Status:  patch
        Priority:  normal            |            Milestone:
       Component:  Compiler          |              Version:  8.6.3
      Resolution:                    |             Keywords:
Operating System:  MacOS X           |         Architecture:  x86_64
 Type of failure:  Compile-time      |  (amd64)
  crash or panic                     |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):  Phab:D5462
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by Alec Theriault <alec.theriault@…>):

 In [changeset:"6b5ec08a4a64525bae87a8c2202688ffc6f86aa8/ghc"
 6b5ec08a/ghc]:
 {{{
 #!CommitTicketReference repository="ghc"
 revision="6b5ec08a4a64525bae87a8c2202688ffc6f86aa8"
 Check that libs found by GCC aren't folders

 Summary:
 We use 'gcc -B<base-location> --print-file-name mylib.a' as a way of
 checking if 'gcc' can discover 'mylib.a' at the given location. However,
 this can break down if there is a folder caller 'mylib.a' that 'gcc' can
 discover. We can guard against this by explicitly checking that the path
 returned by 'gcc' is a file.

 This may seem like a far-fetched scenario, but since
 3d17f1f10fc00540ac052f2fd03182906aa47e35, we look for libraries without
 any prefix or suffix (ie. 'extra-libraries: softfloat', we look for just
 'softfloat' as well as 'softloat.a', 'softfloat.dll.a', etc.) which means
 that there might actusally be a folder of that name in one of the base
 locations.

 Reviewers: Phyx, bgamari, hvr, angerman

 Reviewed By: Phyx, angerman

 Subscribers: angerman, rwbarton, carter

 GHC Trac Issues: #16063

 Differential Revision: https://phabricator.haskell.org/D5462
 }}}

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


More information about the ghc-tickets mailing list