Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some EIP-663 updates #2056

Merged
merged 2 commits into from
May 21, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion EIPS/eip-663.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ This results in wasting a byte in the cases of only referring to the top 255 sta

### Option C

This option extends Option A with two new instructions, `DUPSn` and `SWAPSn`, where the value of `n` is encoded as an 8-bit immediate value following the opcode.
This option extends Option B with two new instructions, `DUPSn` (`0xb2`) and `SWAPSn` (`0xb3`), where the value of `n` is encoded as an 8-bit immediate value following the opcode.

The value `n` has a range of 0 to 255, but otherwise the same rules apply as in Option A.

Expand All @@ -68,6 +68,12 @@ This has no effect on backwards compatibility.

TBA

## References

A similar proposal was made with [EIP-174](https://github.com/ethereum/EIPs/issues/174). Read the thread for some detailed discussion.

Rootstock [RSKIP26](https://github.com/rsksmart/RSKIPs/blob/master/IPs/RSKIP26.md) also introduced `SWAPN` and `DUPN` with Option A described above.

## Copyright

Copyright and related rights waived via [CC0](https://creativecommons.org/publicdomain/zero/1.0/).