core-lightning/lightningd/test
Rusty Russell 1764d6c907 grind_htlc_tx_fee: benchmark.
Takes 15 seconds on my laptop to do the worst-case grind:

	$ onchaind/test/run-grind_feerate 250001
	250001 iterations in 15893 msec = 63574 nsec each

It's not worth optimizing as it's 75% in libsecp:

    29.65%  run-grind_feera  run-grind_feerate  [.] secp256k1_fe_mul_inner
    23.51%  run-grind_feera  run-grind_feerate  [.] secp256k1_fe_sqr_inner
    11.04%  run-grind_feera  run-grind_feerate  [.] secp256k1_gej_double_var.part.6.constprop.34
     9.56%  run-grind_feera  run-grind_feerate  [.] secp256k1_scalar_reduce_512
     5.70%  run-grind_feera  run-grind_feerate  [.] Round

Even forcing a compile with -O3 -flto, it's only 13883 msec = 55534 nsec each.

Fixes: #291
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2018-04-04 02:31:41 +00:00
..
Makefile Re-enable builds with DEVELOPER=0 2017-12-20 12:43:10 +01:00
run-commit_tx.c utils: remove tal_tmpctx altogether, use global. 2018-03-16 00:16:10 +00:00
run-cryptomsg.c utils: remove tal_tmpctx altogether, use global. 2018-03-16 00:16:10 +00:00
run-find_my_path.c grind_htlc_tx_fee: benchmark. 2018-04-04 02:31:41 +00:00
run-funding_tx.c utils: remove tal_tmpctx altogether, use global. 2018-03-16 00:16:10 +00:00
run-key_derive.c utils: add a global tmpctx. 2018-03-16 00:16:10 +00:00