1. A security appliance operatively coupled to a network, the security appliance comprising: a plurality of memories in a memory hierarchy configured to store a plurality of nodes of at least one finite automaton; a node cache configured to store at least a threshold number of nodes of the at least one finite automaton; and at least one processor operatively coupled to the plurality of memories and the node cache and configured to cache one or more nodes, of the plurality of nodes, stored in a given memory of the plurality of memories at a hierarchical level in the memory hierarchy, in the node cache based on a cache miss of a given node of the one or more nodes and a hierarchical node transaction size associated with the hierarchical level.