Enhancement: Optimize Pax table insertion performance#1364
Merged
Conversation
7f0085c to
a342620
Compare
a342620 to
72d88a1
Compare
gfphoenix78
reviewed
Sep 23, 2025
688b7cf to
50ef57c
Compare
gfphoenix78
reviewed
Sep 24, 2025
gfphoenix78
reviewed
Sep 25, 2025
yjhjstz
reviewed
Sep 25, 2025
50ef57c to
254eb7b
Compare
jiaqizho
reviewed
Sep 28, 2025
gfphoenix78
reviewed
Sep 29, 2025
bc3ca05 to
d479902
Compare
jiaqizho
approved these changes
Oct 10, 2025
Contributor
jiaqizho
left a comment
There was a problem hiding this comment.
LGTM with single comment
eee39f5 to
4cc222b
Compare
1. Explicit inline functions. 2. Instead of checking the physical size of the file every time a tuple is inserted, it is checked every 16 tuples. performance result ``` create table t1(a int, b int, c int, d int, e text, f text,g text, h text) using pax with(compresstype =zstd,compresslevel=5); gpadmin=# insert into t1 select i, i+1,i+2,i+3, i::text, i::text, i::text, i::text from generate_series(1,5000000) i; INSERT 0 5000000 Time: 6124.535 ms (00:06.125) gpadmin=# insert into t1 select i, i+1,i+2,i+3, i::text, i::text, i::text, i::text from generate_series(1,5000000) i; INSERT 0 5000000 Time: 5993.682 ms (00:05.994) -- optimized with this commit create table t1(a int, b int, c int, d int, e text, f text,g text, h text) using pax with(compresstype =zstd,compresslevel=5); gpadmin=# insert into t1 select i, i+1,i+2,i+3, i::text, i::text, i::text, i::text from generate_series(1,5000000) i; INSERT 0 5000000 Time: 5713.184 ms (00:05.713) gpadmin=# insert into t1 select i, i+1,i+2,i+3, i::text, i::text, i::text, i::text from generate_series(1,5000000) i; INSERT 0 5000000 Time: 5430.221 ms (00:05.430) ```
4cc222b to
9b7abe4
Compare
my-ship-it
approved these changes
Oct 14, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
performance result
Fixes #ISSUE_Number
What does this PR do?
Type of Change
Breaking Changes
Test Plan
make installcheckmake -C src/test installcheck-cbdb-parallelImpact
Performance:
User-facing changes:
Dependencies:
Checklist
Additional Context
CI Skip Instructions