Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ORC bloom filter support for DATE, TIMESTAMP and REAL #967

Merged
merged 4 commits into from Jun 12, 2019

Conversation

@dain
Copy link
Member

commented Jun 12, 2019

No description provided.

@cla-bot cla-bot bot added the cla-signed label Jun 12, 2019
@dain dain merged commit 8518be9 into prestosql:master Jun 12, 2019
2 checks passed
2 checks passed
Travis CI - Pull Request Build Passed
Details
verification/cla-signed
Details
@dain dain added this to the 315 milestone Jun 12, 2019
@dain dain referenced this pull request Jun 12, 2019
@@ -78,6 +82,7 @@
.put(77, TINYINT)
.put(901, DATE)
.put(234.567, DOUBLE)
.put((long) floatToIntBits(987.654f), REAL)

This comment has been minimized.

Copy link
@findepi

findepi Jun 12, 2019

Member
  • floatToRawIntBits
  • why do you force long even though you don't do this for eg DATE?
if (o instanceof Long) {
bloomFilter.addLong((Long) o);
if (testValue.getValue() instanceof RealType) {
bloomFilter.addDouble(intBitsToFloat(((Number) o).intValue()));

This comment has been minimized.

Copy link
@findepi

findepi Jun 12, 2019

Member

((Number) o).intValue()(Long) o (you know it's a long)

@@ -251,6 +262,7 @@ public void testExtractValuesFromSingleDomain()
.put(DATE, 901L)
.put(BIGINT, 4321L)
.put(DOUBLE, 0.123)
.put(REAL, (long) (floatToIntBits(0.456f)))

This comment has been minimized.

Copy link
@findepi

findepi Jun 12, 2019

Member

floatToRawIntBits, unnecessary braces

@@ -64,6 +66,7 @@ public void test()

testType(DATE, ImmutableList.of(new SqlDate(1), new SqlDate(5_000), new SqlDate(10_000)), 5_000L, 7_777L);

testType(REAL, ImmutableList.of(1.11f, 500_000.56f, 1_000_000.99f), (long) floatToIntBits(500_000.56f), (long) floatToIntBits(777_777.77f));

This comment has been minimized.

Copy link
@findepi

findepi Jun 12, 2019

Member

floatToRawIntBits

@dain dain deleted the dain:orc-bloom-filter-improvements branch Jun 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
4 participants
You can’t perform that action at this time.