A storage access system and storage access scheduling method

By introducing the remaining arbitration counter and multi-level arbitration mechanism for the access queue in the storage access system, the problem of discontinuous output of arbitration traffic caused by large queue size or complex arbitration algorithm is solved, and access efficiency and system performance are improved.

CN118467418BActive Publication Date: 2024-12-24HANGZHOU DENGLIN HANHAI TECH CO LTD +1
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
CN202410908349.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-08
Publication Date
2024-12-24
Estimated Expiration
2044-07-08

AI Technical Summary

Technical Problem

In scenarios where the queue size is large or the arbitration algorithm is complex, it is difficult for the existing technology to achieve continuous output of arbitration traffic, resulting in low access efficiency and poor system performance, and air conditioning situations often occur due to repeated arbitration requests.

Method used

Introduce the remaining number of requests for arbitration for each access queue, select the target request through the selector to perform multi-level arbitration, avoid repeated arbitration requests, and ensure continuous output and effective access of the arbitration results.

Benefits of technology

It effectively avoids the occurrence of air conditioning situations, improves the continuous output and overall access efficiency of arbitration traffic, and optimizes system performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118467418B_ABST
    Figure CN118467418B_ABST
Patent Text Reader

Abstract

The embodiment of the present application provides a storage access system and a storage access scheduling method, in which each access queue sends a candidate arbitration request to the corresponding selector when the remaining number of arbitration applications is not zero, and after the candidate arbitration request sent this time is selected by the selector, the remaining number of arbitration applications of the access queue is updated; each selector selects the received candidate arbitration request and / or the first arbitration request fed back by the arbitrator after obtaining the arbitration result, so as to determine the target request to send to the arbitrator; the arbitrator is configured to perform multi-level arbitration on the target request selected by each selector to obtain the arbitration result, and return the target request that has not been arbitrated as the first arbitration request to the corresponding selector according to the arbitration result, and the arbitration result is used to indicate that the target queue without access conflict in multiple access queues is dequeued. In this way, the air-conditioning situation can be avoided, which is conducive to the continuous output of arbitration traffic.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computers, and in particular to a storage access system and a storage access scheduling method. Background Art

[0002] The statements in this section are merely intended to provide background information related to the technical solution of the present application to aid understanding, and they do not necessarily constitute prior art for the technical solution of the present application.

[0003] When hardware resources are limited, when multiple requesters try to access the same resource, the requests can be coordinated through an arbitration mechanism to reduce the occurrence of conflicts, thereby avoiding errors or system crashes caused by resource access conflicts.

[0004] With increasingly complex chip design requirements, one beat (also called a clock cycle) may require access to one or more storage spaces. Multiple beats (i.e., multiple clock cycles) may require more complex access situations. Queue-based arbitration is often required due to various memory access and scheduling requirements. Multiple queues may request arbitration in each beat.

[0005] For smaller queues, the non-empty signal of each queue is generally used as an arbitration request. The arbitration of each queue is completed in the current beat, and the corresponding queue is dequeued in the current beat according to the arbitration result. The non-empty signal is updated for the queue in the next beat to conduct the next round of arbitration. In this way, the arbitration traffic is continuously output. However, when this method is directly applied to scenarios with large queues or complex arbitration algorithms, it often causes air conditioning, which ultimately makes it difficult to output arbitration traffic continuously. Summary of the invention

[0006] The inventors found in their research that if faced with a scenario where the queue size is large or the arbitration algorithm is more complex, when the non-empty signals of each queue are used as arbitration requests to directly participate in the arbitration, the entire arbitration process cannot usually be completed quickly due to the large queue size or the complexity of the arbitration algorithm. This means that the arbitration result cannot be obtained in the current beat and the corresponding queue cannot be dequeued in the current beat, and it also means that the non-empty signal of the queue cannot be updated in the next beat, which will cause the arbitrator to continue to receive repeated arbitration requests initiated by each queue with non-empty signals that have not been updated in the next beat or the next multiple consecutive beats and conduct complex invalid arbitration. In the subsequent arbitration process, if these repeated arbitration requests are arbitrated, it will be impossible to read valid information from the output port of the queue for the repeated arbitration request, resulting in an air conditioning situation. Therefore, it will eventually make it difficult for the arbitration traffic to be continuously output, affecting the overall access efficiency.

[0007] In view of this, the purpose of the present application is to provide a storage access system and a storage access scheduling method to improve the above-mentioned problems. When faced with scenarios where the queue size is large or the arbitration algorithm is more complex, air conditioning can be avoided, thereby facilitating the continuous output of arbitration traffic, improving overall access efficiency, and optimizing overall system performance.

[0008] The purpose of this application is achieved through the following technical solutions:

[0009] In a first aspect, an embodiment of the present application provides a storage access system, comprising an arbitrator, a plurality of access queues, and a plurality of selectors corresponding to the plurality of access queues, wherein each of the access queues is configured with a counter for recording the remaining number of arbitration applications of the current queue;

[0010] Each of the access queues is configured to: when the remaining number of arbitration applications is not zero, send a candidate arbitration request to a selector corresponding to the access queue, and after the candidate arbitration request sent this time is selected by the selector, update the remaining number of arbitration applications of the access queue;

[0011] Each selector is configured to: select the received candidate arbitration request and / or the first arbitration request fed back by the arbitrator after obtaining the arbitration result, so as to determine the target request to be sent to the arbitrator;

[0012] The arbitrator is configured to: perform multi-level arbitration on the target request selected by each selector to obtain an arbitration result, and return the target request that has not been arbitrated as the first arbitration request to the corresponding selector according to the arbitration result, and the arbitration result is used to indicate that the target queue without access conflict in the multiple access queues is dequeued.

[0013] Based on the embodiments of the present application, the remaining number of arbitration applications of the current queue is introduced for each access queue to decide whether to send a candidate arbitration request to the selector corresponding to the queue, and the selector selects the target request that actually participates in the arbitration each time for the corresponding access queue, thereby avoiding invalid arbitration caused by repeated arbitration requests that would otherwise occur if the prior art only took non-empty signals as considerations. Then, there will be no air conditioning situation regarding repeated arbitration requests after the first candidate arbitration request in the queue is finally arbitrated to make the queue dequeued and become an empty queue, thereby avoiding the occurrence of air conditioning situations, which is conducive to the continuous output of arbitration traffic, improves overall access efficiency, and optimizes overall system performance.

[0014] As an optional implementation, one selector corresponds to one access queue, and each selector is configured to: when selecting a target request to participate in arbitration for the corresponding access queue, the priority of the first arbitration request is higher than the priority of the candidate arbitration request; when selecting the candidate arbitration request as the target request, send a selection confirmation signal to the corresponding access queue, so that the corresponding access queue updates the remaining number of arbitration applications of the access queue according to the selection confirmation signal. Based on this implementation, it is conducive to supporting the orderly dequeueing of each queue.

