quarkus
quarkus copied to clipboard
Speedup monomorphic switch type
This could hit a performance issue (see https://stackoverflow.com/questions/44988841/force-tableswitch-instead-of-lookupswitch), because the default -XX:MinJumpTableSize
is 10 and beyond it, the JIT would produce a jump table, instead of having a sort-of binary search among cases, just using a cascade of if
.
This could be alleviated in different ways, like grouping the mostly expected handler(s) type in a main switch and have another "slower path" switch for known but still usually not present handler types.
@geoand let me put it in draft, this is mostly to experiment, if you wanna give it a shot