IP Library › Granted Patent US 11,868,348
Granted Patent B2
US 11,868,348 · App. 17/018,694 · Granted Jan 9, 2024

Hardware friendly key value table design to support relational hash join

Inventors: Shasank Kisan Chavan (Menlo Park, CA); James Kearney (Cambridge, MA); Weiwei Gong (Belmont, CA)
Assignee: Oracle International Corporation
G06F16/24537G06F16/2255
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,868,348
App. No.
17/018,694
Granted
Jan 9, 2024
Kind
B2
Abstract

The present invention relates to join acceleration. In an embodiment, a computer receives a request for a relational join of build data rows with probe data rows. Based on the request for the relational join, a particular kind of data map from many kinds of data map that can implement the relational join is dynamically selected. Based on the build data rows, an instance of the particular kind of data map is populated. A response is sent for the request for the relational join that is based on the probe data rows and the instance of the particular kind of data map.

Claims (63)

1. A method comprising:

receiving a request for a relational join of a build plurality of data rows with a probe plurality of data rows;

selecting, based on the request for the relational join, a particular kind of data map from a plurality of kinds of data map that can be used for said relational join of said build plurality of data rows with said probe plurality of data rows, wherein:

the plurality of kinds of data map includes a first kind of data map and a second kind of data map,

the first kind of data map does not store a build key,

the first kind of data map stores values that have a first size,

the second kind of data map stores values that have a second size that is not the first size;

populating, based on the build plurality of data rows, the particular kind of data map; and

sending a response to the request for the relational join that is based on the probe plurality of data rows and the particular kind of data map;

wherein the method is performed by one or more computers.

2. The method of claim 1 wherein said selecting the particular kind of data map does not entail join selectivity nor cardinality of the build plurality of data rows.

3. The method of claim 1 wherein the plurality of kinds of data map includes at least three kinds of hash table.

4. The method of claim 1 further comprising configuring the particular kind of data map for a size of a non-key value of the build plurality of data rows.

5. The method of claim 4 wherein said configuring the particular kind of data map comprises selecting from a plurality of at least three non-key value sizes.

6. The method of claim 4 wherein:

the particular kind of data map is a hash table;

said configuring the particular kind of data map does not affect a bucket size of the hash table.

7. The method of claim 1 wherein:

the particular kind of data map is a hash table that contains a bucket that contains a segmented array that contains a full segment;

the method further comprises the full segment overflowing into a spare segment that is identified based on at least one selected from the group consisting of: a memory address of the spare segment and a position of the spare segment within a pool of segments.

8. The method of claim 1 wherein:

the particular kind of data map is a hash table that contains a plurality of buckets;

each bucket of the plurality of buckets is configured according to at least one selected from the group consisting of:

the bucket and a respective hardware cache line of a first plurality of hardware cache lines have a same memory address alignment, and

the bucket has a first size that is not greater than a second size of a respective hardware cache line of a second plurality of hardware cache lines.

9. The method of claim 1 wherein:

the first kind of data map is a hash table that contains a plurality of buckets;

the first kind of data map is configured for the plurality of buckets to store hash codes of the build key.

10. The method of claim 1 wherein:

the particular kind of data map is a hash table that contains a plurality of buckets;

executing the relational join comprises applying a SIMD instruction to a bucket of the plurality of buckets.

11. The method of claim 1 wherein:

the particular kind of data map accepts an encoding dictionary code as a lookup key;

executing the relational join does not entail dictionary decoding.

12. One or more non-transitory computer-readable media storing instructions that, when executed by one or more processors, cause:

receiving a request for a relational join of a build plurality of data rows with a probe plurality of data rows;

selecting, based on the request for the relational join, a particular kind of data map from a plurality of kinds of data map that can be used for said relational join of said build plurality of data rows with said probe plurality of data rows, wherein:

the plurality of kinds of data map includes a first kind of data map and a second kind of data map,

the first kind of data map does not store a build key,

the first kind of data map stores values that have a first size,

the second kind of data map stores values that have a second size that is not the first size;

populating, based on the build plurality of data rows, the particular kind of data map; and

sending a response to the request for the relational join that is based on the probe plurality of data rows and the particular kind of data map.

13. The one or more non-transitory computer-readable media of claim 12 wherein said selecting the particular kind of data map does not entail join selectivity nor cardinality of the build plurality of data rows.

14. The one or more non-transitory computer-readable media of claim 12 wherein the plurality of kinds of data map includes at least three kinds of hash table.

15. The one or more non-transitory computer-readable media of claim 12 wherein the instructions further cause configuring the particular kind of data map for a size of a non-key value of the build plurality of data rows.

16. The one or more non-transitory computer-readable media of claim 12 wherein:

the particular kind of data map is a hash table that contains a bucket that contains a segmented array that contains a full segment;

the instructions further cause the full segment overflowing into a spare segment that is identified based on at least one selected from the group consisting of: a memory address of the spare segment and a position of the spare segment within a pool of segments.

17. The one or more non-transitory computer-readable media of claim 12 wherein:

the particular kind of data map is a hash table that contains a plurality of buckets;

each bucket of the plurality of buckets is configured according to at least one selected from the group consisting of:

the bucket and a respective hardware cache line of a first plurality of hardware cache lines have a same memory address alignment, and

the bucket has a first size that is not greater than a second size of a respective hardware cache line of a second plurality of hardware cache lines.

18. The one or more non-transitory computer-readable media of claim 12 wherein:

the particular kind of data map is a hash table that contains a plurality of buckets;

the particular kind of data map is configured for the plurality of buckets to store hash codes of the build key.

19. The one or more non-transitory computer-readable media of claim 12 wherein:

the particular kind of data map is a hash table that contains a plurality of buckets;

executing the relational join comprises applying a SIMD instruction to a bucket of the plurality of buckets.

20. The one or more non-transitory computer-readable media of claim 12 wherein:

the particular kind of data map accepts an encoding dictionary code as a lookup key;

executing the relational join does not entail dictionary decoding.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Sep 11, 2020
From: CHAVAN, SHASANK KISAN; KEARNEY, JAMES; GONG, WEIWEI
To: ORACLE INTERNATIONAL CORPORATION
Reel/Frame 053750/0619 →
Continuity (4)
Provisional Application 62899587 · Sep 12, 2019
Provisional Application 62899589 · Sep 12, 2019
Provisional Application 62899603 · Sep 12, 2019
Related Publication 20210081417A1 · Mar 18, 2021
Cited By (1)
US 12,566,716