phlogiston 1.1.2
Ethereum Virtual Machine (EVM) assembler / disassembler.
To use this package, run the following command in your project's root directory:
Manual usage
Put the following dependency into your project's dependences section:
This package provides sub packages which can be used individually:
phlogiston:core - Library for assembling / disassembling EVM code.
Phlogiston
An assembler and disassembler for the Ethereum Virtual Machine (EVM).
Building
To build this package assuming you have DUB Package Manager installed you can do the following:
$ dub build
Assembler Usage
The following is a simple contract:
PUSH1 0x60
PUSH1 0x40
MSTORE
PUSH1 0x0a
DUP1
PUSH1 0x10
PUSH1 0x00
CODECOPY
PUSH1 0x00
RETURN
PUSH1 0x60
PUSH1 0x40
MSTORE
PUSH1 0x08
JUMP
JUMPDEST
STOP
To compile it you would write:
$ phlogiston assemble input.evm output.txt
When we examine output.txt we will find:
6060604052600a8060106000396000f360606040526008565b00
Disassembler Usage
Given the bytecode file we just previously entered:
6060604052600a8060106000396000f360606040526008565b00
To disassemble it you would write:
$ phlogiston disassemble output.txt result.evm
When we example result.evm
we will find:
PUSH1 0x60
PUSH1 0x40
MSTORE
PUSH1 0x0a
DUP1
PUSH1 0x10
PUSH1 0x00
CODECOPY
PUSH1 0x00
RETURN
PUSH1 0x60
PUSH1 0x40
MSTORE
PUSH1 0x08
JUMP
JUMPDEST
STOP
- Registered by Eric Scrivner
- 1.1.2 released 8 years ago
- etscrivner/phlogiston
- MIT
- Copyright © 2016, Eric Scrivner
- Authors:
- Sub packages:
- phlogiston:core
- Dependencies:
- phlogiston:core
- Versions:
-
2.0.2 2016-Jul-28 2.0.1 2016-Jul-28 2.0.0 2016-Jul-28 1.1.3 2016-Jul-28 1.1.2 2016-Jul-28 - Download Stats:
-
-
0 downloads today
-
0 downloads this week
-
0 downloads this month
-
78 downloads total
-
- Score:
- 1.3
- Short URL:
- phlogiston.dub.pm