Skip to content

Explore a collection of assembly programs designed for a CPU simulator in this repository. These programs cover various fundamental concepts, including arithmetic and logical operations, memory reference instructions, register reference instructions, and more. Each program is carefully crafted to run seamlessly in a specified CPU simulation tool.

Notifications You must be signed in to change notification settings

Namit-Rana6/CpuSimProjects

Repository files navigation

CpuSimProjects

Welcome to my CPU Simulator repository! This project encompasses a comprehensive set of assembly language programs designed to simulate various aspects of a CPU based on a specific architecture. Each project is aimed at implementing different functionalities to create a holistic understanding of the instruction cycle and register operations.

Projects Overview

1. Machine Architecture

Create a machine based on a specified architecture, providing a foundational framework for subsequent projects.

2. Fetch Routine (Instruction Cycle)

Implement the Fetch routine of the instruction cycle, crucial for fetching instructions and preparing for execution.

3. ADD Operation

Write an assembly program to simulate the ADD operation on two user-entered numbers.

4. SUBTRACT Operation

Write an assembly program to simulate the SUBTRACT operation on two user-entered numbers.

5. Logical Operations

Write assembly programs to simulate various logical operations (AND, OR, NOT, XOR, NOR, NAND) on two user-entered numbers.

6. Memory-Reference Instructions

Implement assembly programs to simulate memory-reference instructions (ADD, LDA, STA, BUN, ISZ).

7. Register Reference Instructions (Part 1)

Write assembly programs to simulate register reference instructions (CLA, CMA, CME, HLT) and determine the contents of AC, E, PC, AR, and IR registers after execution.

8. Register Reference Instructions (Part 2)

Simulate additional register reference instructions (INC, SPA, SNA, SZE) and analyze register contents after execution.

9. Register Reference Instructions (Part 3)

Implement assembly programs to simulate more register reference instructions (CIR, CIL) and analyze register contents post-execution.

10. Integer Summation (Negative Non-Zero Termination)

Write an assembly program that reads integers, adds them until a negative non-zero number is encountered, and outputs the sum (excluding the last number).

11. Integer Summation (Zero Termination)

Implement an assembly program to read integers, add them until zero is encountered, and output the sum.

Feel free to explore each project in this repository to gain insights into CPU simulation, instruction execution, and register manipulation. The structured layout and use of headers make it easy for users to navigate and understand the contents of your repository.

About

Explore a collection of assembly programs designed for a CPU simulator in this repository. These programs cover various fundamental concepts, including arithmetic and logical operations, memory reference instructions, register reference instructions, and more. Each program is carefully crafted to run seamlessly in a specified CPU simulation tool.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published