GithubHelp home page GithubHelp logo

00mjk / instruction-set-architecture Goto Github PK

View Code? Open in Web Editor NEW

This project forked from aditya9211/instruction-set-architecture

0.0 0.0 0.0 11 KB

Conversion of Assembly to Machine code using Two Pass Assembler

C 100.00%

instruction-set-architecture's Introduction

Instruction-Set-Architecture

Info:

* Developed an I.S.A using two pass assembler which performs 
  Basic Arithmetic and Logical Operations

* I.S.A which understand user inputs(assembly language codes (32 bits)) 
  and gives desired outputs

Two pass assembler Implementation with Instruction Set Architecture

Pass 1 : 	* Read Assembly Language Instructions from Console and create the symbol table, 
		  mnemonic op-code table and operand fields;  
		  then convert the whole instructions into Machine Level code.
		
		* Determine the storage required for each Assembly Language statement 
		  and Update the location counter.
		
		
Pass 2 :	Extract the Instructions from Machine Code File, using translation of op-code 
		and symbolic operands specified by I.S.A;
		then generate value defined by different instructions.

Instructions:

• Run "part1.c", giving Assembly Language Instructions From Console

• then Run "part2.c", and get the desired results.

Sample Program

1.  gcc part1.c
    MOVI $15 R01     // Move value 15 to register R01
    MOVI $25 R02    // Move value 25 to register R01
    ADD R02 R01     // Add value R02 = R02 + R01 and store in register R02
    PRINT R02       // Print R02
    HLT             // End of Program
    
2.  gcc part2.c    // Outputs 40

instruction-set-architecture's People

Contributors

aditya9211 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.