[0015] As an optional implementation, each of the access queues is configured with a first counter for recording the remaining number of arbitration applications of the current queue, and each access queue is configured to: increase the remaining number of arbitration applications of the access queue when the current queue is enqueued; reduce the remaining number of arbitration applications of the access queue when the candidate arbitration request sent by the current queue is selected by the selector as the target request; indicate that the current queue is in an empty queue state when the remaining number of arbitration applications of the current queue is zero. Based on this implementation, the queue can be judged empty, and the arbitration scheduling performed for the requests of each queue based on this can avoid causing air conditioning, which is conducive to the continuous output of arbitration traffic.

[0016] As an optional implementation manner, the arbitrator is configured to: receive target requests selected by the multiple selectors for each access queue, determine valid requests from the target requests as arbitration results through multi-level arbitration, and use the arbitration results obtained at the end of the last level of arbitration as the output of the arbitrator; wherein, during the multi-level arbitration process, the arbitration of the next level is performed according to the arbitration results obtained at the end of each level of arbitration, and the arbitration results obtained at the end of each level of arbitration are used to represent the valid requests selected for arbitration at this level; for each level of arbitration, latch the requests to be arbitrated input to the arbitration at this level, or latch the requests that have not been arbitrated at the end of the arbitration at this level; for the last level of the multi-level arbitration, determine the requests that have not been arbitrated at the last level according to the arbitration results obtained at the end of the arbitration at this level, and return them to the corresponding selector as the first arbitration request. Based on this implementation, the arbitrator can output the arbitration results of each period at the last level of multi-level arbitration, which is conducive to the continuous output of arbitration traffic, and can enable requests that are not arbitrated after each round of arbitration to have the opportunity to participate in the subsequent arbitration of the next round, avoiding the loss of request data. For the arbitrator using multi-level arbitration, the requests that are not arbitrated after each arbitration of the arbitrator can be directly or indirectly determined, and the unarbitrated requests can be fed back to the corresponding selector for subsequent arbitration.

[0017] Optionally, the arbitrator is configured to perform multi-level arbitration according to a preset arbitration algorithm to select a valid request from all target requests selected by each selector as an arbitration result.

[0018] As an optional implementation, the arbitrator is further configured to: upon receiving a back pressure request, update the arbitration result currently arbitrated according to the back pressure request, wherein the back pressure request is used to indicate that some or all of the requests arbitrated from the target request are considered as not arbitrated; determine the unarbitrated requests in the target request according to the updated arbitration result, and return them to the corresponding selector as the first arbitration request. Based on this implementation, back pressure processing can be implemented on the output side of the storage access system to avoid data loss caused by the inability to continue writing data due to limited space of the accessed object.

[0019] As an optional implementation, each access queue is used to store access requests for objects to be accessed, and each access request includes address information of the object to be accessed. The object to be accessed may be a storage block or a data cache module.

[0020] As an optional implementation, the storage access system further includes: at least one storage block, each access queue is used to store the address information of the target storage block to be accessed, the storage block is used to store the accessible data, and each storage block supports the access of one access queue at a time; the storage access system is configured to: obtain the address information of the target queue dequeue output corresponding to the arbitration result; access the target storage block to be accessed by the target queue according to the address information, so as to obtain the data in the corresponding target storage block. Based on this implementation, efficient access to a system with multiple storage blocks (banks) can be supported to avoid access conflicts to storage blocks (banks).

[0021] As an optional implementation, the storage access system further includes: at least one data cache module corresponding to the multiple access queues, and the storage access system is further configured to: after accessing the target storage block according to the address information output by the target queue, write the data accessed from the target storage block into the data cache module corresponding to the target queue; after the data cache module corresponding to the target queue is full, send a back pressure request to the arbitrator performing multi-level arbitration, so that the arbitrator updates the arbitration result currently arbitrated at the last level according to the back pressure request, and determines the arbitration request that is not currently arbitrated at the last level according to the updated arbitration result, and returns it to the corresponding selector as the first arbitration request. Based on this implementation, the data obtained from the storage block (bank) for the queue can be written into the data cache module corresponding to the queue, and back pressure processing is performed when the space of the data cache module is insufficient to support the continued writing of data. The arbitrator can update the arbitration result under the instruction of the back pressure request, thereby determining the queue that can actually be dequeued, staggering the dequeuing time of the queue, and avoiding the queue that is not allowed to dequeue from losing data.

[0022] As an optional implementation, the storage access system further includes: at least one data cache module corresponding to the multiple access queues, the data cache module is used to store accessible data, each access queue is used to store address information of the data cache module to be accessed, and each data cache module supports access to one access queue at a time; the storage access system is configured to: obtain the address information of the target queue dequeue output corresponding to the arbitration result; access the data cache module to be accessed in the target queue according to the address information, thereby reading or writing data to the corresponding data cache module. Based on this implementation, the data cache module is directly used as the accessed object, and the data cache module with limited ports can be efficiently accessed directly without going through the storage block (bank).

[0023] In a second aspect, an embodiment of the present application provides a storage access scheduling method, which is applied to the storage access system described in the first aspect, wherein the storage access system includes an arbitrator, multiple access queues, and multiple selectors corresponding to the multiple access queues respectively; the method includes:

[0024] The plurality of access queues receive a plurality of access requests for at least one object to be accessed;

[0025] For each access queue among the multiple access queues, when the remaining number of arbitration applications of the current queue is not zero, sending a candidate arbitration request to a selector corresponding to the access queue, and after the candidate arbitration request sent this time is selected by the selector, updating the remaining number of arbitration applications of the access queue;

[0026] Each of the multiple selectors selects a request to participate in arbitration for the access queue corresponding to the selector, and sends the request as a target request to the arbitrator, where the target request is the candidate arbitration request sent by the access queue or the first arbitration request fed back by the arbitrator after obtaining the arbitration result;

[0027] The arbitrator performs multi-level arbitration on the target request selected by each selector to obtain an arbitration result;

[0028] The arbitrator instructs the target queue without access conflict among the multiple access queues to dequeue according to the arbitration result so as to access the object to be accessed currently corresponding to the target queue, and returns the target request that has not been arbitrated as the first arbitration request to the corresponding selector according to the arbitration result.

[0029] The technical solution of the embodiment of the present application may have the following beneficial effects:

[0030] By introducing the remaining number of arbitration applications of the current queue and the corresponding selector for each access queue, the target request that actually participates in the arbitration is determined each time. Multi-level arbitration is performed based on the request selected by the selector to obtain the arbitration result, so that the queue without access conflict is dequeued, and the request that is not arbitrated can be fed back to the selector so that it has the opportunity to participate in subsequent arbitration. Based on this scheme, the objects to be accessed in each queue can be effectively accessed, and invalid arbitration caused by repeated arbitration requests that only take non-empty signals as considerations in the prior art can be avoided. The occurrence of air conditioning can be avoided, which is conducive to the continuous output of arbitration traffic, improves the overall access efficiency, and optimizes the overall system performance.

[0031] It should be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] The drawings herein are incorporated into the specification and constitute a part of the specification, showing embodiments consistent with the present application, and together with the specification, are used to explain the principles of the present application. Obviously, the drawings described below are only some embodiments of the present application, and for ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work. In the drawings:

[0033] Figure 1 The figure is a schematic diagram of a principle analysis of arbitration for a small-scale queue under the existing technology.

