in reply to Hash space/ time tradeoff

Could there be a significant performance improvement by maintaining a second hash of just 'attr1' to pre-determine if any keys start with attr1?

No!

The time saved hashing a slightly shorter key for the first lookup will be completely negated by the need to do a second lookup if the first hits.

And using 3 keys will be significantly slower.

Moreover, multilevel hashes require considerably more memory (and memory management).


With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.