Methods and systems to accomplish variable width data input
Disclosed are methods and systems for variable width data input to a pattern-recognition processor. A variable width data input method may include receiving bytes over a data bus having a first width and receiving one or more signals indicating the validity of each of the one or more bytes. The valid bytes may be sequentially provided to a pattern-recognition processor in an 8-bit wide data stream. In an embodiment, a system may include one or more address lines configured to provide the one or more signals indicating the validity of the bytes transferred over the data bus. The system may include a buffer and control logic to sequentially process the valid bytes.
1. A method, comprising:
receiving, at variable width control logic, a data stream via a data bus having a first width; and
processing, at a processor, the data stream in sequential units having a second width, less than the first width.
2. The method of claim 1 , comprising receiving, at the variable width control logic, a indicator of what portions of the data stream are valid.
3. The method of claim 2 , wherein processing comprises processing only the portions of the data stream that are valid.
4. The method of claim 1 , wherein processing comprises processing the data stream in sequential units have a width equal to one byte.
5. The method of claim 4 , comprising receiving, at the variable width control logic, a byte valid signal indicating what bytes of the data stream are valid.
6. The method of claim 1 , wherein processing at a processor comprises searching for a pattern in the data stream at a pattern-recognition processor.
7. A method, comprising:
receiving a plurality of data bytes at variable width control logic, simultaneously;
receiving one or more byte valid signals at the variable width control logic together with the plurality of data bytes, the one or more byte valid signals indicating the validity of each of the data bytes; and
processing the valid data bytes sequentially.
8. The method of claim 7 , wherein the plurality of data bytes comprises one of 2 bytes, 4 bytes or 8 bytes.
9. The method of claim 7 , comprising storing the valid data bytes before processing the valid data bytes sequentially.
10. The method of claim 9 , wherein storing comprises storing the valid data bytes in a first-in-first-out register.
11. The method of claim 7 , wherein processing comprises searching the valid data bytes for a pattern.
12. The method of claim 11 , wherein searching comprises comparing the valid data bytes to a search term of a search criterion.