[0034] Figure 2 The present invention is a schematic diagram of a principle analysis of arbitration for complex scenarios under the existing technology.

[0035] Figure 3 A schematic diagram of a storage access system provided in an embodiment of the present application.

[0036] Figure 4 A schematic diagram of the principle of an access queue provided in an embodiment of the present application.

[0037] Figure 5 A schematic diagram of another storage access system provided in an embodiment of the present application.

[0038] Figure 6 A flowchart of a storage access scheduling method provided in an embodiment of the present application.

[0039] Figure 7 A schematic diagram of another storage access system provided in an embodiment of the present application. DETAILED DESCRIPTION

[0040] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application is further described in detail by specific embodiments in conjunction with the accompanying drawings. It should be understood that the described embodiments are part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without creative work belong to the scope of protection of the present application. When not emphasized, relational terms such as "first", "second", etc. in the description of the present application are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. "At least one" means one or more.

[0041] The block diagrams shown in the accompanying drawings are merely functional entities and do not necessarily correspond to physically independent entities. That is, these functional entities may be implemented in software form, or in one or more hardware modules or integrated circuits, or in different networks and / or processor devices and / or microcontroller devices.

[0042] The storage access system is an indispensable device in the field of computer equipment. The data in its storage space can be accessed by other hardware by making access requests, and the access requests usually carry the address information of the object to be accessed.

[0043] In a common storage access mode, several storage blocks (banks) are configured as the objects to be accessed. Each storage block has only one accessible port. Each storage block can be accessed at the same time, but each storage block only supports one access at a time. The data accessed from the storage block can also be further written into the system's output cache for caching. The output cache has several data cache modules.

[0044] In another storage access mode, there may be no storage block (bank), and several data cache modules are directly used as the objects to be accessed. Each data cache module can be accessed at the same time, but each data cache module only supports one access at a time.

[0045] Regardless of the form of storage access mode, as long as the resources of the object to be accessed are limited and the ports available for access are limited, an arbitration mechanism is usually set up to make decisions and schedule the access process in order to avoid access conflicts. With increasingly complex chip design requirements, various memory access and scheduling requirements often require queue-based arbitration. Each queue receives access requests for the object to be accessed, and initiates an arbitration request to the arbitrator for the received access request to request valid access to the object to be accessed. Multiple queues may request to participate in arbitration in each beat (also called a clock cycle).

[0046] After research, the inventor found that for smaller queues, the non-empty signal of each queue is generally used as an arbitration request. Since the queue size is small and arbitration is relatively simple, arbitration for each queue can be completed in the beat when the arbitration request is received, and the corresponding queue can be dequeued in the beat according to the arbitration result, and the non-empty signal is updated for the queue in the next beat to conduct a round of arbitration in the next beat, so that the arbitration traffic can be continuously output. However, if the queue size is large or the arbitration algorithm is more complex, when the non-empty signal of each queue is used as the arbitration request to directly participate in the arbitration, due to the large size of the queue or the complexity of the arbitration algorithm, it is usually impossible to complete the entire arbitration process quickly. This means that the arbitration result cannot be obtained in the beat and the corresponding queue cannot be dequeued in the beat, and it also means that the non-empty signal of the queue cannot be updated in the next beat, which will cause the arbitrator to continue to receive repeated arbitration requests initiated by each queue with a non-empty signal that has not been updated in each beat in the next beat or the next consecutive beats and conduct complex invalid arbitration. In the subsequent arbitration process, the arbitrator may complete the arbitration for the first arbitration request and dequeue the corresponding queue according to the arbitration result. For the queues that participated in the arbitration but have not actually dequeued, the next beat cannot update the non-empty signal. Then, the arbitrator will have air conditioning (also known as bubble phenomenon) for these queues that have been dequeued later but have already initiated repeated arbitration requests. The air conditioning here means that even if a request is arbitrated, the correct information corresponding to the request cannot be obtained (because the queue that initiated the repeated arbitration request has been dequeued, resulting in the required access request tag or the address to be accessed or the data that needs to be written to a certain address is no longer in the queue). Therefore, if these repeated arbitration requests are arbitrated in the subsequent arbitration process, valid information cannot be read from the queue for the repeated arbitration request. Therefore, it will eventually make it difficult to output arbitration traffic continuously, affecting the overall access efficiency of each queue.

[0047] For ease of understanding, we will combine Figure 1 and Figure 2 An example is given to illustrate the two situations. When a queue (QueueA) receives an access request d1 about an object to be accessed, it becomes a non-empty queue. At time t1, it participates in arbitration with a non-empty signal as an arbitration request. The arbitrator arbitrates the arbitration request of queue A and indicates with the arbitration result whether the access request d1 corresponding to the arbitration request is allowed to be dequeued from queue A. For the sake of comparison, it is assumed that the arbitration result indicates that queue A is allowed to be dequeued. After the access request d1 is dequeued from queue A, the information of the access request d1 can no longer be obtained by reading queue A. For a system with a small queue size, such as Figure 1As shown in the figure, arbitration processing is usually relatively simple and fast. After d1 is inserted into queue A and becomes a non-empty queue at time t1, the arbitration result can be determined in the clock cycle (the beat) from t1 to t2, and queue A is read to make d1 dequeue from queue A. Queue A becomes an empty queue at t2, so updating the non-empty signal in the next beat (referring to the clock cycle starting from t2) is allowed. However, if the queue size is large or the arbitration algorithm is more complex, if the non-empty signal of queue A is still used as the arbitration request, such as Figure 2 As shown, the arbitrator needs to go through a complex arbitration process of multiple beats before it can output the arbitration result in the beat t3~t4, so as to read queue A to make d1 dequeue from queue A. This means that the non-empty signal of queue A cannot be updated during the period t2~t4. Then during the period t2~t4, queue A will continue to make repeated arbitration requests for d1 with a non-empty signal, so that the arbitrator not only has to process the arbitration request of the beat t1~t2 to make queue A output d1, but also has to process repeated arbitration requests to make queue A output d1. However, in fact, d1 can only be dequeued from the queue once. Therefore, after t4, the arbitration made by the arbitrator for repeated arbitration requests is actually invalid. Even if the subsequent arbitration reaches the repeated arbitration request initiated by queue A during the period t2~t4, the corresponding arbitration result can no longer be used to obtain the information of d1 that has already been dequeued from queue A from queue A. Therefore, an air-conditioning situation occurs, and invalid calls occur. Frequent air-conditioning situations will eventually make it difficult for arbitration traffic to be output continuously, affecting the overall access efficiency of each queue.

[0048] In view of this, the embodiments of the present application provide a storage access system and a storage access scheduling method, which can avoid air conditioning when facing scenarios with large queue sizes or more complex arbitration algorithms, thereby facilitating the continuous output of arbitration traffic, improving overall access efficiency, and optimizing overall system performance.

[0049] like Figure 3 As shown, an embodiment of the present application provides a storage access system, including an arbitrator, multiple access queues, and multiple selectors corresponding to the multiple access queues. One selector is connected to one access queue. The output ends of all selectors are connected to the arbitrator.

