Skip to content

JDhruvR/IAS-Processor-Design

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

IAS-Processor-Design# IAS Processor Design

This repository contains the implementation of an IAS processor simulator. This project includes an assembler to convert assembly code into machine code and a processor simulator to execute the machine code.

Table of Contents

Files

  • Assembler.py: Converts assembly code into machine code.
  • Processor.py: Simulates the execution of machine code on the IAS processor.
  • assemblyCode.txt: Contains the assembly code for testing.
  • machineCode.txt: Contains the machine code generated by the assembler.
  • cCode.c: A C program for checking if a number is prime, provided for comparison.

Usage

Assembler

The assembler reads the assembly code from assemblyCode.txt and converts it into machine code. The machine code is then printed to the console.

To run the assembler:

python Assembler.py

Processor

The processor reads the machine code and simulates its execution. It prints the state of various registers after each instruction is executed.

To run the processor:

python Processor.py

Example

The provided assembly code checks if a number is prime. The number to be checked is input by the user when running Processor.py. The result (0 for not prime, 1 for prime) is printed at the end.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published