Tcmalloc fixes - #5407
Open
graydon wants to merge 2 commits into
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds configurable tcmalloc support, repairs Tracy memory-tracking configuration, and introduces heap measurements for Soroban module-cache compilation.
Changes:
- Adds
--disable-tcmallocand Tracy memory-tracking build flags. - Reports WASM and heap-byte metrics during module-cache rebuilds.
- Documents Tracy and Heaptrack profiling workflows.
Reviewed changes
Copilot reviewed 15 out of 15 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
configure.ac |
Adds allocator configuration and compatibility checks. |
common.mk |
Defines Tracy memory-tracking flags. |
src/util/TcmallocConfig.h |
Declares heap-usage query API. |
src/util/TcmallocConfig.cpp |
Queries tcmalloc heap usage. |
src/ledger/SharedModuleCacheCompiler.h |
Tracks compilation heap measurements. |
src/ledger/SharedModuleCacheCompiler.cpp |
Samples and logs heap changes. |
src/ledger/SorobanMetrics.h |
Declares renamed and new metrics. |
src/ledger/SorobanMetrics.cpp |
Registers module-cache byte metrics. |
src/ledger/LedgerManagerImpl.cpp |
Publishes rebuild measurements. |
src/transactions/test/InvokeHostFunctionTests.cpp |
Updates renamed metric references. |
docs/metrics.md |
Documents metric changes. |
performance-eval/performance-eval.md |
Adds memory-profiling guidance. |
INSTALL.md |
Moves Windows Tracy instructions. |
Builds/VisualStudio/stellar-core.vcxproj |
Adds new utility sources. |
Builds/VisualStudio/stellar-core.vcxproj.filters |
Categorizes new utility sources. |
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.
This improves our ability to do memory profiling .. a bit:
--disable-tcmallocso that you can use memory profilers that hook malloc like heaptrack--enable-tracy-memory-trackingwhich was broken