By the way, in practice I have found that in many situations, the input to hash functions is nowhere near pseudo-random, e.g. this is very much true of identifiers in programs, so the best hash algorithm is often one that is specialized for the particular non-pseudo-random domain.
Of course in the case of switch statements, it is perfectly fine to have a different algorithm for each switch statement (using perfect hashing where appropriate). That's what the BCPL compiler did (these many 42 years ago :-))