Patents
Literature
Patsnap Eureka AI that helps you search prior art, draft patents, and assess FTO risks, powered by patent and scientific literature data.

13 results about "Readers–writer lock" patented technology

In computer science, a readers–writer (single-writer lock, a multi-reader lock, a push lock, or an MRSW lock) is a synchronization primitive that solves one of the readers–writers problems. An RW lock allows concurrent access for read-only operations, while write operations require exclusive access. This means that multiple threads can read the data in parallel but an exclusive lock is needed for writing or modifying data. When a writer is writing the data, all other writers or readers will be blocked until the writer is finished writing. A common use might be to control access to a data structure in memory that cannot be updated atomically and is invalid (and should not be read by another thread) until the update is complete.

Socket interface multi-task coordinated parasitic parameter extraction method and system

The invention provides a parasitic parameter extraction method and system for Socket interface multi-task coordination, and belongs to the technical field of parasitic parameter extraction. The method comprises the following steps: acquiring and analyzing an initial configuration file, and creating a read-write lock mechanism of a process pool and a global task coordination table; establishing non-blocking transmission control protocol monitoring, and mapping a Socket connection handle established by the sub-process and the host process to a global task coordination table; executing parasitic parameter extraction by utilizing the screened sub-processes, and generating a parasitic parameter result data packet after the extraction is completed; and performing Hash abstract verification, and if the Hash abstract verification is passed, marking the task corresponding to the parasitic parameter result data packet as completion and recording the extracted parasitic parameter. According to the method, a traditional file synchronization mechanism is replaced based on non-blocking Socket communication and an event-driven model, so that the inter-process communication efficiency is remarkably improved; and by adopting read-write lock hierarchical control and atomic operation, the utilization rate of hardware resources is effectively improved.
Owner:青岛展诚科技有限公司

A configurable read-write priority strategy read-write lock implementation method of an MMU-free embedded real-time operating system

The application discloses a configurable read-write priority strategy read-write lock implementation method of an MMU-free embedded real-time operating system, and comprises the following steps: S1, performing strategy binding in a read-write lock creation stage; S2, realizing atomic operation in a middle-off mode; S3, actively eliminating writer starvation in a write priority mode; S4, performing priority inheritance when a write lock is applied; S5, adopting a double-waiting queue separation design; S6, adopting static memory pool zero dynamic allocation; and S7, adopting single-field tri-state encoding to mark a lock state. The configurable read-write priority strategy read-write lock implementation method of the MMU-free embedded real-time operating system realizes lightweight configurable read-write locks of the MMU-free embedded real-time operating system, can support flexible configuration of read / write priority strategies and has zero runtime switching overhead in the whole process, does not need special hardware instructions and MMU context support, and is perfectly compatible with low-end MCUs without exclusive access capability, such as Cortex-M0 / M0+.
Owner:HUNAN BOJIANG INFORMATION TECHNOLOGY CO LTD

Using atomic operations to implement a read-write lock

A processing device maintains locking data including a first portion indicating whether a write operation is updating a data item or awaiting to update the data item, and a second portion indicating a number of read operations accessing the data item. A first read operation to the read the data item is received. a first locking condition is determined to be satisfied using the locking data, representing that no write operations are updating the data item or awaiting to update the data item. Responsive to the determination the first locking condition is satisfied, the second portion of the locking data is atomically incremented to reflect the number of read operations reading the data, and the first read operation to read the data is executed.
Owner:NVIDIA CORP

Business data caching and reporting method suitable for remote terminal of Internet of Things

