diff options
| author | s-ol <s+removethis@s-ol.nu> | 2021-07-06 10:26:46 +0000 |
|---|---|---|
| committer | s-ol <s+removethis@s-ol.nu> | 2021-07-06 11:08:54 +0000 |
| commit | 631f09462050c8173dacb22a83e6ef3dacc3c8a1 (patch) | |
| tree | 4cbd147e158991e229ce1fc2001525078a020b83 /ex.valid | |
| parent | good helloworld example (diff) | |
| download | subv-631f09462050c8173dacb22a83e6ef3dacc3c8a1.tar.gz subv-631f09462050c8173dacb22a83e6ef3dacc3c8a1.zip | |
update README/ex example
Diffstat (limited to 'ex.valid')
| -rw-r--r-- | ex.valid | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/ex.valid b/ex.valid new file mode 100644 index 0000000..1652954 --- /dev/null +++ b/ex.valid @@ -0,0 +1,16 @@ +== code 0x80000000 +# repeatedly print "Hi\n" +main: +# load 0x10010000 (UART0) into t0 +37/u 5/rd 10010/imm20 +# store 0x48 (H) in UART0+0 +13/i 6/rd 0/funct3 0/rs 48/imm12 +23/s 5/rs1 0/imm12 2/funct3 6/rs2 +# store 0x69 (i) in UART0+0 +13/i 6/rd 0/funct3 0/rs 69/imm12 +23/s 5/rs1 0/imm12 2/funct3 6/rs2 +# store 0x0a (\n) in UART0+0 +13/i 6/rd 0/funct3 0/rs a/imm12 +23/s 5/rs1 0/imm12 2/funct3 6/rs2 +# jump back up to the top +6f/j 0/rd main/off21 |
