Skip to content

Commit b0cc290

Browse files
committed
bench: change variable naming
--- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: na - task: lint_package_json status: na - task: lint_repl_help status: na - task: lint_javascript_src status: na - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: passed - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: na - task: lint_typescript_tests status: na - task: lint_license_headers status: passed ---
1 parent 0c56b1b commit b0cc290

File tree

2 files changed

+22
-22
lines changed

2 files changed

+22
-22
lines changed

lib/node_modules/@stdlib/blas/base/zdotu/benchmark/benchmark.js

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -42,15 +42,15 @@ var options = {
4242
* Creates a benchmark function.
4343
*
4444
* @private
45-
* @param {PositiveInteger} len - array length
45+
* @param {PositiveInteger} N - array length
4646
* @returns {Function} benchmark function
4747
*/
48-
function createBenchmark( len ) {
49-
var zx;
50-
var zy;
48+
function createBenchmark( N ) {
49+
var x;
50+
var y;
5151

52-
zx = new Complex128Array( uniform( len*2, -100.0, 100.0, options ) );
53-
zy = new Complex128Array( uniform( len*2, -100.0, 100.0, options ) );
52+
x = new Complex128Array( uniform( N*2, -100.0, 100.0, options ) );
53+
y = new Complex128Array( uniform( N*2, -100.0, 100.0, options ) );
5454
return benchmark;
5555

5656
/**
@@ -65,7 +65,7 @@ function createBenchmark( len ) {
6565

6666
b.tic();
6767
for ( i = 0; i < b.iterations; i++ ) {
68-
d = zdotu( zx.length, zx, 1, zy, 1 );
68+
d = zdotu( x.length, x, 1, y, 1 );
6969
if ( isnan( d ) ) {
7070
b.fail( 'should not return NaN' );
7171
}
@@ -88,19 +88,19 @@ function createBenchmark( len ) {
8888
* @private
8989
*/
9090
function main() {
91-
var len;
9291
var min;
9392
var max;
93+
var N;
9494
var f;
9595
var i;
9696

9797
min = 1; // 10^min
9898
max = 5; // 10^max
9999

100100
for ( i = min; i <= max; i++ ) {
101-
len = pow( 10, i );
102-
f = createBenchmark( len );
103-
bench( pkg+':len='+len, f );
101+
N = pow( 10, i );
102+
f = createBenchmark( N );
103+
bench( pkg+':size='+N, f );
104104
}
105105
}
106106

lib/node_modules/@stdlib/blas/base/zdotu/benchmark/benchmark.ndarray.js

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -42,15 +42,15 @@ var options = {
4242
* Creates a benchmark function.
4343
*
4444
* @private
45-
* @param {PositiveInteger} len - array length
45+
* @param {PositiveInteger} N - array length
4646
* @returns {Function} benchmark function
4747
*/
48-
function createBenchmark( len ) {
49-
var zx;
50-
var zy;
48+
function createBenchmark( N ) {
49+
var x;
50+
var y;
5151

52-
zx = new Complex128Array( uniform( len*2, -100.0, 100.0, options ) );
53-
zy = new Complex128Array( uniform( len*2, -100.0, 100.0, options ) );
52+
x = new Complex128Array( uniform( N*2, -100.0, 100.0, options ) );
53+
y = new Complex128Array( uniform( N*2, -100.0, 100.0, options ) );
5454
return benchmark;
5555

5656
/**
@@ -65,7 +65,7 @@ function createBenchmark( len ) {
6565

6666
b.tic();
6767
for ( i = 0; i < b.iterations; i++ ) {
68-
d = zdotu( zx.length, zx, 1, 0, zy, 1, 0 );
68+
d = zdotu( x.length, x, 1, 0, y, 1, 0 );
6969
if ( isnan( d ) ) {
7070
b.fail( 'should not return NaN' );
7171
}
@@ -88,19 +88,19 @@ function createBenchmark( len ) {
8888
* @private
8989
*/
9090
function main() {
91-
var len;
9291
var min;
9392
var max;
93+
var N;
9494
var f;
9595
var i;
9696

9797
min = 1; // 10^min
9898
max = 5; // 10^max
9999

100100
for ( i = min; i <= max; i++ ) {
101-
len = pow( 10, i );
102-
f = createBenchmark( len );
103-
bench( pkg+':ndarray:len='+len, f );
101+
N = pow( 10, i );
102+
f = createBenchmark( N );
103+
bench( pkg+':ndarray:size='+N, f );
104104
}
105105
}
106106

0 commit comments

Comments
 (0)