I’m trying to store a pointer initialized as:
int* x;
into a regular variable initialized as
int y;
thus:
y = *x;
In mips is it just as simple as
$s1 = ($a0);?
And vice versa?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Assembly language usually doesn’t have operators. You probably want the
lwinstruction:The use of
$s1and$a0is of course context dependent. If those register match the rest of the code you’re using, it’ll be fine.