Skip to content
forked from chdft/AbaSim

AbaSim is a library that virtualizes Abacus instructionset CPUs

Notifications You must be signed in to change notification settings

TheMHMoritz3/AbaSim

 
 

Repository files navigation

AbaSim

AbaSim is a library that virtualizes Abacus instructionset CPUs. Note that this library does not emulate the actual circuit of an abacus CPU, but implements all operations using equivalent operations provided by the host platform.

Features

  • all instructions (excluding vector and synchronization)
  • Memory Caching (single- and multi-layer, shared and separate)
  • Debugger API
  • Abacus assembler compiler (API and command line utility)
  • Abacus binary runner (API and command line utility)
  • Extendibility (many event-based hooks and sensible class hierarchy)

Additional instructions (like vector instructions) are architecturally possible and could be added, but currently not implemented.

Usage

Compiler

AbaSim.ConsoleCompiler [sourceFile [destinationFile]]

Where sourceFile is a textfile containing abacus assembler. The output will be written to destinationFile. If sourceFile is missing, the application reads from stdin. If destinationFile the application writes to stdout. On compilation erros, the exit code is unequal to 0.

Runner

AbaSim.ConsoleRunner programMemoryDump dataMemoryDump [Flags]

Where programMemoryDump is a binary file containing the initial program memory and dataMemoryDump is a binary file containing the initial data memory. Specify flag C for control flow monitoring - this may impact execution speed. Specify F to enable program flow analysis (requires C flag) - this may impact execution speed, but enables endless loop detection. Specify flag P to start with paused execution.

You can press ESC at any time to cancel the program execution. Press H for help.

Contained Magic

  • String Magic (see AssemblerLexer)
  • Bit Magic (see instruction decoding)
  • structure overlay Magic (see Word)
  • Reflection Magic (see AssemblerCompiler)
  • Threading/TPL Magic (see Host)

About

AbaSim is a library that virtualizes Abacus instructionset CPUs

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 100.0%