Make a simple assembler for the dlx processor

Assignment Help Assembly Language
Reference no: EM131445757

Assembler Language Assignment Project

What is my assignment?

Getting Started (Items you have to review or learn to do for the project)

In order to get started on creating your assembler you must be able to have the program understand basic syntax of a text file containing a program. In this first part of the program you will deal with the basic functions of string processing and reading files. The following is a list of items to complete to help you do the project.

1) You will need to be able to read in arguments pass from the command line.
Ex: project1.exe inputfile.txt outputfile1.txt

2) You will need to be able to parse a string.
Ex: You will need to use the strtok() function in the string.h file.

3) You will need to convert all letters to lowercase letters.

4) You will need to compare a string to a list of know words.
(add, load, store, r0, r1, r2)

5) You will need to have a number in text 123 be converted to a number (integer) in the C program.

6) You will also need to be able to read and write files.

Project

Your assignment is to make a simple assembler for the DLX processor. We will simplify the assembler by only using the core instructions, we will not do the floating point instructions. The registers will be named as r0, r1, r2, ... r29, r30, r31. We will also not allow any advance naming for saving constant or memory locations the assembly source code we write will hard code any constant and memory location to read and write to. The only advance item we will do is use a label for branching and jumping in code.

Items to turn in: a report that tells how you created your program, source code, test files and a flow chart.

Tips

It is common to run an assembler in a two pass structure. The first pass goes through the source files and finds all the labels and addresses for each instruction. You can start your program by assuming the first line of code is at memory location 0. You will make a table of label and address. On the second pass you will then convert the assembly instruction into machine code and fill in any labels using your table.

What to turn in

The following is what needs to be turned in for project 1:

Report

The report is made up of the following 4 parts:

1) The first part tells me if the project was successful or unsuccessful. If unsuccessful tell me which parts work and which parts do not work.

2) I need a documentation of each function of your code. Give me the name of the function, the inputs/outputs, and a description of what the behavior of the function is.

3) Instead of a flow chart give me a written set of steps that occur in your code design, reference the names of function calls as needed. You will write is as

Step 1 - what is done in step 1

Step 2 - what is done in step 2. If you have decisions write if X occurs go to step Y.

4) Project output. I need you to write a test file that test one instruction of each type (Load, Store, Branch, ALU, ALUi, JR, J). Write out the instructions in the test file and give me a screenshot of the output. Show the output of the encoding done by hand and compare it to the encoding of your program.

Source Code

Test Files
(SubI r12,R20,255
start: lw r7,-16(R31)
SLT r3,r1,r9
BEQZ r1, STOP
SGTI r3,r7,-5
stop: sb 16(r11),r9
jalr r4
J start)

All of the files should be placed in one zip file. Name the file as P1_lastname.zip I do not want the files sent in an email. Post the file in blackboard under the Project 1 assignment. I will take off 20 points if I receive an email of your project.

Reference no: EM131445757

Questions Cloud

Furnace in a foundry keeps a room warm during winter : Heat from a furnace in a foundry keeps a room warm during the winter. However, during the summer, the combination of furnace heat and warm humid external air in the room can become difficult for workers to tolerate.
Find the nash equilibrium using backward induction : Find the Nash equilibrium using backward induction.
Describe the data presented to the operator : State the minimum number of printed-circuit cards required to construct a basic controller, naming each of the cards and produce a sketch to show the construction of the data words on the data highway.
What is the value of this annuity today : You buy an annuity that will pay you $20,000 a year for 25 years. The payments are paid on the first day of each year. What is the value of this annuity today if the discount rate is 8.5 percent? Upon graduation one year from today you expect to be e..
Make a simple assembler for the dlx processor : Your assignment is to make a simple assembler for the DLX processor. We will simplify the assembler by only using the core instructions, we will not do the floating point instructions.
Uses the proceeds to repurchase shares : Meyer & Co. expects its EBIT to be $87,000 every year forever. The firm can borrow at 12 percent. Meyer currently has no debt, and its cost of equity is 16 percent.    If the tax rate is 35 percent, what is the value of the firm? What will the value ..
Maintain fiscal accountability and control : Write a 250- to 350-word paper examining 1 of the 3 ways to maintain fiscal accountability and control (management control systems, measures of performance, and quality control) in a public service organization.
Briefly define backward induction : Modify Solomon's decision problem so that each woman actually loses the value she places on the child if she is not awarded the child. The value to the true mother is assumed to satisfy CT > 2CF .
Provide optional or discretionary benefits : All employee benefits that are not required by law are called optional or discretionary benefits. What are the broad categories of optional or discretionary benefits that employers may provide? Why do employers provide optional or discretionary b..

Reviews

Write a Review

Assembly Language Questions & Answers

  Define a second byte array to store the frequencies

Write a code block to print the content of chA and write a code block to print the transpose of chA - Write a code block to compute the individual summation per each column, per each row and the overall summation of chA.

  Use a loop with indirect or indexed addressing

Use a loop with indirect or indexed addressing to reverse the elements of the integer array in place. Do not copy the elements to any other array

  Prepare an assembly program that reads in a number of cents

prepare an assembly program that reads in a number of cents. the program will write out the number of dollars and cents

  Modify the single-cycle mips processor

Modify the single-cycle MIPS processor to implement one of the following instructions. Sec Appendix B for a definition of the instructions. Mark up a copy to indicate the changes to the datapath. Name any new control signals.

  Design and develop an embedded system

Assembly language program to control the operation of the embedded system and thorough testing to ensure correct operation of system

  Recode all functions utilizing the stack frame method

Recode all functions utilizing the Stack Frame method - Test each function from main, print appropriate array after each test.

  Demonstrate a clear understanding of online tools

Demonstrate a clear understanding of, and ability to use, the specific features of different online tools Convey a coherent and consistent identity and related theme across all elements of your web presence

  Provide the rtl instructions

Provide the RTL instructions and the time steps that will facilitate the execution of the following assembly language instructions  LDA addr,x  STX addr,x

  Document the protocols for passing

You must document the protocols for passing parameters and returning the result to the subroutine and also follow the convertion of saving and restoring registers in the subroutine.

  Assignment related to arm assembly

The 8-Segment display and LEDs will show status of the safe: U: indicates safe is unlocked, L: indicates safe is locked, P: indicates safe is programming a code, C: indicates safe is confirming a new code

  Find out the largest number from an unordered array

Write an Assembly Language Program to Find out the largest number from an unordered array of 16 numbers( 8-bit) starting at the location 0500H (offset) in the segment 2000H

  What is the maximum number of one-address instructions

A certain machine has 16-bit instructions and 6-bit addresses. Some instructions have one address and others have two. If there are n two-address instructions, what is the maximum number of one-address instructions?

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd