CSE/EEE230 Exam 1 Review (Fall 2021) IMPORTANT NOTE: You will not be allowed to start the exam later than 15 minutes after the exam starting time. You must start the exam on time. - Bring your ASU...

1 answer below »
I have a midterm today, with a focus on MIPS Assembly. My other tutor isn't available. Could I do a two-hour session with you today, October 13? I'm available till 1:00 PM/13:00 Mountain Time United States. Thanks so much for your consideration.


CSE/EEE230 Exam 1 Review (Fall 2021) IMPORTANT NOTE: You will not be allowed to start the exam later than 15 minutes after the exam starting time. You must start the exam on time. - Bring your ASU CARD photo ID to each exam. We check IDs. Get an ASU Sun Card if you don’t have one: https://cfo.asu.edu/cardservices - Closed notes, closed books. - One cheat sheet of the size of 8.5 in by 5.5 in (half of the regular sheet of paper) is allowed. Both sides of a sheet can be used. You will be asked to submit your cheat sheet along with your exam papers at the end of testing time (and it will not be returned to you). Not submitting your cheat sheet will be considered a violation of Academic Integrity Policy. You may not use a photocopy of someone else's cheat sheet. You need to make your own cheat sheet. It can be typed or hand-written. -You don’t need to bring a green sheet. It will be provided by the instructor -Cell phones must be put completely off and in backpacks or purses. If your cell phone is seen on your lap or out in any way during an exam, you will be given a grade of E or XE and reported for a violation of ASU’s Academic Integrity Policy. -You may not wear any kind of watch. -You may not be on-line, obviously. -You can bring a calculator. You may not share a calculator with anyone.  TI-Nspires are not allowed. Topics to be covered: Chapter 1 -What are the five classic components of computer? Chapter 2 -How to convert among binary, decimal, and hex representations. -Registers, $zero, $v0-$v1, $a0-$a3, $t0-$t7, $s0-$s7, $t8-$t9, $sp, $ra -MIPS assembly instructions, add, sub, addi, lw, sw, and, or, nor, andi, ori, sll, srl, bne, beq, slt, slti, j, jal, jr, mul, div, mflo, mfhi -Know how to convert a MIPS assembly instruction to the corresponding Machine code using binary, decimal, or hex, for add, sub, addi, lw, sw, and, or, nor, andi, ori, sll, srl, beq, bne, slt, slti, j, and jr. -Know R-type, I-type, and J-type. And also from a given machine code (using binary decimal, or hex), convert to the corresponding MIPS assembly instruction. -How to convert “if, if-else, if-else if, else, …” statements in C into MIPS assembly code. -How to convert loops in C into MIPS assembly code. -How to create procedures in MIPS assembly code, how to call them, using the stack pointer. -How to operate arithmetic operations in MIPS assembly code, how to use arrays of integers in MIPS assembly code. -branch with PC-relative addressing, jump with Pseudo-direct addressing. -Spilling Registers technique Chapter 3 -How to represent negative integers using 2’s complement representation. -Convert a number in 2’s complement representation into a signed decimal number. -How to detect overflow for addition and subtraction -Binary integer Multiplication/Division -Binary fraction, floating point numbers -IEEE 754 floating point single precision representation, double precision representation -Biased exponent -Binary floating point addition/multiplication -Guard digits, rounding CSE/EEE230 Exam 1 Review (Fall 2021) IMPORTANT NOTE: You will not be allowed to start the exam later than 15 minutes after the exam starting time. You must start the exam on time. - Bring your ASU CARD photo ID to each exam. We check IDs. Get an ASU Sun Card if you don’t have one: https://cfo.asu.edu/cardservices - Closed notes, closed books. - One cheat sheet of the size of 8.5 in by 5.5 in (half of the regular sheet of paper) is allowed. Both sides of a sheet can be used. You will be asked to submit your cheat sheet along with your exam papers at the end of testing time (and it will not be returned to you). Not submitting your cheat sheet will be considered a violation of Academic Integrity Policy. You may not use a photocopy of someone else's cheat sheet. You need to make your own cheat sheet. It can be typed or hand-written. -You don’t need to bring a green sheet. It will be provided by the instructor -Cell phones must be put completely off and in backpacks or purses. If your cell phone is seen on your lap or out in any way during an exam, you will be given a grade of E or XE and reported for a violation of ASU’s Academic Integrity Policy. -You may not wear any kind of watch. -You may not be on-line, obviously. -You can bring a calculator. You may not share a calculator with anyone.  TI-Nspires are not allowed. Topics to be covered: Chapter 1 -What are the five classic components of computer? Chapter 2 -How to convert among binary, decimal, and hex representations. -Registers, $zero, $v0-$v1, $a0-$a3, $t0-$t7, $s0-$s7, $t8-$t9, $sp, $ra -MIPS assembly instructions, add, sub, addi, lw, sw, and, or, nor, andi, ori, sll, srl, bne, beq, slt, slti, j, jal, jr, mul, div, mflo, mfhi -Know how to convert a MIPS assembly instruction to the corresponding Machine code using binary, decimal, or hex, for add, sub, addi, lw, sw, and, or, nor, andi, ori, sll, srl, beq, bne, slt, slti, j, and jr. -Know R-type, I-type, and J-type. And also from a given machine code (using binary decimal, or hex), convert to the corresponding MIPS assembly instruction. -How to convert “if, if-else, if-else if, else, …” statements in C into MIPS assembly code. -How to convert loops in C into MIPS assembly code. -How to create procedures in MIPS assembly code, how to call them, using the stack pointer. -How to operate arithmetic operations in MIPS assembly code, how to use arrays of integers in MIPS assembly code. -branch with PC-relative addressing, jump with Pseudo-direct addressing. -Spilling Registers technique Chapter 3 -How to represent negative integers using 2’s complement representation. -Convert a number in 2’s complement representation into a signed decimal number. -How to detect overflow for addition and subtraction -Binary integer Multiplication/Division -Binary fraction, floating point numbers -IEEE 754 floating point single precision representation, double precision representation -Biased exponent -Binary floating point addition/multiplication -Guard digits, rounding
Answered Same DayOct 13, 2021

