A method of multi-path polling arbitration and related apparatus

By employing a multi-path polling arbitration method with real-time data acquisition and state locking, combined with subtractors and logic gates, the conflict problem of accessing shared resources in on-chip networks and multi-core systems is resolved, achieving efficient and concise resource scheduling and system stability.

CN121092474BActive Publication Date: 2026-06-30XIAN MICROELECTRONICS TECH INST
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
XIAN MICROELECTRONICS TECH INST
Filing Date
2025-09-10
Publication Date
2026-06-30

AI Technical Summary

Technical Problem

Existing polling arbitration methods cannot effectively resolve conflicts in accessing shared resources in on-chip network systems and multi-core systems, and they also have shortcomings in terms of structural simplicity and applicability.

Method used

A multi-channel polling arbitration method is adopted to collect the input signals of all request source channels in real time, generate arbitration input information, locate the nearest request source channel based on the arbitration input information and the current polling pointer, perform the access operation, and update the polling pointer to wait for the next request trigger. A simple circuit structure is implemented using subtractors and logic gates.

Benefits of technology

It improves scheduling flexibility, simplifies circuit structure, enhances adaptability to different system bus competition problems, avoids communication conflicts, and improves resource access efficiency and system stability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121092474B_ABST
    Figure CN121092474B_ABST
Patent Text Reader

Abstract

This invention belongs to the field of integrated circuit design and computer networks, and discloses a multi-channel polling arbitration method and related apparatus. By real-time acquisition of input signals from all request source channels, the method enters arbitration mode upon detecting any request status signal, locks the request status of all current request source channels to generate arbitration input information, and uses this information combined with the current polling pointer to locate the nearest request source channel and generate an arbitration result. After performing the access operation, the method exits arbitration mode and updates the polling pointer to await the next request trigger. This method significantly improves scheduling flexibility to adapt to varying loads, simplifies circuit structure to reduce implementation complexity, enhances adaptability to different system bus contention problems to alleviate conflicts, effectively solves the problem of shared resource access conflicts in on-chip networks and multi-core systems, and meets the requirements for efficient access.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of integrated circuit design and computer network technology, and particularly relates to a multi-path polling arbitration method and related apparatus. Background Technology

[0002] In systems with multiple request sources accessing shared resources, arbitration of shared resources is a crucial step in ensuring stable system operation. Currently, various arbitration methods have been developed in the industry to address the access needs of multiple request sources to shared resources. Among them, the round-robin arbitration method is widely used to ensure the smoothness of the shared resource access process because it can evenly distribute access qualifications and prevent a single request source from occupying resources for a long time.

[0003] Existing polling arbitration methods mostly adopt a "request-as-authorize" design approach, meaning that when polling reaches the current channel, access is directly authorized if there is an access request for that channel. However, the above methods have limitations in terms of scheduling flexibility, circuit structure simplicity, and adaptability to different system bus contention issues, making it difficult to meet the needs of on-chip network systems and multi-core systems for efficient access to shared resources.

[0004] It is evident that existing polling arbitration methods cannot effectively resolve conflicts in accessing shared resources in on-chip network systems and multi-core systems, and also have shortcomings in terms of structural simplicity and applicability. Summary of the Invention

[0005] The purpose of this invention is to provide a multi-path polling arbitration method and related apparatus. This method can effectively schedule access to shared resources, thereby avoiding communication conflicts caused by multiple hosts accessing shared resources at the same time. This not only avoids functional abnormalities caused by conflicts, but also the calculation process and circuit structure of this method are simple, flexible, and widely applicable, and can handle bus contention problems within various systems.

[0006] To achieve the above objectives, the present invention adopts the following technical solution:

[0007] A multi-round polling arbitration method includes:

[0008] Real-time acquisition of input signals from all request source channels;

[0009] If the input signal of any one or more request source channels is a request status signal, enter the arbitration working state and lock the request status of all current request source channels, and generate arbitration input information;

[0010] Based on the arbitration input information and the current polling pointer, locate the most recent request source channel to generate the arbitration result;

[0011] Based on the arbitration result and the most recent request source channel, perform the access operation;

[0012] Exit the arbitration process and update the polling pointer to wait for the next request to be triggered based on the updated polling pointer.

