RISC-V Project: Double Linked-list Simulation

Overview

This project implements a RISC-V assembly program that processes a series of list manipulation commands provided as a single input string. The input string, declared as listInput in the .data section, contains commands separated by the ~ character (ASCII 126). The main function and associated functions handle commands to add, delete, print, sort, and reverse elements in a list.

Features

Input Handling

Command Format

Assembly Code Structure

Usage

  1. Place the listInput string in the .data section of the RISC-V assembly code.
  2. Ensure the input string follows the specified format and constraints.
  3. Run the program to see the list manipulation based on the commands provided in listInput.

Example Input

listInput: .string "ADD(a)~ADD(b)~PRINT~SORT~PRINT~REV~PRINT"

Example Output

  1. Initial Input: ADD(a)~ADD(b)~PRINT~SORT~PRINT~REV~PRINT
  2. Output:
    a
    b
    -----
    a
    b
    -----
    b
    a
    

This README description outlines the functionality, input handling, command format, and usage of the RISC-V assembly project for processing list commands.

Program Logic

Test - Video Demo

Watch the video

Documentation & Repository

You can download the complete documentation here. The repository is available here for browsing all the project resources.