1. A digital computer has a memory unit with 24 bits per word. The instruction set consists of 150 different operations. All instructions have an operation code part (opcode) and an address part (allowing for only one address). Each instruction is stored in one word of memory.
Answer the following:
a. How many bits are needed for the opcode?
b. How many bits are left for the address part of the instruction?
c. What is the largest unsigned binary number that can be accommodated in one word of memory?
2. Given the instruction set for MARIE in this chapter, decipher the following MARIE machine language instructions. (Write the assembly language equivalent.)
a. 0010000000000111
b. 1001000000001011
c. 0011000000001001
3. Write a program to evaluate the arithmetic statement x = (a×( b + c ) × d - e) using a stack organized computer with zero-address instructions (so only pop and push can access memory).
4. What is the difference between using direct and indirect addressing? Give an example.
5. Consider a byte-addressable computer with 24-bit addresses, a cache capable of storing a total of 64K bytes of data and blocks of 32 bytes. Show the format of a 24-bit memory address for:
a. direct mapped
b. associative
c. 4-way set associative
6. Suppose the daytime processing load consists of 60% CPU activity and 40% disk activity. Your customers are complaining that the system is slow. After doing some research, you have learned that you can upgrade your disks for $8,000 to make them 2.5 times as fast as they are currently. You have also learned that you can upgrade your CPU to make it 1.4 as fast for $5,000. Which would you choose to yield the best performance improvement for the least amount of money?
7. Suppose a disk drive has the following characteristics:
• 6 surfaces
• 16,383 tracks per surface
• 63 sectors per track
• 512 bytes/sector
• Tract-to-track seek time of 8.5 milliseconds
• Rotational speed of 7,200 RPM.
a. What is the capacity of the drive?
b. What is the access time?
8. Suppose we have the instruction LDA 800. Given the memory as follows and the base register contains the value 100.
Memory address value
800 900
900 1000
1000 500
1100 600
1200 800
1300 250
What would be loaded into the AC if the addressing mode for the operand is:
a. immediate
b. direct
c. indirect
d. indexed