Skip to content

Commit 4bf83f8

Browse files
committed
fix mod position
1 parent 3b9e364 commit 4bf83f8

File tree

4 files changed

+5
-21
lines changed

4 files changed

+5
-21
lines changed

.github/workflows/benchmark.yml

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,6 @@ jobs:
3333
env:
3434
BACKEND: /home/runner/.bb/bb
3535

36-
- name: Compare gates reports
37-
id: gates_diff
38-
uses: noir-lang/noir-gates-diff@dbe920a8dcc3370af4be4f702ca9cef29317bec1
39-
with:
40-
report: gates_report.json
41-
summaryQuantile: 0.9 # only display the 10% most significant circuit size diffs in the summary (defaults to 20%)
42-
4336
- name: Store ACIR opcode benchmark result
4437
uses: benchmark-action/github-action-benchmark@v1
4538
with:
@@ -91,16 +84,6 @@ jobs:
9184
- name: Generate brillig report
9285
run: ./scripts/build-brillig-report.sh
9386

94-
- name: Compare brillig reports
95-
id: brillig_bytecode_diff
96-
uses: noir-lang/noir-gates-diff@dbe920a8dcc3370af4be4f702ca9cef29317bec1
97-
with:
98-
report: brillig_report.json
99-
header: |
100-
# Changes to Brillig bytecode sizes
101-
brillig_report: true
102-
summaryQuantile: 0.9 # only display the 10% most significant circuit size diffs in the summary (defaults to 20%)
103-
10487
- name: Store brillig benchmark result
10588
uses: benchmark-action/github-action-benchmark@v1
10689
with:

scripts/build-gates-report.sh

100644100755
File mode changed.

src/benchmarks/bigcurve_benchmarks.nr

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ comptime fn make_bench(m: Module, params: Quoted) -> Quoted {
55
let add_bench_name = f"add_{module_name}".quoted_contents();
66
let sub_bench_name = f"sub_{module_name}".quoted_contents();
77
let one_bench_name = f"one_{module_name}".quoted_contents();
8+
let mul_bench_name = f"mul_{module_name}".quoted_contents();
89
let BigCurve = quote { crate::BigCurve };
910

1011
let from_field_bench_name = f"from_field_{module_name}".quoted_contents();
@@ -13,17 +14,17 @@ comptime fn make_bench(m: Module, params: Quoted) -> Quoted {
1314
quote {
1415
#[export]
1516
fn $add_bench_name(a: $typ, b: $typ) -> $typ {
16-
a.add(b)
17+
a + b
1718
}
1819

1920
#[export]
2021
fn $sub_bench_name(a: $typ, b: $typ) -> $typ {
21-
a.sub(b)
22+
a-b
2223
}
2324

2425
#[export]
2526
fn $one_bench_name() -> $typ {
26-
$typ::one()
27+
$BigCurve::one()
2728
}
2829

2930
}

src/lib.nr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ pub(crate) mod curve_jac;
33
mod test_data;
44
mod bigcurve_test;
55
pub mod scalar_field;
6-
mod benchmarks;
76
pub(crate) mod utils;
87
pub(crate) mod curves;
98

@@ -13,6 +12,7 @@ use bignum::bignum::evaluate_quadratic_expression;
1312
use crate::curve_jac::AffineTranscript;
1413
use crate::scalar_field::ScalarField;
1514
use std::ops::{Add, Neg, Sub};
15+
mod benchmarks;
1616

1717
/// Implements an elliptic curve over a prime field that is not the circuit's native field.
1818

0 commit comments

Comments
 (0)