Writing a basic function in MIPS
I have wrote a function in MIPS which is supposed to copy some words from memory and saving it to another memory address using assembly.
The source address, destination address and the number of words to copy are input arguments of the function.
I have used $a0 to $a2 for arguments as follows:
$a0 = The source address,
$a1 = destination address
$a2 = the number of words to copy are input arguments of the function.
Now the problem I have is I get Exceptions when I run the code.
Is a function supposed to have .main, .text, .data parts in the file?
how can I write a main program which calls this function to copy few hundred words from
memory address for example 0x50000 to 0x90000.
Cheers guys, I have been stuck on this for a day now =(
|All times are GMT +5.5. The time now is 01:55.|