Tweek the sizing rules as well as optimise the hashing algo so it creates a more even distribution (for at least one set of test cases)

This commit is contained in:
Peter Lawrey
2014-10-23 21:20:46 +01:00
parent 113c51566a
commit 9a8a2512f0
8 changed files with 210 additions and 29 deletions
@@ -63,8 +63,12 @@ enum DirectLongValueFactory implements ObjectFactory<LongValue> {
INSTANCE;
@Override
public LongValue create() throws Exception {
return (LongValue) NativeBytes.UNSAFE.allocateInstance(ByteableLongValueMarshaller.DIRECT);
public LongValue create() {
try {
return (LongValue) NativeBytes.UNSAFE.allocateInstance(ByteableLongValueMarshaller.DIRECT);
} catch (InstantiationException e) {
throw new AssertionError(e);
}
}
}