[0050] The access queue is used to receive and output information about access requests for objects to be accessed. For any access queue, each access request received by a single queue may be about different objects to be accessed, or may be for the same object to be accessed.

[0051] The access queue may have the characteristics of First Input First Output (FIFO). It may be a simple sequential queue or a circular queue. Of course, it may also be a priority queue, in which the elements in the priority queue have a predefined priority. The specific implementation details of the queue should not be construed as limiting the present application.

[0052] In the storage access system of the embodiment of the present application, for each access queue, the remaining number of arbitration applications of the current queue is recorded. Each access queue is configured to: increase the remaining number of arbitration applications of the access queue when the current queue performs an enqueue operation; and reduce the remaining number of arbitration applications of the access queue when the candidate arbitration request sent by the current queue is selected as the target request by the corresponding selector.

[0053] When the number of remaining arbitration applications of the current queue is zero, it indicates that the current queue is in an empty queue state, and when the number of remaining arbitration applications of the current queue is not zero, it indicates that the current queue is in a non-empty state. It should be noted that when the number of remaining arbitration applications of the current queue is zero, although it indicates that the current queue is in an empty queue state, the queue may not actually be dequeued and become an empty queue.

[0054] In an embodiment of the present application, each access queue is configured to: when the remaining number of arbitration applications of the current queue is not zero, send a candidate arbitration request to the selector corresponding to the access queue, and after the candidate arbitration request sent this time is selected by the selector, update the remaining number of arbitration applications of the access queue. When the remaining number of arbitration applications of the current queue is zero, there is no need to send a candidate arbitration request to the selector corresponding to the access queue, which can reduce the arbitration processing pressure and avoid invalid arbitration. When a selector selects a candidate arbitration request as a target request, it sends a selection confirmation signal to the corresponding access queue, so that the corresponding access queue updates the remaining number of arbitration applications of the access queue according to the selection confirmation signal.

[0055] Each access queue can continuously receive external access requests, and send a candidate arbitration request (such as a 1-bit non-empty signal) to the corresponding selector for each access request (such as 30 bits of information) according to the order in which each access request arrives at the queue and the recorded remaining number of arbitration applications. It can be understood that the bit size here is only an example.

[0056] Each selector is configured to select a received candidate arbitration request and / or a first arbitration request fed back by the arbitrator after obtaining an arbitration result, so as to determine a target request to send to the arbitrator.

[0057] Among them, each selector may face three situations: the first is that only the candidate arbitration request of the queue is received, and the candidate arbitration request is used as the target request; the second is that the candidate arbitration request of the queue and the first arbitration request fed back by the arbitrator are received at the same time, in which case the selection can be made according to the set priority; the third is that only the first arbitration request fed back by the arbitrator is received, and the fed back first arbitration request is used as the target request. Each selector can select the request that actually participates in arbitration each time, that is, the target request, for the access queue corresponding to the selector from the request signal actually received at present. Exemplarily, if the selector selects the candidate arbitration request (signal) output by the queue, a high-level signal of one clock cycle can be fed back to the corresponding queue, so that the queue updates the remaining number of arbitration applications based on the high-level signal. For the selection logic of the selector, as an implementation method, each selector can be configured as follows: when selecting the target request to participate in arbitration for the corresponding access queue, the priority of the first arbitration request is higher than the priority of the candidate arbitration request. This will enable the selector to prioritize the first arbitration requests fed back by the arbitrator as new target requests for the corresponding access queue next time to participate in the next arbitration of the arbitrator, and enable the arbitrator to process the requests in the order of priority, which is conducive to supporting the first-in-first-out of the queue for each access request and supporting orderly access.

[0058] The arbitrator is configured to: perform multi-level arbitration on the target request selected by each selector to obtain an arbitration result, and return the target request that has not been arbitrated as a first arbitration request to the corresponding selector according to the arbitration result.

[0059] In the embodiment of the present application, a request arbitrated by the arbitrator means that: the request has been selected by the selector to become the target request participating in the arbitration, and is finally selected by the arbitrator to become a valid request. If a request is selected by the selector to become the target request, but has not been selected as a valid request after being processed by the arbitration algorithm of the arbitrator, it is deemed that the request has not been arbitrated, and the queue corresponding to the request is temporarily not supported to be dequeued. Based on the arbitration result generated by the last level, the arbitrator can send an arbitration confirmation signal to the target queue so that the target queue is read, and dequeue the access request information associated with the arbitrated arbitration request according to the arbitration confirmation signal, and execute the access request based on this.

[0060] It is understandable that a target request selected by a selector for a corresponding access queue is associated with the access request in the access queue. When a target request is finally arbitrated by the arbitrator to become a valid request, the queue corresponding to the target request is the target queue, and the output of the target queue is the information of the access request associated with the target request. The multi-level arbitration of each target request can also be regarded as a multi-level screening of each queue. The arbitrator can analyze and select the queue corresponding to each target request according to the pre-configured arbitration algorithm, so as to determine a group of queues without access conflicts as the target queue.

[0061] Based on the indication of the arbitration result finally output by the arbitrator, the storage access system can schedule the target queue without access conflict among the above-mentioned multiple access queues to be dequeued, and the access request dequeued based on the target queue can access the object to be accessed currently corresponding to the target queue, that is, execute the access request output by the target queue.

[0062] In some application scenarios, multiple access requests can be integrated in advance, and access queues can be grouped. The relationship between access queues and objects to be accessed can be set in advance. For example, a group of access queues (each group has one or more) can be specified to only accept access requests for a specific object to be accessed. In this way, one queue can be selected from each group of queues as the queue allowed to be dequeued during arbitration. If the relationship between access queues and objects to be accessed is not set in advance, but the priority is predefined for access requests or access queues, the predefined priority can be used as a factor for arbitration, for example, queues with higher priorities can be dequeued first. Of course, the priority of the queue can also be adjusted.

[0063] Those skilled in the art can change the selection logic of the selector or the arbitration algorithm logic of the arbitrator according to actual needs to adjust the priority processing order of each arbitration request, as long as it can ensure that access conflicts are avoided. For example, in some embodiments, the processing time can be considered. When it is detected that the arbitration processing time exceeds a certain set threshold, the arbitration request whose arbitration processing time exceeds the threshold is adjusted in priority (lowering or increasing the priority). Special arbitration requests with adjusted priorities can be marked for separate processing, and this application does not require this.

