Make SpecConstr more aggressive, by neglecting reboxing
authorsimonpj@microsoft.com <unknown>
Fri, 24 Nov 2006 13:20:54 +0000 (13:20 +0000)
committersimonpj@microsoft.com <unknown>
Fri, 24 Nov 2006 13:20:54 +0000 (13:20 +0000)
commitd8a34b36969e4c41a727b4678d6049266f7a1c58
treed6634de5940d909fbdd09ba268536f1850f0b9c5
parent5d53543308da8a9b2c81c1dacf41a76f31a55dcd
Make SpecConstr more aggressive, by neglecting reboxing

SpecConstr was conservative about avoiding reboxing (see Note [Reboxing])
but that meant it lost useful opportunities.  This patch makes it much
more aggressive, but at the risk of doing some reboxing.

Actually, the strictness analyser has the same property (it's possible
for it to generate reboxing code, and thus increase allocation), but we
don't worry so much about that.  Maybe we should.

Ideally, one would do some more sophisticated analysis that spotted
the reboxing cases without excluding the useful ones.

But meanwhile, let's try this.
compiler/specialise/SpecConstr.lhs