NVMe Dual Port Command Load Balancing via Multi-Level Queues
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
The complexity of command management in solid-state drives (SSDs) leads to increased IO latency due to delays in processing read and write commands, particularly when multiple commands are issued from different queues and namespaces, causing uneven load distribution across ports and functions.
Innovation Solution
Implementing a multi-level queue system in the SSD controller's front end, where commands are categorized and scheduled using a round-robin or weighted round-robin approach to balance load across first-level queues based on categories and second-level queues based on command types, ensuring active commands are processed efficiently without being stuck behind larger data transfers.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Loss of time
If commands are processed in a single queue without categorization, then the device complexity is low, but the IO latency increases due to uneven load distribution
Solution Approach 1:
The patent divides the command processing system into multiple first-level queues organized in a tree structure, where each queue handles specific categories of commands. This segmentation allows different command types to be processed in parallel, reducing IO latency by preventing small commands from being blocked by large data transfers while managing complexity through structured organization.
2Productivity
If multiple first-level queues are implemented to categorize commands, then the IO latency is reduced through better load distribution, but the device complexity increases
Solution Approach 1:
The patent implements a nested queue structure where first-level queues contain multiple second-level queues, forming a tree hierarchy. This nesting allows commands to be routed through multiple levels of categorization (e.g., command type, then sub-type), improving processing efficiency by enabling fine-grained parallelism while managing complexity through hierarchical organization rather than flat management of numerous queues.
3Speed
If commands are strictly prioritized by size, then smaller data transfers are processed faster, but the device complexity increases due to scheduling mechanisms
Solution Approach 1:
The patent performs preliminary categorization of commands into different first-level queues based on command type and characteristics before processing. By pre-organizing commands into appropriate queues based on their size and type, the system ensures small commands are naturally positioned in queues that will be serviced more frequently, improving their processing speed without requiring complex real-time scheduling decisions during execution.
Data Source
AI summary
In an example, a method of processing commands for a non-volatile storage device includes storing the commands among a plurality of first-level queues in a random access memory (RAM). Each command is assigned to a first-level queue based on membership in one of a plurality of first-level categories. The method further includes removing selected commands from the plurality of first-level queues according to a first schedule and performing at least one operation on the selected commands. The method further includes storing the selected commands among a plurality of second-level queues in the RAM. Each selected command is assigned to a second-level queue based on whether the command is a read command or a write command. The method further includes removing active commands from the plurality of second-level queues according to a second schedule. The method further includes issuing the active commands to a back end of the controller for processing.


