Coder Social home page Coder Social logo

nobodywasishere / ponyo Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 0.0 2.87 MB

A framework for implementing ISA simulators for any number of ISAs, currently supporting a subset of LEGv8

Home Page: https://blog.eowyn.net/ponyo

License: GNU General Public License v3.0

Python 98.60% Makefile 1.40%
legv8 isa assembly simulator

ponyo's Introduction

ponyo

Ponyo is a (work-in-progress) ISA simulator currently supporting (some of) LEGv8. It also aims to be a framework for implementing simulators for any number of ISAs.

A blog post describing the initial development of this project is on my blog here.

Simulator

  • ARM LEGv8 Simulator
    • Harvard architecture
    • Takes in assembly source code
    • Takes in memory file
    • Step through program execution
    • Jump to pre-defined break points in code

CLI

usage: ponyo [-h] -f ASM [-d MEM] [--isa ISA] [--debug] [--gui]

options:
  -h, --help         show this help message and exit
  -f ASM, --asm ASM  Assembly file
  -d MEM, --mem MEM  Data memory file
  --isa ISA          ISA of assembly file
  --debug
  --gui

Execute directly:

$ ./ponyo/ponyo.py -f examples/legv8/fib.asm --debug

Install using pip:

$ git clone https://github.com/nobodywasishere/ponyo
$ cd ponyo
$ pip install .
...
$ ponyo -f examples/legv8/fib.asm --gui

Set breakpoints in the assembly by adding //$break on any given line.

GUI

Simply run ponyo with the --gui flag and the assembly file you wish to run.




Supported Architectures

LEGv8 Harvard

33/57 instructions supported

  • ADD, ADDI, ADDS, ADDIS

  • AND, ANDI, ANDS, ANDIS

  • B, B.COND, BL, BR, CBNZ, CBZ

  • EOR, EORI

  • LDUR, LDURB, LDURH

  • LDURSW, LDXR

  • LSL, LSR

  • MOVK, MOVZ

  • ORR, ORRI

  • STUR, STURB, STURH

  • STURSW, STXR

  • SUB, SUBI, SUBS, SUBIS

  • FADDS, FADDD, FCMPS, FCMPD, FDIVS, FDIVD, FMULS, FMULD, FSUBS, FSUBD

  • LDURS, LDURD, MUL, SDIV, SMULH, UDIV, UMULH

  • CMP, CMPI, MOV

  • LDA

13/13 instructions supported




Fishbowl icon created by Becris - Flaticon

ponyo's People

Contributors

nobodywasishere avatar

Watchers

 avatar  avatar

ponyo's Issues

List')

ponyo/ponyo/ponyo.py

Lines 96 to 101 in bf7a73d

root.set_title('CUI TODO List')
s = SimulatorTUI(root)
root.start()
else:
cpu.debug = args.debug
time_exec_start = time.time()


This issue was generated by todo based on a TODO comment in bf7a73d. It's been assigned to @nobodywasishere because they committed the code.

/CONCEPT

ponyo/README.md

Lines 25 to 29 in 66e5107

TODO/CONCEPT
Optional TUI for interacting with simulator. Has a handful of components.
- Code pane


This issue was generated by todo based on a TODO comment in 66e5107. It's been assigned to @nobodywasishere because they committed the code.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.