Blockchain Transaction Grouping via Atomic Arrays

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing blockchain technologies face inefficiencies in grouping transactions with read-write conflicts, which necessitate serial execution, leading to reduced throughput due to the time-consuming nature of traditional grouping algorithms.

Innovation Solution

A method and apparatus that utilize a shared memory to concurrently manage a belonging array and an associative array through atomic comparative change operations, allowing multiple threads to group transactions based on association relationships without complex data structure searches, thereby optimizing multi-CPU performance.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If a single thread groups transactions based on overlapping read-write sets, then the grouping can be performed sequentially, but the throughput rate is greatly restricted when there are tens of thousands of transactions

Engineering Contradiction:
Improvethroughput rateVSAvoidgrouping algorithm complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent divides the transaction grouping task into multiple independent segments that can be processed by different threads simultaneously. Each thread handles a subset of transactions and uses atomic operations to update shared data structures (belonging array and associative array), enabling parallel processing that significantly improves throughput rate

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent introduces atomic operations as intermediaries to coordinate access between multiple threads to shared memory structures. The atomic comparative change operation serves as a mediator that allows threads to safely update the belonging array and associative array without conflicts, enabling efficient parallel grouping

Inventive Principle:
Principle #24Intermediary (Mediator)

2Loss of time

If traditional grouping algorithms are used, then the read-write conflicts can be detected, but hundreds of milliseconds are needed for the grouping algorithm

Engineering Contradiction:
Improvegrouping timeVSAvoidtransaction processing speed
Core Design Contradiction:
Loss of timeVSProductivity

Solution Approach 1:

The patent performs preliminary actions by pre-establishing the belonging array and associative array data structures before transaction grouping begins. Transactions are processed in batches, and the atomic operations prepare the grouping results in advance, reducing the overall grouping time from hundreds of milliseconds to a much shorter duration

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent makes the grouping process dynamic by using atomic comparative change operations that can adaptively update the belonging array and associative array based on real-time transaction characteristics. This dynamic approach allows the system to efficiently handle varying transaction volumes and conflict patterns

Inventive Principle:
Principle #15Dynamics

Data Source

PatentEP3961431B1Method and apparatus for grouping transactions that need to be serially executed based on a sequence of transactions in one block of a blockchain
Publication Date: 2023.08.30 ALIPAY (HANGZHOU) INFORMATION TECH CO LTD
  • EP3961431B1 patent drawingFigure 1
  • EP3961431B1 patent drawingFigure 2
  • EP3961431B1 patent drawingFigure 3~5

AI summary

Implementations of the present specification provide a method and an apparatus for grouping transactions in a blockchain. The method includes: obtaining a first transaction in multiple transactions; obtaining a first variable accessed in the first transaction; reading a first value of a first belonging variable corresponding to the first variable; reading a first value of a first associated variable corresponding to the first transaction; if the first value of the first belonging variable is a numbering value of a second transaction in the multiple transactions, recording an association relationship between the first transaction and the second transaction in the associative array by performing an atomic comparative change operation on an atomic variable in an associative array; and grouping the multiple transactions based on the associative array.