Script Restoration BIPs: fix OP_RIGHT definition, clarify and adjust costing with wordspan notation, UPSHIFT, CLTV/CSV, final success-check #2204

pull jmoik wants to merge 2 commits into bitcoin:master from jmoik:gsr changing 2 files +110 −66
  1. jmoik commented at 2:41 PM on June 27, 2026: none

    BIP-0440: clarify wordspan costs

    BIP-0441: update wordspan costs and fix OP_RIGHT

    • Apply BIP-0440 wordspan notation to numeric and bitvector costs.

    • Define OP_RIGHT as rightmost-byte extraction with bounded copying cost.

    • Clarify OP_UPSHIFT, CLTV/CSV, and final success-check costs.

  2. BIP-0440: clarify wordspan costs 503939b53d
  3. BIP-0441: update wordspan costs and OP_RIGHT
    - Apply BIP-0440 wordspan notation to numeric and bitvector costs.
    
    - Define OP_RIGHT as rightmost-byte extraction with bounded copying cost.
    
    - Clarify OP_UPSHIFT, CLTV/CSV, and final success-check costs.
    e840999d2d
  4. jmoik marked this as ready for review on Jun 27, 2026
  5. jonatack added the label BIP Update by Owner on Jun 28, 2026
  6. jonatack added the label Bug fix on Jun 28, 2026
  7. in bip-0440.mediawiki:351 in e840999d2d
     347 | @@ -331,6 +348,7 @@ Work in progress:
     348 |  
     349 |  ==Changelog==
     350 |  
     351 | +* 0.2.1: 2026-06-15: define wordspan notation and clarify byte-length versus word-span costs.
    


    jonatack commented at 7:53 PM on June 28, 2026:

    It may not matter, but in both changelog additions in this pull, the date is two weeks ago.


    jmoik commented at 9:44 AM on July 1, 2026:

    Thanks for reviewing!

    I don't think the changes are substantial enough to provide value for the mailing list, the OP_RIGHT definition was simply a mistake it seems, it now corresponds to the historical and the more natural semantics. I would give some time for @rustyrussell to take a look at the diff, but otherwise fine from my side.

  8. jonatack commented at 7:56 PM on June 28, 2026: member

    I don't see any obvious errors in this change.

    Are you waiting for review from anyone, or do you plan to send a mail list post to discuss?


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bips. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-07-08 20:10 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me