Message Transmitting Queue with Flag-Based Coordination

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

In multi-threaded systems, message misplacement or overlap occurs when using general serial queues due to the size of transmitted messages exceeding atomic data read/write size, leading to inefficiencies and performance issues, which are compounded by the need for complex software semaphores to prevent these problems.

Innovation Solution

A buffer device with a message transmitting queue that includes multiple message rows, each with write and distribution complete flags, a write control unit, and a read control unit, which manages message storage and retrieval to prevent misplacement and overlap without using semaphores, by sequentially outputting free message row addresses and issuing read requests based on complete flags.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Device complexity

If a general serial queue with only write pointer and read pointer is used, then the structure is simple, but message misplacement or overlap occurs in multi-threaded systems

Engineering Contradiction:
Improvequeue structureVSAvoidmessage transmission reliability
Core Design Contradiction:
Device complexityVSReliability

Solution Approach 1:

The patent divides the message transmission process into distinct phases by segmenting the queue structure into multiple message rows, each with independent write complete flags and distribution complete flags. This segmentation allows multiple threads to operate on different message rows simultaneously without interference, preventing message misplacement and overlap while maintaining structural clarity.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent introduces complete flags as intermediary elements between the write pointer/read pointer and the actual message data. These flags act as mediators that coordinate the writing and reading operations, ensuring that a message is fully written before being marked for distribution and preventing overlap between concurrent threads without requiring complex semaphore mechanisms.

Inventive Principle:
Principle #24Intermediary (Mediator)

2Reliability

If semaphore is used to prevent message overlap, then message transmission reliability is improved, but software operation complexity increases and system performance is impacted

Engineering Contradiction:
Improvemessage transmission reliabilityVSAvoidsoftware operation complexity
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The patent implements self-service by allowing the queue structure itself to manage thread coordination through its built-in complete flags. The write complete flags automatically signal when a message is fully written, and the distribution complete flags coordinate reading operations, eliminating the need for external semaphore mechanisms and reducing software operational complexity.

Inventive Principle:
Principle #25Self-service

Solution Approach 2:

The patent extracts the coordination function from complex software semaphore operations and embeds it directly into the queue hardware structure through complete flags. This extraction simplifies software operations by removing the need for manual semaphore manipulation while maintaining reliable message transmission through the flag-based coordination mechanism.

Inventive Principle:
Principle #2Taking out (Extraction)

3Reliability

If the write pointer cannot move until message writing completes, then data integrity is maintained, but system throughput is reduced in multi-threaded environments

Engineering Contradiction:
Improvedata integrityVSAvoidsystem throughput
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent applies dynamics by making the write pointer movement conditional rather than blocking. The write pointer can advance to the next message row as long as the current message row's write complete flag is set, allowing overlapping operations between threads. This dynamic approach maintains data integrity through flag verification while significantly improving throughput by eliminating unnecessary blocking.

Inventive Principle:
Principle #15Dynamics

Solution Approach 2:

The patent implements preliminary action by setting the write complete flag before the write pointer moves to the next message row. This preliminary flag setting allows the write pointer to advance proactively without waiting for the actual read operation to complete, enabling overlapping write and read operations across different message rows and improving system throughput while maintaining data integrity.

Inventive Principle:
Principle #10Preliminary action

Data Source

PatentUS7779083B2Message transmitting queue and associated method
Publication Date: 2010.08.17 VIA TECH INC
  • US7779083B2 patent drawing
  • US7779083B2 patent drawing
  • US7779083B2 patent drawing

AI summary

A message transmitting queue delivers messages between a source controller and a destination controller. According to the message transmitting request of the source controller, sequentially distribute the free message row of the message transmitting queue, and set the message row to the distributed state. After the source controller writes the message of the message row, set the message row to the written state. At this moment, when the message row is in the position that is read sequentially by the destination controller, a read request is issued, so that the destination controller reads the message according to the read request when the reading completes, clears the distributed signal and the written signal, so that the message row goes back to the free state. When the message transmitting queue has no free message row, a no free message row signal to inform the source controller is issued.