You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Oh this is incredible and I didn't know about it. What this allows us to do is eliminate a megamorphic virtual dispatch. The replacement looks to be a tableswitch. Without digging into the JIT output, I can only guess about how it gets inlined, but clearly this gives the runtime a lot more information to work with. Very nice.
The linked scala/scala PR is really interesting. I did a similar set of benchmarking (though more specialized to IOFiber and obviously not including ClassValue) and found that virtual dispatch fell behind tableswitch more or less across the board. I suspect there's a subtle interaction with the inliner here.
I think
java.lang.ClassValue
is faster than current implementation.The text was updated successfully, but these errors were encountered: