+

CN112491748B - A Credit-Based Proportional Fair Scheduling Method Supporting Data Packet Switching - Google Patents

A Credit-Based Proportional Fair Scheduling Method Supporting Data Packet Switching Download PDF

Info

Publication number
CN112491748B
CN112491748B CN202011309628.1A CN202011309628A CN112491748B CN 112491748 B CN112491748 B CN 112491748B CN 202011309628 A CN202011309628 A CN 202011309628A CN 112491748 B CN112491748 B CN 112491748B
Authority
CN
China
Prior art keywords
credit
intersection
resvn
data packets
output
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011309628.1A
Other languages
Chinese (zh)
Other versions
CN112491748A (en
Inventor
张卜方
刘淑涛
魏璇
刘扬
张宗森
刘海龙
刘丙亚
邢翔宇
马迅
张亚洲
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
CETC 54 Research Institute
Original Assignee
CETC 54 Research Institute
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by CETC 54 Research Institute filed Critical CETC 54 Research Institute
Priority to CN202011309628.1A priority Critical patent/CN112491748B/en
Publication of CN112491748A publication Critical patent/CN112491748A/en
Application granted granted Critical
Publication of CN112491748B publication Critical patent/CN112491748B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/25Routing or path finding in a switch fabric
    • H04L49/253Routing or path finding in a switch fabric using establishment or release of connections between ports
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/52Queue scheduling by attributing bandwidth to queues
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/62Queue scheduling characterised by scheduling criteria
    • H04L47/6215Individual queue per QOS, rate or priority

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a credit-based proportional fair scheduling method supporting data packet switching, and belongs to the technical field of high-speed serial switching output scheduling. The invention guarantees the boundary of necessary reserved bandwidth and distributable bandwidth for each data flow by means of parameter configuration, and guarantees each data flow to share the bandwidth fairly by using credit borrowing and supplementing mechanisms. By the method, the data stream can be isolated, different service streams can share the guaranteed bandwidth which can be shared by the different service streams, and even if malicious or highly bursty service streams exist, other normal service streams are not influenced.

Description

一种基于信用的支持数据包交换的比例公平调度方法A Credit-Based Proportional Fair Scheduling Method Supporting Data Packet Switching

技术领域technical field

本发明涉及高速串行交换输出调度技术领域,特别是指一种基于信用的支持数据包交换的比例公平调度方法。The invention relates to the technical field of high-speed serial switching output scheduling, in particular to a credit-based proportional fair scheduling method supporting data packet switching.

背景技术Background technique

交换芯片主要负责数据从一个端口到另一个端口的传输,主要包括输入/出端口、交换结构和控制模块。交换结构作为交换芯片的核心部分,其性能关系到交换芯片的整体性能。在交换结构的基础上,研究简单高效的调度算法,保证数据包的无阻塞交换以及低延迟,高吞吐率和公平性是交换芯片研究的重要方向。The switch chip is mainly responsible for the transmission of data from one port to another port, mainly including input/output ports, switching structure and control module. As the core part of the switching chip, the performance of the switching fabric is related to the overall performance of the switching chip. On the basis of the switching structure, the research of simple and efficient scheduling algorithm to ensure the non-blocking switching of data packets, low delay, high throughput and fairness is an important direction of switching chip research.

交叉点带缓存的联合输入交叉点排队(Combined Input and CrosspointQueuing,CICQ)结构是一种最简单而高性能的交换结构,它的优点是高吞吐率、低延迟,并且调度算法复杂度低,容易实现。同时,由于各个端口在空间上更加独立,在CICQ结构中,进行数据传输时输入过程和输出过程相互独立,从而取消了进行匹配的调度算法,这种交换结构既降低了算法的设计难度,又能保证交换系统的高速率运行。The Combined Input and Crosspoint Queuing (CICQ) structure with buffered crosspoint is one of the simplest and high-performance switching structures. It has the advantages of high throughput, low latency, and low complexity and easy scheduling accomplish. At the same time, since each port is more independent in space, in the CICQ structure, the input process and the output process are independent of each other during data transmission, thus canceling the matching scheduling algorithm. This switching structure not only reduces the design difficulty of the algorithm, but also It can ensure the high-speed operation of the switching system.

此外,由于CICQ结构使用了交叉点缓存,交叉点缓存将输入端和输出端之间隔离开来。所以,在调度过程中,端口之间的调度不需要进行“请求-允许-接受”的交互操作,因此CICQ调度算法可以采用分布式调度策略,也就是端口之间的调度相互隔离开来,互相之间没有任何信息依赖。采用这种分布式调度策略可大大降低算法的复杂度,并且可以根据端口自身的情况采用不同的调度策略,给了调度算法更大的灵活性和调度方式的多样性。此外,CICQ结构还支持对变长帧的交换调度,这是其他没有交叉点缓存结构的交换结构采用集中式调度方式很难做到的。In addition, since the CICQ structure uses a cross-point buffer, the cross-point buffer isolates the input from the output. Therefore, in the scheduling process, the "request-allow-accept" interactive operation is not required for the scheduling between ports, so the CICQ scheduling algorithm can adopt a distributed scheduling strategy, that is, the scheduling between ports is isolated from each other and There is no information dependency between them. Adopting this distributed scheduling strategy can greatly reduce the complexity of the algorithm, and can adopt different scheduling strategies according to the situation of the port itself, giving the scheduling algorithm greater flexibility and diversity of scheduling methods. In addition, the CICQ structure also supports switching scheduling of variable-length frames, which is difficult for other switching structures without a cross-point buffer structure to implement centralized scheduling.

高性能的交换结构和调度算法在一些共性问题方面应该具有有效性(包含吞吐率、稳定性和时延特性)、公平性和复杂性等诸多良好特性。因此,调度算法也必须以实现这三个目标来进行设计。由于各个端口在空间上更加独立,在CICQ结构中,进行数据传输时输入和输出端相互独立,从而可以采用分布式调度方式,即,输入端调度、输出端调度分别设计的方式。输入调度实现了同一端口内部流之间的公平性能,输出调度实现了不同端口流之间的公平性能,输入调度和输出调度共同实现了基于流的公平调度机制。目前的各种CICQ调度算法大部分是在IQ(Input Queued,输入排队)、OQ(Output Queued,输出排队)、CIOQ(Combined Input and Output Queued,联合输入输出排队)交换结构调度算法的基础上发展起来的,它们大体可以分为两类:High-performance switching structures and scheduling algorithms should have many good characteristics such as effectiveness (including throughput, stability and delay characteristics), fairness and complexity in some common problems. Therefore, scheduling algorithms must also be designed to achieve these three goals. Since each port is more independent in space, in the CICQ structure, the input and output terminals are independent of each other during data transmission, so a distributed scheduling method can be adopted, that is, the input terminal scheduling and output terminal scheduling are designed separately. Input scheduling realizes the fair performance between flows within the same port, and output scheduling achieves the fair performance between flows on different ports. Input scheduling and output scheduling jointly realize the flow-based fair scheduling mechanism. Most of the current CICQ scheduling algorithms are developed on the basis of IQ (Input Queued, input queuing), OQ (Output Queued, output queuing), CIOQ (Combined Input and Output Queued, combined input and output queuing) switching structure scheduling algorithm. They can be roughly divided into two categories:

(1)无队列状态信息的调度:如输入调度RR(Round Robin,轮询)-输出调度RR等。其优点是简单、硬件实现容易,缺点是虽然在均匀的业务流下性能良好,但在非均匀的业务流下性能无法令人满意。(1) Scheduling without queue status information: such as input scheduling RR (Round Robin, polling) - output scheduling RR, etc. The advantage is that it is simple and easy to implement in hardware. The disadvantage is that although the performance is good under uniform traffic flow, the performance is unsatisfactory under non-uniform traffic flow.

(2)基于队列状态信息的调度:如输入调度LQF(Longest Queue First,最长队列优先)-输出调度RR、输入调度OCF(Oldest Cell First,最久队列优先)-输出调度OCF等。与无队列状态信息的调度算法相比,这些算法性能比较好,但算法复杂度较高。(2) Scheduling based on queue status information: such as input scheduling LQF (Longest Queue First, longest queue first) - output scheduling RR, input scheduling OCF (Oldest Cell First, longest queue first) - output scheduling OCF, etc. Compared with scheduling algorithms without queue state information, these algorithms have better performance but higher algorithm complexity.

发明内容SUMMARY OF THE INVENTION

有鉴于此,本发明提供了一种基于信用的支持数据包交换的比例公平调度方法,该方法能够以较好的公平性和灵活性实现对多优先级业务的QOS支持和带宽的公平分配,可用于支持优先级调度的交叉点带缓存的CICQ交换电路。In view of this, the present invention provides a credit-based proportional fair scheduling method supporting data packet exchange, which can achieve QoS support for multi-priority services and fair bandwidth allocation with better fairness and flexibility, Can be used for CICQ switching circuits with buffered crosspoints that support priority scheduling.

为了实现上述目的,本发明采用的技术方案为:In order to achieve the above object, the technical scheme adopted in the present invention is:

一种基于信用的支持数据包交换的比例公平调度方法,包括以下步骤:A credit-based proportional fair scheduling method supporting data packet switching, comprising the following steps:

(1)将数据包在CICQ交叉点进行缓存排队,同时根据该交叉点缓存中数据包的优先级进行排序,每个CICQ交叉点设置一个计数器和一个比较器;(1) Queue the data packets at the CICQ intersection, and sort according to the priority of the data packets in the buffer at the intersection, and set a counter and a comparator for each CICQ intersection;

(2)每个交叉点队列根据该队列的空满情况向输出调度器发出申请;(2) Each intersection queue sends an application to the output scheduler according to the empty condition of the queue;

(3)输出调度器选择优先级最高的申请授权仲裁,优先级相同时采用轮询的方式授权仲裁;(3) The output scheduler selects the application with the highest priority to authorize arbitration, and the polling method is used to authorize arbitration when the priority is the same;

(4)各列交叉点初始时被分配的信用量为一正值resvn,当交叉点有数据包输出时,每个时钟周期把信用量resvn减1,直到信用量resvn为负;(4) The initially assigned credit of each column intersection is a positive value resvn. When there is a data packet output at the intersection, the credit resvn is decremented by 1 every clock cycle until the credit resvn is negative;

(5)当列交叉点信用量resvn为负时,借用处于idle状态的交叉点的初始信用量,总可借用量为所有idle状态交叉点信用量的和sum,并继续轮询仲裁;若信用量为负的列交叉点总信用量达到阈值min,则清零所有交叉点队列的信用量值,返回步骤(1);若总借用的信用量达到idle状态交叉点信用量的和sum,并且没有交叉点信用量resvn达到阈值min,则进入步骤(6);(5) When the credit amount resvn of the column intersection point is negative, the initial credit amount of the intersection point in the idle state is borrowed, and the total borrowable amount is the sum of the credit amounts of all the intersection points in the idle state, and the polling and arbitration continues; If the total credit of the column intersection with negative amount reaches the threshold min, the credit value of all intersection queues will be cleared, and return to step (1); if the total borrowed credit reaches the sum of the credit of the intersection in the idle state, and If there is no intersection credit amount resvn reaches the threshold min, then enter step (6);

(6)用信用量为负的交叉点补充一次resvn大小的信用量,若补充后有端口的信用量为正,则该端口连发,直至所有端口的信用量均为负时,开始轮询,轮询直到再次达到idle状态交叉点信用量的和sum时,再次进行补充;直到有端口信用量达到min值,重新回到步骤(1)。(6) Use the intersection with the negative credit to supplement the resvn-sized credit once. If the credit of the port is positive after the supplement, the port will send continuous transmission until the credit of all ports is negative, and start polling. , polling until the sum of the credits of the intersections of the idle state is reached again, and supplement it again; until the credits of some ports reach the min value, go back to step (1).

进一步的,步骤(1)中,数据包在CICQ交叉点进行缓存,根据该交叉点所有数据包的优先级标签进行排队,高优先级的数据包先于低优先级的数据包输出,同一优先级的数据包按照输出调度结果输出。Further, in step (1), the data packets are buffered at the CICQ intersection, and are queued according to the priority labels of all data packets at the intersection. The high-priority data packets are output before the low-priority data packets, and the same priority The data packets of the advanced level are output according to the output scheduling result.

进一步的,步骤(4)中为交叉点分配的resvn是实时更新的,resvn更新以时钟周期为单位,每个时钟周期结束更新结算。Further, the resvn allocated to the intersection in step (4) is updated in real time, and the resvn update takes the clock cycle as the unit, and the update settlement is completed at the end of each clock cycle.

进一步的,步骤(6)中信用量resvn为负值后,对其信用量补充时,只提供该交叉点可用的信用值,不修改交叉点resvn值,resvn值在交叉点输出数据包时的更新方式不变。Further, after the credit amount resvn is negative in step (6), when supplementing the credit amount, only the available credit value of the intersection is provided, and the resvn value of the intersection is not modified, and the resvn value is the same when the data packet is output at the intersection. The update method remains the same.

本发明与背景技术相比,具有如下优点:Compared with the background technology, the present invention has the following advantages:

(1)本发明通过把带宽的计算转化成信用量的计算,在实施过程中无需存储大量队列状态信息,只通过设置带宽计数器和相应的阈值,并通过不同条件的数值增减的方式即可实现对输出带宽的动态分配。因此,对于降低了调度算法的设计难度和复杂度。(1) The present invention converts the calculation of the bandwidth into the calculation of the credit amount, and does not need to store a large amount of queue status information during the implementation process. It only needs to set the bandwidth counter and the corresponding threshold, and increase or decrease the value of different conditions. Realize dynamic allocation of output bandwidth. Therefore, the design difficulty and complexity of the scheduling algorithm are reduced.

(2)本发明通过为每个交叉点预留信用量来保证他们的可用带宽,通过为每个交叉点设置独立的信用量更新机制,来确保不同的数据流能够享用自己可以享用的带宽,即使存在恶意或高突发性业务,也不会影响到自身的正常数据流。(2) The present invention ensures their available bandwidth by reserving credits for each intersection, and ensures that different data streams can enjoy their own bandwidth by setting up an independent credit update mechanism for each intersection, Even if there is malicious or highly bursty business, it will not affect its normal data flow.

(3)本发明通过配置max和min两个参数,这两个参数设置了每个交叉点信用量所能累积的界限,保证他们不会无限增加和减少。也可以灵活配置参数值来应对交叉点遭受不规则的流时(例如一个是272byte的数据包,另一个是32byte的数据包),对于边界的侦测。(3) The present invention configures two parameters, max and min. These two parameters set the limit that the credits of each intersection can be accumulated to ensure that they will not increase or decrease infinitely. The parameter value can also be flexibly configured to deal with the boundary detection when the intersection suffers from irregular flow (for example, one is a 272byte data packet and the other is a 32byte data packet).

(4)本发明还具有较强的灵活性性和适用性,能够在支持变长包的多种排队交换结构中使用,也可以根据业务类型灵活配置参数,使交换达到较好的性能。(4) The present invention also has strong flexibility and applicability, can be used in various queuing switching structures supporting variable-length packets, and can flexibly configure parameters according to business types, so that the switching can achieve better performance.

附图说明Description of drawings

图1是本发明实施例中交叉点缓存型CICQ交换结构输出调度示意图。FIG. 1 is a schematic diagram of output scheduling of a cross-point buffered CICQ switching structure in an embodiment of the present invention.

图2是本发明实施例中交叉点实现框图。FIG. 2 is a block diagram of an implementation of a cross point in an embodiment of the present invention.

图3是本发明实施例中公平调度方法的流程图。FIG. 3 is a flowchart of a fair scheduling method in an embodiment of the present invention.

图4是本发明实施例中公平调度器的实现框图。FIG. 4 is an implementation block diagram of a fair scheduler in an embodiment of the present invention.

具体实施方式Detailed ways

参照图1至图4,一种基于信用的支持数据包交换的比例公平调度方法,其包括以下步骤:1 to 4, a credit-based proportional fair scheduling method supporting data packet switching, which includes the following steps:

(1)配置阈值参数resvn,max,min(负值),对输入数据数据包在CICQ交叉点进行缓存排队,同时根据该交叉点缓存中数据包的优先级高低进行排序,每个CICQ交叉点设置一个计数器和一个比较器;(1) Configure the threshold parameters resvn, max, min (negative value), queue the input data packets at the CICQ intersection, and sort the packets according to the priority of the data packets in the buffer at the intersection. Each CICQ intersection Set up a counter and a comparator;

(2)每个交叉点队列根据该队列中空满的情况向输出调度器发出申请;(2) Each intersection queue sends an application to the output scheduler according to the empty condition of the queue;

(3)输出调度器选择优先级最高的申请授权仲裁,优先级相同时采用轮询的方式授权仲裁。(3) The output scheduler selects the application with the highest priority to authorize arbitration. When the priority is the same, the polling method is used to authorize arbitration.

(4)各列交叉点初始被分配初始信用量为resvn(正值),当交叉点有数据包输出时,每个时钟周期把信用量resvn减1,直到信用量resvn为负;(4) Each column intersection is initially assigned the initial credit amount resvn (positive value), when there is a data packet output at the intersection point, the credit amount resvn is decremented by 1 every clock cycle until the credit amount resvn is negative;

(5)列交叉点信用量resvn为负时,其将借用处于idle状态的交叉点的初始信用量,总可借用量为所有idle状态交叉点信用量的和sum,并开始继续轮询仲裁。如果信用量为负的列交叉点总信用量达到阈值min,则清零所有交叉点队列的credit值,同时回到步骤(1)。否则转到步骤(6)。(5) When the column intersection credit amount resvn is negative, it will borrow the initial credit amount of the intersection in the idle state, and the total borrowable amount is the sum of the credit amounts of all the intersection points in the idle state, and start to continue polling and arbitration. If the total credit of the column intersection with negative credit amount reaches the threshold min, then clear the credit value of all intersection queues, and return to step (1). Otherwise go to step (6).

(6)如总借用信用量达到idle状态交叉点信用量的和sum,并且没有交叉点信用量resvn达到min值,信用量为负的交叉点各自补充一次resvn大小的信用量,补充后开始在信用量为正的交叉点轮询调度(如补充后只有一个端口信用量为正,该端口连发直到为负),轮询直到再次到达阈值(同步骤步(3)的值),再次补充。直到有端口信用量达到min值。重置开始步骤(1)。(6) If the total borrowed credit reaches the sum of the credits of the intersections in the idle state, and there is no intersection credit resvn reaches the min value, the intersections with negative credits will each replenish the credits of the size of resvn once. Cross-point polling scheduling with positive credit (if only one port credit is positive after replenishment, and the port continues to send until it is negative), poll until the threshold (the value of step (3)) is reached again, and replenish again . Until the port credit reaches the min value. Reset start step (1).

如图1所示,数据包从输入端口进入CICQ交换结构,数据包根据其目标输出端口进入相应的交叉点进行缓存排队,优先级最高的数据包排在该交叉点最前面。其中,公平调度过程是指数据包从某一列N个交叉点,经输出调度到输出端口N的缓存的过程。As shown in Figure 1, the data packet enters the CICQ switching structure from the input port, and the data packet enters the corresponding cross point according to its target output port for buffering and queuing, and the data packet with the highest priority is queued at the top of the cross point. The fair scheduling process refers to a process in which data packets are scheduled from a certain column of N intersections to the buffer of output port N through output scheduling.

图1中输出调度是指从一列交叉点缓存中,选择一个有数据包的交叉点,并将该交叉点排队最前面的数据包发送到输出端口。In Figure 1, output scheduling refers to selecting a cross point with data packets from a column of cross point buffers, and sending the front data packet queued at the cross point to the output port.

图2是本发明实施例中交叉点实现框图。根据调度结果,调度器接口模块控制数据包根据交叉点情况向公平调度器提出申请,并根据调度器调度结果从缓存中读出,并且反馈给调度器交叉点当前状态。FIG. 2 is a block diagram of an implementation of a cross point in an embodiment of the present invention. According to the scheduling result, the scheduler interface module controls the data packet to apply to the fair scheduler according to the situation of the intersection, reads it from the cache according to the scheduling result of the scheduler, and feeds back the current state of the intersection to the scheduler.

图3是本发明实施例中公平调度方法的流程图。其中,根据端口的数据包队列长度(Qi),队首数据包优先级(pi)以及端口当前的信用量(ci)将端口划分为五个不同的状态:idle(空闲)、waking(待唤醒)、wait(等待)、series(连发)和round(轮巡)。状态定义如下:FIG. 3 is a flowchart of a fair scheduling method in an embodiment of the present invention. Among them, the port is divided into five different states: idle ( idle ), waking (waiting to wake up), wait (waiting), series (burst) and round (round). The states are defined as follows:

idle:Qi=0并且ci>0;idle: Q i =0 and c i >0;

waking:Qi=0并且ci≤0;waking: Q i =0 and c i ≤ 0;

wait:Qi>0并且pi<p;wait: Q i > 0 and p i <p;

series:Qi>0 并且ci>0、pi≥p;(p为其他队首数据包优先级)series: Q i >0 and c i >0, p i ≥p; (p is the priority of the first packet of other teams)

round:Qi>0并且ci≤0、pi≥p。round: Q i >0 and c i ≤ 0, p i ≥ p.

输出调度器选择优先级最高的申请授权仲裁是指对每个交叉点队首数据包的优先级进行比较,选择优先级最高的作为调度结果,当最高优先级数据包同时出现在同一列多个交叉点时,进行轮询仲裁,并启动公平调度机制。The output scheduler selects the application authorization arbitration with the highest priority, which means to compare the priority of the first data packet of each intersection, and select the highest priority as the scheduling result. When the highest priority data packets appear in the same column at the same time, multiple At the intersection point, round-robin arbitration is performed, and the fair scheduling mechanism is started.

流程2中idle状态是指初始时,交叉点没有数据包,被分配初始信用量;waking状态是信用量消耗变成负值或者0时状态。In process 2, the idle state refers to the initial time when there is no data packet at the intersection, and the initial credit is allocated; the waking state is the state when the credit consumption becomes negative or 0.

流程3中waiting状态表示该交叉点有数据包,但是该数据包优先级低于其他交叉点数据包优先级,该交叉点需要等待发送数据包。The waiting state in process 3 indicates that there is a data packet at the intersection, but the priority of the data packet is lower than that of other intersection points, and the intersection needs to wait to send data packets.

图4是本发明实施例中公平调度器的实现框图。配置模块对算法的三个相关参数max、min、resvn进行配置。参数定义如下:FIG. 4 is an implementation block diagram of a fair scheduler in an embodiment of the present invention. The configuration module configures the three related parameters max, min and resvn of the algorithm. The parameters are defined as follows:

resvn:预留信用量,初始状态各交叉点信用量以及各交叉点每次补充的信用量。resvn: reserved credits, credits at each intersection in the initial state, and credits replenished at each intersection each time.

min:单个交叉点信用量可达到的最小值,达到最小值后所有端口重置到初始状态,该值为负值。min: The minimum value that can be achieved by the credit of a single cross point. After reaching the minimum value, all ports are reset to the initial state. This value is a negative value.

max:resvn寄存器可配置的最大值。max: The configurable maximum value of the resvn register.

带宽分配寄存器根据各交叉点信用的消耗量和补充量决定各交叉点所能分配的带宽。信用量计数和更新模块根据算法规则决定信用量的增加和减小。The bandwidth allocation register determines the bandwidth that can be allocated by each cross-point according to the consumption and replenishment of each cross-point credit. The credit amount counting and updating module determines the increase and decrease of the credit amount according to the algorithm rules.

本方法中, max值是正值,min值时负值,两个数的绝对值相等。resvn是处于max到0之间的正值。三个参数的含义为:resvn表示预留信用量,初始状态各交叉点信用量以及各交叉点每次补充的信用量。min表示是单个交叉点信用量可达到的最小值,达到最小值后所有端口重置到初始状态。max表示resvn寄存器可配置的最大值。In this method, the max value is a positive value, the min value is a negative value, and the absolute values of the two numbers are equal. resvn is a positive value between max and 0. The meanings of the three parameters are: resvn represents the reserved credit amount, the credit amount of each intersection point in the initial state, and the credit amount supplemented each time at each intersection point. min indicates the minimum value that can be achieved by the credit of a single crosspoint. After reaching the minimum value, all ports are reset to the initial state. max indicates the configurable maximum value of the resvn register.

第(4)步中所述的信用量的更新方式为:当该交叉点有数据包输出时,每个时钟周期信用量减去1,直到数据包传输完毕,或者有信用量的更新操作。The update method of the credit amount described in step (4) is: when there is a data packet output at the intersection, the credit amount is subtracted by 1 in each clock cycle, until the data packet transmission is completed, or there is an update operation of the credit amount.

当只有一个交叉点信用量Ci>0时并且有数据包时,该交叉点处于series状态,调度器连续调度该交叉点数据包,直到状态发生改变。当有多个交叉点信用量Ci>0并且有数据包时,这些交叉点会处于round状态,调度器在这些交叉点进行轮巡调度,直到状态发生改变。When there is only one cross point credit C i > 0 and there are data packets, the cross point is in the series state, and the scheduler continuously schedules the cross point data packets until the state changes. When there are multiple cross-point credits C i > 0 and there are data packets, these cross-points will be in the round state, and the scheduler will perform round-robin scheduling at these cross-points until the state changes.

第(5)步中所述借用的信用量是实时更新的,当交叉点从idle状态变成其他状态时,sum值会更新。例如,开始只有一个交叉点发包,可借用信用量为(N-1)倍resvn。此时另一个交叉点有数据包等待发送,总可借用信用量立刻更新为(N-2)倍resvn。The borrowed credits described in step (5) are updated in real time, and the sum value is updated when the intersection changes from the idle state to other states. For example, there is only one cross-point to send packets at the beginning, and the amount of borrowable credits is (N-1) times resvn. At this time, there are data packets waiting to be sent at another intersection, and the total available credits are immediately updated to (N-2) times resvn.

第(5)步中所述的idle状态的交叉点的信用量必须是正值,负值时无法被借用。The amount of credit at the intersection of the idle state described in step (5) must be positive, and it cannot be borrowed when it is negative.

第(6)步中所述的交叉点各自补充一次resvn是指,所有当前状态有数据包等待发送(非空队列)的交叉点补充信用值。具体来说,首先实时计算处于借用状态交叉点的信用消耗量,对比idle状态交叉点信用量的和sum,如果两值相等,且这个过程中没有任何一个交叉点信用值达到min,则对当前信用量为负的交叉点进行补充,每次每个交叉点补充量为resvn。The intersections described in step (6) each replenish resvn once, which means that all intersections in the current state have data packets waiting to be sent (non-empty queues) to replenish the credit value. Specifically, first calculate the credit consumption at the intersection of the borrowing state in real time, and compare the sum of the credits at the intersection of the idle state. Intersections with negative credits are replenished, and each intersection is replenished with resvn.

借用状态交叉点的信用消耗量是指所有借用状态交叉点实际借用量的总和。The credit consumption of the borrow state intersection refers to the sum of the actual borrow amount of all borrow state intersections.

idle状态交叉点信用量的和sum是指当前列交叉点可以借用的信用量总和。其值始终大于实际借用量总和。The sum of the credits of the idle state intersections refers to the sum of the credits that can be borrowed at the current column intersections. Its value is always greater than the sum of the actual borrowings.

该方法通过可配置的阈值参数和初始信用量,设定调度器的计数边界,并且基于每个独立的交叉点的信用量的借用和补充机制,保证来源于每个端口的数据流都能按照比例实现不同端口的数据流之间公平共享输出带宽。This method sets the count boundary of the scheduler through configurable threshold parameters and initial credits, and based on the borrowing and replenishment mechanism of the credits of each independent intersection, it ensures that the data flow from each port can be The ratio enables fair sharing of output bandwidth among data streams on different ports.

总之,本发明针对交叉点缓存型CICQ交换结构输出调度算法针对不同源的数据流可能会被分配不同的服务带宽,无法公平分享的问题,通过参数配置的方式为每个数据流保证必须的预留带宽和可分配带宽的边界,并且使用信用量借用和补充机制,保证每个数据流公平分享带宽。通过本方法,还能够对数据流进行隔离,确保不同的业务流能够享用自己可以享用的被保证的带宽,即使存在恶意或高突发性业务流,也不致于影响到其它的正常业务流。In a word, the present invention aims at the problem that the output scheduling algorithm of the cross-point buffered CICQ switching structure may be allocated different service bandwidths for the data streams of different sources, which cannot be shared fairly. The boundary of bandwidth and allocable bandwidth is reserved, and the credit borrowing and replenishment mechanism is used to ensure that each data flow shares the bandwidth fairly. The method can also isolate the data flow to ensure that different service flows can enjoy the guaranteed bandwidth that they can enjoy. Even if there are malicious or highly bursty service flows, other normal service flows will not be affected.

Claims (3)

1.一种基于信用的支持数据包交换的比例公平调度方法,其特征在于,包括以下步骤:1. a credit-based proportional fair scheduling method supporting data packet exchange, characterized in that, comprising the following steps: (1)将数据包在CICQ交叉点进行缓存排队,同时根据该交叉点缓存中数据包的优先级进行排序,每个CICQ交叉点设置一个计数器和一个比较器;(1) Queue the data packets at the CICQ intersection, and sort according to the priority of the data packets in the buffer at the intersection, and set a counter and a comparator for each CICQ intersection; (2)每个交叉点队列根据该队列的空满情况向输出调度器发出申请;(2) Each intersection queue sends an application to the output scheduler according to the empty condition of the queue; (3)输出调度器选择优先级最高的申请授权仲裁,优先级相同时采用轮询的方式授权仲裁;(3) The output scheduler selects the application with the highest priority to authorize arbitration, and the polling method is used to authorize arbitration when the priority is the same; (4)各列交叉点初始时被分配的信用量为一正值resvn,当交叉点有数据包输出时,每个时钟周期把信用量resvn减1,直到信用量resvn为负;(4) The initially assigned credit of each column intersection is a positive value resvn. When there is a data packet output at the intersection, the credit resvn is decremented by 1 every clock cycle until the credit resvn is negative; (5)当列交叉点信用量resvn为负时,借用处于idle状态的交叉点的初始信用量,总可借用量为所有idle状态交叉点信用量的和sum,并继续轮询仲裁;若信用量为负的列交叉点总信用量达到阈值min,则清零所有交叉点队列的信用量值,返回步骤(1);若总借用的信用量达到idle状态交叉点信用量的和sum,并且没有交叉点信用量resvn达到阈值min,则进入步骤(6);(5) When the credit amount resvn of the column intersection point is negative, the initial credit amount of the intersection point in the idle state is borrowed, and the total borrowable amount is the sum of the credit amounts of all the intersection points in the idle state, and the polling and arbitration continues; If the total credit of the column intersection with negative amount reaches the threshold min, the credit value of all intersection queues will be cleared, and return to step (1); if the total borrowed credit reaches the sum of the credit of the intersection in the idle state, and If there is no intersection credit amount resvn reaches the threshold min, then enter step (6); (6)为信用量为负的交叉点补充一次resvn大小的信用量,若补充后有端口的信用量为正,则该端口连发,直至所有端口的信用量均为负时,开始轮询,轮询直到再次达到idle状态交叉点信用量的和sum时,再次进行补充;直到有端口信用量达到min值,重新回到步骤(1);信用量resvn为负值后,对其信用量补充时,只提供该交叉点可用的信用值,不修改交叉点resvn值,resvn值在交叉点输出数据包时的更新方式不变。(6) Supplement a resvn-sized credit for the intersection with negative credit. If the credit of any port is positive after the supplement, the port will send continuous transmission until the credit of all ports is negative, and start polling , polling until the sum of the credits of the intersection of the idle state is reached again, and supplement it again; until the credit of a port reaches the min value, go back to step (1); after the credit resvn is negative, its credit When supplementing, only the credit value available at the intersection is provided, and the resvn value of the intersection is not modified. The update method of the resvn value at the intersection outputting data packets remains unchanged. 2.根据权利要求1所述的一种基于信用的支持数据包交换的比例公平调度方法,其特征在于,步骤(1)中,数据包在CICQ交叉点进行缓存,根据该交叉点所有数据包的优先级标签进行排队,高优先级的数据包先于低优先级的数据包输出,同一优先级的数据包按照输出调度结果输出。2 . A credit-based proportional fair scheduling method supporting data packet switching according to claim 1 , wherein in step (1), data packets are buffered at a CICQ intersection, and all data packets at the intersection The priority label is queued, the high-priority data packets are output before the low-priority data packets, and the data packets of the same priority are output according to the output scheduling result. 3.根据权利要求1所述的一种基于信用的支持数据包交换的比例公平调度方法,其特征在于,步骤(4)中为交叉点分配的resvn是实时更新的,resvn更新以时钟周期为单位,每个时钟周期结束更新结算。3. A credit-based proportional fair scheduling method for supporting data packet switching according to claim 1, wherein the resvn allocated for the cross point in step (4) is updated in real time, and the resvn update is based on a clock cycle of Unit, the settlement is updated at the end of each clock cycle.
CN202011309628.1A 2020-11-20 2020-11-20 A Credit-Based Proportional Fair Scheduling Method Supporting Data Packet Switching Active CN112491748B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011309628.1A CN112491748B (en) 2020-11-20 2020-11-20 A Credit-Based Proportional Fair Scheduling Method Supporting Data Packet Switching

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011309628.1A CN112491748B (en) 2020-11-20 2020-11-20 A Credit-Based Proportional Fair Scheduling Method Supporting Data Packet Switching

Publications (2)

Publication Number Publication Date
CN112491748A CN112491748A (en) 2021-03-12
CN112491748B true CN112491748B (en) 2022-05-27

Family

ID=74932643

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011309628.1A Active CN112491748B (en) 2020-11-20 2020-11-20 A Credit-Based Proportional Fair Scheduling Method Supporting Data Packet Switching

Country Status (1)

Country Link
CN (1) CN112491748B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118869611A (en) * 2024-08-05 2024-10-29 无锡众星微系统技术有限公司 A programmable network transmission traffic scheduling method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1933441A (en) * 2005-09-16 2007-03-21 中国科学院计算技术研究所 Router exchange structure for supporting uniform exchange and service quality guarantee method
CN105163393A (en) * 2015-09-28 2015-12-16 上海理工大学 Wireless link resource management method for use in intelligent traffic
CN109379304A (en) * 2018-10-30 2019-02-22 中国电子科技集团公司第五十四研究所 A Fair Scheduling Method for Reducing the Delay of Low Priority Packets

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101958824B (en) * 2009-07-14 2012-06-27 华为技术有限公司 Data exchange method and data exchange structure
US8737414B2 (en) * 2009-12-10 2014-05-27 Polytechnic Institute Of New York University Scheduling, including distributed scheduling, for a buffered crossbar switch
CN101964758A (en) * 2010-11-05 2011-02-02 南京邮电大学 Differentiated service-based queue scheduling method
CN111934916B (en) * 2020-07-23 2023-05-09 中国科学院空间应用工程与技术中心 A network scheduling method and system based on mixed service transmission

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1933441A (en) * 2005-09-16 2007-03-21 中国科学院计算技术研究所 Router exchange structure for supporting uniform exchange and service quality guarantee method
CN105163393A (en) * 2015-09-28 2015-12-16 上海理工大学 Wireless link resource management method for use in intelligent traffic
CN109379304A (en) * 2018-10-30 2019-02-22 中国电子科技集团公司第五十四研究所 A Fair Scheduling Method for Reducing the Delay of Low Priority Packets

Also Published As

Publication number Publication date
CN112491748A (en) 2021-03-12

Similar Documents

Publication Publication Date Title
US7596086B2 (en) Method of and apparatus for variable length data packet transmission with configurable adaptive output scheduling enabling transmission on the same transmission link(s) of differentiated services for various traffic types
AU746166B2 (en) Fair and efficient cell scheduling in input-buffered multipoint switch
US7742411B2 (en) Highly-scalable hardware-based traffic management within a network processor integrated circuit
US6185221B1 (en) Method and apparatus for fair and efficient scheduling of variable-size data packets in an input-buffered multipoint switch
US7161906B2 (en) Three-stage switch fabric with input device features
US7474668B2 (en) Flexible multilevel output traffic control
US7539199B2 (en) Switch fabric scheduling with fairness and priority consideration
US6654343B1 (en) Method and system for switch fabric flow control
US6160812A (en) Method and apparatus for supplying requests to a scheduler in an input buffered multiport switch
US7023841B2 (en) Three-stage switch fabric with buffered crossbar devices
US12137055B2 (en) Virtual channel starvation-free arbitration for switches
JP4287157B2 (en) Data traffic transfer management method and network switch
US20110038261A1 (en) Traffic manager and a method for a traffic manager
JP2007512719A (en) Method and apparatus for guaranteeing bandwidth and preventing overload in a network switch
WO2010125448A1 (en) Hierarchical pipelined distributed scheduling traffic manager
US11483259B2 (en) VOQ-based network switch architecture using multi-stage arbitration fabric scheduler
CN102104545A (en) Credit scheduling method and device and bypass device for solving linear speed of packet
US20040083326A1 (en) Switch scheduling algorithm
US6947380B1 (en) Guaranteed bandwidth mechanism for a terabit multiservice switch
US20030223420A1 (en) Distributed weighted fair arbitration and forwarding
Zhang et al. Deficit round-robin scheduling for input-queued switches
CN101695051A (en) Queue length balance dispatching method used for buffered Crossbar
US8879578B2 (en) Reducing store and forward delay in distributed systems
CN112491748B (en) A Credit-Based Proportional Fair Scheduling Method Supporting Data Packet Switching
US7623456B1 (en) Apparatus and method for implementing comprehensive QoS independent of the fabric system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载