Question

5. a.) Design an Expanding Opcode to allow all the following to be encoded in a...

5. a.) Design an Expanding Opcode to allow all the following to be encoded in a 16-bit instruction:

4 instructions with two 5-bit addresses and one 3-bit register number

15 instructions with one 5-bit address and one 3-bit register number

31 instructions with no addresses or registers

(Specify the bit organization and the beginning opcode and ending opcode for each category.)

b.) Design an Expanding Opcode to allow all the following to be encoded in a 36-bit instruction:

7 instructions with two 15-bit addresses and one 3-bit register number

500 instructions with one 15-bit address and one 3-bit register number

40 instructions with no addresses or registers

(Specify the bit organization and the beginning opcode and ending opcode for each category.)

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Answer:-----------
5. a).
The first format
consists of a 3-bit opcode, two 5-bit address fields, and one 3-bit register field. The 3-bit opcode allows for 4 instructions and one opcode for “expansion”.

The second format consists of a 3-bit fixed “extended” opcode field, 5-bits for the extended opcode, one 5-bit address field, and one 3-bit register field. The 5-bit extended opcode allows 32 unique instructions, which easily contains the required 15 instructions.

The third format consists of a 3-bit fixed “extended” opcode field, a fixed 5-bit “extended-extended” opcode field, and 8-bits for additional instructions. Alternately, the second format had plenty of opcodes available to define 31 instructions where the address and register fields would be ignored.

Format 1 Opcode, 3-bits 4 instructions
000 - 011
Address
5 bits

Address
5 bits

Register
3-bits
Format 2 Expanding Opcode
Basis
100
Expanding Opcode
5 bits
15 of 32 used
Address
5 bits
Register
3-bits
Format 3 Expanding Opcode
Basis
100
Expanding Opcode
5 bits
31 of 32 used
Unused Unused

5. b).
The first format consists
of a 3-bit opcode, two 15-bit address fields, and one 3-bit register field. The 3-bit opcode allows for 7 instructions and one opcode for “expansion”.

The second format consists of a 3-bit fixed “extended” opcode field, 15-bits for the extended opcode, one 15-bit address field, and one 3-bit register field. The 15-bit extended opcode allows 32,768 unique instructions, which easily contains the required 500 instructions.

The third format consists of a 3-bit fixed “extended” opcode field, a fixed 15-bit “extended-extended” opcode field, and 18-bits for additional instructions. Alternately, the second format had plenty of opcodes available to define 40 instructions where the address and register fields would be ignored.

Format 1 Opcode, 3-bits 7 instructions
000 - 110
Address
15 bits

Address
15 bits