[0064] It should be noted that in the present application, for each access queue, the remaining number of arbitration applications of the current queue is introduced to determine whether to send a candidate arbitration request to the selector corresponding to the queue, and the candidate arbitration request is issued only when the remaining number of arbitration applications is not zero. Multiple selectors are also set between multiple access queues and the arbitrator, and multiple selectors correspond to multiple access queues. Each selector will select the target request that actually participates in the arbitration for each corresponding access queue, instead of directly providing the arbitration request proposed by the access queue based on the current non-empty signal to the arbitrator for arbitration. In addition, the arbitrator performs multi-level arbitration based on the target request selected by each selector to obtain the arbitration result, and returns the requests that have not been arbitrated in the target request to the corresponding selector, so that the selector has the opportunity to select these requests that are fed back to participate in the next arbitration. Based on this, when a certain access queue (such as the aforementioned queue A) initiates the first candidate arbitration request and the request is selected as the target request to participate in arbitration, even if the arbitrator needs a long time to complete a round of arbitration to output an arbitration result, since the first candidate arbitration request is selected as the target request, the remaining number of arbitration applications for the queue will be updated regardless of when the first candidate arbitration request can be arbitrated by the arbitrator. Therefore, if the first candidate arbitration request of the queue A requires the arbitrator to spend a long time to arbitrate before it can be arbitrated, then during the period that has not been arbitrated (for example Figure 2 During the period t2~t4), the following two situations may occur.

[0065] The first case: during this period, the remaining number of arbitration applications of the queue is updated to zero. In this case, even if the queue has not yet dequeued the first candidate arbitration request, it is not actually an empty queue at this time, and the queue will not immediately initiate a second candidate arbitration request to request to participate in the next arbitration. The second candidate arbitration request will not be initiated until the remaining number of arbitration applications is not zero. Therefore, in this case, during the period when the queue is not empty but the remaining number of arbitration applications is zero, it can avoid the invalid arbitration caused by repeated arbitration requests caused by the existing technology that only considers non-empty signals. Then, there will be no air conditioning of repeated arbitration requests after the first candidate arbitration request is finally arbitrated and the queue is instructed to dequeue and become an empty queue, avoiding the occurrence of air conditioning, which is conducive to the continuous output of arbitration traffic, improving overall access efficiency, and optimizing overall system performance. In addition, this processing method can also reduce the pressure of arbitration processing and improve the overall processing efficiency.

[0066] In the second case, during this period, the remaining number of arbitration applications of the queue is updated but still not zero. In this case, the queue is not an empty queue, and a second candidate arbitration request will be initiated. However, since the arbitrator has not arbitrated the first candidate arbitration request selected as the target request during this period, the selector will receive the first arbitration request with a higher priority fed back by the arbitrator. Even if the selector of the queue receives the second candidate arbitration request, it will not select the second candidate arbitration request to participate in the next arbitration at this time, so that the previous request can continue to be arbitrated by the arbitrator as the target request of the new round, until the previous request is finally arbitrated and the correct information output by the corresponding queue is successfully read based on the previous arbitration request, and the queue can be dequeued in an orderly manner.

[0067] Optionally, the empty and full states of the access queue can be distinguished in different ways, such as Figure 4 As shown, in one example, two independent counters (denoted as a first counter and a second counter) can be configured for each access queue to mark and manage the empty queue state and full queue state of a queue, wherein the first counter is used to mark the empty queue state of the queue, based on which an empty queue signal (empty signal) or a not empty signal (not empty signal) of the queue can be generated, and the second counter is used to mark the full queue state of the queue, based on which a full queue signal (full signal) can be generated.

[0068] The second counter is used to count the number of access requests in the current queue and to indicate whether the current queue is full. When the current queue is enqueued, an access request for an object to be accessed is obtained, and the number of access requests in the current queue is increased; when the current queue is dequeued, an access request for an object to be accessed is output, and the number of access requests in the current queue is reduced; when the number of access requests in the current queue is equal to the queue depth of the current queue, the current queue is determined to be full. In this way, a full queue signal of the queue can be generated to back-pressure the queue enqueue interface, so that the current queue stops receiving access requests.

[0069] The second counter can be used to perform statistics based on the actual enqueue operations and dequeue operations of the current queue, or can be used to perform judgment and statistics based on the changes in the read and write pointers of the queue.

[0070] The first counter is used to record the remaining number of arbitration applications of the current queue, and is used to mark whether the current queue is in an empty queue state. The recorded remaining number of arbitration applications can be increased by 1 when the current queue performs an enqueue operation. When the queue issues a candidate arbitration request based on the access request of the enqueue operation and the request is selected as the target request, the remaining number of arbitration applications of the queue is updated according to the selection confirmation signal received from the selector, and the remaining number of arbitration applications is reduced by 1. When the number is reduced to zero, even if the queue has not actually performed a dequeue operation on the request, an empty queue signal of the queue is generated.

[0071] As an implementation, the arbiter may be configured to obtain target requests sent to the arbiter by multiple selectors for each access queue according to a set period. The set period is related to the period of a reference clock (clk) signal of the system and may be an integer multiple of the reference clock period.

[0072] The arbitrator is configured to: receive target requests selected by multiple selectors for each access queue according to a set cycle, determine valid requests from all target requests as arbitration results through multi-level arbitration, and use the arbitration results obtained at the end of the last level of arbitration as the output of the arbitrator. In the multi-level arbitration process, the arbitration of the next level is carried out according to the arbitration results obtained at the end of each level of arbitration, and the arbitration results obtained at the end of each level of arbitration are used to represent the valid requests selected for arbitration at this level. For the last level of the multi-level arbitration, the requests that have not been arbitrated at the last level are determined according to the arbitration results obtained at the end of the last level of arbitration, and are returned to the corresponding selector as the first arbitration request. In this way, the corresponding selector can select the first arbitration request as the new target request for the corresponding access queue to participate in the next multi-level arbitration. For the entire storage access system, in the process of the arbitrator performing multi-level arbitration, each access queue can continue to receive access requests for multiple objects to be accessed (i.e., enter the queue) if the queue is not full, and propose candidate arbitration requests based on this. The entire storage access system can also follow the arbitration outputs of the arbitrator and schedule the corresponding queues to be dequeued according to the arbitration results of each stage, thereby performing data access on the corresponding objects to be accessed, thereby avoiding access conflicts on the corresponding objects to be accessed.

[0073] Optionally, in order to determine the requests that have not been arbitrated at the last level, the requests to be arbitrated that are input to each level of arbitration can be latched, or the requests that have not been arbitrated at the end of the level of arbitration can be latched. The arbitrator latches or records data in the middle of the multi-level arbitration process, which is helpful for providing a basis for arbitration processing in each period, and is helpful for quickly determining which requests among all the target requests provided by the selector to the arbitrator are valid at what time, and can also quickly determine the requests that have not been arbitrated among the target requests so that the requests that have not been arbitrated in a certain round have the opportunity to participate in the subsequent rounds of arbitration.

[0074] In one example, the arbitrator may be configured to perform arbitration according to a selectable arbitration algorithm such as fixed priority arbitration, mixed priority arbitration, fair round-robin arbitration, weighted round-robin arbitration, etc.

[0075] For example, Figure 5 As shown, the arbitrator can be configured to perform multi-stage arbitration on all target requests selected by multiple selectors through multiple arbitration modules. Those skilled in the art can set the same or different arbitration algorithms for the arbitration modules at each level of the arbitrator according to actual needs. The arbitrator can perform multi-stage arbitration in an arbitration pipeline with multiple arbitration modules cascaded to obtain an arbitration result.

