Computer composition principle quick, easy to understand, quick review at the end of the term

Principles of Computer Composition

computer unit of calculation

  • capacity unit
    insert image description here
    insert image description here
  • speed unit
    insert image description here
    insert image description here
    insert image description here
    insert image description here

I/O system

insert image description here

insert image description here
insert image description here
insert image description here
insert image description here
insert image description here

Communication between CPU and IO device

CPU speed is inconsistent with IO device speed

  • Disadvantages of program interruption
    insert image description here
    insert image description here
    : reduce the execution efficiency of the CPU

  • DMA (Direct Memory Access)
    insert image description here

Classification of memory

  • Classification by storage medium:

    • Semiconductor memory: memory, U disk, solid state drive
    • Magnetic Storage: Tape, Disk
  • By access method:

    • Random Access Memory (RAM): Random reads, independent of position
    • Serial memory: location dependent, lookup in order
    • Read Only Memory (ROM): Read only, not write

memory hierarchy

cache, main memory, auxiliary memory

insert image description here

  • Principle: Locality principle
    Replace the memory frequently accessed by the program to the cache to improve the speed of the computer
  • Implementation: Add a layer of fast (small capacity) Cache between CPU and main memory
  • Purpose: To solve the problem of insufficient main memory speed

insert image description here

insert image description here

insert image description here

insert image description here

computer cache

insert image description here

insert image description here

insert image description here

  • example

insert image description here

insert image description here

insert image description here

insert image description here

computer command system

  • form of machine instructions

insert image description here
insert image description here

insert image description here

insert image description here

  • The type of operation of the machine instruction
    • Control instructions, shift operations, data transfers, arithmetic and logic operations
  • Addressing of machine instructions
    • Instruction addressing: sequential addressing, jump addressing
    • Data addressing: immediate addressing, indirect addressing, direct addressing

insert image description here
insert image description here
insert image description here

  • Advantages and disadvantages of various addressing modes

insert image description here

computer controller

The controller coordinates and controls the operation of the computer

  • program counter
    insert image description here

  • Timing generator (the CPU's metronome)
    insert image description here

  • instruction decoderinsert image description here

  • various registers

    • instruction register
      insert image description here

    • main memory address register
      insert image description here

    • Main memory data register
      insert image description here

    • general purpose register
      insert image description here

  • bus

computer calculator

The calculator is used to perform data operation and processing

  • data buffer
    insert image description here

  • ALU
    insert image description here

  • general purpose register
    insert image description here

  • Status word register
    insert image description here

  • bus

Execution of computer instructions

  • instruction execution process
    insert image description here
    insert image description here
    insert image description here

  • CPU pipeline design
    insert image description here

insert image description here
Ideally, pipeline efficiency is three times that of serial

Basics of base arithmetic

insert image description here

  • Signed and unsigned numbers
  • original code notation
    insert image description here
  • two's complement notation
    insert image description here
  • one's complement notation
    insert image description here
  • Original code, complement code, inverse code conversion
    insert image description here

IEEE754 standard

insert image description here

insert image description here

Fixed and floating point numbers

  • How to represent fixed point numbers
    insert image description here
    insert image description here

  • Representation of floating point numbers
    insert image description here
    insert image description here
    insert image description here
    insert image description here
    insert image description here
    insert image description here
    insert image description here
    insert image description here

  • Fixed point vs floating point
    insert image description here
    insert image description here

Addition and Subtraction of Fixed Point Numbers

insert image description here
insert image description here
insert image description here
insert image description here

Addition and subtraction of floating point numbers

insert image description here

insert image description here
insert image description here
insert image description here
insert image description here
insert image description here
insert image description here
insert image description here
insert image description here
insert image description here
insert image description here

Multiplication and division of floating point numbers

  • Multiplication : addition of exponents, product of mantissas
  • Division : Subtract the exponents, and obtain the quotient of the mantissas

practice

insert image description here

  • Implement doubly linked list
    insert image description here

  • Implement the permutation algorithm
    insert image description here

insert image description here
insert image description here

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324291842&siteId=291194637