Skip to content

Commit 00a2948

Browse files
authored
bench: replace pow with powf
PR-URL: #13825 Reviewed-by: Athan Reines <kgryte@gmail.com>
1 parent c76524b commit 00a2948

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

  • lib/node_modules/@stdlib/math/base/special/fibonaccif/benchmark

‎lib/node_modules/@stdlib/math/base/special/fibonaccif/benchmark/benchmark.js‎

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,11 @@
2323
var bench = require( '@stdlib/bench' );
2424
var Int32Array = require( '@stdlib/array/int32' );
2525
var discreteUniform = require( '@stdlib/random/array/discrete-uniform' );
26+
var powf = require( '@stdlib/math/base/special/powf' );
2627
var roundf = require( '@stdlib/math/base/special/roundf' );
2728
var sqrtf = require( '@stdlib/math/base/special/sqrtf' );
28-
var pow = require( '@stdlib/math/base/special/pow' );
2929
var isnanf = require( '@stdlib/math/base/assert/is-nanf' );
3030
var PHI = require( '@stdlib/constants/float32/phi' );
31-
var float64ToFloat32 = require( '@stdlib/number/float64/base/to-float32' );
3231
var format = require( '@stdlib/string/format' );
3332
var pkg = require( './../package.json' ).name;
3433
var FIBONACCI = require( './../lib/fibonacci.json' );
@@ -70,8 +69,7 @@ bench( format( '%s::analytic', pkg ), function benchmark( b ) {
7069
var i;
7170

7271
function fibonaccif( n ) {
73-
// TODO: replace with powf once implemented
74-
return roundf( float64ToFloat32( pow( PHI, n ) ) / SQRT_5 );
72+
return roundf( powf( PHI, n ) / SQRT_5 );
7573
}
7674

7775
x = discreteUniform( 100, 0, 36 );

0 commit comments

Comments
 (0)