[0076] As an implementation method, each arbitration module may be assigned a first register and a second register, the first register may be used to record the arbitration result of the arbitration module at this level, and the second register may be used to latch the request to be arbitrated input to the arbitration module at this level (for example, the N-level arbitration module uses the N-1 level or N-level register to latch the request of each level in the intermediate process). When it is necessary to determine the request that has not been arbitrated at a certain level (for example, the last level), the arbitration result recorded by the first register may be used to update the content latched by the second register (for example, by performing a mask operation to update), thereby determining the request that has not been arbitrated at this level, so that the first arbitration request that needs to be returned to the corresponding selector can be quickly determined. Optionally, the second register may also be replaced in other examples to be used to directly store the request that has not been arbitrated by the arbitration module at this level, so that the last level arbitration module can directly determine the request that has not been arbitrated at the last level, thereby quickly determining the first arbitration request that needs to be returned to the corresponding selector. The functions of the first register and the second register may also be combined, for example, using a group of registers to record which queues' requests are considered to be arbitrated (for example, by marking the valid requests this time with 1) and which queues' requests are considered to be not arbitrated (for example, by marking them with 0). The manner of recording the arbitration process and arbitration results should not be understood as a limitation on the present application.

[0077] Exemplarily, if there are 128 access queues and 8 objects to be accessed, then the corresponding 128 selectors can select 128 target requests for the 128 access queues, and the arbitrator can be configured to perform multi-level arbitration on the 128 target requests to select 8 valid requests from them. The 8 access queues corresponding to the 8 valid requests are the target queues at this time, and are allowed to be dequeued. The remaining 120 requests are fed back by the arbitrator to the corresponding selector for the next selection. Among them, 64 can be selected from the 128 target requests in the first-level arbitration, and the second-level arbitration selects 32 from the 64 requests based on the result of the first-level arbitration. The third-level arbitration selects 8 valid requests from the 32 requests based on the result of the second-level arbitration as the arbitration result of a multi-level arbitration. In multiple consecutive clock cycles, after multiple multi-level arbitrations, the arbitration results can be continuously output again and again, and each arbitration determines 8 valid requests for queue scheduling to access the objects to be accessed in the 8 queues. It can be understood that the third-level arbitration used here to select 8 requests from 32 requests can also be further decoupled into multi-level arbitration. For example, 16 requests are first selected from 32 requests, and then 8 are selected from the 16 requests to determine the 8 target queues allowed to be dequeued at this time.

[0078] In some application scenarios where data is written for access, for storage access systems, in addition to setting a back pressure processing mechanism on the input side of the system (referring to the queue entry interface of each access queue) to suspend receiving access requests when the queue is full, a back pressure processing mechanism can also be set on the output side of the system (referring to the arbiter output interface) to avoid data loss caused by the inability to continue writing data due to limited space of the accessed object when accessing the object to be accessed. The back pressure can be released when the object to be accessed supports continued data writing.

[0079] As an implementation mode, in a storage access system, an arbitrator using multi-level arbitration may be further configured to: upon receiving a back pressure request, update the arbitration result currently arbitrated according to the back pressure request, and determine the unarbitrated requests in the target request according to the updated arbitration result, and return them as the first arbitration request to the corresponding selector. The back pressure request is used to indicate that some or all of the requests arbitrated from the target request are considered unarbitrated.

[0080] For ease of understanding, the aforementioned 128 access queues receive access requests for 8 objects to be accessed, and the arbitrator is configured to select 8 valid requests as arbitration results through multi-level arbitration. For example, each access queue is associated with the object to be accessed that needs to write data each time, and each access queue has its own queue tag. If the system detects that the storage space of two of the 8 objects to be accessed is full, then it is temporarily not supported to continue writing data to the two objects to be accessed, and arbitration processing under back pressure is required. The arbitrator will receive a back pressure request (signal). The back pressure request can come from the object to be accessed that currently does not support continued writing of data. The arbitrator can determine to update the arbitration result of the current arbitration according to the indication of the back pressure request. For example, if there is exactly one request corresponding to the queue that needs to write data to the object to be accessed that has made a back pressure request among the 8 valid requests arbitrated by the arbitrator this time, then the current arbitration result needs to be updated so that the request is deemed not to be arbitrated this time, and the request deemed not to be arbitrated is returned to the corresponding selector as the first arbitration request, waiting for subsequent arbitration. In this way, the timing of writing data of the access object by each access queue can be staggered.

[0081] In one application scenario, the storage access system may further include at least one storage block (bank). The storage block may be used as an object to be accessed. The storage block is used to store accessible data, and each storage block supports access by one access queue at a time. Each access queue is used to store address information of a target storage block to be accessed. Since each storage block supports access by one access queue at a time, the arbitrator may be configured to perform multi-level arbitration on all target requests selected by multiple selectors according to the principle of non-conflict of storage blocks, so as to obtain an arbitration result, thereby indicating that the target queue that will not have access conflict with the storage block is dequeued. The storage access system is configured to: obtain the address information of the dequeued output of the target queue corresponding to the arbitration result; and access the target storage block to be accessed by the target queue according to the obtained address information, so as to obtain the data in the corresponding target storage block.

[0082] Among them, in order to store the data read by each queue after accessing the storage block (bank), the storage access system may also include at least one data cache module corresponding to the multiple access queues. The storage access system may pre-set the correspondence between the data cache module and the access queue. Based on the correspondence, after accessing the target storage (bank) block according to the address information output by the target queue, the data accessed from the target storage block may be written into the data cache module corresponding to the target queue. The storage access system may also be configured to: after the data cache module corresponding to the target queue is full, send a back pressure request to the arbitrator performing multi-level arbitration, so that the arbitrator updates the arbitration result currently arbitrated at the last level according to the back pressure request, and determines the arbitration request that is not currently arbitrated at the last level according to the updated arbitration result, and returns it to the corresponding selector as the first arbitration request.

[0083] In some embodiments, the correspondence between the data cache module and the access queue can be determined by the channel (lane) address tag. The storage access system supports access to multiple non-continuous storage blocks in one clock cycle, and each access queue is configured to be grouped according to the channel (lane). Each data cache module corresponds to a channel and is dedicated to data caching for a group of queues in the same channel. After the access request (including the address information of the target storage block) output for each access queue is read from the storage block to obtain data, if it is required that the data read from the storage block cannot be returned across the channel, the arbitrator can be configured in advance to: perform multi-level arbitration on all target requests selected by multiple selectors according to the principle that the storage block (bank) address does not conflict and the channel (lane) address does not conflict, so as to obtain the arbitration result, and the target queue that indicates that there will be no access conflict to the storage block and no access conflict to the data cache module will be dequeued based on this arbitration result. In this way, in the face of complex access, the data reading efficiency for each storage block and the data writing efficiency for each data cache module can be taken into account.

[0084] For data cache modules and access queues marked by channels, if the data cache module of a channel is full, a back pressure request can be sent to the arbitrator. Based on the back pressure request, the arbitrator can perform arbitration processing under back pressure for the entire group of queues of the same channel corresponding to the data cache module. For example, the arbitration request corresponding to the entire group of queues of the same channel is masked in the arbitration result to update the arbitration result currently arbitrated at the last level, and determine the arbitration request that has not been arbitrated at the last level based on the updated arbitration result, and return it to the corresponding selector as the first arbitration request.

