make nfaExecCastle0_QR() more efficent

1. Reverse scan for the last escape and only process later events.
2. Only scheck subcastles which may expire for staleness
This commit is contained in:
Alex Coyte
2015-12-02 15:49:49 +11:00
committed by Matthew Barr
parent b9c5d65f0e
commit e065c4d60b
6 changed files with 229 additions and 109 deletions

View File

@@ -63,6 +63,7 @@ struct SubCastle {
* - struct Castle
* - struct SubCastle[numRepeats]
* - tables for sparse model repeats
* - sparse iterator for subcastles that may be stale
*
* Castle stores an "active repeats" multibit in stream state, followed by the
* packed repeat state for each SubCastle. If all SubCastles are mutual
@@ -83,6 +84,9 @@ struct ALIGN_AVX_DIRECTIVE Castle {
char pureExclusive; //!< tells us if all SubCastles are mutual exclusive
u8 activeIdxSize; //!< number of bytes in stream state to store
// active SubCastle id for exclusive mode
u32 staleIterOffset; //<! offset to a sparse iterator to check for stale
// sub castles
union {
struct {
char c;