Skip to content

LimXu1/Assembly-To-Machine-Code-RISC-V

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

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

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 99.6%
  • Assembly 0.4%