#4838: LLVM mangler takes too long at runtime
---------------------------------+------------------------------------------
    Reporter:  benl              |       Owner:  davidte...@…                
        Type:  bug               |      Status:  new                         
    Priority:  normal            |   Component:  Compiler (LLVM)             
     Version:  7.0.1             |    Keywords:                              
    Testcase:                    |   Blockedby:                              
          Os:  MacOS X           |    Blocking:                              
Architecture:  Unknown/Multiple  |     Failure:  Compile-time performance bug
---------------------------------+------------------------------------------
 Compiling the !BarnesHut example from DPH takes 30 min with -fllvm, but
 only 2 min with -fasm. The Words benchmark has similar problems. Running
 GHC with -v and using 'top' shows that the llvm compiler finishes in <
 1min, so the problem is in GHC and not LLVM. Suspect complexity issues in
 LLVM mangler, which is  only needed on OSX. #4211 is related.

 {{{
 limitingfactor:dph-examples benl$ pwd
 /Users/benl/devel/ghc/build/nightly/ghc-head/libraries/dph/dph-examples

 # Compiling with the NCG
 /usr/bin/time ../../../inplace/bin/ghc-stage2 -fasm -Odph \
  --make imaginary/Words/Main.hs -package dph-prim-par -package dph-par \
  -iimaginary/Words -fforce-recomp
 [1 of 2] Compiling WordsVect        ( imaginary/Words/WordsVect.hs,
 imaginary/Words/WordsVect.o )
 [2 of 2] Compiling Main             ( imaginary/Words/Main.hs,
 imaginary/Words/Main.o )
 Linking imaginary/Words/Main ...
        93.21 real        91.30 user         1.68 sys

 # Compiling with LLVM
 /usr/bin/time ../../../inplace/bin/ghc-stage2 -fllvm -Odph \
  --make imaginary/Words/Main.hs -package dph-prim-par \
  -package dph-par -iimaginary/Words -fforce-recomp
 [1 of 2] Compiling WordsVect        ( imaginary/Words/WordsVect.hs,
 imaginary/Words/WordsVect.o )

 # ... 10 mins later I'm getting bored so Control-C it, though it's
 completed in the past.
 ^C      677.91 real       673.53 user         3.59 sys

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/4838>
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