Cross-posting to the JVM Languages group. You might want to see the
history of this thread as well:
http://old.nabble.com/-scala--r19952%3A-performance-degradation-to26663553.html
Can anyone from the experts comment on the fact why using null as
exception type ('any' in javap) in a handler instead of Throwable
results in such a big performance win (> 2x) ? Is it a special
performance optimization in the Hotspot VM for finally clauses? Is it
known and documented somewhere?
Thanks,
Johannes
On Sun, Dec 6, 2009 at 9:51 PM, Lukas Rytz <
lukas...@epfl.ch> wrote:
> amazing.. this probably means that we can speed up any exception
> handler catching `Throwable`.
>
> On Sun, Dec 6, 2009 at 19:14, Paul Phillips <
pa...@improving.org> wrote:
>>
>> On Sun, Dec 06, 2009 at 05:36:20PM +0100, Lukas Rytz wrote:
>> > Thanks for trimming it down. I'll have a look.
>>
>> Also, I reproduced the slowdown and verified that this diff alone is
>> enough to induce it.
>>
>> - (NoSymbol, expectedType, exhCtx => {
>> + (ThrowableClass, expectedType, exhCtx => {
>>
>> --
>> Paul Phillips | Where there's smoke, there's mirrors!
>> Future Perfect |
>> Empiricist |
>> pal, i pill push |----------*
http://www.improving.org/paulp/
>> *----------
>
>
--
Johannes
-----------------------------------------------
Johannes Rudolph
http://virtual-void.net