Midterm 1 Review Sheet

	The first Midterm is a closed-book comprehensive 50-minute exam, 
covering everything in Chapters 1-5, in class, and in discussion.  You can 
bring 1 handwritten sheet of paper, (both sides OK).  No Calculators.  I will 
provide all the tables and raw data you need, so don't bother filling your 
sheet with that kind of stuff.  

	My tests are aimed at people who are familiar with the topic - this 
means the test will be much too long if you have not been doing the homeworks 
and practicing (if you need several minutes to convert from Hex to Binary, you 
are going to be in trouble).  Cramming is probably not useful - make sure you 
*understand* the stuff.  As was stated earlier, there are problems with answers
in the back of the book.  It would probably be a good idea to work those
problems and make sure you are getting the right answer.

	Good Luck!

*******************************************************************************

What you know at this point:

	A Transistor is an on-off switch, and is the basic building block which 
is used to build computers.  How can this work?  "Simple":  We have defined a 
set of  arbitrary meanings to groups of these 1's and 0's.  By consistently 
using and building upon these definitions, we are capable of building machines 
that can take us to the moon, become chess grand masters, fly our planes, drive 
our cars, balance our checkbooks, and make our heads hurt.

How do we represent these bit patterns?
    Binary, Octal, Decimal, Hex - know what these are, how to convert from one
	Base to another.

How do we group these bit patterns?
    bits (single switch), bytes (8 bits), words (multiple bytes), nibbles 
	(4 bits) 

What meanings have we given to these bit patterns?
    Numbers 
	Integers 
	    size/accuracy tradeoff (range) 
	    Unsigned, Sign-Magnitude, 1's Complement, 2's Complement 
	Reals 
	    Scientific Notation 
	    Floating Point 
	    Normalization, hidden one

    Characters 
	8 bits, ASCII, I/O

    Instructions 
	Types of instructions (operand, operate)
	Components of instructions (opcode, mode, operand)
	    Opcode 
	        Specifies which operation is to be performed (ADD, JUMP, etc.)
	    Mode
		Specifies which addressing mode is to be used (Direct,
			Immediate, Indexed, etc.)
	    Operands 
	        What are they?  (What gets operated on) 
	        Where are they?  (Addressing Modes) 
	        How big are they?  (Operand Size specifier) 

	How do we create/define instructions?  (OOMAAA)

    When does a given bit pattern become
	An instruction? 
		Upon entry into IR 
	A Number? 
		When used in a mode consistent with numbers 
	A character? 
		When used in a mode consistent with characters 

How do we configure a machine to interpret these assignments?
    Block level diagram of machine 
	I/O: Input/Output, how the user communicates with the hardware

	Memory:  Storage cells, addresses, bytes, words (addressable units)

	CPU: Control, ALU, some storage (registers)
	    Control (in charge of sequencing, changing PC) 
		Jumps, Flags, compare instructions
	    ALU (Arithmetic Logic Unit) 
		Adds, Logical instructions, sets flags
	    Registers (fast, expensive memory.  Number of them relates to 
		Instruction set)

    How do the blocks interact? 

    What sequence needs to be performed to cause program to execute? 
	Fetch	(PC used as address, IR <- memory[PC]) 
	Decode 	(PC incremented; Decode contents of IR) 
	Execute	(Perform operation defined by bit pattern in IR on specified  
			Operands) 

How do we generate the appropriate bit patterns?
    High level language -> Compiler -> Assembler 
	Assembler 
	    What is it, what does it do? 
	    What is Symbol Table? 
	    What is 1-pass vs. 2-pass assembly? 
	    What is an assembler directive?
	    What is the Location Counter?

    Linking 
	What is it? What kind of stuff has to be in header to support this? 

    Loading 
	What is it? 

    How do the source, list and object files differ? 

What is the Index Register, what is it used for?
    Why have indexing mode anyway?
    How does the XR work?
    How is this addressing mode specified?
    What are looping instructions?  Why are they useful?  (AOC, SOJ)
    How do arrays map to memory, what are the equations to help manage them?