Assembly Language Question

aceman817

Senior member
Jul 15, 2001
204
0
0
I came across this question in one of my courses that I'm not sure of. Here it is...

Show a pseudo assembly language code segment to load a new process onto a CPU (that is, to change the PC after restoring other registers) for a processor that contains arithmetic-logical registers R0-R3, processor status register PSR, condition code register CC, program counter PC, and instruction register IR.

I know some assembly language from a course I took not too long ago, but I'm not sure what they want here. Is the "load" statement used to populate the registers one by one? Does the stack need to be used to save existing values? Any help is greatly appreciated.
 

clamum

Lifer
Feb 13, 2003
26,256
406
126
I've only had experience with MIPS assembly so...

The load statements in MIPS (load word and load byte), load a word/byte from memory and put it in a specific register. So to do multiple registers you would have to execute the statement multiple times.

I never dealt with the PSR or CC registers so I can't help you there. I've never done process switching via assembly so I can't help you much, I just figured I'd give my two cents on the load instruction. Good luck. :)