Question: Consider the following C code: int main ( ) { int d = 1 ; int e; int c = - 1 ; c =

Consider the following C code:
int main()
{ int d =1;
int e;
int c =-1;
c = mysub(d,d,e);
exit(0)
}
int mysub(int a, int b, int c)
{ int d, e;
a = a + c;
return (a)
}
Presume that the system call stack starts at x7000 and moves "backwards" in memory, as had been standard in this class. Presume that while main() is running (and before mysub() is callsed) that R5(the frame pointer) contains the address x6FFA. Also presume that the program has been running, the subroutine mysub() has been called, and it is JUST ABOUT to START executing the line of code:
a = a + c;
What hex value will be in location x6FFA?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!