Register
3-bits
Format 2 Expanding Opcode
Basis
111
Expanding Opcode
15 bits
500 of 32,768 used
Address
15 bits
Register
3-bits
Format 3 Expanding Opcode
Basis
111
Expanding Opcode
15 bits
40 of 32,768 used
Unused Unused
Add a comment
Know the answer?
Add Answer to:
5. a.) Design an Expanding Opcode to allow all the following to be encoded in a...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Suppose a computer has 20-bit instructions. The instruction set consists of 32 different operations. All instructions have an opcode and two address fields (allowing for two addresses). The frst...

    Suppose a computer has 20-bit instructions. The instruction set consists of 32 different operations. All instructions have an opcode and two address fields (allowing for two addresses). The frst of these addresses must be a register, and the second must be memory. Expanding opcodes are not used. The machine has 16 registers. What is the maximum allowable size for memory? o 2 K byte O 14K byte O 11 K byte Next » ous Suppose a computer has 20-bit instructions....

  • Question 20 5 pts Suppose a computer has 32-bit instructions. The instruction set consists of 64...

    Question 20 5 pts Suppose a computer has 32-bit instructions. The instruction set consists of 64 different operations. All instructions have an opcode and two address fields (allowing for two addresses). The first of these addresses must be a register direct address, and the second must be a memory address. Expanding opcodes are not used. The machine has 16 registers. What's the size of the largest memory space that can be addressed by this computer?Assume byte addressable memory.

  • Goals: To learn general-purpose register architectures. To learn encoding an instruction set. Questions: 100 points: (1)...

    Goals: To learn general-purpose register architectures. To learn encoding an instruction set. Questions: 100 points: (1) 30 points, (2) 70 points 1. (30 points) The design of MIPS provides for 32 general-purpose registers and 32 floating-point registers. If registers are good, are more registers better? List and discuss as many trade-offs as you can that should be considered by instruction set architecture designers examining whether to, and how much to increase the numbers of MIPS registers. 2. [70 points] Consider...

  • pls both ans Question 20 5 pts Suppose a computer has 32-bit instructions. The instruction set...

    pls both ans Question 20 5 pts Suppose a computer has 32-bit instructions. The instruction set consists of 64 different operations. All instructions have an opcode and two address fields (allowing for two addresses). The first of these addresses must be a register direct address, and the second must be a memory address. Expanding opcodes are not used. The machine has 16 registers. How many bits can be used for the memory address? Question 21 5 pts Suppose we have...

  • (d) 7650 (e) None of the above Question 7 [18 Points]-Instruction Set Architecture (ISA) I. Suppose an instruction set has 32-bit instructions. Every instruction has an 8-bit opcode and a 12- bit...

    (d) 7650 (e) None of the above Question 7 [18 Points]-Instruction Set Architecture (ISA) I. Suppose an instruction set has 32-bit instructions. Every instruction has an 8-bit opcode and a 12- bit immediate operand. Some instructions have three register operands (two sources and a destination register). Every instruction that uses registers must be able to specify any of the registers. How many registers can this instruction set support? (a) 32. (b) 64. (c) 16. (d) There is not enough information...

  • 1) We would like to design a bus system for 32 registers of 16 bits each....

    1) We would like to design a bus system for 32 registers of 16 bits each. How many multiplexers are needed for the design? Select one: 5 16 1 4 32 2) The basic computer can be interrupted while another interrupt is being serviced. Select one: True False 3) If the Opcode bits of an instruction is 111, then the basic computer instruction type is either memory-reference or input-output. Select one: True False 4) The content of AC in the...

  • On a typical microprocessor, a distinct I/O address is used to refer to the I/O data...

    On a typical microprocessor, a distinct I/O address is used to refer to the I/O data registers and a distinct address for the control and status registers in an I/O controller for a given device. Such registers are referred to as ports. In the Intel 8088, two I/O instruction formats are used. In one format, the 8-bit opcode specifies an I/O operation; this is followed by an 8- bit port address. Other I/O opcodes imply that the port address is...

  • 1 to 15 blanks thank you! (1 point) For registers, Integers are encoded in one of...

    1 to 15 blanks thank you! (1 point) For registers, Integers are encoded in one of two basic types 1. and 2. (1 point) The number 201 as a one byte unsigned integer is represented as in binary and in hexadecimal. (1 point) The 2 methods for representing signed integers are 3. and (5 points) What is the 16 bit representation of -125 in 2's complement notation? 4. (5 points) What is the decimal representation of the signed integer 10000001?...

  • please answer all of 5,thank you! QUESTION 1 Choose one that an instruction-set-architecture doesn't define the...

    please answer all of 5,thank you! QUESTION 1 Choose one that an instruction-set-architecture doesn't define the number of general purpose registers the size of the program counter register instructions and their binary encodings instructions and their cycle times QUESTION 2 ADD instruction in the RV321 RISC-V ISA is an arithmetic instruction True False QUESTION 3 Consider the following C code f-g+h+itik If it is compiled for an ISA where an 'ADD' instruction takes two source registers and one output register...

  • 7. On a machine, an instruction is always 16 bits long, and the re are 16...

    7. On a machine, an instruction is always 16 bits long, and the re are 16 registers. (1) Briefly explain the idea of expanding opcode. (5%) (2) Given this scheme of expanding opcode, identify how many three-address instructions, two-address instructions, one-address instructions, and zero- address instructions are supported. (10%) O 0000 xxxx yyyy zzzz 0001 xxxX yyyy ZZZZ 0010 xxxx yyyy zzZZZ 92 3-address SE instructions 0111 xxxx yyyy zzzz 1000 0000 yyyy zzZz 1000 0001 yyyy zzzz 1000 0010...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT