[GHC] #8472: Primitive string literals prevent optimization
GHC
ghc-devs at haskell.org
Mon Nov 14 04:46:42 UTC 2016
#8472: Primitive string literals prevent optimization
-------------------------------------+-------------------------------------
Reporter: akio | Owner: gridaphobe
Type: bug | Status: patch
Priority: normal | Milestone:
Component: Compiler | Version: 7.6.3
Resolution: | Keywords: newcomer
Operating System: Linux | Architecture: x86_64
Type of failure: Runtime | (amd64)
performance bug | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s): Phab:D2554,
Wiki Page: | Phab:D2605
-------------------------------------+-------------------------------------
Comment (by akio):
My patch (Phab:D2605) causes some compiler perf regressions. This happens
because
{{{
f x = ... "foo"# ...
}}}
now gets transformed into
{{{
foo = "foo"#
f x = ... foo ...
}}}
and this means a larger code size.
For example, on `perf/compiler/T1969`, the `peak_megabytes_allocated` goes
from 63 to 68 (a 8% increase), the code size (in terms of the `Term`
component of `CoreStats`) goes from 12603 to 13271 (a 10% increase), and
this is fully explained by the above effect, which increases the code size
by 2 for each top-level string literal.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8472#comment:16>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list