Skip to content

test(test-benchmark): add bn128_add precompile special case benchmarks#2811

Merged
LouisTsai-Csie merged 2 commits intoethereum:forks/amsterdamfrom
GottfriedHerold:ECTestCases
May 7, 2026
Merged

test(test-benchmark): add bn128_add precompile special case benchmarks#2811
LouisTsai-Csie merged 2 commits intoethereum:forks/amsterdamfrom
GottfriedHerold:ECTestCases

Conversation

@GottfriedHerold
Copy link
Copy Markdown
Contributor

🗒️ Description

This adds 2 new benchmark tests regarding the ecAdd precompile. Notably,
we include test cases for the special cases where we

  • double a point
  • add the negative of a point to itself
    These cases are highly likely to require different code paths in most implementations, to we should benchmark them separately.

…ase where the second point is the negative of the first.

(so the result is the point at infinity)
@codecov
Copy link
Copy Markdown

codecov Bot commented May 6, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 88.62%. Comparing base (1f41b21) to head (96fec8f).
⚠️ Report is 3 commits behind head on forks/amsterdam.

Additional details and impacted files
@@                 Coverage Diff                 @@
##           forks/amsterdam    #2811      +/-   ##
===================================================
+ Coverage            88.17%   88.62%   +0.45%     
===================================================
  Files                  577      577              
  Lines                35659    35659              
  Branches              3490     3490              
===================================================
+ Hits                 31442    31604     +162     
+ Misses                3654     3492     -162     
  Partials               563      563              
Flag Coverage Δ
unittests 88.62% <ø> (+0.45%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Copy Markdown
Collaborator

@LouisTsai-Csie LouisTsai-Csie left a comment

Choose a reason for hiding this comment

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

LGTM, thank you for the new cases

@LouisTsai-Csie LouisTsai-Csie changed the title test: Add benchmark tests for bn128_add precompile special cases feat(test-benchmark): add bn128_add precompile special case benchmarks May 7, 2026
@LouisTsai-Csie LouisTsai-Csie added A-test-benchmark Area: execution_testing.benchmark and tests/benchmark C-test Category: test labels May 7, 2026
@LouisTsai-Csie LouisTsai-Csie changed the title feat(test-benchmark): add bn128_add precompile special case benchmarks test(test-benchmark): add bn128_add precompile special case benchmarks May 7, 2026
@LouisTsai-Csie LouisTsai-Csie merged commit 1292bce into ethereum:forks/amsterdam May 7, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-test-benchmark Area: execution_testing.benchmark and tests/benchmark C-test Category: test

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants