Store Queue with Store-Marks for Ordered Unordered Stores
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
The disparity between microprocessor clock speeds and memory access speeds leads to significant performance issues in computer systems, with existing store queue designs inefficiently managing cache misses and interfering accesses, resulting in prolonged idle times for processors.
Innovation Solution
A processor system that creates a store queue with thread-level buffers and cache line records, using store-marks to manage cache lines, allowing for merging of stores without violating memory models like TSO, and providing bounded-time responses to read-after-write bypasses and forward-progress requests.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If stores are placed in a store queue in program order, then memory consistency is maintained, but memory access time increases and processor idle time increases
Solution Approach 1:
The patent implements a dynamic store queue that can switch between ordered and unordered record modes based on cache line store-mark status. When a cache line is store-marked, the system uses ordered records to maintain memory consistency. When not store-marked, it uses unordered records to allow reordering and merging, thereby reducing processor idle time while maintaining reliability only when necessary.
Solution Approach 2:
The system changes the ordering parameter of store records dynamically based on the cache line's store-mark status. This parameter change allows the store queue to adapt its behavior - maintaining strict ordering when consistency is required (store-marked) and allowing reordering when performance optimization is safe (not store-marked), thus resolving the contradiction between reliability and time loss.
2Loss of energy
If stores are merged in the store queue, then memory bandwidth is reduced, but complexity of managing store order increases
Solution Approach 1:
The patent segments the store queue into two distinct data structures: ordered records and unordered records. This segmentation allows the system to apply different management strategies to different sets of stores. Unordered records can be freely merged to reduce memory bandwidth usage, while ordered records maintain strict sequencing when needed, simplifying the overall management complexity by clearly defining when merging is safe.
Solution Approach 2:
The store-mark mechanism acts as an intermediary that mediates between the conflicting requirements of store merging and order maintenance. When a cache line is store-marked, it signals that ordering must be preserved; when not store-marked, it permits merging. This intermediary mechanism simplifies the complexity by providing a clear, binary control signal that automatically adjusts store queue behavior without requiring complex decision logic.
3Reliability
If the processor waits for cache miss completion, then memory access accuracy is ensured, but processor productivity decreases
Solution Approach 1:
The patent implements preliminary actions by placing stores in the store queue with ordered or unordered records before actual memory access completion. The system prepares store data in advance, organizing it into appropriate record types based on cache line status, so that when memory access completes, the data is ready for immediate processing without requiring the processor to wait idle, thus maintaining accuracy while improving productivity.
Solution Approach 2:
By using unordered records for non-store-marked cache lines, the system enables continuous processor execution without waiting for memory access completion. The store queue continuously processes and merges stores in the background, allowing the processor to maintain productive work while memory operations complete asynchronously, ensuring accuracy is ultimately maintained while eliminating idle wait time.
Data Source
AI summary
Some described embodiments provide a system that performs stores in a memory system. During operation, the system receives a store for a first thread. The system then creates an entry for the store in a store queue for the first thread. While creating the entry, the system requests a store-mark for a cache line for the store, wherein the store-mark for the cache line indicates that one or more store queue entries are waiting to be committed to the cache line. The system then receives a response to the request for the store-mark, wherein the response indicates that the cache line for the store is store-marked. Upon receiving the response, the system updates a set of ordered records for the first thread by inserting data for the store in the set of ordered records, wherein the set of ordered records include store-marked stores for the first thread.


