File tree Expand file tree Collapse file tree
strided/special/drsqrt/benchmark/c Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -731,7 +731,6 @@ A total of 95 issues were closed in this release:
731731
732732<details>
733733
734- - [`5029670`](https://github.com/stdlib-js/stdlib/commit/5029670736574df60258c5519cf1f6670b50806e) - **bench:** refactor to use dynamic memory allocation in `math/strided/special/drsqrt` [(#11665)](https://github.com/stdlib-js/stdlib/pull/11665) _(by Uday Kakade)_
735734- [`0359230`](https://github.com/stdlib-js/stdlib/commit/0359230c32ad65ec22d76e3c6fb5679c9dd88255) - **bench:** refactor to use dynamic memory allocation in `math/strided/special/dinv` [(#11666)](https://github.com/stdlib-js/stdlib/pull/11666) _(by Uday Kakade)_
736735- [`4948ecc`](https://github.com/stdlib-js/stdlib/commit/4948ecca63ca031e99f94d72def40f445852e4db) - **bench:** refactor to use dynamic memory allocation in `math/strided/special/dsqrt` [(#11668)](https://github.com/stdlib-js/stdlib/pull/11668) _(by Uday Kakade)_
737736- [`2cd5062`](https://github.com/stdlib-js/stdlib/commit/2cd5062361403748ac15fd295708f925d4c3c92f) - **bench:** refactor to use dynamic memory allocation in `math/strided/special/dtrunc` [(#11669)](https://github.com/stdlib-js/stdlib/pull/11669) _(by Uday Kakade)_
Original file line number Diff line number Diff line change @@ -114,13 +114,11 @@ float rand_uniformf( float a, float b ) {
114114*/
115115static double benchmark ( int iterations , int len ) {
116116 double elapsed ;
117- double * x ;
118- double * y ;
117+ double x [ len ] ;
118+ double y [ len ] ;
119119 double t ;
120120 int i ;
121121
122- x = (double * ) malloc ( len * sizeof ( double ) );
123- y = (double * ) malloc ( len * sizeof ( double ) );
124122 for ( i = 0 ; i < len ; i ++ ) {
125123 x [ i ] = rand_uniform ( 0.0 , 200.0 );
126124 y [ i ] = 0.0 ;
@@ -137,8 +135,6 @@ static double benchmark( int iterations, int len ) {
137135 if ( y [ 0 ] != y [ 0 ] ) {
138136 printf ( "should not return NaN\n" );
139137 }
140- free ( x );
141- free ( y );
142138 return elapsed ;
143139}
144140
You can’t perform that action at this time.
0 commit comments