source: benchmark/creation/node_cor.js @ 96f5b30

ADTarm-ehast-experimentalenumforall-pointer-decayjacob/cs343-translationjenkins-sandboxnew-astnew-ast-unique-exprpthread-emulationqualifiedEnum
Last change on this file since 96f5b30 was a21dec4, checked in by Peter A. Buhr <pabuhr@…>, 4 years ago

not sure if this test is for function or coroutine

  • Property mode set to 100644
File size: 472 bytes
Line 
1var times = 50000000
2var argc = process.argv.length // node, path
3if ( argc > 3 ) process.exit( 1 )
4if ( argc == 3 ) times = Number( process.argv[2] )
5
6function * coroutine() {
7}
8var hrstart = process.hrtime()
9for ( var i = 0; i < times; i += 1 ) {
10        cor = coroutine()
11}
12hrend = process.hrtime( hrstart )
13var dur = (1000000000 * hrend[0] + hrend[1]) / times
14console.log( dur )
15
16// Local Variables: //
17// tab-width: 4 //
18// compile-command: "node node_cor.js" //
19// End: //
Note: See TracBrowser for help on using the repository browser.