[0085] In another application scenario, the storage access system can directly access the data cache module without accessing the storage block (bank) to directly read or write data to the data cache module. In this application scenario, the storage access system includes: at least one data cache module corresponding to multiple access queues, the data cache module is used to store accessible data, each access queue is used to store the address information of the data cache module to be accessed, and each data cache module supports the access of one access queue at a time. The storage access system is configured to: obtain the address information of the target queue corresponding to the arbitration result, which is dequeued and output according to the first-in-first-out principle; access the data cache module to be accessed by the target queue according to the address information, so as to read or write data to the corresponding data cache module. Among them, in this application scenario, the arbitrator can be configured to: perform multi-level arbitration on all target requests selected by multiple selectors according to the principle that the data cache module address does not conflict, so as to obtain an arbitration result, and based on this arbitration result, it can be indicated that the target queue that will not have access conflict with the data cache module is dequeued. If the data cache module needs back pressure, a back pressure request can still be sent to the arbitrator.

[0086] If the storage access system has only one data cache module for all access queues to write cache data, then when the only data cache module sends a back pressure request to the arbitrator, it means that no queue can be allowed to dequeue to continue writing data to the data cache module, and the arbitration of the last level of the arbitrator stops. At this time, the arbitration results obtained at the last level are deemed invalid. The arbitration results need to be updated under back pressure, and the first arbitration request is fed back to all selectors based on the updated arbitration results. It is understandable that even if the arbitration result of the last level is updated in a certain beat under back pressure, the arbitrator using a multi-level arbitration pipeline mechanism can continue to perform arbitration calculations in the next beat to obtain the arbitration result of the next beat. If the back pressure has not been released in the next beat, the arbitration result of the next beat is also updated.

[0087] Based on the same inventive concept, Figure 6 As shown, the embodiment of the present application also provides a storage access scheduling method, which is applied to the aforementioned storage access system. The method can avoid the occurrence of air conditioning when facing a scenario with a large queue size or a complex arbitration algorithm, thereby facilitating the continuous output of arbitration traffic, improving overall access efficiency, and optimizing overall system performance. The method includes the following steps:

[0088] S110: Multiple access queues receive multiple access requests for at least one object to be accessed.

[0089] In one implementation, the object to be accessed may be the aforementioned storage block (bank), in another implementation, the object to be accessed may be a data cache module related to a channel (lane), and in yet another implementation, the object to be accessed may be a data cache module unrelated to a channel.

[0090] S120: For each access queue among the multiple access queues, when the remaining number of arbitration applications of the current queue is not zero, a candidate arbitration request is sent to the selector corresponding to the access queue. After the candidate arbitration request sent this time is selected by the selector, the remaining number of arbitration applications of the access queue is updated.

[0091] S130: Each selector among the multiple selectors selects a request to participate in arbitration for the access queue corresponding to the selector, and sends it to the arbitrator as a target request.

[0092] The target request is a candidate arbitration request sent by the access queue or a first arbitration request fed back by the arbitrator after obtaining an arbitration result. Optionally, the first arbitration request has a higher priority than the candidate arbitration request.

[0093] S140: The arbitrator performs multi-level arbitration on the target request selected by each selector to obtain an arbitration result, and returns the target request that has not been arbitrated as a first arbitration request to the corresponding selector according to the arbitration result.

[0094] The arbitration result is used to instruct a target queue without access conflict among multiple access queues to dequeue.

[0095] S150: According to the indication of the arbitration result, the target queue is scheduled to be dequeued so as to access the to-be-accessed object currently corresponding to the target queue.

[0096] S150 may include: reading an access request from a target queue according to an indication of the arbitration result, and accessing an object to be accessed corresponding to the access request.

[0097] Exemplarily, in an application scenario, a storage access system includes an input interface, multiple storage blocks, and an output cache. The input interface is used to receive a number of access requests for each storage block. Each access request may carry the address of the storage block to be accessed (used to indicate which storage block to read data from), and may also carry the address of a channel (used to determine which channel to access the storage block from, and ultimately cache the data read from the storage block according to the principle of unchanged channels). Multiple storage blocks are used to store accessible data, and each storage block supports access to one channel at a time. The output cache includes multiple data cache modules, and one data cache module is used to cache the access results of a channel, so the address of the data cache module can be determined based on the address of the channel in the access request. Figure 7As shown, taking 8 channels accessing 8 storage blocks as an example, the system includes 8 storage blocks and an output cache with 8 data cache modules. In order to support the dual improvement of access efficiency and storage resource utilization, an arbitrator, 64 access queues and 64 selectors are set at the input interface of the system. The system continuously receives several access requests from 8 channels to 8 storage blocks in multiple clock cycles. These access requests are integrated according to the address and enter the classified 64 access queues for processing (the 64 access queues can be divided into 8 groups according to 8 channels or 8 storage blocks). The 64 access queues can initiate arbitration request signals (here, candidate arbitration requests) to their respective selectors in one clock cycle, and the 64 selectors select for their respective corresponding queues to obtain 64 target requests corresponding to the 64 queues. The arbitrator is configured to analyze the access queues associated with the 64 target requests through three-level arbitration, and select 8 valid requests from the 64 target requests as arbitration results for these queues (the remaining 56 requests are returned to the corresponding selector). According to the queue tags of these 8 valid requests, 8 target queues can be read from the 64 queues, and the addresses of the target storage blocks that the 8 target queues currently need to access can be taken out, that is, 8 target queues in the 64 queues are scheduled to be dequeued. According to the addresses of the 8 target storage blocks output by the 8 target queues, these 8 target storage blocks can be accessed to obtain the data in the target storage blocks. According to the channel corresponding to the queue, the data obtained from the storage block can be written to the data cache module of the corresponding channel. When the data cache module of a channel does not support continued writing of data, the arbitrator performs arbitration processing under back pressure and updates the arbitration result to avoid the loss of data obtained from the storage block due to nowhere to store.

[0098] After performing access based on an arbitration result, each queue may continue to submit candidate arbitration requests for access requests that have not been effectively accessed for selection by the selector, thereby performing new arbitration.

[0099] It should be understood that the aforementioned embodiments or application scenarios are only introductions to some implementation methods and are only used as examples. In other application scenarios, the dequeue scheduling of each queue may not be restricted by channel conditions, for example, a part of the queues without access conflicts may be selected randomly or according to a predefined priority for dequeueing.

[0100] For other details of the method part, please refer to the above description of the system part, which will not be repeated here. It should be understood that although the method is introduced using steps in the above embodiments, it should be understood that this is not a specific restriction on the execution order, and the steps can be executed synchronously or asynchronously as appropriate. The functions or related steps of the execution described above in conjunction with the system can be implemented by different hardware modules, circuits or components, or as part of the control circuit, control logic or controller of the processor.

[0101] In this specification, the phrases "in some embodiments", "in one embodiment", or "in an embodiment" appearing in various places throughout the specification do not necessarily refer to exactly the same embodiments. In addition, specific features, structures, or properties can be combined in any suitable manner in one or more embodiments or implementations, and thus, specific features, structures, or properties shown or described in conjunction with one embodiment can be combined in whole or in part with features, structures, or properties of one or more other embodiments without restriction, as long as the combination is not illogical or inoperable.

