One user/student made the following comment earlier: "@nitrorex1713 In the latter portion of the video, when going through the example of allocating space, shouldn't the Store Word instruction be used in order to insert values into the RAM? I thought load word was for when you are retrieving values from the RAM." Unfortunately, I deleted the comment by mistake, but they are absolutely right, we should have used store word instead of load word when loading values from the CPU to the RAM, everything else should stay the same (i.e. register number, immediates, ...)
@tylerhartman1630
Жыл бұрын
You may want to send an email about this as well. I shared it with the classmates I know, but I'm not sure if others have seen it.
@tylerhartman1630
Жыл бұрын
Another thing I noticed that you sort of glossed over is the part where we can't move up, but what if I used code such as the following: addi $sp, $sp, -4 li $s0, 0 sw $s0, 0($sp) addi $sp, $sp, -4 li $s0, 3 sw $s0, 0($sp) addi $sp, $sp, -4 li $s0, 9 sw $s0, 0($sp) Would this pose similar issues or would it tend to function as intended?
@pythonmeetsaws5297
Жыл бұрын
That would be okay, there's nothing wrong with what you did here. Instead of allocating the 12 bytes at the beginning, you decided to allocate 4 bytes at a time. For the other students: Here, `li $register, immediate` (load immediate, which is a pseudo-instruction) is essentially the same as `addi $register, $zero, immediate`
@tylerhartman1630
Жыл бұрын
Also, I was confused as to why there was no equivalent to store immediates, and it turns out that it has to do with the design of MIPS being a register oriented assembly language. After looking into it, I have a better appreciation for the design of MIPS assembly than I did prior and thought I might mention that this knowledge has helped my understanding and capabilities within MIPS immensely.
Пікірлер: 5