-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b01fa47
commit 9f81cdb
Showing
1 changed file
with
22 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# ChaiVM - Virtual machine for chai bytecode. | ||
## How to build: | ||
```shell | ||
$ make build | ||
``` | ||
## How to use | ||
```shell | ||
$ build/chai <app.chai> | ||
``` | ||
### Chai bytecode currently is just a Sequence of instructions. | ||
For instance, there is disassembler of simple app.chai | ||
``` | ||
Mov 6 r2 | ||
Mov 8 r3 | ||
Ldra r3 | ||
Mul r2 | ||
Print acc | ||
Mov o ro | ||
Ret; | ||
``` | ||
Where Ret returns exit code `r0`. | ||
This script compiled to chai-bytecode should print "0", because '0' == 48. |