Queue mapping optimization method based on CAM
Through the CAM-based queue mapping optimization method and deep learning algorithm, the resource bottleneck and static threshold alarm lag problems of traditional solutions in high concurrency and low latency business scenarios are solved, and efficient and dynamic queue mapping and load balancing are achieved.
Patent Information
- Application Number
- CN202510508729.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-22
- Publication Date
- 2025-07-11
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
In the prior art In network equipment, traditional queue mapping schemes are difficult to balance resource efficiency, dynamic scalability and energy efficiency in high concurrency and low latency business scenarios, especially when large-scale stream ID mapping, there are storage resource bottlenecks, hash collision delays and high power consumption problems. In addition, the traditional static threshold alarm mechanism cannot adapt to dynamic traffic changes, resulting in traffic scheduling lag.
The CAM-based queue mapping optimization method is adopted to split the stream ID into two parts as addresses, and the two pieces of RAM are used for parallel reading, and the PD number is determined through bitwise and operational operations. At the same time, it is combined with the deep learning algorithm to collect multi-dimensional load indicators in real time for structured encoding, and the overload risk is identified through spectral decomposition, and dynamic strategy adjustment and predictive load balancing are realized.
It effectively improves the resource efficiency and dynamic scalability of queue mapping, reduces latency and power consumption, realizes support for high-concurrency and low-latency services, and accurately identify overload risks through multi-dimensional load analysis, avoiding the problem of misjudgment lag in traditional solutions.
Smart Images

