Skip to content

test: add build log memory benchmarks - #27

Merged
fcying merged 1 commit into
mainfrom
dev
Aug 11, 2026
Merged

test: add build log memory benchmarks#27
fcying merged 1 commit into
mainfrom
dev

Conversation

@fcying

@fcying fcying commented Aug 11, 2026

Copy link
Copy Markdown
Owner

No description provided.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5bc83196b2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread internal/build_log_benchmark_test.go Outdated
if tool.StatusCode != 0 {
b.Fatalf("parser status: %d", tool.StatusCode)
}
runtime.KeepAlive(stdout)

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Release the discovery buffer before parsing

When this benchmark is used to characterize Make-discovery peak memory, runtime.KeepAlive(stdout) forces the entire 10–500 MiB backing buffer to remain reachable throughout tool.Parse. The production runDiscoveryMake path stops using stdoutBuf after scanBuildLog, and bufio.Scanner.Text copies each token, so the buffer can be collected during parsing; retaining it here inflates the reported RSS and can mask memory improvements. Remove this keepalive or otherwise match the production object's lifetime.

Useful? React with 👍 / 👎.

Comment thread README.md Outdated
@fcying
fcying merged commit 6c1c155 into main Aug 11, 2026
12 checks passed
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