Skip to content

Log getMemoryLoad()#63

Draft
Sjors wants to merge 5 commits intostratum-mining:masterfrom
Sjors:2025/11/memory
Draft

Log getMemoryLoad()#63
Sjors wants to merge 5 commits intostratum-mining:masterfrom
Sjors:2025/11/memory

Conversation

@Sjors
Copy link
Copy Markdown
Collaborator

@Sjors Sjors commented Nov 24, 2025

Poll getMemoryLoad() (introduced by bitcoin/bitcoin#33922) once a minute and log the result.

Skipped for older node versions that don't have this method.

@Sjors
Copy link
Copy Markdown
Collaborator Author

Sjors commented Nov 24, 2025

I'm running this locally for a while, logging once every 10 seconds instead of every minute.

Testing against a mainnet node with the default 300 MiB -maxmempool, polling it aggressively from the TP with -sv2interval=1 -sv2feedelta=1. It may take a while to get interesting results because its mempool started empty.

@Sjors
Copy link
Copy Markdown
Collaborator Author

Sjors commented Nov 24, 2025

Rebased after #64 and #66.

@Sjors
Copy link
Copy Markdown
Collaborator Author

Sjors commented Nov 24, 2025

The second commit generates plots like this:

getmemoryload-scatter

I'll leave it running for a bit longer.

@Sjors Sjors force-pushed the 2025/11/memory branch 6 times, most recently from ff88c5c to e685264 Compare November 25, 2025 11:59
@Sjors Sjors force-pushed the 2025/11/memory branch 3 times, most recently from b2928b0 to 1a280b1 Compare December 3, 2025 14:01
@Sjors Sjors force-pushed the 2025/11/memory branch 2 times, most recently from 02fb959 to daf32c7 Compare April 15, 2026 21:43
@Sjors Sjors force-pushed the 2025/11/memory branch 2 times, most recently from 766d611 to f4b245f Compare April 15, 2026 22:22
@Sjors
Copy link
Copy Markdown
Collaborator Author

Sjors commented Apr 15, 2026

Couple of pushes today. I rebased past the v31 changes from #65 and added an integration test, which required #91.

Sjors added 5 commits April 17, 2026 08:12
Assisted-by: OpenAI GPT-5-Codex
Add Python script to make plots.

Assisted-by: GitHub Copilot
Assisted-by: OpenAI GPT-5.1-Codex
Add template provider unit test coverage for the periodic memory
footprint log entry. The mock mining interface now exposes a configurable
MemoryLoad value so the test can exercise the IPC-backed getMemoryLoad()
path and assert the formatted MiB value.

Assisted-by: OpenAI GPT-5-Codex
Shorten the template provider memory reporting interval only in the SRI
configuration, then assert that the scenario observes the memory footprint
log entry without adding a separate wait loop.

Assisted-by: OpenAI GPT-5-Codex
Build Bitcoin Core from the bitcoin/bitcoin#33922 branch for the SRI
integration test so the node IPC interface matches the getMemoryLoad()
coverage added in this branch.

Assisted-by: OpenAI GPT-5-Codex
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.

1 participant