[0013] Furthermore, before the real-time acquisition of input signals from all request source channels, the process includes:

[0014] Initialize the polling system:

[0015] Define the req[n:0] signal as the input signal of the request source channel, where a bit of 0 indicates that the corresponding request source channel has not initiated an access request, a bit of 1 indicates that the corresponding request source channel has initiated an access request, and n represents the number of channels;

[0016] Define round_port[n:0] as the request source channel of the current polling, and use it as the current polling pointer;

[0017] Define arb_port[n:0] as the current arbitration result.

[0018] Furthermore, if the input signal of any one or more request source channels is a request status signal, the system enters the arbitration working state and locks the request status of all current request source channels, generating arbitration input information, including:

[0019] When the input signal of any one or more request source channels becomes 1, the polling system enters the arbitration working state, immediately locks the request status of all current request source channels, and generates a request snapshot of the req[n:0] signal as arbitration input information;

[0020] The generated request snapshot is input into the arbitration unit of the polling system to execute the arbitration process.

[0021] Furthermore, the step of locating the most recent request source channel based on the arbitration input information and the current polling pointer to generate an arbitration result includes:

[0022] Collect a snapshot of the request for the req[n:0] signal and the current polling pointer round_port[n:0];

[0023] The req[n:0] signal is expanded to obtain the expanded input signal, and the current polling request source channel round_port[n:0] is expanded to obtain the expanded polling pointer;

[0024] The extended input signal is subtracted from the extended polling pointer. The difference is then bitwise inverted. The inverted result is then ORed with the original req[n:0] signal to locate the nearest request source channel and generate the arbitration result.

[0025] Furthermore, the base exits the arbitration working state and updates the polling pointer to wait for the next request to be triggered according to the updated polling pointer, including:

[0026] Before any access operation, the arbitration process is always maintained, the requested snapshot is locked, and changes from new requests are masked.

[0027] Furthermore, the step of exiting the arbitration working state and updating the polling pointer to wait for the next request to be triggered based on the updated polling pointer includes:

[0028] The specific steps to exit the arbitration process and update the polling pointer are as follows:

[0029] If the most recent request source channel located this time is the highest channel, then update the polling pointer to channel 0; otherwise, update the polling pointer to the most recent request source channel + 1.

[0030] The system waits for the next request to be triggered based on the updated polling pointer.

[0031] A multi-round polling arbitration system includes:

[0032] The data acquisition module is used to acquire input signals from all request source channels in real time.

[0033] The input information generation module is used to enter the arbitration working state and lock the request status of all current request source channels when the input signal of any one or more request source channels is a request status signal, and generate arbitration input information.

[0034] The arbitration result calculation module is used to locate the most recent request source channel based on the arbitration input information and the current polling pointer, in order to generate the arbitration result;

[0035] The execution module is used to perform access operations based on the arbitration result and the most recent request source channel;

[0036] The update module is used to exit the arbitration working state and update the polling pointer to wait for the next request to be triggered based on the updated polling pointer.

[0037] Furthermore, the arbitration result calculation module includes an arbitration unit;

[0038] The arbitration unit includes one subtractor, four inverters, and six logic gates. The input signal of the minuend of the subtractor is the request source input signal, and the input signal of the subtrahend is the current polling pointer. The output of the subtractor is connected to the input of the four inverters to invert the subtraction result. The corresponding bits of the output of each inverter and the original input signal are connected to the two inputs of an AND gate. The output of the AND gate is then connected to the input of an OR gate to output the arbitration result.

[0039] A multi-path polling arbitration device, comprising:

[0040] Memory, used to store computer programs;

[0041] A processor is used to implement the steps of the above-described multiple-round polling arbitration method when executing the computer program.

[0042] A computer-readable storage medium storing a computer program, which, when executed by a processor, is used to implement the steps of the above-described multiple-round polling arbitration method.

[0043] Compared with the prior art, the present invention has the following beneficial effects:

