blem that can provide higher performance than CAM-based search engines but are also more tuned for organizations that can afford them. This chapter provides background to the classification engines, which we describe in the following chapter. THE PACKET CLASSIFICATION CONTEXT OF A SEARCH ENGINE We will start by providing a sneak preview of the classification context. We do not intend to spoil the information provided in the next chapter, which discusses specialized classification engines, but we must clarify some basic concepts within the packet classification context. In fact, newcomers to this industry are often confused by the relationship between search engines and classification engines. The two engines will inevitably overlap since chip vendors in pursuit of product differentiation have con- fused matters. On the one hand, they have packed functionality that undisputedly adds value into their chips. On the other hand, the boundary between the two is blurred as one can find "search engines," "classification engines" and "search and classification engines." A packet can be handed over to a network-processing system in two ways: either by its own host central processing unit (CPU) or, in the case of a switch/router, it can arrive at the network process- ing unit (NPU) as a member of a stream of unrelated or related packets. They may have been stream- ing by one of the line-card interfaces (following the switch/router's ingress path) or by the switch fabric interface (following the egress path). The NPU will have to conduct several operations with and/or on each one of these packets. Classification is the very first task that needs to be performed on a packet arriving in a stream of other packets. However, in order to put things into the right context, we must clarify that a classifi- cation engine (also known sometimes in the industry as the classifier) receives as its input an aggre- gate stream of packets, which the majority of the time are rushing in at wire speed (which can easily reach 40 Gbps). By applyi