Rusty Russell on Nostr: Jeremy Rubin asked on Twitter what was happening with #GSR. Good q! After far too ...
Jeremy Rubin asked on Twitter what was happening with #GSR. Good q!
After far too much fiddling with benchmarks I now have preliminary numbers. Budget is 5200 varops per weight. Fast ops (compare, zero fill, copy) cost 1 varop per stack byte. SHA256 costs 10 per byte. Everything else costs 2 per byte.
I need to clean up my benchmarks so everyone can run them, and get "on your machine the worst case validation would be <X> seconds, doing OP_<Y>". That's concrete and gives us a chance to find any wild machines which are unexpectedly slow, and gives a tangible worst case, which should allow fruitful discussion
I also need to write code to answer "what input size (if any) would cause <this script> to exhaust it's varops budget?". This again enables us to think concretely about my thesis (yet to be proven to my satisfaction!) that it's possible to have a budget which allows any reasonable scripts not to worry about it.
Published at
2024-08-02 07:39:18Event JSON
{
"id": "528f144f35e9e9dcac1bb6fa9ef1b6a637c8fb451b7ac1c390d31f4c858d6591",
"pubkey": "f1725586a402c06aec818d1478a45aaa0dc16c7a9c4869d97c350336d16f8e43",
"created_at": 1722584358,
"kind": 1,
"tags": [
[
"t",
"GSR"
],
[
"t",
"gsr"
]
],
"content": "Jeremy Rubin asked on Twitter what was happening with #GSR. Good q!\n\nAfter far too much fiddling with benchmarks I now have preliminary numbers. Budget is 5200 varops per weight. Fast ops (compare, zero fill, copy) cost 1 varop per stack byte. SHA256 costs 10 per byte. Everything else costs 2 per byte.\n\nI need to clean up my benchmarks so everyone can run them, and get \"on your machine the worst case validation would be \u003cX\u003e seconds, doing OP_\u003cY\u003e\". That's concrete and gives us a chance to find any wild machines which are unexpectedly slow, and gives a tangible worst case, which should allow fruitful discussion \n\nI also need to write code to answer \"what input size (if any) would cause \u003cthis script\u003e to exhaust it's varops budget?\". This again enables us to think concretely about my thesis (yet to be proven to my satisfaction!) that it's possible to have a budget which allows any reasonable scripts not to worry about it.\n\n",
"sig": "f01d33a88ccaebd9224670dc1e0c99179281ceb6ff97b25990e6cd3f8fd6ee54e261b1cf35d197c0e1e648522fb128e325fe1782d61e82899e8d3bb202d92e4e"
}