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

Reduce memory usage for scratch buffer #403

Merged
merged 9 commits into from
Dec 13, 2024
Merged

Conversation

Binyang2014
Copy link
Contributor

In the executor, we allocate the scratch buffer based on sendMemRange. However, for certain execution plans, this allocation may be unsuitable, as the plan does not support messages of this size.

To avoid allocating to much data and cause OOM error, set scratch buffer size to min(scratchBufferSize(maxMessageSizeSupportedForPlan), scratchBufferSize(sendMemRange))

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request.

Files not reviewed (3)
  • src/executor/execution_plan.cc: Language not supported
  • src/executor/executor.cc: Language not supported
  • src/include/execution_plan.hpp: Language not supported
Copy link
Contributor

@caiomcbr caiomcbr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@caiomcbr caiomcbr self-requested a review December 11, 2024 21:36
Copy link
Contributor

@caiomcbr caiomcbr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Binyang2014 Binyang2014 merged commit ee75caf into main Dec 13, 2024
23 checks passed
@Binyang2014 Binyang2014 deleted the binyli/memory_reduce branch December 13, 2024 21:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants