Quiz_sol3 - ECE 445 — Computer Organization Name K6 1 i G...

Info icon This preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ECE 445 — Computer Organization Name K6 1 i G#: .. _ ___ Quiz #3 ”1‘0 TA’L “ 15 Wednesday, September 23, 2009 1. The following assembly language code is given 1024 addi $30, $zero, 0 1028 addi $s1, $zero, 5 1032 L1: add $50, $30, $81 1036 addi $sl,$sl,—1 1040 bne $31, $zero, L1 1044 add $t0, $zero, $zero (a) On what condition does the Branch instruction go to the instruction at L1? 0] it imam lo L1 WM 41:31 4:13 11131“?th in (0‘, (b) What are the values in $30 and $51 at the completion of this code segment? Note: the code segment is compiete when the instruction at address 1044 is executed. E1] $s0= l_§_ [I] $31=L (0) Which HLL instruction, when compiled, would result in this assembly language code? {‘1 ..' IP-ELSE STATEMENT ' (Circle one) ((1) Specify the instruction format type and the decimal value of each instruction field for the Branch instruction in the assembly language code above. [11 Instruction Format: 3: histmcnoii Field _ Decimalfly'aiué' (U) egfide [5—7 a} , 1 a??? a "1 3mm W479, «r 3 (—4 i '1 fir”; Note: there may be more rows in the table than are necessary. ECE 445 — Computer Organization . Write the MIPS Assembly language code segment to implement each of the Branch conditions given below. Use a minimum number of instructions. Assume that [a] A—>$s(} B—>$sl The Branch instruction should branch to label “L2” when the condition is true. ...
View Full Document

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern