-
Notifications
You must be signed in to change notification settings - Fork 0
Andreabont/SimRam
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
To read the theoretical part go to: http://en.wikipedia.org/wiki/Random_access_machine ##RAM ISA load X M[0] <- M[X] load= X M[0] <- X load* X M[0] <- M[M[X]] store X M[0] -> M[X] store* X M[0] -> M[M[X]] read X Tape -> M[X] read* X Tape -> M[M[X]] write X Tape <- M[X] write= X Tape <- X write* X Tape <- M[M[X]] // NB: operator can be {add, sub, mul, div} operator X M[0] <- M[0] op M[X] operator= X M[0] <- M[0] op X operator* X M[0] <- M[0] op M[M[X]] jmp LABEL Jump to 'LABEL' jz LABEL Jump to 'LABEL' if M[0] = 0 jgz LABEL Jump to 'LABEL' if M[0] > 0 halt Stop execution (required) ##Syntax for the emulator label LABEL Set 'LABEL' on the next istruction. debug X Call the X° debug function. # XXX Ignore line 'XXX' ##Debug function 1 Registers dump.
About
RAM machine emulator
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published