# A Comprehensive Survey on Knowledge-Defined Networking
## 6 Data Plane
### Forwarding Devices
#### 6.2.2 Physical Switches  
Compared to legacy network forwarding, which is IP or MAC address-based, OpenFlow switching can occur based on TCP addresses, VLAN IDs, or switch ports, which increases the length of the rule field and increases the processing complexity of the flow table. Thus, recent work has proposed integrating a Graphic Processing Unit (GPU) along with a CPU to accelerate packet processing in switches by utilizing the GPU's parallel processing capability [400]. A Network Processing Unit (NPU) from vendors such as Intel, Cavium, Broadcom, etc. has been utilized as the processing unit in switches [401]. Some have proposed network processor-based acceleration cards to improve the processing capability of the switches [402]. Some have proposed a hardware implementation of the OpenFlow programmable packet parser using a Field Programmable Gate Array (FPGA) to increase the switch speed and reduce the waiting and service times [403]. Recent research investigates the feasibility of a traffic offload hybrid switch using an Application Specific Integrated Circuit (ASIC) and FPGA. This switch proposes to offload switching between two different technologies: fast ASIC and programmable FPGA based on volume, priority, volatility, etc., in order to yield high throughput and low latency [404]. Some researchers have proposed using a combination of CPU and ASIC for processing different types of flows. In particular, to handle frequently occurring small flows, a CPU with relatively lower processing power is proposed, while to handle large and non-frequent traffic, an ASIC implementation of the switch is proposed [405]. In order to be compatible with legacy networks, most modern switches are manufactured as hybrid switches, which support traditional forwarding based on routing protocols in the switch combined with logically centralized control-based forwarding in KDN [406]. However, pure KDN switches only support KDN and do not support traditional routing protocol-based switching. Ternary Content Addressable Memory (TCAM) is the most widely used memory for forwarding elements in KDN, as it provides high-speed lookup and forwarding capabilities, making it well suited for implementing the match-action tables used in switches. However, TCAM is expensive and less power efficient, and the TCAM capacities of current OpenFlow switches on the market can vary in a vast range from a few thousand to a few millions [407]. Other memory technologies, such as Dynamic Random State Memory (DRAM) or Static Random Access Memory (SRAM), do not provide the same level of speed and efficiency as TCAM [408]. However, SRAM is more flexible and scalable. Thus, there are proposals to use a combination of TCAM and SRAM in order to have high flexibility and high packet classification performance [409]. A forwarding device is responsible for packet forwarding based on the flow rules installed in its memory, with the help of a local processor. Thus, the main function of a KDN switch is to process packets (forward based on installed flow rules) and collect and send data to management and control planes. However, a given forwarding device has limited memory and processing power. When the size of the network becomes large, the number of flow rules in a given switch can also increase, so efficient flow rule management techniques can be used to manage flow rules with limited space. Such management techniques should make sure that an optimal number of flow rules are maintained without removing flow rules that could result in violating network policies and constraints. Filling up the switch memory can result in packet dropping and provoke frequent communication with the controller to search for unknown rules, thus degrading the controller's performance. OpenFlow rules are more complex and consume more memory than forwarding rules in conventional IP-based routers.