Hardware Locking System for Multi-Threaded Resource Sharing

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing computer systems face inefficiencies in managing access to hardware resources due to the overhead of software locks, particularly in multi-threaded and multi-processor environments, where conventional mechanisms are burdensome and limit performance advantages of hardware accelerators and asynchronous hardware resources.

Innovation Solution

A hardware locking system that uses data structures and logic within the computer system to actively manage locks, involving control bits, control registers, and waiting lists, allowing hardware resources to participate in lock management, reducing the need for extensive operating system involvement and minimizing context switching overhead.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If software locks are used to manage hardware resource access, then exclusive access is ensured, but system performance deteriorates due to lock acquisition and release overhead

Engineering Contradiction:
Improveexclusive accessVSAvoidsystem performance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent replaces the software-based lock management mechanism with a hardware-based locking mechanism. The hardware lock uses dedicated hardware circuits and memory locations to manage access to shared hardware resources, eliminating the need for software locks and their associated overhead. This substitution of mechanical (software) system with hardware system directly addresses the contradiction by ensuring exclusive access through hardware enforcement while eliminating lock acquisition/release overhead that degraded system performance.

Inventive Principle:
Principle #28Mechanics substitution (Replace mechanical system)

Solution Approach 2:

The hardware lock mechanism enables self-service by allowing the hardware resource itself to manage its own access control. The locked hardware resource automatically enforces exclusivity through hardware-level signaling and blocking mechanisms, without requiring continuous software intervention. This self-service capability maintains reliable exclusive access while minimizing the operational overhead typically associated with software lock management.

Inventive Principle:
Principle #25Self-service

2Productivity

If hardware resources are made asynchronous for true parallelism, then processing efficiency improves, but access control complexity increases

Engineering Contradiction:
Improveprocessing efficiencyVSAvoidaccess control complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent segments the access control function by creating separate hardware lock mechanisms for different hardware resources. Each hardware resource has its own dedicated lock circuitry, allowing independent control and management. This segmentation enables asynchronous operation of multiple resources without creating a single point of complexity, as each resource's access control is isolated and can be managed independently, thus maintaining processing efficiency while controlling overall system complexity.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The hardware lock acts as an intermediary between the asynchronous hardware resource and the software thread requesting access. This intermediary hardware layer handles the complexity of coordination and exclusivity enforcement, allowing the hardware resource to operate asynchronously for improved processing efficiency while the hardware lock mediator manages the access control complexity that would otherwise burden the software system.

Inventive Principle:
Principle #24Intermediary (Mediator)

3Productivity

If multiple threads share hardware resources, then resource utilization increases, but race conditions and conflicts increase

Engineering Contradiction:
Improveresource utilizationVSAvoidrace conditions
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The hardware lock mechanism provides beforehand cushioning by establishing exclusive access rights before a thread actually uses the hardware resource. The lock is acquired in advance, and the hardware circuitry maintains this exclusive state throughout the resource access period, preventing race conditions from occurring. This preemptive protection enables multiple threads to share hardware resources efficiently while cushioning against the risks of race conditions and conflicts.

Inventive Principle:
Principle #11Beforehand cushioning (Prior cushioning)

Solution Approach 2:

The hardware lock incorporates feedback mechanisms where the locked hardware resource continuously signals its locked state to requesting threads through hardware-level signals. This feedback allows the system to dynamically manage access, grant resources to waiting threads when appropriate, and maintain exclusivity without requiring complex software-based race condition detection and prevention, thus improving resource utilization while maintaining reliability.

Inventive Principle:
Principle #23Feedback

Data Source

PatentUS8726279B2System for multi threaded multi processor sharing of asynchronous hardware units
Publication Date: 2014.05.13 NVIDIA CORP
  • US8726279B2 patent drawing
  • US8726279B2 patent drawing
  • US8726279B2 patent drawing

AI summary

Methods and system for sharing a hardware resource in a computer system running at least one software process having multiple threads. A lock_indicator is provided in data structures within the computer system. A request is received to use the hardware resource by one of the threads that is defined to be a requesting tread. Based on the lock_indicator, it is determined whether the hardware resource is available for use by the requesting thread. If this indicates that the hardware resource is available, the lock_indicator is set under control of the hardware resource to instead indicate that the hardware resource is unavailable, and a go_indicator signals to indicate that use of the hardware resource for the request can now proceed.