Skip to content
STIMSMITH

Load-Store Unit

Concept WIKI v1 · 5/28/2026

A Load-Store Unit is the execution-stage functional unit responsible for load and store memory operations in the cited RISC-V superscalar processor. In that design, it is a two-cycle pipelined module containing the data cache and surrounding logic; it computes addresses, handles load forwarding checks, accesses or stalls on the data cache, and delays store updates until the store is non-speculative at the head of the reorder buffer.

Overview

In the cited RISC-V superscalar processor, the Load-Store Unit is one of the functional units in the execution stage, alongside the integer ALU and the branch resolve unit. The execution stage also includes data-routing logic needed to connect instructions to these functional units.

The Load-Store Unit is described as a two-cycle pipelined module that contains the data cache and its surrounding logic. It handles memory-access instructions, with distinct behavior for stores and loads.

Pipeline behavior

Store operations

For store instructions, the first Load-Store Unit stage calculates the target address. Stores are not allowed to modify memory immediately: they may update memory only after they have been deemed non-speculative. In the cited processor, this happens when the store reaches the head of the reorder buffer (ROB).

Load operations

For load instructions, the first stage calculates the address and checks whether the load can be forwarded from the ROB. If no forwarding hit occurs, the load is routed to the second pipeline stage.

The second stage mainly consists of the data cache and associated logic. In this stage, information is retrieved from the pipeline register, and the instruction is either served directly, pushed into the data cache, or stalled while waiting.

Relationship with the reorder buffer

The reorder buffer supports out-of-order completion while enforcing in-order commit. It also tracks speculative instructions. This tracking is specifically used for store instructions, because stores must not modify cache contents until they are non-speculative.

Verification targeting

The cited verification work describes a random instruction generator that can be configured to generate direct tests targeting the Load/Store Unit. Setting load and store instruction probabilities to 50 produces load/store-heavy instruction sequences, such as combinations of address setup instructions with LW, SH, SW, LHU, and LBU operations.

The same generator includes a memory-access address dependency parameter, defined as the probability of generating a load/store instruction pair targeting the same memory address. This makes load/store address interactions an explicit part of verification stimulus generation.

CITATIONS

8 sources
8 citations
[1] The execution stage of the cited RISC-V superscalar processor includes the integer ALU, branch resolve unit, and Load-Store Unit. [PDF] UVM-based verification of RISC-V superscalar processors
[2] The Load-Store Unit is a two-cycle pipelined module containing the data cache and surrounding logic. [PDF] UVM-based verification of RISC-V superscalar processors
[3] For stores, the first Load-Store Unit stage calculates the address, and stores may modify memory only after becoming non-speculative at the ROB head. [PDF] UVM-based verification of RISC-V superscalar processors
[4] For loads, the first stage calculates the address and checks for possible forwarding from the ROB; absent a hit, the load proceeds to the second stage. [PDF] UVM-based verification of RISC-V superscalar processors
[5] The second Load-Store Unit stage mainly consists of the data cache and related logic, where an instruction may be served directly, pushed into the data cache, or stalled. [PDF] UVM-based verification of RISC-V superscalar processors
[6] The ROB enables in-order commit despite out-of-order completion and tracks speculative instructions, which is used to prevent stores from modifying cache contents before they are non-speculative. [PDF] UVM-based verification of RISC-V superscalar processors
[7] The random instruction generator can be configured to create direct tests targeting the Load/Store Unit by setting load and store probabilities, producing load/store instruction sequences. [PDF] UVM-based verification of RISC-V superscalar processors
[8] The generator includes a memory-access address dependency parameter for generating load/store instruction pairs targeting the same memory address. [PDF] UVM-based verification of RISC-V superscalar processors