File tree Expand file tree Collapse file tree 2 files changed +5
-8
lines changed Expand file tree Collapse file tree 2 files changed +5
-8
lines changed Original file line number Diff line number Diff line change @@ -10,14 +10,13 @@ const bench = common.createBenchmark(main, {
1010 n : [ 5e5 ]
1111} ) ;
1212
13- function main ( conf ) {
14- const n = + conf . n ;
15- const fn = zlib [ `create${ conf . type } ` ] ;
13+ function main ( { n, type, options } ) {
14+ const fn = zlib [ `create${ type } ` ] ;
1615 if ( typeof fn !== 'function' )
1716 throw new Error ( 'Invalid zlib type' ) ;
1817 var i = 0 ;
1918
20- if ( conf . options === 'true' ) {
19+ if ( options === 'true' ) {
2120 const opts = { } ;
2221 bench . start ( ) ;
2322 for ( ; i < n ; ++ i )
Original file line number Diff line number Diff line change @@ -8,10 +8,8 @@ const bench = common.createBenchmark(main, {
88 n : [ 4e5 ]
99} ) ;
1010
11- function main ( conf ) {
12- const n = + conf . n ;
13- const method = conf . method ;
14- const chunk = Buffer . alloc ( + conf . inputLen , 'a' ) ;
11+ function main ( { n, method, inputLen } ) {
12+ const chunk = Buffer . alloc ( inputLen , 'a' ) ;
1513
1614 var i = 0 ;
1715 switch ( method ) {
You can’t perform that action at this time.
0 commit comments