For this programmingexercise, use only those instructions that have been discuss
ID: 3618020 • Letter: F
Question
For this programmingexercise, use only those instructions that have been discussed sofar in these notes:
In the Settingsmenu of SPIM set Bare Machine ON, Allow Pseudo Instructions OFF,Load Trap File OFF, Delayed Branches ON, Delayed Loads ON, MappedIO OFF, Quiet OFF.
This exercise continuesexercise 2.
Write a program thatsearches for perfect numbers. It has an outer loop that countsupward from two to some limit. Each number is tested (as above) tosee if it is a perfect number. If it is a perfect number it isstored at a memory location. Store perfect numbers at successivefull-word memory locations. Look at exercise 1 for a way to dothis.
add div mflo slt, slti addi divu mult sltu, sltiu addiu j multu sra addu lb nor srl and lbu or sub andi lh ori subu beq lhu sb sw bgez lui sh xor bltz lw sll xori bne mfhiExplanation / Answer
Dear,
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.