[0044] This invention provides a multi-path polling arbitration method. It acquires input signals from all request source channels in real time, enters arbitration mode upon detecting any request status signal, locks the request status of all current request source channels to generate arbitration input information, and uses this information combined with the current polling pointer to locate the nearest request source channel and generate an arbitration result. After performing the access operation, it exits arbitration mode and updates the polling pointer to await the next request trigger. The real-time acquisition and status locking mechanism ensures that arbitration processing is based on a consistent request snapshot, avoiding decision interference caused by real-time signal changes. The dynamic positioning and updating strategy of the polling pointer achieves fair scheduling based on position priority, preventing channel starvation and optimizing resource allocation. The arbitration state only operates when a request is active, reducing idle operation overhead and improving response efficiency. This significantly improves scheduling flexibility to adapt to varying loads, simplifies circuit structure to reduce implementation complexity, enhances adaptability to different system bus contention problems to alleviate conflicts, effectively solves the problem of shared resource access conflicts in on-chip networks and multi-core systems, and meets the requirements for efficient access.

[0045] Preferably, in this invention, the initialization step defines a request signal, a polling pointer, and an arbitration result signal to ensure the consistency and stability of the system state at startup, simplify the circuit implementation structure, make the design easier to understand and maintain, improve structural simplicity, facilitate adaptation to different system requirements, and reduce implementation complexity.

[0046] Preferably, in this invention, when a request signal is triggered, the state of all channels is immediately locked to generate a request snapshot as arbitration input. This prevents real-time signal changes from interfering with decision-making, improves arbitration accuracy, enhances robustness to bus contention scenarios, ensures arbitration is based on a consistent snapshot, reduces conflict risk, and improves response efficiency.

[0047] Preferably, in this invention, the most recent request source channel is located by performing subtraction, inversion, and logical OR operations after expanding the input signal and polling pointer. This method uses simple mathematical and logical operations to accelerate the arbitration process, optimize the hardware circuit structure, reduce implementation complexity, and improve scheduling efficiency and fairness.

[0048] Preferably, in this invention, an arbitration state lock request snapshot is maintained before the access operation and new request changes are shielded to ensure that the arbitration decision is not affected by external interference, improve system stability and reliability, enhance adaptability to dynamic bus contention, and prevent conflicts from occurring.

[0049] Preferably, in this invention, after exiting the arbitration state, the polling pointer is updated based on the position of the nearest channel. If it is the highest channel, it is reset to the initial channel; otherwise, it is incremented to ensure polling fairness, prevent channel starvation, optimize resource allocation efficiency, and simplify the pointer management process. Attached Figure Description

[0050] Figure 1 A general principle block diagram of the multi-path polling arbitration method provided in the embodiments of the present invention;

[0051] Figure 2 A schematic diagram of the polling arbitration process is provided for embodiments of the present invention;

[0052] Figure 3 A circuit schematic diagram of the arbitration unit is provided for embodiments of the present invention;

[0053] Figure 4 A flowchart of a multi-path polling arbitration method provided in an embodiment of the present invention;

[0054] Figure 5 This is a schematic diagram of a multi-path polling arbitration system provided in an embodiment of the present invention. Detailed Implementation

[0055] To facilitate a deeper understanding of the technical solution of the present invention, the following detailed description is provided in conjunction with embodiments:

[0056] As described in the background section, existing polling methods require determining whether a channel has filed an arbitration request before polling each channel. This can easily lead to communication conflicts due to access to shared resources, which in turn can cause functional abnormalities.

[0057] To achieve the above objectives, this embodiment provides a multi-path polling arbitration method. This method can fairly and sequentially poll each request source channel. When the currently polled channel has an access request, the arbitration approves the access operation of the current channel. When the currently polled channel has no access request, it approves the access operation of the channel that is closest to the current polling channel and has initiated the access request. After each access operation is completed, the polled channel is updated to the next channel after the channel that was approved in the last operation. Since it can directly jump to the channel that is closest to the currently polled channel and has initiated the access request, it is not necessary to poll each channel sequentially. This can save a lot of time in scenarios with a large number of request sources. At the same time, this method is implemented using a subtractor and logic gates, so the overall structure is simple and reliable, consumes few resources, is easy to port, and has good versatility.

[0058] like Figure 4 As shown, this embodiment provides a multi-way polling arbitration method, including:

[0059] Real-time acquisition of input signals from all request source channels;

[0060] If the input signal of any one or more request source channels is a request status signal, enter the arbitration working state and lock the request status of all current request source channels, and generate arbitration input information;

