1. A method comprising: executing, on a processor, instructions stored on a machine-readable medium to perform operations of: generating, by the processor, multiple secondary lookup tables from a primary lookup element by extracting, for each secondary lookup table, a part of the primary lookup table; performing, by the processor, a lookup process on a header of a packet based on the multiple secondary lookup tables; generating, by the processor, rule results for the secondary lookup tables in a combinable format; and grouping, by the processor, the multiple secondary lookup tables into secondary lookup table groups and generating a mapping table to map the rule results of each of the secondary lookup tables into results for the secondary lookup table groups.