Skip to content

Instantly share code, notes, and snippets.

@edo9k
Forked from drguildo/TIS-100.md
Last active October 19, 2018 00:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save edo9k/222092d680123dd92db6846fc75d1e95 to your computer and use it in GitHub Desktop.
Save edo9k/222092d680123dd92db6846fc75d1e95 to your computer and use it in GitHub Desktop.
TIS-100 Cheat Sheet

TIS-100 Cheat Sheet

Instructions

Name Syntax Description
NOP NOP No operation
MOV MOV <SRC>, <DST> Move value from source to destiny
SWP SWP Swap values of ACC and BAK
SAV SAV Send ACC value to BAK
ADD ADD <SRC> Add source value to ACC
SUB SUB <SRC> Subtract source value from ACC
NEG NEG Multiplies ACC by negative one (-1)
NIL MOV ACC, NIL Equivalent to Linux /dev/null for outputs. Reading from NIL always results in zero (0)
Name Syntax Description
JMP JMP <LABEL> Jumps to label
JEZ JEZ <LABEL> Jumps to label if ACC equals to zero (ACC == 0)
JNZ JNZ <LABEL> Jumps to label if ACC is diffent from zero (ACC != 0)
JGZ JGZ <LABEL> Jumps to label if ACC is greater than zero (ACC > 0)
JLZ JLZ <LABEL> Jumps to label if ACC is lower than zero (ACC < 0)
JRO JRO <SRC> Jumps SRC number of instructions (also accepts negative numbers)

Keyboard Shortcuts

Keys Description
Ctrl-Z Undo last change
Ctrl-Y Redo last change
Ctrl-X Cut selected text to clipboard
Ctrl-C Copy selected text to clipboard
Ctrl-V Paste clipboard text
Ctrl-↑ Navigate to upper execution node
Ctrl-↓ Navigate to lower execution node
Ctrl-← Navigate to execution node on the right
Ctrl-→ Navigate to execution node on the left
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment