Patent ID: 7613189

Claim:
A network switch comprising: a matching device that employs a first data structure to select one of N address groups including a first partial address of an Internet Protocol (IP) packet, wherein each of said N address groups includes an address range in a first partial address space, and wherein N is an integer greater than one; an action table that selects one of a next hop location corresponding to a longest prefix match and a first matching operation for said IP packet based on said selected one of said N groups, wherein when said first matching operation is selected, said matching device employs a second data structure to select one of M address groups including a second partial address of said IP packet, wherein each of said M address groups includes an address range in a second partial address space, and wherein M is an integer greater than one, and wherein said action table selects one of a next hop location corresponding to a longest prefix match and a second matching operation for said IP packet based on said selected one of said M groups; and a routing engine that routes said IP packet based on said first and second next hop locations.