#2884: Compiled code performance worsens when module names are long enough
-----------------------------+----------------------------------------------
Reporter: jcpetruzza | Owner:
Type: bug | Status: new
Priority: normal | Component: Compiler
Version: 6.10.1 | Severity: normal
Keywords: | Testcase:
Os: Unknown/Multiple | Architecture: Unknown/Multiple
-----------------------------+----------------------------------------------
Attached to this report is an example where by simply renaming a module,
performance degrades 2.5 times.
{{{
#diff long-modname-ver.hs short-modname-ver.hs
2c2
< import VeryLongModuleName
---
> import ShortM
#diff VeryLongModuleName.hs ShortM.hs
1c1
< module VeryLongModuleName
---
> module ShortM
#ghc --make -O2 -Wall long-modname-ver.hs
#ghc --make -O2 -Wall short-modname-ver.hs
#time -p ./long-modname-ver > /dev/null
real 55.90
user 55.17
sys 0.51
#time -p ./short-modname-ver > /dev/null
real 22.23
user 21.97
sys 0.10
}}}
According to some measures by dons, the threshold seems to be at module
length 10 (see attached graph).
Some further disussion on this thread
[http://thread.gmane.org/gmane.comp.lang.haskell.glasgow.user/16037].
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/2884>
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