Skip to content

Latest commit

 

History

History
25 lines (17 loc) · 1 KB

README.md

File metadata and controls

25 lines (17 loc) · 1 KB

Assembly To Machine Code Translation

A C++ program which can convert a RISC – V assembly code to its corresponding Machine Code along with Data Memory. Here is the link for RISC – V simulator https://venus.cs61c.org/ . All conversion is based on formats present in RISC – V Reference Sheet available in Project.

Test Cases

Test Cases for several Programs such as Sorting, Factorial is provided in the project for better understanding.

Support

The Project currently supports all instructions available in format.txt file. Pseudo instructions such as Load Address and Load Word (due to data part) is also handled.

Built With/ Concepts Used

• C ++
• RISC – V (32-Bit Architecture)

How to build program (In Compiler)

• Type following
-> Place the code to translate in test.asm File
-> Compile A-to-M.cpp
-> Output will be produced in MCode.mc File
-> MCode.mc has Machine Code in Hexadecimal Form with Program Counter followed by Data Memory Part.

Built By

Kritagya Agarwal