25
Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control Muhammad Zeeshan Haider Ali Lecturer ISP. Multan [email protected] https://zeeshanaliatisp.wordpress.com/

Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

  • Upload
    others

  • View
    22

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Computer Organization and Assembly Language (CS-506)

Lecture 3

Microprocessor Bus Architecture

Data, Addressing and Control

Muhammad Zeeshan Haider Ali

Lecturer

ISP. Multan

[email protected]

https://zeeshanaliatisp.wordpress.com/

Page 2: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Today’s Agenda:

• System Bus

• Bus Interconnection

• Data, Address and Control Bus

• Bus Types

• Bus Arbitration

• Assignment

Page 3: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

System buses• Set of wires, that interconnects all the components

(subsystems) of a computer• A source component sources out data onto the bus

• A destination component inputs data from the bus

• May have a hierarchy of buses • Address, data and control buses to access memory and an I/O

controller.

• Second set of buses from I/O controller to attached devices/peripherals

• PCI bus is an example of a very common local bus

Page 4: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Bus Interconnection

• A CPU communicates with the other units using signals.

• These signals are of 3 types

Data

Address

Control

• These signals Travels along with set of parallel wires called buses.

• These buses connects the different components of Pc’s.

Page 5: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Bus Interconnection

• As signal generated by CPU there are three different buses used in Pc’s.

Data Bus

Address Bus

Control Bus

Page 6: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Data Bus

• Carries data• Remember that there is no difference between “data” and “instruction” at

this level

• Width is a key determinant of performance• 8, 16, 32, 64 bit

Page 7: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Address bus

• Identify the source or destination of data

• e.g. CPU needs to read an instruction (data) from a given location in memory

• Bus width determines maximum memory capacity of system• e.g. 8080 has 16 bit address bus giving 64k address space

Page 8: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Control Bus

• Control and timing information• Memory read/write signal

• Interrupt request

• Clock signals

Page 9: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Big and Yellow?

• What do buses look like?• Parallel lines on circuit boards

• Ribbon cables

• Strip connectors on mother boards• e.g. PCI

• Sets of wires

Page 10: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Single Bus Problems

• Lots of devices on one bus leads to:• Propagation delays

• Long data paths mean that co-ordination of bus use can adversely affect performance

• If aggregate data transfer approaches bus capacity

• Most systems use multiple buses to overcome these problems

Page 11: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Bus Interconnection

Page 12: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Physical Connectors.

Page 13: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Bus Types

• Dedicated• Separate data & address lines

• Multiplexed• Shared lines

• Address valid or data valid control line

• Advantage - fewer lines

• Disadvantages• More complex control

• Ultimate performance

Page 14: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Bus Arbitration

• More than one module controlling the bus• e.g. CPU and DMA controller

• Only one module may control bus at one time

• Arbitration may be centralised or distributed

Page 15: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Centralised Arbitration

• Single hardware device controlling bus access• Bus Controller

• Arbiter

• May be part of CPU or separate

Page 16: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Distributed Arbitration

• Each module may claim the bus

• Control logic on all modules

Page 17: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Timing

• Co-ordination of events on bus

• Synchronous• Events determined by clock signals

• Control Bus includes clock line

• A single 1-0 is a bus cycle

• All devices can read clock line

• Usually sync on leading edge

• Usually a single cycle for an event

Page 18: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Master / slave

• Broadly speaking, devices may be classified as:

• masters - those that initiate data transfers, or

• slaves - those that wait for requests;

• some devices can act as a bus master and a bus slave, but not at the same time.

Page 19: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Buses• What are the Bus design considerations?

• Accessibility

• Speed

• Reliability

• Extensibility

• Bottle necks

• Noise (electrical)

• Flexibility

• Ease of Interfacing

• Power

• Share ability

• Communication Protocol

• Length

Page 20: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Bus Interconnection

ISA Slow-speed devices like mouse, modem

PCI High-speed devices like hard disks and network cards

AGP Connects memory and graphics card for faster video

performance

USB Supports “daisy-chaining” eliminating the need for

multiple expansion cards; hot-swappable

IEEE 1394

(FireWire)

High-speed bus connecting video equipment to the

computer

PC Card Credit card sized PC card devices normally found on

laptops

Page 21: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

PCI Bus

• Peripheral Component Interconnection (PCI)

• Intel released to public domain

• 32 or 64 bit

• 50 lines

Page 22: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

PCI Bus Lines (required)

• Systems lines• Including clock and reset

• Address & Data• 32 time mux lines for address/data• Interrupt & validate lines

• Interface Control

• Arbitration• Not shared• Direct connection to PCI bus arbiter

• Error lines

Page 23: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

PCI Bus Lines (Optional)

• Interrupt lines• Not shared

• Cache support

• 64-bit Bus Extension• Additional 32 lines

• Time multiplexed

• 2 lines to enable devices to agree to use 64-bit transfer

• JTAG/Boundary Scan• For testing procedures

Page 24: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

PCI Commands

• Transaction between initiator (master) and target

• Master claims bus

• Determine type of transaction• e.g. I/O read/write

• Address phase

• One or more data phases

Page 25: Computer Organization and Assembly Language (CS-506)€¦ · Computer Organization and Assembly Language (CS-506) Lecture 3 Microprocessor Bus Architecture Data, Addressing and Control

Assignment.

• Bus Protocols• Asynchronous• Synchronous• Memory Read / Writes ?• I/O Read Writes?• Peer communication – e.g. CPU to CPU• Are communications verified?• Is there error checking ?

You are Required to Discuss these bus protocols in detail.