[0061] Based on the arbitration input information and the current polling pointer, locate the most recent request source channel to generate the arbitration result;

[0062] Based on the arbitration result and the most recent request source channel, perform the access operation;

[0063] Exit the arbitration process and update the polling pointer to wait for the next request to be triggered based on the updated polling pointer.

[0064] The polling arbitration method provided in this embodiment will be further explained below with reference to the accompanying drawings:

[0065] Before collecting the input signals of all request source channels in real time, the polling system needs to be initialized. The `req[n:0]` signal is defined as the input signal of the request source channel, where `n` represents the number of channels. When each bit is 0, it indicates that the corresponding request source channel has not initiated an access request; when each bit is 1, it indicates that the corresponding request source channel has initiated an access request. For example, when there are 4 request source channels, each bit of `req[3:0]` corresponds to the request status of channels 3 to 0 respectively. If `req[1]` is 1, it means that channel 1 has initiated an access request. Simultaneously, `round_port[n:0]` is defined as the request source channel currently being polled, serving as the current polling pointer. This signal can only have one bit set to 1. For example, when `round_port[2]` is 1, it indicates that channel 2 is currently being polled. Additionally, `arb_port[n:0]` is defined as the current arbitration result, which can also only have one bit set to 1, used to indicate the channel that has been approved for access.

[0066] like Figure 1 and Figure 2 As shown, after the system initialization is completed, the status control unit continuously monitors each bit of the req[n:0] signal through timing logic under the drive of the system clock (Clk) to obtain the access request status of each request source channel in real time.

[0067] When the input signal of any one or more request source channels becomes 1, the polling system enters the arbitration working state. At this time, the request status of all current request source channels must be locked immediately, and a request snapshot of the req[n:0] signal is generated and used as the arbitration input information. This is because the calculation process of the arbitration unit is implemented by combinational logic. If the request status is not locked, subsequent changes in the input signals of the request source channels will lead to unstable arbitration results, thereby affecting the normal operation of the system. After generating the request snapshot, it is input to the arbitration unit of the polling system to execute the arbitration process. For example, when the req signals of channel 1 and channel 3 become 1, the status control unit will freeze the req[3:0] value at this time, generate a request snapshot, and pass it to the arbitration unit.