[0102] Although the present application has been described through the above-mentioned embodiments, the present application is not limited to the embodiments described herein, and also includes various changes and modifications made without departing from the scope of the present application.

Claims

1. A storage access system, characterized in that: It includes an arbitrator, a plurality of access queues, and a plurality of selectors corresponding to the plurality of access queues, respectively, one selector corresponding to one access queue; Each of the access queues is configured to: when the remaining number of arbitration applications of the current queue is not zero, send a candidate arbitration request to the selector corresponding to the access queue, and after the candidate arbitration request sent this time is selected by the selector, update the remaining number of arbitration applications of the access queue; wherein each of the access queues is configured with a first counter for recording the remaining number of arbitration applications of the current queue, and each of the access queues is configured to: when the current queue performs an enqueue operation, increase the remaining number of arbitration applications of the access queue; when the candidate arbitration request sent this time by the current queue is selected by the selector as the target request, reduce the remaining number of arbitration applications of the access queue; when the remaining number of arbitration applications of the current queue is zero, indicate that the current queue is in an empty queue state; Each selector is configured to: select the received candidate arbitration request and / or the first arbitration request fed back by the arbitrator after obtaining the arbitration result, so as to determine the target request to be sent to the arbitrator; The arbitrator is configured to: perform multi-level arbitration on the target request selected by each selector to obtain an arbitration result, and return the target request that has not been arbitrated as the first arbitration request to the corresponding selector according to the arbitration result, and the arbitration result is used to indicate that the target queue without access conflict in the multiple access queues is dequeued.

2. The storage access system according to claim 1, characterized in that: Each selector is configured as: When selecting a target request to participate in arbitration for a corresponding access queue, the priority of the first arbitration request is higher than the priority of the candidate arbitration request; When the candidate arbitration request is selected as the target request, a selection confirmation signal is sent to the corresponding access queue, so that the corresponding access queue updates the remaining number of arbitration applications of the access queue according to the selection confirmation signal.

3. The storage access system according to claim 1, characterized in that: The arbiter is configured to: receiving target requests selected by the multiple selectors for each access queue, determining valid requests from the target requests as arbitration results through multi-level arbitration, and using the arbitration results obtained at the end of the last level of arbitration as output of the arbitrator; For the last level of multi-level arbitration, the requests that have not been arbitrated at the last level are determined according to the arbitration result obtained at the end of the last level of arbitration, and are returned to the corresponding selector as the first arbitration request.

4. The storage access system according to claim 3, characterized in that: The arbitrator is further configured to: In the multi-level arbitration process, the arbitration of the next level is carried out according to the arbitration result obtained at the end of each level of arbitration. The arbitration result obtained at the end of each level of arbitration is used to indicate the valid request selected for arbitration at this level; For each level of arbitration, the requests to be arbitrated that are input to the arbitration at that level are latched, or the requests that are not arbitrated when the arbitration at that level ends are latched.

5. The storage access system according to any one of claims 1 to 4, characterized in that: The arbitrator is further configured to: When a backpressure request is received, updating the arbitration result currently arbitrated according to the backpressure request, wherein the backpressure request is used to indicate that some or all of the requests arbitrated from the target request this time are regarded as not being arbitrated; The unarbitrated requests in the target requests are determined according to the updated arbitration result, and are returned to the corresponding selector as the first arbitration request.

6. The storage access system according to any one of claims 1 to 4, characterized in that: Also includes: At least one storage block, each access queue is used to store address information of a target storage block to be accessed, the storage block is used to store accessible data, and each storage block supports access by one access queue at a time; The storage access system is configured to: Obtaining the address information of the target queue dequeue output corresponding to the arbitration result; The target storage block to be accessed by the target queue is accessed according to the address information, thereby obtaining data in the corresponding target storage block.

7. The storage access system according to claim 6, characterized in that: Also includes: At least one data cache module corresponding to the multiple access queues, the storage access system is further configured to: After accessing the target storage block according to the address information output by the target queue, writing the data accessed from the target storage block into the data cache module corresponding to the target queue; After the data cache module corresponding to the target queue is full, a back pressure request is sent to the arbitrator performing multi-level arbitration, so that the arbitrator updates the arbitration result currently arbitrated at the last level according to the back pressure request, and determines the arbitration request that is not currently arbitrated at the last level according to the updated arbitration result, and returns it to the corresponding selector as the first arbitration request.

8. The storage access system according to any one of claims 1 to 4, characterized in that: Also includes: At least one data cache module corresponding to the multiple access queues, the data cache module is used to store accessible data, each access queue is used to store address information of a data cache module to be accessed, and each data cache module supports access by one access queue at a time; The storage access system is configured to: Obtaining the address information of the target queue output corresponding to the arbitration result; The data cache module to be accessed by the target queue is accessed according to the address information, so as to read or write data to the corresponding data cache module.

9. A storage access scheduling method, characterized in that: A storage access system applied to any one of claims 1 to 8, the storage access system comprising an arbitrator, a plurality of access queues, and a plurality of selectors corresponding to the plurality of access queues, one selector corresponding to one access queue, each of the access queues being configured with a first counter for recording the remaining number of arbitration applications of the current queue; The method comprises: The plurality of access queues receive a plurality of access requests for at least one object to be accessed; For each access queue in the multiple access queues, when the remaining number of arbitration applications of the current queue is not zero, a candidate arbitration request is sent to the selector corresponding to the access queue, and after the candidate arbitration request sent this time is selected by the selector, the remaining number of arbitration applications of the access queue is updated; wherein, when the current queue performs an enqueue operation, the remaining number of arbitration applications of the access queue is increased; when the candidate arbitration request sent this time by the current queue is selected by the selector as a target request, the remaining number of arbitration applications of the access queue is reduced; when the remaining number of arbitration applications of the current queue is zero, it is indicated that the current queue is in an empty queue state; Each of the multiple selectors selects a request to participate in arbitration for the access queue corresponding to the selector, and sends the request as a target request to the arbitrator, where the target request is the candidate arbitration request sent by the access queue or the first arbitration request fed back by the arbitrator after obtaining the arbitration result; The arbitrator performs multi-level arbitration on the target request selected by each selector to obtain an arbitration result; The arbitrator instructs the target queue without access conflict among the multiple access queues to dequeue according to the arbitration result so as to access the object to be accessed currently corresponding to the target queue, and returns the target request that has not been arbitrated as the first arbitration request to the corresponding selector according to the arbitration result.

Citation Information

Patent Citations

  • On-chip system bus with anisochronous transmission structure

    CN105068951A

  • Memory access circuit, memory access method, integrated circuit and electronic equipment

    CN116521096A

  • Memory access circuit, memory access method, integrated circuit and electronic equipment

    CN116578245A

  • Memory access circuit, memory access method, integrated circuit and electronic equipment

    CN116661703A

  • Arbitration-based storage access system, processor and computing equipment

    CN117891758A