It's actually quite interesting:
http://stackoverflow.com/questions/10287700/difference-between-jvma-lookupswitch-and-tableswitch

(Not that I knew it before:-)
On 28 Jan 2014 17:37, "Christoph Engelbert" <notifications@github.com>
wrote:

> In
> hazelcast/src/main/java/com/hazelcast/concurrent/semaphore/SemaphoreDataSerializerHook.java:
>
> > @@ -31,6 +48,91 @@ public int getFactoryId() {
> >
> >      @Override
> >      public DataSerializableFactory createFactory() {
> > -        return null;
> > +        ConstructorFunction<Integer, IdentifiedDataSerializable> constructors[] = new ConstructorFunction[LEN];
>
> I think Mehmet is right since it is a table lookup + goto and I'm not sure
> if lookup time is constant. If so then HotSpot applied automatic reordering
> of cases wouldn't make sense ;)
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/hazelcast/hazelcast/pull/1641/files#r9235994>
> .
>