The invention discloses a business data caching and reporting method suitable for an internet of things remote terminal, which comprises the following steps of: constructing a persistent cache architecture and initializing: adopting local file mapping as a cache carrier to realize data persistence; circular caching and data adding: managing a plurality of service cache blocks by adopting a circular queue; multi-concurrent sending queue and service routing: designing a multi-concurrent sending queue adaptive to the bandwidth and the processing capability of the Internet of Things terminal, and adaptively selecting a reporting channel according to the service data type; timed scheduling and dynamic timeout processing: realizing real-time maintenance of a sending queue through a timed polling and dynamic timeout mechanism; dual-mode data deletion and cache self-arrangement: realizing automatic arrangement of cache blocks through two deletion modes of temporary recovery and thorough deletion, and hierarchical concurrency control: adopting hierarchical control of a mutual exclusion lock and a read-write lock to distinguish write operation and read operation; the problems of cache data loss, low sending efficiency, resource competition and the like after the terminal is powered off and restarted are solved.
Owner:CHENGDU STAR WEIXUN TECHNOLOGY CO LTD

Thread processing method and device

The embodiment of the invention provides a thread processing method and device, relates to the technical field of computers, and can solve the problem of priority inversion in a read-write lock scene and improve the execution efficiency of threads. The method is applied to the electronic equipment, the electronic equipment comprises a target processor, the target processor comprises a target operation queue, the target operation queue comprises a first thread, a second thread and a third thread, and the method comprises the steps that under the condition that the first thread holds a read lock of a target resource, the second thread enters a sleep state and is not cleared from the target operation queue; under the condition that the first thread releases the read lock of the target resource, the second thread is awakened and holds the write lock of the target resource; after the second thread runs, the third thread runs, and the priority of the third thread is lower than that of the second thread and higher than that of the first thread.
Owner:HONOR DEVICE CO LTD

Read-write lock method and system with enhanced read performance, storage medium and product

The invention discloses a read-write lock method and system with enhanced read performance, a storage medium and a product, relates to the technical field of high-performance concurrency control, and aims to solve the problem that the read performance of a read-write lock is delayed due to high-frequency atomic operation in related technologies. The method comprises the following steps: constructing a thread read-write lock containing a non-atomic read control word and an atomic write control word for each read-write thread, and storing all the thread read-write locks into a global lock queue for unified management. When the read lock is obtained, the thread only needs to operate the own thread read-write lock, and atomic operation competition between read threads is avoided by checking the atomic write control word and setting the read state in a non-atomic manner. When the write lock is obtained, all thread read-write locks in the global lock queue need to be traversed and locked, so that the data consistency is ensured. According to the method and the device, the read-write lock which is independently written through the non-atomic read operation is constructed, so that the multi-thread read-write lock is constructed, and the delay of read operation performance in a high-concurrency scene is reduced.
Owner:SHENZHEN TINYSOFT CO LTD

Lock mechanism-based paas platform business document number generation method and system

The application provides a PaaS platform business document number generation method and system based on a lock mechanism. The method according to the application comprises the following steps: S1: judging whether a serial number counter in a PaaS platform needs to be reset, and selecting to execute step S2 or step S3 according to a judgment result; S2: taking a number model ID as a lock key and applying for a write lock based on the judgment result, and selecting to execute step S3 or re-execute step S1 according to a write lock locking result; S3: taking the number model ID as the lock key and applying for a read lock based on the judgment result, and generating a PaaS platform business document number according to a read lock locking result, or re-executing step S1. The application effectively solves the problem of business document number generation in a high-concurrency scenario by using a read-write lock mechanism, flexible number rule configuration and an efficient serial number generation strategy, improves the concurrent processing capacity, accuracy and maintainability of the system, and is suitable for various business scenarios that need to automatically generate unique numbers.
Owner:和创(北京)科技股份有限公司

Self-adaptive read-write lock partition optimization method and device, equipment and storage medium

The invention relates to the field of data processing, and discloses a self-adaptive read-write lock partition optimization method, device and equipment and a storage medium, and the method is used for dynamically adapting to data segmentation cold and hot adjustment and guaranteeing cross-segment writing safety. The method comprises the following steps: continuously collecting real-time access indexes of each data segment protected by a read-write lock; dynamically analyzing and identifying a hot data segment and a cold data segment based on the change trend of the real-time access index in a plurality of continuous acquisition periods; local structure adjustment strategies corresponding to the hot data segments and the cold data segments are generated respectively; adjusting the hot data segment and the cold data segment based on a local structure adjustment strategy, and in the adjustment process, when a cross-segment write operation related to a plurality of data segments is triggered, identifying a target data segment related to the cross-segment write operation, obtaining global locking based on a sequence coordination and failure retry mechanism of a write intention lock, and obtaining a target data segment related to the target data segment; and temporarily freezing the structure adjustment of the target data segment, and uniformly releasing the resources and updating the state after writing is completed.
Owner:JIHUA LAB

