A Resource Locking Method for Memory Read and Write Process

A memory resource and resource technology, applied in the direction of resource allocation, program synchronization, multi-program installation, etc., can solve the problems of affecting the number of concurrency, occupying operating system CPU resources, system deadlock, etc., to increase the number and efficiency of concurrency, improve Scalability, the effect of avoiding deadlock
CN109857566BActive Publication Date: 2020-09-29TIANYI LOVE ANIMATION CULTURE MEDIA CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
TIANYI LOVE ANIMATION CULTURE MEDIA CO LTD
Publication Date
2020-09-29

Smart Images

  • Figure 1
    Figure 1
  • Figure 2
    Figure 2
  • Figure 3
    Figure 3
Patent Text Reader

Abstract

The invention provides a resource locking algorithm for a memory read-write process, which is used for read-write operation of a memory resource D with an addressing mark, and the addressing mark comprises an address interval, an authority identifier and a timestamp; wherein the authority identifiers are in three mutually exclusive states of distributable, read-only and write-only; the locking algorithm directs the read operation request to the memory resource of which the permission identifier is read-only; the locking algorithm directs the write operation request to memory resources only written by permission; when the locking algorithm is in write operation, if the write operation aims at the memory space S of the existing content X, the locking algorithm copies the content X in the memory to form a mirror image space L with only write permission, and the mirror image space L is used for replacing the memory space S to respond to the write operation aiming at the content X and replacing the memory space S after the write operation is finished; according to the method, the memory switching algorithm can be used for replacing a mutual exclusion lock to solve the synchronization problem of shared resource mutual exclusion access in the scenes of memory data block single-process (thread) writing and multi-process (thread) reading.
Need to check novelty before this filing date? Find Prior Art

Description

technical field

[0001] The invention relates to the technical field of computing equipment, in particular to a resource locking method for memory reading and writing processes. Background technique

[0002] Mutex locks are generally implemented using semaphores, which are used to synchronize or mutually exclude access to shared resources. A large number of operations and uses of semaphores will occupy a large amount of CPU resources in the system, and seriously affect the resource advantages of multiple CPUs or multiple cores in the system. The demand for concurrency is relatively high, and the system with multiple processes (threads) sharing resources is a relatively large bottleneck. Since the resource protection of the semaphore can only allow one process or thread to access at a time, multiple processes or threads accessing a common resource will cause processes or threads to wait in line, which cannot meet the efficient operation of the system.

[0003] Currently, reso...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More