Multiple character string matching method and chip
A string matching and character technology, applied in the field of information processing, can solve the problems of slow matching speed, impracticality, obvious impact on storage space, etc., to achieve the effect of reducing space requirements and solving the problem of space explosion
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0078] This embodiment provides a method for matching multiple character strings, which is specifically based on the principle of a cache state machine and is mainly characterized by eliminating cross conversion rules. At the same time, this method can also completely eliminate restart conversion rules and failure conversion rules. see Figure 5 , with the current state S i , the current input is K, and the storage state number N=1 is taken as an example for illustration, the method includes the following steps:
[0079] Step 101: Define the cache rules of the cache state machine, that is, the cache state function, according to the application situation.
[0080] The cache rule of this embodiment is specifically described by the cache state function (ie θ), specifically: after the current state receives the current character, if the initial state S 0 Receive the current character and have the next state in the basic conversion rule, then store the next state in the cache C ...
Embodiment 2
[0098] This embodiment provides a multi-character string matching method, which is based on the cache state machine principle and mainly features the isomorphic path merging technology, a multi-character string matching method.
[0099] First, merge the existing basic transformation rules into isomorphic paths, taking P={betters, pattern} as an example, see Figure 8, the DFA graph constructed for the AC algorithm (which does not include restart transition rules and failure transition rules), requires a total of 14 basic transition rules and 15 states, and the state S 2 -S 5 with state S 9 -S 12 have the same property, that is, they all receive the string "tter", and this form is called an isomorphic path. For isomorphic paths, cache state machines are used to merge them.
[0100] see Figure 9 ,for Figure 8 Schematic diagram of the merged cache state machine, which aggregates the next state into one state S 1 and state S 8 Called the convergent state, the next state ...
Embodiment 3
[0113] see Figure 10 , the embodiment provides a multi-character string matching chip, the chip includes: an interface module, a status register, a cache status register, a conversion rule module and a control module.
[0114] Wherein, the interface module is used for receiving input characters;
[0115] The state register is used to store the current state;
[0116] The cache state register is used to store the cache state, and there are N cache states, and N can be 1 or other values;
[0117] The conversion rule module is used for storing the state conversion rule base, and searches for the next state according to the character received by the interface module, the current state stored in the state register and the cache state stored in the cache state register;
[0118] The control module is used to control the interface module to normally receive input characters, control the status register to update the current status, control the cache status register to update the b...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com