[SOLVED] CS301 Assignment 4

20.00 $

Category:
Click Category Button to View Your Next Assignment | Homework

You will receive the following solution file(s) instantly after successful payment:

zip file icon Assignment-4-jn6ixi.zip (93.8 KB)
Assignment Instructions Updated Recently? Submit Below and we will provide new Solution!
Submit New Instructions
🔒 Securely Powered by:
Secure Checkout
5/5 - (1 vote)

Q 1) If we ​freeze​ one machine, copy all state (memory, register file, PC, flags register) to another machine, will both machines give the same result? What if the second machine has a different design, but implements the same ISA? What if the second machine has a different ISA?

Q 2) Consider the following recursive function foo foo(n) {

If n == 2
Return 2

If n == 1
Return 1

Return foo(n-1) + foo(n-2) }

Suppose we make a call foo(5) from the main() function. What is the maximum number of activation blocks seen in the stack?
(Consider the activation block for main() being at the bottom of the stack).

  • Assignment-4-jn6ixi.zip