Skip to content

ci: compile TCP benchmark targets on PRs - #595

Merged
Coldwings merged 2 commits into
mainfrom
fix/tcp-benchmark-pr-ci
Jul 11, 2026
Merged

ci: compile TCP benchmark targets on PRs#595
Coldwings merged 2 commits into
mainfrom
fix/tcp-benchmark-pr-ci

Conversation

@Coldwings

@Coldwings Coldwings commented Jul 11, 2026

Copy link
Copy Markdown
Owner

Description

Add a PR CI compile-only check for the TCP loopback benchmark targets. The new job configures ELIO_BUILD_TCP_BENCHMARKS=ON and builds bench_tcp_elio, bench_tcp_libuv, and bench_tcp_asio without running the benchmark loop.

The job uses the existing path-filter pattern and exits successfully with an explicit skip message when no TCP benchmark-affecting files changed, so intentional skips are not treated as failures. The contributor guide is updated to include the new TCP benchmark compile check in the PR validation contract.

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • Documentation (changes to documentation, comments, or examples)
  • Build/CI (changes to build system, CI configuration, or dependencies)

Related Issues

Closes #580
Related to #581

Changes Made

Core Changes

  • Added a tcp_benchmark paths-filter output for benchmark-affecting changes.
  • Added a tcp-benchmark-compile CI job that installs benchmark compile dependencies, configures a Release examples build with TLS/HTTP disabled, and builds the three TCP benchmark targets.
  • Kept non-matching changes as an explicit successful skip step instead of a job-level skipped/failed state.
  • Updated CONTRIBUTING.md so the documented PR CI contract includes TCP benchmark compile checks.

API Changes (if applicable)

None.

Migration Guide (if breaking change)

Not applicable.

Testing

Unit Tests

  • Added new tests for the changes
  • Updated existing tests if needed
  • All tests pass locally

Integration Tests

  • Tested with existing examples
  • Tested in real-world scenarios (if applicable)

Sanitizer Testing

  • Tested with ASAN (AddressSanitizer)
  • Tested with TSAN (ThreadSanitizer)
  • No new warnings or errors

Test Results

git diff --check
python3 YAML parse check for .github/workflows/ci.yml
HTTP_PROXY=http://192.168.31.164:7890 HTTPS_PROXY=http://192.168.31.164:7890 ALL_PROXY=http://192.168.31.164:7890 cmake -S . -B /tmp/elio-build-580 -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DELIO_BUILD_TESTS=OFF -DELIO_BUILD_EXAMPLES=ON -DELIO_ENABLE_TLS=OFF -DELIO_ENABLE_HTTP=OFF -DELIO_ENABLE_HTTP2=OFF -DELIO_BUILD_TCP_BENCHMARKS=ON
cmake --build /tmp/elio-build-580 --target bench_tcp_elio bench_tcp_asio --parallel 2

Local note: actionlint is not installed in this environment. Local libuv development files are also unavailable, so the local CMake configure did not generate bench_tcp_libuv; the CI job installs libuv1-dev before building all three targets.

Checklist

Code Quality

  • My code follows the project's code style
  • I have added/updated comments for complex logic
  • I have removed any debug code, TODOs, or commented-out code
  • My changes generate no new warnings

Documentation

  • I have updated documentation (wiki, README, code comments)
  • I have added examples for new features (if applicable)
  • I have updated API documentation (if applicable)

Testing

  • I have added tests that prove my fix is effective or my feature works
  • New and existing unit tests pass locally with my changes
  • I have tested with ASAN and TSAN

Compatibility

  • My changes are backward compatible (or I've documented breaking changes)
  • I have considered the impact on existing users
  • I have updated CHANGELOG.md (if applicable)

Performance (if applicable)

  • I have considered the performance impact
  • I have added benchmarks for performance-critical changes

Screenshots / Diagrams

Not applicable.

Additional Notes

This intentionally compiles the TCP benchmark targets on PRs but does not run the loopback benchmark. Runtime benchmark execution remains in the dedicated TCP Loopback Benchmark workflow.

Reviewer Guidance

Areas requiring special attention:

  • Path-filter coverage for files that can break TCP benchmark compilation.
  • The successful skip behavior for unrelated non-code/doc-only changes.
  • The dependency set for building libuv and standalone Asio benchmark targets.

Questions for reviewers:

  • Should any additional files be included in the tcp_benchmark path filter?

Copilot AI review requested due to automatic review settings July 11, 2026 12:57

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@Coldwings

Copy link
Copy Markdown
Owner Author

@copilot please re-review only; do not make direct code modifications.

@Coldwings
Coldwings merged commit 1a1276e into main Jul 11, 2026
11 checks passed
@Coldwings
Coldwings deleted the fix/tcp-benchmark-pr-ci branch July 11, 2026 13:18
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.

[CI] Pull request CI does not compile TCP benchmark targets

2 participants