Skip to content

Conversation

@jnie-TT
Copy link
Contributor

@jnie-TT jnie-TT commented Nov 26, 2025

Problem description

Currently the only memory debug logs are on the program level #5967, we want to support more comprehensive logging.

What's changed

Added MemoryLogLevel bit flag that describes the memory logging level, and runtime API setMemoryLogLevel to configure the logging level. Currently there are 2 levels:

  • Program: This will log at the beginning and end of program execution. Useful for debugging memory footprint across program runs.
  • Operation: This will log at the beginning of each operation within the program. Useful for debugging memory footprint within a program run, e.g. OOM errors.

Checklist

  • New/Existing tests provide coverage for changes

@codecov-commenter
Copy link

Codecov Report

❌ Patch coverage is 0% with 9 lines in your changes missing coverage. Please review.
✅ Project coverage is 69.38%. Comparing base (da89b93) to head (534d2f5).
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
runtime/python/runtime/runtime.cpp 0.00% 7 Missing ⚠️
runtime/lib/runtime.cpp 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6037      +/-   ##
==========================================
+ Coverage   69.34%   69.38%   +0.03%     
==========================================
  Files         334      333       -1     
  Lines       51001    50990      -11     
==========================================
+ Hits        35369    35378       +9     
+ Misses      15632    15612      -20     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

this->stride = stride.value_or(utils::calculateStride(shape));
this->physicalVolume = physicalVolume.value_or(volume());
}
const std::optional<uint64_t> physicalVolume = {});
Copy link
Contributor

Choose a reason for hiding this comment

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

Just curious, what is the deal with the TensorDesc changes here and in other file?

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.

4 participants