Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Answers to CSCI 4717 Project 1: Underused Opcodes and Instruction Set Expansion - Prof. Da, Study Guides, Projects, Research of Computer Architecture and Organization

Answers to project 1 questions for csci 4717 computer architecture course. It explains the opcode for initializing memory to 0x00, identifies unused opcodes for instruction set expansion, and discusses adding new instructions for compare with constant, push/pull to/from stack, and 2's complement of acc. It also suggests dividing executeinstruction() function into decode and execute stages, and proposes further subdivision of the execution stage.

Typology: Study Guides, Projects, Research

Pre 2010

Uploaded on 08/16/2009

koofers-user-4vi
koofers-user-4vi 🇺🇸

10 documents

1 / 2

Toggle sidebar

Related documents


Partial preview of the text

Download Answers to CSCI 4717 Project 1: Underused Opcodes and Instruction Set Expansion - Prof. Da and more Study Guides, Projects, Research Computer Architecture and Organization in PDF only on Docsity! CSCI 4717 – Computer Architecture Answers to Project 1 Questions 1. What opcode will blank memory initialized to 0x00 look like to the processor? In binary, the opcode 0x00 is simply all zeros: A function of 0 represents a store function, the register of 0 represents the accumulator ACC, and the method of 00 indicates that the operand is an address. This means that the opcode 0x00 is: STOR ACC, [address] Assuming all of memory is cleared, then the operand will also be 0x0000. Therefore, the final function will be: STOR ACC, [0x0000] 2. Of the 256 possible opcodes we can get from and 8-bit opcode, how many are not being used in our instruction set, i.e., how many instructions could we add for future expansions of our processor? I enumerated all of the 256 possible opcodes and identified the operation for each one. It identified one branch opcode (0x17), special opcodes 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, and 0x1f, all of the opcodes beginning with "001", and all of the opcodes beginning with a binary "01" as unused. I counted these and came up with 103 undefined opcodes. I also took into account that some operations did not make sense. For example, it shouldn't be possible to store a value into a constant, opcodes 0x01 and 0x05. I also discounted the opcodes that I told you not to worry about, i.e., the opcodes that had operands of three or more bytes. These totaled 18. Therefore, I accepted answers in the range of 103 to 121. 3. What would we need to add to our simulator to be able to include the following instructions: compare ACC with a constant, PUSH to or PULL from the stack, and take the 2's complement of ACC? Each of these operations would require an additional opcode assigned to that function. In the case of the 2's complement, this might be a bit of a pain because all of the opcode patterns are already used for the mathematical/logical operations. The other two could be assigned to the "special operations" set without much problem. To compare ACC with a constant, there would need to be an additional register for the "virtual subtraction" and a set of flags to hold the result. 0 0 0 0 0 0 0 0 FUNCTION REGISTER METHOD
Docsity logo



Copyright © 2024 Ladybird Srl - Via Leonardo da Vinci 16, 10126, Torino, Italy - VAT 10816460017 - All rights reserved