Docsity

Memory Scheduling in Advanced Computer Architecture: Dynamic Scheduling and Solutions, Lab Reports of Electrical and Electronics Engineering

Partial preview of the text

Download Memory Scheduling in Advanced Computer Architecture: Dynamic Scheduling and Solutions and more Lab Reports Electrical and Electronics Engineering in PDF only on Docsity!

Dynamic Memory Scheduling Dynamic Memory Scheduling

EECS 470: Computer Architecture

Lecture Overview Lecture Overview

  • Dynamic Scheduling Overview
  • The Memory Scheduling Problem
  • Conventional Solutions
    • In-order Load/Store Scheduling
    • Blind Dependence Scheduling
    • Conservative Dataflow Scheduling
  • Recent Developments
    • Memory Dependence Speculation
    • Memory Renaming
  • Future Directions

Dynamic Scheduling Pipeline Dynamic Scheduling Pipeline

IF ID REN CT

In-order

Dispatch

In-order

Commit

Out-of-order

Execute

Dynamic Scheduler

(One) Dynamic Scheduler Implementation (One) Dynamic Scheduler Implementation

Scheduler

Logic

Results

Input/Result Networks

Reservation Stations

Inputs Network Control Valid Bits

Tag Tag

V

V

Value Value Op Flags

  • synchronization managed by scheduler logic
  • communication through input/output networks
  • infrastructure geared towards register communication

The Memory Scheduling Problem The Memory Scheduling Problem

  • loads/stores also have dependencies through memory
    • described by effective addresses
  • cannot directly leverage existing infrastructure
    • indirectly specified memory dependencies
      • dataflow schedule is a function of program computation, prevents accurate description of communication early in the pipeline
      • pipelined scheduler slow to react to addresses
    • large communication space (232-64^ bytes!)
      • cannot fully map communication space, requires more complicated cache and/or store forward network

Requirements for a Solution Requirements for a Solution

  • accurate description of memory dependencies
    • no (or few) missing or false dependencies
    • permit realization of dataflow schedule
  • early presentation of dependencies
    • permit pipelining of scheduler logic
  • fast access to communication space
    • preferably as fast as register communication (zero cycles)

In-order Load/Store Scheduling In-order Load/Store Scheduling

  • schedule all loads and stores in

program order

  • cannot violate true data dependencies (non- speculative)
  • capabilities/limitations:
  • not accurate - may add many false dependencies
  • early presentation of dependencies (no addresses)
  • not fast, all communication through memory structures
  • found in in-order issue pipelines

st X ld Y st Z ld X ld Z

true realized

Dependencies

program order

ld Y

st X st X

In-order Load/Store Scheduling Example In-order Load/Store Scheduling Example

st X ld Y st Z ld X ld Z

true realized

Dependencies

program order

time

ld Y st Z ld X ld Z

st Z ld X ld Z

ld Y

st X

st Z ld X ld Z

ld Y

st X

st Z ld X ld Z

ld Y

st X

st Z ld X ld Z

ld Y

st X st X

Blind Dependence Speculation Example Blind Dependence Speculation Example

st X ld Y st Z ld X ld Z

true realized

Dependencies

program order

time

ld Y st Z ld X ld Z

st Z ld X ld Z

ld Y

st X

st Z ld X ld Z

ld Y

st X

st Z ld X ld Z

ld Y

st X

st Z ld X ld Z

mispeculation

detected!

Questions Questions

  • Suggest two ways to detect blind load mispeculation
  • Suggest two ways to recover from blind load mispeculation

Conservative Dataflow Scheduling Conservative Dataflow Scheduling

  • schedule loads and stores when all

dependencies known satisfied

  • conservative - won’t violate true dependencies (non-speculative)
  • capabilities/limitations:
  • accurate only if addresses arrive early
  • late presentation of dependencies (verified with addresses)
  • not fast, all communication through memory and/or complex store forward network
  • common for larger windows

st X ld Y st?Z ld X ld Z

true realized

Dependencies

program order

ld Y

st X st X

Conservative Dataflow Scheduling Conservative Dataflow Scheduling

st X ld Y st?Z ld X ld Z

true realized

Dependencies

program order

time

ld Y st?Z ld X ld Z

st?Z ld X ld Z

ld Y

st X

st?Z ld X ld Z

ld Y

st X

st Z ld X ld Z

ld Y

st X

st Z ld X ld Z

ld Y

st X

st Z ld X ld Z

Z

stall cycle

Lecture Overview Lecture Overview

  • Dynamic Scheduling Overview
  • The Memory Scheduling Problem
  • Conventional Solutions
    • In-order Load/Store Scheduling
    • Blind Dependence Scheduling
    • Conservative Dataflow Scheduling
  • Recent Developments
    • Memory Dependence Speculation [Moshovos97]
    • Memory Renaming [Tyson/Austin97]
  • Future Directions

Memory Dependence Speculation Memory Dependence Speculation [Moshovos97][Moshovos97]

  • schedule loads and stores when data

dependencies satisfied

  • uses dependence predictor to match sourcing stores to loads
  • doesn’t wait for addresses, may violate true dependencies (speculative)
  • capabilities/limitations:
  • accurate as predictor
  • early presentation of dependencies (data addresses not used in prediction)
  • not fast, all communication through memory structures

st?X ld Y st?Z ld X ld Z

true realized

Dependencies

program order