The RISC-V Assembler and Runtime Simulator (RARS) can be downloaded from:
All information is in pdf file
Laboratory 1 Assembly Language and the RISC-V ISA
Page 1of 6School of EngineeringEEET2261–Computer Architecture and OrganisationLaboratory 1Assembly Language and the RISC-V ISA1Aims(i)To develop an appreciation for the abstraction provided by a microprocessor’s Instruction Set Architecture (ISA).(ii)To use theRISC-V specification to understand thefunctional operation of the RISC-V ISA.(iii)To implement common algorithms typical of those suited to optimisation through direct assembly language programmingusing the RV32I base ISA.(iv)To develop an appreciation for theconstraints imposed on software by the underlying ISA.(v)To utilise the RISC-V assembler and runtime simulatorto implement, assembleand evaluate algorithms in assembly language
IntroductionYou are expected to work individually. Each student must submit asingle .zip archive containing their assembly code files according to the supplied project template.This laboratory project will run for two weeks,withsubmission dueat the end of week 3(electronicsubmission via the subject Canvas website).The so-called Internet of Things (IoT) has given rise to an explosion in the development and deployment of small, cheap, and often resource constrained, embedded systems. To maximise performance, these systems are good candidates for code optimisation through direct assembly language programming. In this laboratory, you will implement in RISC-V assembly language, a number of algorithms typical of those required in such embedded systems. Specifically, you will make use of the RV32I subset of the RISC-V instruction set architecture (ISA)[1,2]. To evaluate your submitted solutions, your code will be assembled and linked to a set of test routines, and its functionality assessed using the RISC-V Assembler and Runtime Simulator (RARS) version 1.5 .RARS may be downloaded from the link below (see ) as a.jar file. You will need Java8 or later to run it.RARS is comprised of a simple text editor for viewing and writing assembly language code(although you may use any text editor you prefer, outside of RARS), a RISC-Vassembler and a register level runtime simulator that supports single stepping and breakpoints for debugging.
To get started, download the project template from the subject Canvas website.The project template (provided as a single .zip archive) contains code stubs together with example test routinesfor each of the assembly programming tasks described below.You will complete these code stubs and must then archive (.zip) and submit your project directory for assessment.3Loops and conditionals (Linear search)The project template contains twofiles:min.asmand max.asm.Each file contains a code stubdefining a procedureto compute the minimum and maximum, respectively,of an array of signed 32-bit integersofarbitrary length. Your task is to complete eachof these code stubsto return the minimum and maximum value using a linear search of the supplied array. Your implementation of each of these procedures must satisfy the following constraints:1.The array of integers is stored in memory in a contiguous range of addresses. When each procedure(minor max) is called, the starting address of the array will be stored in a0and the number of integers in the array will be stored in a1.2.Each procedureshould return the index of its target (i.e., the minimum or maximumvalue) in a0.3.Eachprocedureshould end with a retpseudo-instruction.