LLVM mangler takes too long at runtime
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 ...
- 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
Trac metadata
| Trac field | Value |
|---|---|
| Version | 7.0.1 |
| Type | Bug |
| TypeOfFailure | OtherFailure |
| Priority | normal |
| Resolution | Unresolved |
| Component | Compiler (LLVM) |
| Test case | |
| Differential revisions | |
| BlockedBy | |
| Related | |
| Blocking | |
| CC | |
| Operating system | |
| Architecture |