[0068] Next, based on the arbitration input information and the current polling pointer, the nearest request source channel is located to generate the arbitration result. First, a request snapshot of the req[n:0] signal and the current polling pointer round_port[n:0] are captured. Then, the req[n:0] signal is expanded to obtain the expanded input signal. Specifically, req[n:0] is expanded to {req[n:0], req[n:0]}. This is done to handle the case where there is no request in the high bits of the current polling channel but a request in the low bits, ensuring that the nearest request source channel can be accurately found. At the same time, the current polling request source channel round_port[n:0] is expanded to obtain the expanded polling pointer. The expansion method is {(n{1'b0}), round_port[n:0]}, that is, 0 is padded to the first n bits, while keeping the subsequent polling pointer bits unchanged.

[0069] Next, a subtraction operation is performed between the expanded input signal and the expanded polling pointer, with the expanded input signal as the minuend and the expanded polling pointer as the subtrahend. Taking n=5 (i.e., 6 channels, channels 0 to 5) as an example, assume the current polling pointer round_port[5:0] is 001000 (polling channel 2), and the requested snapshot req[5:0] is 010000 (channel 4 has a request). The expanded input signal is 010000010000, and the expanded polling pointer is 000000001000. After performing the subtraction, the difference is obtained. This difference is then bitwise inverted, and the inverted result is logically ORed with the original req[n:0] signal. This logical operation identifies the most recently requested source channel, thus generating the arbitration result arb_port[n:0].

[0070] Before performing an access operation based on the arbitration result and the most recent request source channel, the arbitration process must be maintained at all times, the request snapshot must be locked, and changes from new requests must be masked. This is because if a new request signal changes during the access operation, it may interfere with the arbitration result, causing errors in the access operation. Therefore, it is essential to ensure that during the access operation, the arbitration unit operates only based on previously generated request snapshots and is unaffected by new requests.

[0071] After the access operation is completed, it is necessary to exit the arbitration working state and update the polling pointer to wait for the next request to be triggered based on the updated polling pointer. The specific steps for updating the polling pointer when exiting the arbitration working state are as follows: if the most recently requested source channel located this time is the highest channel (i.e., arb_port[n] is 1), then update the polling pointer to channel 0; otherwise, update the polling pointer to the most recently requested source channel + 1. For example, if the approved channel this time is 3 (not the highest channel, assuming the highest channel is 4), then the next polling pointer will be updated to channel 4; if the approved channel this time is 4 (the highest channel), then the next polling pointer will be updated to channel 0. After the update is completed, the system returns to the waiting state and continues to monitor the req[n:0] signal based on the updated polling pointer, waiting for the next request to be triggered.

[0072] In this embodiment, to more clearly illustrate the execution process of this polling arbitration method, we will take four request source channels (channels 0 to 3) as an example for detailed explanation. First, the system is initialized, defining req[3:0] as the input signal of the request source channel, round_port[3:0] as the current polling pointer, initially setting round_port[3:0] to 0001 (polling channel 0), and arb_port[3:0] as the arbitration result.

[0073] After initialization, the state control unit collects the input signals of req[3:0] in real time. Suppose that at a certain moment, req[3:0] becomes 0101 (that is, channel 1 and channel 3 initiate access requests). At this time, the input signal of any one or more channels is 1. The polling system enters the arbitration working state, immediately locks the current state of req[3:0], generates request snapshot 0101, and inputs the snapshot to the arbitration unit.

[0074] After the arbitration unit acquires the request snapshot 0101 and the current polling pointer round_port[3:0] (0001), it expands req[3:0] to obtain the expanded input signal 01010101; it also expands round_port[3:0] to obtain the expanded polling pointer 00000001. Then, it performs a subtraction calculation, with the minuend being 01010101 and the subtrahend being 00000001, resulting in 01010100. Next, it inverts the difference bit by bit to obtain 10101011. Then, it performs a logical OR operation with the inverted result and the original req[3:0] (0101). The bit corresponding to channel 1 in the result is 1, so the most recent request source channel is located as channel 1, and the arbitration result arb_port[3:0] is generated as 0010.

[0075] Subsequently, based on the arbitration result, Channel 1 performs an access operation. During the access operation, the state control unit maintains the arbitration working state, locks request snapshot 0101, and masks new request changes. When the access operation of Channel 1 is completed, the Req_done signal is set to 1, and the polling system exits the arbitration working state. At this time, since the most recent request source channel located this time is Channel 1, not the highest channel (the highest channel is 3), the polling pointer is updated to Channel 1 + 1 = 2, that is, round_port[3:0] becomes 0100. After the update is completed, the system enters a waiting state, monitors the req[3:0] signal based on the polling pointer 0100, and waits for the next request to be triggered.

[0076] Consider another scenario. Suppose the current polling pointer `round_port[3:0]` is 0100 (polling channel 2), and the requested snapshot `req[3:0]` is 0100 (channel 2 initiates an access request). The arbitration unit expands `req[3:0]` to 01000100 and `round_port[3:0]` to 00000100. A subtraction operation is performed: the minuend `01000100` is subtracted from the subtrahend `00000100`, resulting in `01000000`. The difference is bitwise inverted to obtain `10111111`, and then a logical OR operation is performed with the original `req[3:0]` (0100). The bit corresponding to channel 2 in the result is 1. Therefore, the arbitration result `arb_port[3:0]` is 0100, directly approving the access operation for the current polling channel. After the access is completed, since channel 2 is not the highest channel, the polling pointer is updated to channel 3 (channel 2+1), that is, round_port[3:0] becomes 1000, and the system waits for the next request.

[0077] Another scenario is that the current polling pointer round_port[3:0] is 0001 (polling channel 0), and the snapshot request req[3:0] is 1000 (channel 3 initiates an access request). The expanded input signal is 10001000, and the expanded polling pointer is 00000001. The subtraction result is 10000111, which is bitwise inverted to get 01111000. After performing a logical OR operation with the original req[3:0] (1000), the corresponding bit of channel 3 is 1, and the arbitration result arb_port[3:0] is 1000. After the access is completed, because channel 3 is the highest channel, the polling pointer is updated to channel 0, that is, round_port[3:0] becomes 0001, and the system continues to wait, as shown in Table 1.

[0078] Table 1 shows an example of the calculation method for the polling arbitration method when n=5.

[0079]

[0080] The multi-path polling arbitration method provided in this embodiment has significant advantages. In terms of time efficiency, traditional polling arbitration methods require sequentially traversing each channel, which consumes a significant amount of time when the number of requesting sources is large. This method, however, directly locates the nearest requesting source channel through subtraction and logical operations, eliminating the need for sequential traversal and greatly saving arbitration time. For example, when there are 16 requesting source channels, the currently polled channel is 0, and the nearest requesting channel is 15, the traditional method requires traversing all 15 channels, while this method only requires a single operation to locate the channel, significantly improving time efficiency.

[0081] like Figure 3 As shown, in terms of hardware implementation, a multi-channel polling arbitration system is also provided to implement the steps of this method. The core component of the multi-channel polling arbitration system is the arbitration unit. It adopts a combination structure of subtractors and logic gates, eliminating the need for complex state machines or memory, resulting in a simple, reliable structure with low resource consumption. Taking n channels as an example, the required hardware resources mainly consist of a 2n-bit subtractor, 2n inverters, and several AND and OR gates. Compared to the state machine-based arbitration method, hardware resource consumption can be reduced by 30% to 50%, and the circuit delay is mainly determined by the subtractor and the number of logic gates, meeting the timing requirements of high-speed systems. For example, in this embodiment, the arbitration unit includes one subtractor, four inverters, and six logic gates. The input signal of the minuend of the subtractor is the request source input signal, and the input signal of the subtrahend is the current polling pointer. The output of the subtractor is connected to the input of the four inverters to invert the subtraction result. The corresponding bits of the output of each inverter and the original input signal are connected to the two inputs of the AND gate. The output of the AND gate is then connected to the input of the OR gate to output the arbitration result.

[0082] Furthermore, this method boasts excellent versatility and portability. The number of channels can be expanded according to actual needs, from two channels to any number of channels, simply by proportionally increasing the bit depth of the subtractors and the number of logic gates; the circuit structure requires no fundamental change. Simultaneously, this method can be implemented on different hardware platforms such as FPGAs and ASICs, and is easily adapted to hardware description languages ​​such as Verilog and VHDL, facilitating portability and application across different systems.

[0083] For example, this method can be used in network interface cards (NICs) of systems such as PCs, servers, and measurement and control system centers, and is particularly suitable for computer network systems with high requirements for NIC reliability.

[0084] Using the polling arbitration method and system proposed in this embodiment, a dual-port 10 Gigabit Ethernet bridging chip can accurately and timely poll and arbitrate various interface accesses from dual-channel multi-queues and inform the host. The processing mechanism not only avoids competition for various access requests, but also ensures the integrity and correctness of data frames after the link is restored, effectively improving the reliability of the Ethernet controller. The key is that the method of this invention is simple, the circuit structure is small, and it greatly saves the power consumption and area of ​​the chip.

[0085] Based on the above scheme, the logical design of each module in this system is described using Verilog language, and then integrated with other modules in the network interface card device for system-level verification. Verification results show that the invention achieves its designed functions and its reliability meets expectations.

[0086] Therefore, this embodiment provides a multi-way polling arbitration method, which has the following advantages:

[0087] This method effectively and evenly distributes access to shared resources from multiple request sources, enabling accurate and rapid arbitration results and output from multiple request sources. The arbitrator implementation uses sequential logic to sample the input of the request sources and the output of the arbitration results. The use of subtractors and logic gates in the arbitration method implementation results in fast overall operation and low resource consumption.

[0088] like Figure 5 As shown, this embodiment also provides a multi-channel polling arbitration system, including: a data acquisition module for real-time acquisition of input signals from all request source channels; an input information generation module for entering arbitration working state and locking the request status of all current request source channels when the input signal of any one or more request source channels is a request status signal, and generating arbitration input information; an arbitration result calculation module for locating the nearest request source channel based on the arbitration input information and the current polling pointer, in order to generate an arbitration result; an execution module for performing access operations based on the arbitration result and the nearest request source channel; and an update module for exiting arbitration working state, updating the polling pointer, and waiting for the next request trigger according to the updated polling pointer.

[0089] The present invention also provides a multi-way polling arbitration device, comprising: a memory for storing a computer program; and a processor for executing the computer program to implement the steps of the multi-way polling arbitration method.

[0090] When the processor executes the computer program, it implements the above-mentioned multi-path polling arbitration steps, for example: real-time acquisition of input signals from all request source channels; if the input signal from any one or more request source channels is a request status signal, entering the arbitration working state and locking the request status of all current request source channels, generating arbitration input information; based on the arbitration input information and the current polling pointer, locating the nearest request source channel to generate an arbitration result; based on the arbitration result and the nearest request source channel, performing an access operation; exiting the arbitration working state, updating the polling pointer, and waiting for the next request trigger according to the updated polling pointer.

[0091] Alternatively, when the processor executes the computer program, it implements the functions of each module in the above system, such as: a data acquisition module for real-time acquisition of input signals from all request source channels; an input information generation module for entering the arbitration working state and locking the request status of all current request source channels when the input signal of any one or more request source channels is a request status signal, and generating arbitration input information; an arbitration result calculation module for locating the nearest request source channel based on the arbitration input information and the current polling pointer, in order to generate an arbitration result; an execution module for performing an access operation based on the arbitration result and the nearest request source channel; and an update module for exiting the arbitration working state, updating the polling pointer, and waiting for the next request trigger according to the updated polling pointer.

[0092] Exemplarily, the computer program can be divided into one or more modules / units, which are stored in the memory and executed by the processor to complete the present invention. The one or more modules / units can be a series of computer program instruction segments capable of performing preset functions, the instruction segments describing the execution process of the computer program in the multi-channel polling arbitration device. For example, the computer program can be divided into a data acquisition module, an input information generation module, an arbitration result calculation module, an execution module, and an update module; the specific functions of each module are as follows: the data acquisition module is used to acquire input signals from all request source channels in real time; the input information generation module is used to enter the arbitration working state and lock the request states of all current request source channels when the input signal of any one or more request source channels is a request status signal, generating arbitration input information; the arbitration result calculation module is used to locate the nearest request source channel based on the arbitration input information and the current polling pointer to generate an arbitration result; the execution module is used to perform an access operation based on the arbitration result and the nearest request source channel; the update module is used to exit the arbitration working state, update the polling pointer, and wait for the next request trigger according to the updated polling pointer.

[0093] The multi-way polling arbitration device can be a computing device such as a desktop computer, laptop, handheld computer, or cloud server. The multi-way polling arbitration device may include, but is not limited to, a processor and memory. Those skilled in the art will understand that the above are examples of multi-way polling arbitration devices and do not constitute a limitation on them. The device may include more components than described above, or combine certain components, or use different components. For example, the multi-way polling arbitration device may also include input / output devices, network access devices, buses, etc.

[0094] The processor referred to can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor, or any conventional processor, etc. The processor is the control center of the multi-channel polling arbitration, connecting various parts of the entire multi-channel polling arbitration device through various interfaces and lines.

[0095] The memory can be used to store the computer program and / or modules. The processor implements various functions of the multi-channel polling arbitration device by running or executing the computer program and / or modules stored in the memory and calling the data stored in the memory.

[0096] The memory may primarily include a program storage area and a data storage area. The program storage area may store the operating system and at least one application program required for a function (such as sound playback, image playback, etc.). The data storage area may store data created based on the use of the mobile phone (such as audio data, phonebook, etc.). Furthermore, the memory may include high-speed random access memory and non-volatile memory, such as hard disks, RAM, plug-in hard disks, smart media cards (SMC), secure digital cards (SD cards), flash cards, at least one disk storage device, flash memory device, or other volatile solid-state storage devices.

[0097] The present invention also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the described multi-way polling arbitration method.

[0098] If the modules / units integrated in the multi-path polling arbitration system are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium.

[0099] Based on this understanding, the present invention can implement all or part of the processes in the above-described multi-way polling arbitration method, or it can be accomplished by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the above-described multi-way polling arbitration method. The computer program includes computer program code, which can be in the form of source code, object code, executable file, or a preset intermediate form, etc.

[0100] The computer-readable storage medium may include: any entity or device capable of carrying the computer program code, recording media, USB flash drive, portable hard drive, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal, and software distribution medium, etc.

[0101] It should be noted that the content contained in the computer-readable storage medium may be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, the computer-readable storage medium does not include electrical carrier signals and telecommunication signals.

[0102] The above embodiments are merely one of the implementation methods for achieving the technical solution of the present invention. The scope of protection claimed by the present invention is not limited to this embodiment, but also includes any variations, substitutions and other implementation methods that can be easily conceived by those skilled in the art within the scope of the technology disclosed in the present invention.

Claims

1. A method of arbitrating a multiway poll, the method comprising: include: Real-time acquisition of input signals from all request source channels; If the input signal of any one or more request source channels is a request status signal, the system enters the arbitration working state and locks the request status of all current request source channels, generating arbitration input information, including: When the input signal of any one or more request source channels becomes 1, the polling system enters the arbitration working state, immediately locks the request status of all current request source channels, and generates a request snapshot of the req[n:0] signal as arbitration input information; The generated request snapshot is input into the arbitration unit of the polling system to execute the arbitration process; Based on the arbitration input information and the current polling pointer, locate the most recent request source channel to generate the arbitration result, including: Collect a snapshot of the request for the req[n:0] signal and the current polling pointer round_port[n:0]; The req[n:0] signal is expanded to obtain the expanded input signal, and the current polling request source channel round_port[n:0] is expanded to obtain the expanded polling pointer; The extended input signal is subtracted from the extended polling pointer. The difference is then bitwise inverted. The inverted result is then ORed with the original req[n:0] signal to locate the nearest request source channel and generate the arbitration result. Based on the arbitration result and the most recent request source channel, perform the access operation; Exit the arbitration process and update the polling pointer to wait for the next request to be triggered, including: If the most recent request source channel located this time is the highest channel, then update the polling pointer to channel 0; otherwise, update the polling pointer to the most recent request source channel + 1. Wait for the next request to be triggered based on the updated polling pointer; Before the real-time acquisition of input signals from all request source channels, the following steps are included: Initialize the polling system: Define the req[n:0] signal as the input signal of the request source channel, where a bit of 0 indicates that the corresponding request source channel has not initiated an access request, a bit of 1 indicates that the corresponding request source channel has initiated an access request, and n represents the number of channels; Define round_port[n:0] as the request source channel of the current polling, and use it as the current polling pointer; Define arb_port[n:0] as the current arbitration result; The step of exiting the arbitration working state and updating the polling pointer to wait for the next request to be triggered based on the updated polling pointer includes: Before any access operation, the arbitration process is always maintained, the requested snapshot is locked, and changes from new requests are masked.

2. A multi-path polling arbitration system for implementing the multi-path polling arbitration method of claim 1, characterized by include: The data acquisition module is used to acquire input signals from all request source channels in real time. The input information generation module is used to enter the arbitration working state and lock the request status of all current request source channels when the input signal of any one or more request source channels is a request status signal, and generate arbitration input information. The arbitration result calculation module is used to locate the most recent request source channel based on the arbitration input information and the current polling pointer, in order to generate the arbitration result; The execution module is used to perform access operations based on the arbitration result and the most recent request source channel; The update module is used to exit the arbitration working state and update the polling pointer so as to wait for the next request to be triggered based on the updated polling pointer; The arbitration result calculation module includes an arbitration unit; The arbitration unit includes one subtractor, four inverters, and six logic gates. The input signal of the minuend of the subtractor is the request source input signal, and the input signal of the subtrahend is the current polling pointer. The output of the subtractor is connected to the input of the four inverters to invert the subtraction result. The corresponding bits of the output of each inverter and the original input signal are connected to the two inputs of an AND gate. The output of the AND gate is then connected to the input of an OR gate to output the arbitration result.

3. A multiway polling arbitration device, characterized by include: Memory, used to store computer programs; A processor, configured to implement the steps of the multiple-round polling arbitration method of claim 1 when executing the computer program.

4. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it is used to implement the steps of the multi-way polling arbitration method of claim 1.

Citation Information

Patent Citations

  • Method and device for polling arbitration

    CN108153689A

  • Bus arbitration method, system and device and storage medium

    CN114996178A