Core top-level bindings no longer deduplicated
This module
module Two where
f :: Int -> Int
f n = n + 1 + 1
g :: Int -> Int
g n = n + 1 + 1
used to (in 8.0) optimize to a definition of g
plus f = g
. The Common sub-expression phase noticed f
and g
were equal.
That doesn't happen any more in HEAD and we end up with two copies of the code. The Common sub-expression pass apparently still runs, it just doesn't succeed in removing one of the bindings.
Trac metadata
Trac field | Value |
---|---|
Version | 8.1 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | high |
Resolution | Unresolved |
Component | Compiler |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | |
Architecture |