File read / write method, device and equipment in distributed file system

ActiveCN116226041BTroubleshoot technical issues with slow read/write performanceFile system administrationFile access structuresPathPingDistributed File System
This invention provides a file read / write method, apparatus, and device in a distributed file system to solve the technical problem of low file read / write performance caused by snapshot lock mutual exclusion contention in distributed systems. Without snapshot processing, this invention allows ordinary read / write IO to acquire only the read / write lock of the parent directory of the file being read / written, effectively reducing mutual exclusion lock contention and IO latency involved in snapshot processing. Furthermore, to ensure the reliability of snapshot services, a pre-check process is added to the snapshot configuration process. This pre-check process ensures that no read / write requests acquiring non-full path snapshot locks begin snapshot processing. This invention reduces mutual exclusion contention for snapshot locks in MDS, improves file read / write performance in distributed file systems, and guarantees the reliability of snapshot configuration.
Owner:XINHUASAN INFORMATION TECH CO LTD

Process lock holding detection method, electronic device and readable medium thereof

The application relates to the computer field and discloses a process lock holding detection method, an electronic device and a readable medium. The process lock holding detection method comprises the following steps: determining that a first process of the electronic device is in a process state satisfying a system protection triggering condition, and the first process is waiting for using a read-write lock of shared memory of the electronic device; selecting a plurality of second processes from a thread group in which the first process is located, wherein the second processes are not waiting for the read-write lock and are in a lock holding process state; and saving process information of the plurality of second processes. Therefore, by using the process lock holding detection method, the number of process stacks printed by the final kernel is greatly reduced, the workload of the developer for troubleshooting is greatly reduced, and the lock holding process can be accurately positioned.
Owner:HUAWEI TECH CO LTD

System operation parameter safety management method

The invention provides a system operation parameter safety management method which specifically comprises the following steps: S1, parameter modular design: system operation parameters are split into independent sub-parameters according to functions, each sub-parameter is managed by an exclusive internal class, and an external module needs to be accessed through an interface function; and S2, intelligent pointer memory management: using std:: sharedptr to allocate parameter memory, and automatically managing the memory through reference counting. When parameters are updated, new memories are allocated by creating new intelligent pointers, and old parameter memories are automatically released only after reference counts return to zero; s3, design of a read-write lock mechanism: adopting a read-write lock, allowing multi-thread concurrent reading, exclusively locking during writing, and balancing performance and safety; and the like. According to the system operation parameter security management method, the data stability and the memory security can be improved, and the system performance in a multi-thread environment can be improved.
Owner:ZHUHAI RAYSHARP TECH

Vehicle display control method and device, electronic equipment and storage medium

PendingCN122626785AHolding time shortenedImprove stabilityComputer hardwareData stream
The application relates to the technical field of vehicles and discloses a vehicle-mounted display control method and device, electronic equipment and a storage medium. The method comprises the following steps: in response to the initialization of a read-write lock, a global context and a flow state, starting a data flow of a corresponding device after registering a callback thread of at least one vehicle-mounted image acquisition device; in response to the callback thread of any vehicle-mounted image acquisition device being triggered, generating a local snapshot of a global device handle to obtain a local copy, then acquiring a read lock and holding the read lock within an update period of a global flow state identifier; in response to the update of the global flow state identifier being completed, releasing the read lock and performing a callback exit operation or a whole-process lock-free vehicle-mounted display operation based on the validity of the local copy; and in response to the execution of the callback exit operation or the vehicle-mounted display operation being completed, entering the second step after the next callback thread is triggered until an anti-initialization thread is triggered. The application optimizes the lock mechanism and can improve the stability of mass-produced vehicles.
Owner:CHINA FAW CO LTD +1