Figure CN120301844A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of data communication, and more specifically, to a method for optimizing queue mapping based on CAM. Background Art
[0002] In the field of data communication, with the expansion of network scale and the surge of traffic, network devices need an efficient queue mapping mechanism for processing a massive amount of data streams. In this context, how to accurately map the flow ID to the policy descriptor (PD) packet assembly has become a key technical challenge. The flow ID is usually used to identify a specific data stream in the network, while the PD packet assembly is used to define how to process these data streams, such as bandwidth limitation, traffic shaping, priority marking, etc., which generally refers to encapsulating data into protocol data units according to specific protocol specifications in a communication protocol or network transmission. The core of queue mapping lies in dynamically associating the flow ID that identifies the data stream with the policy descriptor (PD) packet assembly to support differentiated traffic control policies, so as to ensure that different service requirements are accurately met.
[0003] Traditional solutions rely on lookup tables or hash tables to implement the mapping from flow ID to PD. However, as the scale of flow IDs reaches hundreds of thousands, such static storage architectures face severe challenges. Specifically, taking the example of mapping 256k flow IDs to 16 PD packet assemblies and using 4 bits to store each mapping item, the traditional lookup table requires 1024KB of storage space, which causes a resource bottleneck for embedded devices or high-density network chips. Although the hash table can compress storage, the secondary lookup caused by hash conflicts will significantly increase the processing delay. Especially in forwarding scenarios above 100Gbps, the microsecond-level lookup operation will lead to a decrease in throughput and packet loss. In addition, the fixed mapping table is difficult to support dynamic policy adjustment. When the network topology changes or new PD packet assemblies need to be added, the entire mapping structure needs to be reconstructed, resulting in complex system maintenance. More critically, traditional solutions rely on a large number of static memory accesses. When supporting large-scale flow tables, frequent activation of storage units will significantly increase the chip power consumption. These limitations make the existing queue mapping technologies difficult to balance resource efficiency, dynamic scalability, and energy efficiency, restricting the ability of new-generation network devices to handle high-concurrency and low-latency service requirements.
[0004] Therefore, a queue mapping optimization scheme based on CAM is desired. Summary of the Invention
[0005] This application aims at the deficiencies in the prior art and provides a method for optimizing queue mapping based on CAM.
[0006] A CAM-based queue mapping optimization method, comprising: obtaining a flow ID to be mapped; splitting fields of the flow ID to be mapped to obtain a first flow ID part and a second flow ID part; respectively using the first flow ID part and the second flow ID part as addresses to read data at corresponding addresses in a first block of RAM and a second block of RAM to obtain first address data and second address data; performing a bitwise AND operation on the first address data and the second address data to obtain a bitwise AND operation result; and determining a PD number of the flow ID to be mapped based on the bitwise AND operation result.
[0007] Due to the adoption of the above technical solution, the present application has remarkable technical effects: The CAM-based queue mapping optimization method provided by the present application, after obtaining an 18-bit flow ID to be mapped, splits it into a 9-bit first flow ID part and a 9-bit second flow ID part, and uses these two parts as addresses respectively to read corresponding data from the first block of RAM and the second block of RAM, obtaining 16-bit first address data and 16-bit second address data. Subsequently, a bitwise AND operation is performed on the two sets of data to obtain an operation result. Finally, according to the bitwise AND operation result, the PD number corresponding to the flow ID to be mapped is determined. In this way, the queue mapping technology can effectively balance resource efficiency, dynamic scalability, and energy efficiency, and thus better meet the requirements of high-concurrency and low-latency services. BRIEF DESCRIPTION OF THE DRAWINGS
[0008] By describing the embodiments of the present application in more detail in conjunction with the accompanying drawings, the above and other objects, features, and advantages of the present application will become more obvious. The accompanying drawings are used to provide a further understanding of the embodiments of the present application, and constitute a part of the specification. Together with the embodiments of the present application, they are used to explain the present application, and do not constitute a limitation to the present application. In the accompanying drawings, the same reference numerals generally represent the same components or steps.
[0009] Figure 1 It is a flowchart of a CAM-based queue mapping optimization method according to an embodiment of the present application.
[0010] Figure 2 It is a flowchart of another step in the CAM-based queue mapping optimization method according to an embodiment of the present application.
[0011] Figure 3 It is a schematic diagram of data flow of another step in the CAM-based queue mapping optimization method according to an embodiment of the present application.
[0012] Figure 4 It is a flowchart of step S140 in the CAM-based queue mapping optimization method according to an embodiment of the present application. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0013] Next, example embodiments according to the present application will be described in detail with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments of the present application. It should be understood that the present application is not limited by the example embodiments described herein.
[0014] In the field of data communication, the expansion of network scale and the surge in traffic have put forward higher requirements for the queue mapping mechanism. The current core challenge is how to accurately map a large number of flow IDs to policy descriptor (PD) packet assemblies to achieve differential traffic control. Traditional solutions build static mapping relationships based on lookup tables or hash tables, but there are significant limitations in scenarios where 256k flow IDs are mapped to 16 PD packet assemblies: the lookup table requires 1024KB of storage space, forming a resource bottleneck for embedded devices; although the hash table compresses storage, it faces the secondary lookup delay caused by hash conflicts and is difficult to meet the microsecond-level processing requirements of 100Gbps forwarding scenarios. In addition, the static architecture is difficult to support dynamic policy adjustment. Policy changes require reconstructing the mapping table, resulting in complex operation and maintenance. At the same time, frequent memory accesses increase the chip power consumption. These limitations make it difficult to balance the storage efficiency, dynamic scalability, and energy efficiency of existing queue mapping technologies, restricting the technological evolution of high-concurrency and low-latency service scenarios.
[0015] It should be understood that a content-addressable memory (CAM) is a special storage structure, and its core feature is that it can directly retrieve the corresponding storage address through the data content, which is in sharp contrast to the traditional random access memory (RAM) that accesses data through addresses. In technical implementation, the CAM quickly locates the target entry that is exactly the same as the input content by parallelly matching the data items in all storage units and returns its physical address or associated information. This feature gives it significant advantages in scenarios that require high-speed search (such as network packet processing, routing table query, cache tag matching). In the present application, the CAM is constructed by two 512x16-bit RAM modules, each storing 512 16-bit data items, and an efficient mapping from flow ID to PD packet assembly is implemented based on this structure. Compared with the linear search method of traditional RAM that requires traversal or binary search, the parallel matching mechanism of the CAM can reduce the time complexity to O(1), thus meeting the low-latency data processing requirements of communication systems with strict real-time requirements.
[0016] Based on this, the present application proposes an optimized method for queue mapping based on CAM. Figure 1 It is a flowchart of the optimized method for queue mapping based on CAM according to an embodiment of the present application. As Figure 1As shown in the figure, the CAM-based queue mapping optimization method according to an embodiment of the present application includes: S1, obtaining a flow ID to be mapped; S2, splitting the fields of the flow ID to be mapped to obtain a first flow ID part and a second flow ID part; S3, respectively using the first flow ID part and the second flow ID part as addresses to read the data at the corresponding addresses in the first block of RAM and the second block of RAM to obtain first address data and second address data; S4, performing a bitwise AND operation on the first address data and the second address data to obtain a bitwise AND operation result; S5, based on the bitwise AND operation result, determining the PD number of the flow ID to be mapped.
[0017] In step S1, a flow ID to be mapped is obtained. Specifically, in an embodiment of the present application, the flow ID to be mapped has 18 bits. It should be understood that the flow ID to be mapped (18 bits) is the core identifier for the network device to distinguish different data flows. The 18-bit flow ID can represent 262,144 different data flows, which can cover the flow table requirements of a 256k scale, and thus can effectively avoid policy conflicts caused by duplicate flow IDs. That is, obtaining the flow ID to be mapped is to uniquely identify each data flow, which is the basis for the entire mapping process.
[0018] In step S2, the fields of the flow ID to be mapped are split to obtain a first flow ID part and a second flow ID part. Specifically, in an embodiment of the present application, the first flow ID part and the second flow ID part each have 9 bits. It should be understood that the present application uses a CAM structure composed of two 512x16-bit RAMs to implement the mapping from the flow ID to the PD packet assembly. Each block of RAM can store 512 data items, and the address space is 9 bits (2 9 ^9 = 512). Splitting the 18-bit flow ID to be mapped into two 9-bit parts and using them as the addresses of the two blocks of RAM for operation can be adapted to the hardware structure of the CAM and make full use of its storage and search characteristics. In this way, each flow ID can find a corresponding storage location in the storage system of the CAM, thereby providing a basis for subsequent data reading and establishment of the mapping relationship. And through splitting, data can be read in parallel in the two blocks of RAM. Compared with using a larger storage unit to store the complete mapping relationship, it greatly improves the data search speed, reduces the search time, and meets the requirements of the high-speed network environment for low latency. In addition, splitting the flow ID to be mapped into two parts can make the mapping process more modular and clear. Each 9-bit part corresponds to a block of RAM, and when establishing and querying the mapping relationship, the logic is simpler and clearer, which is convenient for the system to operate and manage, reduces the complexity of the system, and is also beneficial to the subsequent maintenance and expansion of the mapping relationship.
[0019] In step S3, using the first stream ID part and the second stream ID part as addresses respectively, the data at the corresponding addresses in the first block of RAM and the second block of RAM are read to obtain first address data and second address data. Specifically, in the embodiments of the present application, the first address data and the second address data are 16-bit. It should be understood that the parallel address data reading of the two blocks of RAM enables the table lookup process to avoid sequential access or hash collision detection. Hardware can simultaneously obtain the candidate policy masks (16 bits each) of the high / low order fields within a single cycle, which can provide input for the subsequent bitwise AND operation, thus avoiding the multiple memory accesses and latency jitter caused by conflicts in traditional hash tables.
[0020] In step S4, a bitwise AND operation is performed on the first address data and the second address data to obtain a bitwise AND operation result. It should be understood that performing a bitwise AND operation on the first address data and the second address data is to filter out the unique valid policy descriptor (PD) identifier through logical operations, solving the problem of policy ambiguity caused by hash conflicts or static mapping in traditional solutions. Specifically, since the first address data and the second address data are respectively 16-bit masks output from two independent RAMs (each bit represents the candidate state of a PD), the bitwise AND operation can use the intersection of the two masks as the determination basis for the valid policy, that is, only when a certain PD is marked as valid in both masks (the corresponding bit positions are both 1), will this PD be finally selected. This design replaces the multiple table lookups or conflict handling processes in traditional solutions through hardware-level logical operations, avoiding the risk of hash conflicts, ensuring the uniqueness of the mapping from the stream ID to the PD, and at the same time providing underlying support for dynamic policy adjustment - by modifying the value of the mask bit in any RAM, the binding relationship between the stream ID and the PD can be redefined without reconstructing the global mapping table.
[0021] In step S5, based on the result of the bitwise AND operation, determine the PD number of the to-be-mapped flow ID. Specifically, in the embodiment of the present application, step S5 includes: If exactly one bit in the result of the bitwise AND operation is 1, the position of this bit is the PD number of the to-be-mapped flow ID. Specifically, in the embodiment of the present application, step S5 includes: If all the results of the bitwise AND operation are 0, it means that there is no PD number matching the to-be-mapped flow ID. It should be understood that the PD number is used to uniquely identify a specific PD packet assembly. Each PD number corresponds to a set of predefined processing rules or parameter sets, which is convenient for quickly locating and selecting the appropriate PD packet assembly to process the data stream. During communication, the PD packet assembly encapsulates the data according to specific protocol specifications to ensure the efficiency and accuracy of data transmission. Determining the PD number of the to-be-mapped flow ID through the result of the bitwise AND operation, its core purpose is to convert the result of the hardware logic operation into a clear policy execution instruction to ensure that each data stream can accurately match the predefined processing rules. Since the result of the bitwise AND operation is a 16-bit mask (for example, 0x0002 corresponds to the binary 0000000000000010), this step determines whether the flow ID has a valid configured policy by detecting whether the result is a single valid bit (only 1 bit is 1) or all 0. If exactly one valid bit exists in the result, its position (such as the 2nd bit, with the index from right to left being 1) corresponds to the PD number (such as PD = 1), thereby binding the network traffic to the corresponding PD packet assembly; if the result is all 0, it indicates that the current flow ID has no configured policy, and the default processing rule or alarm mechanism can be triggered. In this way, through a strict bit detection mechanism, it is possible to avoid problems such as overlapping of multiple policies or no policy matching caused by hash conflicts or mapping table errors in traditional solutions, and at the same time, it can provide clear feedback on the effective state for the dynamic configuration of policies.
[0022] In summary, the CAM-based queue mapping optimization method based on the embodiment of the present application is elucidated. After obtaining the 18-bit to-be-mapped flow ID, it is split into a 9-bit first flow ID part and a 9-bit second flow ID part, and these two parts are respectively used as addresses to read the corresponding data from the first block of RAM and the second block of RAM, obtaining 16-bit first address data and 16-bit second address data. Subsequently, a bitwise AND operation is performed on the two sets of data to obtain an operation result. Finally, based on this bitwise AND operation result, the PD number corresponding to the to-be-mapped flow ID is determined. In this way, the queue mapping technology can effectively balance resource efficiency, dynamic scalability, and energy efficiency, and thus better meet the requirements of high-concurrency and low-latency services.
[0023] In particular, driven by the dual factors of surging network traffic and business diversification, queue congestion in network devices has become a core problem restricting service quality. The dynamic accumulation of massive data streams in the PD packet assembly queue often leads to problems such as buffer overflow, packet loss, and end-to-end delay jitter. Traditional solutions rely on static threshold warning mechanisms. For example, when the queue length of PD packet assembly exceeds a preset threshold, traffic scheduling is triggered. However, this passive response mode has fundamental defects: First, fixed thresholds cannot adapt to the dynamic changes of traffic characteristics. For example, the load patterns of bursty live traffic and periodic data reporting are significantly different, and a single threshold is likely to cause frequent false alarms or missed alarms. Second, the formation of queue overload is often caused by the coupling of multi-dimensional factors. It is difficult to accurately represent the true load status of PD packet assembly only based on the queue length indicator. For example, when the CPU utilization rate has reached 90% but the queue length has not reached the threshold, the system may still experience hidden overload due to the exhaustion of computing resources. Third, traditional methods lack forward-looking judgment of traffic trends and can only start policy adjustments after queue congestion occurs, resulting in traffic scheduling lagging behind actual needs.
[0024] Based on this, the technical concept of this application is to use data analysis and processing algorithms based on deep learning to first collect heterogeneous indicators such as the queue depth, CPU load, and bandwidth occupancy rate of each PD packet assembly in real time, fuse and encode them into a structured vector representing the current operating state, and then use a query response mechanism to perform similarity matching between the state characteristics of the PD packet assembly to be evaluated and each real-time state feature library, and reveal its abnormal association characteristics in the global load distribution through the response vector. Finally, it can intelligently judge and dynamically determine the overload risk. This solution breaks through the limitations of traditional single-dimensional threshold determination, accurately identifies hidden overload caused by resource competition through multi-index collaborative modeling, effectively solves the misjudgment and lag problems of the static threshold mechanism, and realizes the leap from passive warning to predictive load balancing.
[0025] Figure 2 It is a flowchart of another step in the CAM-based queue mapping optimization method according to an embodiment of the present application. Figure 3 It is a schematic diagram of data flow of another step in the CAM-based queue mapping optimization method according to an embodiment of the present application. As Figure 2 and Figure 3As shown, the CAM-based queue mapping optimization method according to an embodiment of the present application further includes: S110, obtaining the actual load conditions of each PD packet, where the actual load conditions include queue length, CPU utilization, and bandwidth utilization; S120, performing structured embedding encoding on the actual load conditions of each PD packet to obtain a set of structured embedding encoding vectors of PD packet states; S130, extracting the structured embedding encoding vector of the PD packet state corresponding to the PD packet to be recognized from the set of structured embedding encoding vectors of PD packet states as the query encoding vector of the PD packet state; S140, performing PD packet state query based on spectral graph decomposition on the query encoding vector of the PD packet state and the set of structured embedding encoding vectors of PD packet states to obtain a query response encoding vector of the PD packet state; S150, based on the query response encoding vector of the PD packet state, determining whether to mark the PD packet to be recognized as an overloaded PD packet.
[0026] In step S110, the actual load conditions of each PD packet are obtained, where the actual load conditions include queue length, CPU utilization, and bandwidth utilization. It should be understood that in the process of a network device processing a large amount of data streams, relying on a single indicator cannot comprehensively and accurately evaluate the load status of PD packets. The queue length reflects the accumulation of data in the PD packet queue. The continuous increase in the queue length often means that there are more data streams waiting to be processed, which may lead to buffer overflow and packet discard, and is an important indicator directly reflecting the current load pressure of PD packets. The CPU utilization is related to the computing ability of the network device to process data. If the CPU utilization is too high, even if the queue length does not reach the traditional threshold, the device may not be able to process newly incoming packets in time due to insufficient computing resources, thus causing hidden overload. The bandwidth utilization indicates the degree of use of network bandwidth resources. Excessive bandwidth utilization may lead to an increase in data transmission delay and affect network performance. Generally speaking, the queue length, CPU utilization, and bandwidth utilization respectively reveal the resource status of PD packets from the three dimensions of storage, computing, and transmission, and can provide a comprehensive basis for accurately determining whether a PD packet is overloaded.
[0027] In step S120, the actual load conditions of the respective PD packets are subjected to structured embedding encoding to obtain a set of structured embedding encoding vectors of the PD packet states. Accordingly, considering that the load state of the PD packets is essentially the result of the dynamic coupling of multiple dimensions such as queue cache resources, computing resources, and transmission bandwidth, relying solely on an isolated metric such as the queue length can neither characterize the potential processing delay caused by CPU overload nor identify the non-linear correlation between bandwidth saturation and cache occupancy. Moreover, for different types of data, their value ranges and physical meanings are different. Based on this, in the technical solution of the present application, the actual load conditions of the respective PD packets are subjected to structured embedding encoding to obtain a set of structured embedding encoding vectors of the PD packet states. In particular, in a specific example of the present application, a multi-layer perceptron can be used to perform structured encoding on the actual load conditions of the respective PD packets to obtain a set of structured embedding encoding vectors of the PD packet states. Specifically, heterogeneous metrics such as queue length, CPU utilization, and bandwidth utilization are used as input features, and cross-dimensional feature interaction and abstraction are performed through the hidden layer of the multi-layer perceptron. That is, the multi-layer perceptron has a powerful non-linear mapping ability. Through the combination of multiple layers of neurons and the action of activation functions, it can automatically learn and capture the non-linear correlation between these metrics, thereby encoding the actual load conditions more accurately. For example, CPU utilization and bandwidth utilization may jointly affect the change in queue length, and this complex relationship is difficult to describe with a simple linear model, while the multi-layer perceptron can effectively handle it.
[0028] In step S130, a packet data (PD) packet status structured embedding encoding vector corresponding to the PD packet to be recognized is extracted from the set of PD packet status structured embedding encoding vectors as a PD packet status query encoding vector. Correspondingly, considering that the set of PD packet status structured embedding encoding vectors contains the status information of multiple PD packets, the limitation of traditional overload detection methods lies in their isolated decision-making logic - the load status of each PD packet is evaluated independently, lacking the correlation analysis of the global resource distribution situation. When there are hundreds of PD packets working together in the network, the overload risk of a single node is often closely related to the overall load balancing state. For example, a certain PD packet may face potential congestion due to resource preemption by adjacent nodes, but its local indicators (such as queue length) have not reached the warning threshold, and it is difficult to predict the risk based on its own data alone. Based on this, in the technical solution of this application, a PD packet status structured embedding encoding vector corresponding to the PD packet to be recognized is extracted from the set of PD packet status structured embedding encoding vectors as a PD packet status query encoding vector. In this way, the difference degree between the status of the PD packet to be recognized and that of other PD packets or the normal status can be judged, so as to realize anomaly detection. For example, if the query encoding vector has a low similarity with the encoding vectors of most normal statuses, it may mean that there are abnormal loads or other problems with the PD packet to be recognized.
[0029] In step S140, a PD packet status query based on spectral graph decomposition is performed on the PD packet status query encoding vector and the set of PD packet status structured embedding encoding vectors to obtain a PD packet status query response encoding vector. Specifically, Figure 4 FIG. is a flowchart of step S140 in the CAM-based queue mapping optimization method according to an embodiment of the present application. As Figure 4As shown, step S140 includes: S141, performing dynamic coupling decision point response on each PD packetization state structured embedding coding vector in the set of the PD packetization state query coding vector and the PD packetization state structured embedding coding vectors to obtain a set of PD packetization state decision point implicit coding vectors; S142, calculating a PD packetization state decision point state class neighborhood matrix based on the set of the PD packetization state decision point implicit coding vectors; S143, calculating a PD packetization state decision point state class degree matrix based on the set of the PD packetization state decision point implicit coding vectors; S144, calculating a PD packetization state decision point state Laplacian matrix based on the PD packetization state decision point state class neighborhood matrix and the PD packetization state decision point state class degree matrix; S145, performing spectral decomposition on the PD packetization state decision point state Laplacian matrix to obtain a set of PD packetization state decision point key component coding vectors; S146, performing dynamic fusion on the set of the PD packetization state decision point key component coding vectors to obtain the PD packetization state query response coding vector.
[0030] It should be understood that the overload risk of PD packetization is often not an isolated event, but there are complex conduction and competition relationships with the load states of other nodes in the network. For example, a certain PD packet may enter a sub-healthy state due to resource preemption by adjacent nodes, but its own indicators have not triggered a threshold alarm; or when multiple nodes form a load resonance mode, even if the indicators of a single node are normal, the overall system may still face the risk of avalanche congestion. The traditional method based on single-node threshold determination cannot capture this unique group abnormal mode of distributed systems. The root cause is that it treats each PD packet as an independent unit and lacks the ability to jointly model the global state map of the network. Based on this, this application performs PD packetization state query based on spectral graph decomposition on the set of the PD packetization state query coding vector and the PD packetization state structured embedding coding vectors to obtain the PD packetization state query response coding vector.
[0031] Specifically, this step first uses dynamic coupling decision point response to perform implicit space mapping on the query vector and other vectors in the set, and captures its potential interaction patterns through non-linear transformation (such as the cross-node competition relationship between bandwidth occupancy rate and CPU load). Subsequently, a decision point class neighborhood matrix and a class degree matrix are constructed based on the set of implicit space vectors to explicitly encode the local connection strength and global weight distribution between nodes. Through spectral decomposition of the Laplacian matrix, the complex correlation relationships in the high-dimensional feature space are transformed into key component coding vectors in the low-dimensional spectral domain. This process essentially extracts the principal component features of the network load distribution (such as key conduction paths and resource competition hotspots). Finally, through a dynamic fusion mechanism, the key component vectors are dynamically aggregated to generate a query response coding vector reflecting the abnormal degree of the target node in the global load map.
[0032] Specifically, in the application embodiment, the step S141 is used for: performing dynamic coupling decision point response on each PD packet assembly state structured embedding coding vector in the PD packet assembly state query coding vector and the set of PD packet assembly state structured embedding coding vectors, so as to obtain a set of PD packet assembly state decision point implicit coding vectors, which can be expressed by the following formula: ; Wherein, is the set of PD packet assembly state structured embedding coding vectors, and are respectively the 1st, 2nd, th, th and th PD packet assembly state structured embedding coding vectors in the set of PD packet assembly state structured embedding coding vectors, is matrix multiplication, and are respectively the corresponding decision response weight matrix and decision response bias vector between and , is an activation function, and are respectively the 1st, 2nd, th, th, th and th PD packet assembly state decision point implicit coding vectors in the set of PD packet assembly state decision point implicit coding vectors,
[0033] It should be understood that the traditional method treats PD packet assembly as an isolated unit and cannot capture the resource competition relationship across nodes (such as the implicit interaction between bandwidth and CPU load). Through dynamic coupling decision point response, the PD packet assembly state query coding vector and each PD packet assembly state structured embedding coding vector are used to reconstruct the interaction pattern in the hidden space by means of non-linear mapping, aiming to break through the limitation of single-node threshold determination. That is to say, the non-linear transformation models the high-order interaction between features and transforms the originally scattered local indicators into analytic global potential relationships. Specifically, the generated set of PD packet assembly state decision point implicit coding vectors realizes the decoupling and recombination of cross-node features. For example, the implicit conduction path in the load resonance mode is transformed into separable hidden space coordinates. This non-linear projection enables the group anomalies that are difficult to distinguish in the original feature space (such as the early signal of avalanche congestion) to obtain linear separability, and can provide a semantically aligned intermediate representation for subsequent graph structure modeling.
[0034] Specifically, in the application embodiment, the step S142 is used to: calculate the PD packet assembly status decision point state class neighborhood matrix based on the set of PD packet assembly status decision point implicit coding vectors, which can be expressed by the following formula: ; Wherein, is the Euclidean norm of the calculation vector, is the inverse hyperbolic cosine function, and are the eigenvalues at each position in the PD packet assembly status decision point state class neighborhood matrix respectively, is the PD packet assembly status decision point state class neighborhood matrix.
[0035] It should be understood that the local connection relationship between nodes (such as the resource dependence or competition intensity of adjacent nodes) directly affects the load conduction path. The PD packet assembly status decision point state class neighborhood matrix explicitly constructs the node local connection graph structure by quantifying the similarity between node vectors in the implicit space. For example, if the implicit space vectors of node A and node B are highly similar, it may indicate that they share similar load characteristics (such as the upstream and downstream nodes belonging to the same service link). That is, the PD packet assembly status decision point state class neighborhood matrix discretizes the complex global relationship in the high-dimensional feature space into the adjacency relationship of the graph structure, such as identifying the key conduction path (such as a high-bandwidth node group) or the competition hot spot area (such as multiple nodes competing for the same CPU resource). This step provides a structured representation of the data flow manifold for spectral analysis, enabling subsequent analysis to focus on the topological characteristics of network load rather than isolated node metrics.
[0036] Specifically, in the application embodiment, the step S143 is used to: calculate the PD packet assembly status decision point state class degree matrix based on the set of PD packet assembly status decision point implicit coding vectors, which can be expressed by the following formula: ; Wherein, is the square of the calculation vector one-norm, is minus one of the number of vectors in, and are the eigenvalues at each position on the diagonal in the PD packet assembly status decision point state class degree matrix respectively, is the PD packet assembly status decision point state class degree matrix.
[0037] It should be understood that the "centrality" of a node (such as the number of connections or interaction intensity) determines its influence in global load conduction. The degree matrix of the PD packet assembly state decision point state records the number of connections of each node in diagonal form (i.e., the row or column sum of the neighborhood matrix). For example, nodes with a high number of connections may be the core hubs of resource competition (such as gateway nodes). That is, the degree matrix of the PD packet assembly state decision point state strengthens the contribution of key nodes by adjusting the weight distribution of the Laplacian matrix (such as the load fluctuation of nodes with a high number of connections has a greater impact on the global situation). If the degree value of a certain node is significantly higher than that of other nodes, its abnormal load may trigger cascading congestion (such as the avalanche effect). That is, this step can provide prior information on the importance of nodes for spectral decomposition, making subsequent feature extraction pay more attention to the abnormal patterns of key hubs.
[0038] Specifically, in the application embodiment, the step S144 is used to: calculate the Laplacian matrix of the PD packet assembly state decision point state based on the neighborhood matrix of the PD packet assembly state decision point state and the degree matrix of the PD packet assembly state decision point state, which can be expressed by the following formula: ; where is the Laplacian matrix of the PD packet assembly state decision point state.
[0039] It should be understood that the algebraic representation of the graph structure (the Laplacian matrix of the PD packet assembly state decision point state) is the core tool of spectral graph theory, which uniformly encodes the local connections between nodes (the neighborhood matrix of the PD packet assembly state decision point state) and the global weights (the degree matrix of the PD packet assembly state decision point state) into an algebraic form. The eigenvalues of the Laplacian matrix of the PD packet assembly state decision point state correspond to the frequency components of the graph signal. The low-frequency components reflect the globally smooth load distribution, and the high-frequency components correspond to local mutations (such as sudden traffic shocks). That is, the Laplacian matrix of the PD packet assembly state decision point state transforms the graph structure into resolvable spectral domain features through algebraic operations. In this way, the complex interaction relationships of network loads can be decoupled into interpretable patterns in the spectral domain, such as identifying load resonance patterns (multiple nodes are periodically synchronized overloaded).
[0040] Specifically, in the application embodiment, the step S145 is used to: perform spectral decomposition on the Laplacian matrix of the PD packet assembly state decision point state to obtain a set of key component encoding vectors of the PD packet assembly state decision point, which can be expressed by the following formula: ; where is the spectral decomposition operation on , is the eigenvector matrix of the PD packet assembly state, that is, a set of key component encoding vectors of the PD packet assembly state decision point, and The 1st, 2nd, rd, and th key component coding vectors of the set of PD packet assembly status decision point key component coding vectors, is a diagonal matrix of PD packet assembly status eigenvalue where the diagonal elements are and ; and are the corresponding eigenvalues of and respectively, is the diagonal matrix of PD packet assembly status eigenvalue.
[0041] It should be understood that only a small number of components in the high-dimensional graph signal are extremely sensitive to the group (such as the low-dimensional manifold that dominates the load conduction path). Spectral decomposition selects the top k eigenvectors by eigenvalue sorting and projects the data onto the subspace spanned by the main vibration modes. This is equivalent to performing a Fourier transform on the network state, filtering out noise in the frequency domain and retaining the low-frequency components that are strongly correlated with the system stability. That is, the set of key component coding vectors of the PD packet assembly status decision point captures the macroscopic patterns of resource competition. For example, the first eigenvector may correspond to the global load balancing degree, and the second reflects the regional competition intensity. This non-linear dimensionality reduction fuses multi-dimensional metrics (CPU, bandwidth, etc.) into a few latent variables with physical meanings, supporting an intuitive interpretation of complex risk patterns.
[0042] Preferably, in another specific example of the present application, spectral decomposition is performed on the PD packet assembly status decision point state Laplacian matrix to obtain the set of key component coding vectors of the PD packet assembly status decision point, including: performing matrix optimization based on the generalized inverse matrix drive on the PD packet assembly status decision point state Laplacian matrix to obtain the optimized PD packet assembly status decision point state Laplacian matrix; performing spectral decomposition on the optimized PD packet assembly status decision point state Laplacian matrix to obtain the set of key component coding vectors of the PD packet assembly status decision point.
[0043] In particular, since each decision point state can be characterized as a set of accumulation points in the abstract space in the network topology structure, the mathematical essence of the PD packet assembly status decision point state Laplacian matrix can be attributed to the result of the closure operation of such accumulation points. Based on this theoretical framework, first, the connected component features of the PD packet assembly status decision point state class neighborhood matrix and the PD packet assembly status decision point state class degree matrix are extracted through the closure algorithm driven by the generalized inverse matrix: using the product of the separating subspace matrix and its pseudo-inverse to generate the PD packet assembly status decision point state class neighborhood matrix , and at the same time, through the loop subspace matrix The generalized inverse operation generates the PD packetization state decision point state degree matrix , where and correspond to the separated subspace (representing the network segmentation behavior) and the loop subspace (characterizing the cyclic path characteristics) of the exponential mapping and the original matrix for matrix multiplication), and the loop subspace closure (through the original matrix and matrix fusion) for the positive intersection addition operation, finally generating the optimized PD packetization state decision point state Laplacian matrix . This process extracts topological invariants in the network (such as connected components, cyclic paths, etc.), making the spectral distribution characteristics of
[0044] Specifically, this process is expressed by the formula: ; where is the separated subspace matrix, is the inverse matrix of is the loop subspace matrix, is the inverse matrix of is the exponential function value with the natural constant as the base, is the pointwise addition by position, is the optimized PD packetization state decision point state Laplacian matrix .
[0045] After that, perform spectral decomposition on the optimized Laplacian matrix of the PD packet assembly state decision point state to obtain a set of key component coding vectors of the PD packet assembly state decision point. It should be understood that by performing spectral decomposition on the optimized Laplacian matrix of the PD packet assembly state decision point state, the system can capture the essential features in the network load dynamics more accurately. Specifically, through the closure operations of the separated subspace and the loop subspace, the optimized matrix has encoded the key invariants in the network topology (such as the compactness of connected components and the stability of loops) into the algebraic structure, so that the eigenvectors after spectral decomposition are no longer disturbed by local noise or instantaneous perturbations, but focus on the core patterns reflecting the overall network load distribution. For example, the dominant eigenvector will clearly present the spatial distribution of resource competition hotspots, while the secondary components characterize the dependency relationships of potential conduction paths. This decomposition enables the multi-scale load features originally mixed in the raw data - whether it is the global avalanche risk trend or the local sub-healthy state - to be separated into mutually orthogonal signal components in the spectral domain, thus providing a more discriminative low-dimensional representation for subsequent dynamic fusion. Notably, due to the stronger robustness of the spectral characteristics of the optimized matrix to structural perturbations, even when the network topology undergoes dynamic evolution (such as sudden changes in node loads or adjustments in connection relationships), the generated key component coding vectors can still maintain semantic consistency, avoiding violent oscillations in the feature space caused by minor network changes, and ultimately ensuring that the PD packet assembly state query response coding vectors can still stably reflect the true state of the system in a complex environment.
[0046] In step S150, based on the PD packet assembly status query response encoding vector, it is determined whether to mark the PD packet to be recognized as an overloaded PD packet. Specifically, in the embodiment of the present application, step S150 includes: inputting the PD packet assembly status query response encoding vector into an identifier based on a classifier to obtain an identification result of whether to mark the PD packet to be recognized as an overloaded PD packet. It should be understood that the PD packet assembly status query response encoding vector contains information about the complex relationships and characteristics between the PD packet to be recognized and the statuses of other PD packets. The identifier based on the classifier can perform quantitative analysis on this information and convert it into a clear judgment result (whether it is overloaded). The classifier establishes a mapping relationship between the input encoding vector and the output result (overloaded or not overloaded) by learning a large number of known PD packet status data samples of overloaded and non-overloaded ones, thereby providing an objective and quantitative way to judge the status of the PD packet to be recognized and avoiding the limitations of subjective judgment or simple rule judgment. For example, when it is found that a certain PD packet is marked as overloaded, the reason for its overload can be further analyzed and corresponding measures can be taken for adjustment. In particular, in a specific embodiment of the present application, inputting the PD packet assembly status query response encoding vector into an identifier based on a classifier to obtain an identification result of whether to mark the PD packet to be recognized as an overloaded PD packet includes: using the fully connected layer of the classifier to perform fully connected encoding on the PD packet assembly status query response encoding vector to obtain a PD packet assembly status query response fully connected encoding feature vector; inputting the PD packet assembly status query response fully connected encoding feature vector into the Softmax classification function of the classifier to obtain the probability values of the PD packet assembly status query response encoding vector belonging to each classification label, where the classification labels include those for indicating marking the PD packet to be recognized as an overloaded PD packet and those for indicating not marking the PD packet to be recognized as an overloaded PD packet; determining the classification label corresponding to the largest of the probability values as the identification result.
[0047] In summary, the CAM-based queue mapping optimization method according to the embodiments of the present application is elucidated. It uses data analysis and processing algorithms based on deep learning to perform fusion encoding on heterogeneous metrics such as the queue depth, CPU load, and bandwidth occupancy rate of each real-time collected PD packet to obtain a structured vector representing the current operating state. Then, using the query response mechanism, the status characteristics of the PD packet to be evaluated are matched with each real-time status feature library for similarity, and the abnormal association characteristics in the global load distribution are revealed through the response vector, and finally, the overload risk is intelligently judged dynamically. In this way, the limitations of traditional single-dimensional threshold determination can be broken through, the hidden overload caused by resource competition can be accurately identified through multi-index collaborative modeling, the misjudgment and lag problems of the static threshold mechanism can be effectively solved, and the leap from passive alarm to predictive load balancing is achieved.
Claims
1. A CAM-based queue mapping optimization method, characterized in that Including: Obtain the flow ID to be mapped; Perform field splitting on the flow ID to be mapped to obtain a first flow ID part and a second flow ID part; Read the data at the corresponding addresses in the first block of RAM and the second block of RAM using the first flow ID part and the second flow ID part as addresses respectively to obtain first address data and second address data; Perform a bitwise AND operation on the first address data and the second address data to obtain a bitwise AND operation result; Based on the bitwise AND operation result, determine the PD number of the flow ID to be mapped.
2. The CAM-based queue mapping optimization method according to claim 1, wherein The flow ID to be mapped has 18 bits.
3. The CAM-based queue mapping optimization method according to claim 1, characterized in that, The first flow ID part and the second flow ID part each have 9 bits.
4. The CAM-based queue mapping optimization method according to claim 1, wherein The first address data and the second address data have 16 bits.
5. The CAM-based queue mapping optimization method according to claim 4, wherein Based on the bitwise AND operation result, determining the PD number of the flow ID to be mapped includes: If exactly one bit in the bitwise AND operation result is 1, the position of this bit is the PD number of the flow ID to be mapped.
6. The CAM-based queue mapping optimization method according to claim 4, wherein Based on the bitwise AND operation result, determining the PD number of the flow ID to be mapped includes: If the bitwise AND operation result is all 0, it means there is no PD number matching the flow ID to be mapped.
7. The CAM-based queue mapping optimization method according to claim 1, wherein It further includes the steps of: obtaining the actual payload situation of each PD packet group, where the actual payload situation includes queue length, CPU utilization rate, and bandwidth utilization rate; performing structured embedding encoding on the actual payload situation of each PD packet group to obtain a set of PD packet group state structured embedding encoding vectors; extracting the PD packet group state structured embedding encoding vector corresponding to the PD packet group to be recognized from the set of PD packet group state structured embedding encoding vectors as the PD packet group state query encoding vector; performing PD packet group state query based on spectral graph decomposition on the PD packet group state query encoding vector and the set of PD packet group state structured embedding encoding vectors to obtain a PD packet group state query response encoding vector; based on the PD packet group state query response encoding vector, determining whether to mark the PD packet group to be recognized as an overloaded PD packet group.
8. The CAM-based queue mapping optimization method according to claim 7, wherein Perform PD packet assembly status query based on spectral graph decomposition on the set of the PD packet assembly status query encoding vectors and the PD packet assembly status structured embedding encoding vectors, including: performing dynamic coupling decision point response on each PD packet assembly status structured embedding encoding vector in the set of the PD packet assembly status query encoding vectors and the PD packet assembly status structured embedding encoding vectors to obtain a set of PD packet assembly status decision point implicit encoding vectors; calculating a PD packet assembly status decision point state class neighborhood matrix based on the set of the PD packet assembly status decision point implicit encoding vectors; calculating a PD packet assembly status decision point state class degree matrix based on the set of the PD packet assembly status decision point implicit encoding vectors; calculating a PD packet assembly status decision point state Laplacian matrix based on the PD packet assembly status decision point state class neighborhood matrix and the PD packet assembly status decision point state class degree matrix; performing spectral decomposition on the PD packet assembly status decision point state Laplacian matrix to obtain a set of PD packet assembly status decision point key component encoding vectors; and performing dynamic fusion on the set of the PD packet assembly status decision point key component encoding vectors to obtain the PD packet assembly status query response encoding vector.
9. The CAM-based queue mapping optimization method according to claim 8, wherein Performing spectral decomposition on the PD packet assembly status decision point state Laplacian matrix to obtain a set of PD packet assembly status decision point key component encoding vectors, including: performing matrix optimization on the PD packet assembly status decision point state Laplacian matrix driven by a generalized inverse matrix to obtain an optimized PD packet assembly status decision point state Laplacian matrix; and performing spectral decomposition on the optimized PD packet assembly status decision point state Laplacian matrix to obtain the set of the PD packet assembly status decision point key component encoding vectors.
10. The CAM-based queue mapping optimization method according to claim 9, wherein Based on the PD packet assembly status query response encoding vector, determine whether to mark the PD packet to be recognized as an overloaded PD packet, including: inputting the PD packet assembly status query response encoding vector into an identifier based on a classifier to obtain an identification result of whether to mark the PD packet to be recognized as an overloaded PD packet.
Citation Information
Cited By
Data processing method and system for virtual reality animation playing
CN120599101A