diff options
author | Lukas Rytz <lukas.rytz@gmail.com> | 2015-07-08 22:59:56 +0200 |
---|---|---|
committer | Lukas Rytz <lukas.rytz@gmail.com> | 2015-07-10 12:12:15 +0200 |
commit | b97e9d5f20632b2d5c3a5933fa205bcbb5b1b359 (patch) | |
tree | 97c076edd5a2ce91df12123ed25ff5dcb7f5c5f8 /test/files/neg/t8006.scala | |
parent | 02c3bac0b2c534ff8a8bbdb544034bf68a0be334 (diff) | |
download | scala-b97e9d5f20632b2d5c3a5933fa205bcbb5b1b359.tar.gz scala-b97e9d5f20632b2d5c3a5933fa205bcbb5b1b359.tar.bz2 scala-b97e9d5f20632b2d5c3a5933fa205bcbb5b1b359.zip |
Refactor the ClosureOptimizer, run ProdCons only once per method
Refactor and clean up the ClosureOptimzier. The goal of this change
is to run the ProdCons analyzer only once per method, instead of
once per closure instantiation.
Bootstrapping scala with `-Yopt-inline-heuristics:everything` revealed
that ProdCons can take a very long time on large methods, for example
```
[quick.compiler] scala/tools/nsc/backend/jvm/BCodeBodyBuilder$PlainBodyBuilder#genArithmeticOp - analysis: 1 spans, 17755ms
[quick.compiler] scala/tools/nsc/typechecker/SuperAccessors$SuperAccTransformer#transform - analysis: 1 spans, 28024ms
[quick.compiler] scala/tools/nsc/backend/jvm/BCodeBodyBuilder$PlainBodyBuilder#genInvokeDynamicLambda - analysis: 1 spans, 22100ms
```
With this change and enough time and space (-Xmx6000m), bootstrapping
scala succeeds in this test mode.
Diffstat (limited to 'test/files/neg/t8006.scala')
0 files changed, 0 insertions, 0 deletions