Package io.trino.operator.join
Class DefaultPagesHash
java.lang.Object
io.trino.operator.join.DefaultPagesHash
- All Implemented Interfaces:
PagesHash
The PagesHash object that handles all cases - single/multi channel joins
with any types.
This implementation assumes arrays used in the hash are always a power of 2
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultPagesHash(it.unimi.dsi.fastutil.longs.LongArrayList addresses, PagesHashStrategy pagesHashStrategy, PositionLinks.FactoryBuilder positionLinks, HashArraySizeSupplier hashArraySizeSupplier) -
Method Summary
Modifier and TypeMethodDescriptionvoidappendTo(long position, PageBuilder pageBuilder, int outputChannelOffset) int[]getAddressIndex(int[] positions, Page hashChannelsPage) int[]getAddressIndex(int[] positions, Page hashChannelsPage, long[] rawHashes) intgetAddressIndex(int position, Page hashChannelsPage) intgetAddressIndex(int rightPosition, Page hashChannelsPage, long rawHash) static longgetEstimatedRetainedSizeInBytes(int positionCount, HashArraySizeSupplier hashArraySizeSupplier, it.unimi.dsi.fastutil.longs.LongArrayList addresses, List<it.unimi.dsi.fastutil.objects.ObjectArrayList<Block>> channels, long blocksSizeInBytes) longint
-
Constructor Details
-
DefaultPagesHash
public DefaultPagesHash(it.unimi.dsi.fastutil.longs.LongArrayList addresses, PagesHashStrategy pagesHashStrategy, PositionLinks.FactoryBuilder positionLinks, HashArraySizeSupplier hashArraySizeSupplier)
-
-
Method Details
-
getPositionCount
public int getPositionCount()- Specified by:
getPositionCountin interfacePagesHash
-
getInMemorySizeInBytes
public long getInMemorySizeInBytes()- Specified by:
getInMemorySizeInBytesin interfacePagesHash
-
getAddressIndex
- Specified by:
getAddressIndexin interfacePagesHash
-
getAddressIndex
- Specified by:
getAddressIndexin interfacePagesHash
-
getAddressIndex
- Specified by:
getAddressIndexin interfacePagesHash
-
getAddressIndex
- Specified by:
getAddressIndexin interfacePagesHash
-
appendTo
-
getEstimatedRetainedSizeInBytes
public static long getEstimatedRetainedSizeInBytes(int positionCount, HashArraySizeSupplier hashArraySizeSupplier, it.unimi.dsi.fastutil.longs.LongArrayList addresses, List<it.unimi.dsi.fastutil.objects.ObjectArrayList<Block>> channels, long blocksSizeInBytes)
-