Chapter 1 & 2 Flashcards
(36 cards)
Machine Level 4
High-Level Language - application oriented languages which are compiled into assembly language
Ex: C++, Java
Machine Level 3
Assembly Language
- instruction mnemonics that have one-to-one correspondence to machine language
- Translated into ISA (level 2)
Machine Level 2
Instruction Set Architecture (ISA)
- AKA conventional machine language
- executed by level 1
Machine Level 1
Digital Logic
- CPU, system bus, memory
- all it does at hardware level is adding and comparing
MSB
Most Significant Bit
- leftmost bit
- in a byte, bit 15
LSB
Least significant bit
- rightmost bit
- bit 0
What indicates that a number is negative?
The highest bit is turned on
Binary Subtraction
Convert number to be subtracted to two’s complement (AKA additive inverse) and add
Flip the bits, add 1
Boolean Operators
NOT (weird L rotated 90 degrees)
AND ^
OR v
Boolean Operator Precedence
- NOT
- AND & OR
Use () to change precedence
Control Unit (CU)
- Part of the CPU
- Acts like a traffic cop, directing
Arithmetic Logic Unit (ALU)
- Part of the CPU
- Performs arithmetic
Clock
- Part of the CPU
- Synchronizes CPU operations
Bus
Set of connections that connects CPU to some other component on the motherboard
Data Bus
How memory is transported
Instruction Execution Cycle
- Fetch (brings data/instruction to CPU)
- Decode (sets it up to do something)
- Fetch operands
- Execute
- Store output
Cache
High speed memory location
Level 1: inside the CPU
Level 2: outside the CPU
Modes of Operation
- Protected mode - native mode (Windows, Linux)
- Real-address mode - native MS-DOS
- System management mode - power management, system security, diagnostics
- Virtual-8086 mode - hybrid of protected
EAX
Accumulator
ECX
Loop counter
ESP
Stack pointer
ESI, EDI
Index registers
EBP
Base pointer / frame pointer
Holds the base address of the stack frame
CS
Code segment