Coder Social home page Coder Social logo

qrun-rs's Introduction

qrun

Take AArch64 instructions, execute them, and display the final CPU state right away

$ cargo +nightly-2021-07-27 install --git https://github.com/kawadakk/qrun-rs.git

$ qrun --print-encoding -
mov x0, #1
mov x1, #2
add x2, x0, x1
^D
----- Instruction Encoding -----
default_main:
  0000000010000000: d2800020 mov x0, #0x1
  0000000010000004: d2800041 mov x1, #0x2
  0000000010000008: 8b010002 add x2, x0, x1
  000000001000000c: d65f03c0 ret
  0000000010000010: 00000000 udf #0x0
  [  repeated for 1020 times  ]
----- Final CPU State -----
x0  = 0x00000000000001 x1  = 0x00000000000002 x2  = 0x00000000000003 x3  = 0x00000000000000
x4  = 0x00000000000000 x5  = 0x00000000000000 x6  = 0x00000000000000 x7  = 0x00000000000000
x8  = 0x00000000000000 x9  = 0x00000000000000 x10 = 0x00000000000000 x11 = 0x00000000000000
x12 = 0x00000000000000 x13 = 0x00000000000000 x14 = 0x00000000000000 x15 = 0x00000000000000
x16 = 0x00000000000000 x17 = 0x00000000000000 x18 = 0x00000000000000 x19 = 0x00000000000000
x20 = 0x00000000000000 x21 = 0x00000000000000 x22 = 0x00000000000000 x23 = 0x00000000000000
x24 = 0x00000000000000 x25 = 0x00000000000000 x26 = 0x00000000000000 x27 = 0x00000000000000
x28 = 0x00000000000000 x29 = 0x00000000000000 lr  = 0x000000e0000000 sp  = 0x00000010011000
pc  = 0x000000e0000000

Prerequisites

  • rustup (at compile time and runtime)
  • (On Windows) Visual C++ 2017 Windows XP toolchain

qrun-rs's People

Contributors

kawadakk avatar

Stargazers

 avatar  avatar

Watchers

 avatar

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.