Skip to content

GH-45358: [C++][Python] Add MemoryPool method to print statistics - #45359

Merged
pitrou merged 2 commits into
apache:mainfrom
pitrou:memory_pool_print_stats
Jan 27, 2025
Merged

pitrou merged 2 commits into
apache:mainfrom
pitrou:memory_pool_print_stats

Conversation

@pitrou

@pitrou pitrou commented Jan 27, 2025 •

Copy link
Copy Markdown
Member

Rationale for this change

Add a MemoryPool method to print allocator-specific statistics to stderr, to help diagnose perceived memory consumption issues.

Also add missing Python bindings for MemoryPool::total_bytes_allocated and MemoryPool::num_allocations.

Are these changes tested?

Yes.

Are there any user-facing changes?

No.

@github-actions

Copy link
Copy Markdown

⚠️ GitHub issue #45358 has been automatically assigned in GitHub to PR creator.

@raulcd raulcd left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks @pitrou ! This is really useful.
I've tested locally with a couple of memory allocators

@pitrou

pitrou commented Jan 27, 2025

Copy link
Copy Markdown
Member Author

Thank you, will merge

@pitrou
pitrou merged commit ac1e7ec into apache:main Jan 27, 2025
@pitrou
pitrou deleted the memory_pool_print_stats branch January 27, 2025 14:11
@conbench-apache-arrow

Copy link
Copy Markdown

After merging your PR, Conbench analyzed the 4 benchmarking runs that have been run so far on merge-commit ac1e7ec.

There were no benchmark performance regressions. 🎉

The full Conbench report has more details. It also includes information about 14 possible false positives for unstable benchmarks that are known to sometimes produce them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants