Question: EEL3801: Computer Organization Fall 2017 Semester Project #1: Part A You are tasked to calculate a specific algebraic expansion, e. compute the value of t

 EEL3801: Computer Organization Fall 2017 Semester Project #1: Part A You

EEL3801: Computer Organization Fall 2017 Semester Project #1: Part A You are tasked to calculate a specific algebraic expansion, e. compute the value of t and g for the expression: f (AC3-3C%2D2-4B) = without using any intrinsic multiplication instructions. More formally, write MIPS assembly code that accepts four positive integers a, b-c, and d as input parameters. The code shall execute in MARS to prompt the user to enter four positive integers represented in decimal, each separated by the Enter key The prograin shall calculate f=AC'-3C4BD2-4B) and g=(AC+B2D2) using your own self-written maltiplication routine. The program will then output in decimal and binary, using ayscall routines for each output Note: To receive credit, no mltiplication, no division, and no shift instructions shall be used. Namely none of mul, mul.d, mul.s, mulo, mulou, mult, multu, mulu, div, divu, rem sll, sllv, sra, srav, srl, srlv or else a zero score will result. Thus, it is necessary to compose your own multiplication technique. In addition, use of a loop is required for credit to realize the Hint: MARS supports output in binary format using the appropriate parameters with syscall. For the C- language prototype, there are many approaches to print a value in binary in C. Here is my favorite single- line-in-a-loop solution that you can use with any C-compiler to print x in binary, shown with x-9 as an example: main int i,x-9: for (i-31i-0- /* Put char with ASCII ade for .ith8r 0 ar 1 by adding 1 fo th. 1th bst to ASCII af '0' */ putchar('0' + ((x> ) & 1)); return (O) You can use the above in your C-code prototype ox write your own binary output routine in C if you want. Sample output for Part A is: Enter 4 integers for A, B,C,D respectively 15 12 f ten 25533 f two 00000000000000000110001110111101 ten 3429 gtwo 00000000000000000000110101100101 - The submitted program shall provide outputs in exactly the sequence and format shown above. To receive full credit, no additional superfluous outputs shall occur

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!