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

Improve debug mode output: print MemUsed and MemTotal for each node, disable proc/self/statm #161

Merged
merged 8 commits into from
Dec 19, 2023

Conversation

vasdommes
Copy link
Collaborator

@vasdommes vasdommes commented Dec 19, 2023

Output from Timers when debug = true:

  1. Print MemUsed, GB for the first rank of each node at each timer start, see Print MemUsed for each node (debug mode) #158.
  2. Add separator --- between timer name and MemUsed for better readability
  3. Print peak RAM usage for each node (debug mode) #162
  4. Print MemTotal, GB when adding a first timer (it is constant, so we need to print in only once).
  5. Do not print proc/self/statm. Previously, we printed each for each timer for each rank. As a result, SDPB output became too verbose and hard to read. I found that I never used statm in practice - MemUsed per node is enough for tracking progress and RAM usage.

…mTotal at start, don't print proc/self/statm

Printing proc/self/statm for each rank is too verbose, and the results are hard to read.
In practice, I found that I need only MemUsed (for each node) to track progress and RAM usage.
proc/self/statm can be needed in very special cases - for such cases one can always create a separate branch and enable it manually.
@vasdommes vasdommes added this to the 2.6.1 milestone Dec 19, 2023
… mode).

Previously, we got tons of lines like
0 sdpb.solve.run.iter_1.computePrimalResidues cannot parse /proc/meminfo
Example:
0 sdpb.solve.run.iter_1.step.initializeSchurComplementSolver.Cholesky_Q --- MemUsed: 5.69753 GB
0 sdpb.solve.run.iter_1.step.frobenius_product_symmetric --- MemUsed: 5.69753 GB
0 sdpb.solve.run.iter_1.step.computeSearchDirection(betaPredictor) --- MemUsed: 5.69753 GB
0 sdpb.solve.run.iter_1.step.computeSearchDirection(betaCorrector) --- MemUsed: 5.69753 GB
Thus we don't need to call print_max_mem_used() manually each time
Fixes #162 Print peak RAM usage for each node (debug mode)
@vasdommes vasdommes merged commit c18297a into master Dec 19, 2023
2 checks passed
@vasdommes vasdommes deleted the print-memory-usage branch December 19, 2023 18:22
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.

1 participant