CS 3853 Computer Architecture Tomasulo Activity - Reservation Station Load and Store
The reservation stations for memory are often called
Load Buffers and
Store Buffers.
They behave much like the reservation stations for the functional units.
Such a reservation station has two inputs that are used to calculate an address and a register index for the source or destination.
We will only consider floating point loads and stores.
- The two address inputs are an offset and an integer register number.
- The offset and the register value are added to get an effective address.
We assume that this is done with a dedicated ALU in one cycle so there is no contention.
Since we are looking at only floating point operations,
we assume the (integer) register value is always available from the register file.
- Each reservation station has an ID: Load1, Load2, Load3, ..., Store1, Store2, Store3, ...
Initialization: Mark yourself free
Inputs: You are given:
- An immediate value and a base register index
- A source (if load) or destination (if store) register index
On Issue Load:
- Mark yourself busy
- Calculate the effective address
- Reserve the destination register by giving the register file your ID and the destination register number.
After Issue Load:
- If the effective address is in a store buffer and the value is a reservation station ID:
reserve the appropriate floating point register for that reservation station ID
mark yourself free.
you are done.
- If the effective address is in a store buffer, use the value from that store buffer
Otherwise, read the result from memory (wait for it to be available).
- Put the value along with your reservation station ID on the CDB.
- Mark yourself free
Skip stores for now, we will just be doing loads
On Issue Store:
- Mark yourself busy
- Calculate the effective address
- Get the source register value from the register file
After Issue Store:
- If the source register value is a reservation station ID, monitor the CDB for values until it is ready.
- Write the value to memory.
- Mark yourself free