Skip to content

Add test showing that RunMemoryManager runs on skipped benchmarks - #2377

Merged
dmah42 merged 1 commit into
google:mainfrom
mhansen:skip_memory2
Nov 12, 2026
Merged

dmah42 merged 1 commit into
google:mainfrom
mhansen:skip_memory2

Conversation

@mhansen

@mhansen mhansen commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

I've split this out so it's easy to tell the fix is doing something (red/green)

Documents the current behavior in BenchmarkRunner::DoOneRepetition(): when a benchmark calls SkipWithError() before the loop, RunMemoryManager() still runs (memory_manager_ran == true) even though CreateRunReport() discards all memory results (memory_iterations == 0).

A follow-up commit fixes DoOneRepetition() to skip RunMemoryManager() and flips this assertion.

AI-assisted: this change was written with the help of an AI coding tool.

Documents the current behavior in `BenchmarkRunner::DoOneRepetition()`: when a
benchmark calls `SkipWithError()` before the loop, `RunMemoryManager()` still
runs (`memory_manager_ran == true`) even though `CreateRunReport()` discards all
memory results (`memory_iterations == 0`).

A follow-up commit fixes `DoOneRepetition()` to skip `RunMemoryManager()` and
flips this assertion.

AI-assisted: this change was written with the help of an AI coding tool.
@dmah42
dmah42 merged commit 1d58abf into google:main Nov 12, 2026
108 checks passed
@dmah42

dmah42 commented Nov 12, 2026

Copy link
Copy Markdown
Member

thanks!

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.

2 participants