Answer To: CSE/EEE230 Exam 1 Review (Fall 2021) IMPORTANT NOTE: You will not be allowed to start the exam later...

Gaurav answered on Oct 14 2021
105 Votes
1

MIPS Instruction Set

Arithmetic Instructions
Instruction Example Meaning Comments
add add $1,$2,$3 $1=$2+$3
subtract sub $1,$2,$3 $1=$2-$3
add immediate addi $1
,$2,100 $1=$2+100 "Immediate" means a constant
number
add unsigned addu $1,$2,$3 $1=$2+$3 Values are treated as unsigned
integers,
not two's complement integers
subtract unsigned subu $1,$2,$3 $1=$2-$3 Values are treated as unsigned
integers,
not two's complement integers
add immediate
unsigned
addiu
$1,$2,100
$1=$2+100 Values are treated as unsigned
integers,
not two's complement integers
Multiply (without
overflow)
mul $1,$2,$3 $1=$2*$3 Result is only 32 bits!
Multiply mult $2,$3 $hi,$low=$2*$3 Upper 32 bits stored in special
register hi
Lower 32 bits stored in special
register lo
Divide div $2,$3 $hi,$low=$2/$3 Remainder stored in special
register hi
Quotient stored in special registerlo
MIPS Instruction Set
2

Logical
Instruction Example Meaning Comments
and and $1,$2,$3 $1=$2&$3 Bitwise AND
or or $1,$2,$3 $1=$2|$3 Bitwise OR
and immediate andi $1,$2,100 $1=$2&100 Bitwise AND with immediate value
or immediate or $1,$2,100 $1=$2|100 Bitwise OR with immediate value
shift left logical sll $1,$2,10 $1=$2<<10 Shift left by constant number of bits
shift right logical srl $1,$2,10 $1=$2>>10 Shift right by constant number of bits
Data Transfer
Instruction Example Meaning Comments
load word lw
$1,100($2)
$1=Memory[$2+100] Copy from memory to register
store word sw
$1,100($2)
Memory[$2+100]=$1 Copy from register to memory
load upper
immediate
lui $1,100 $1=100x2^16 Load constant into upper 16 bits.
Lower 16 bits are set to zero.
load address la $1,label $1=Address of label Pseudo-instruction (provided by
assembler, not...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here