-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Based on the counts we produce for the main sample file, order the byte-by-byte checks in the matching function to optimize for most likely to early exit. This optimization works by checking the fewest characters possible before switching us to the long range skip mode. The order won't be perfect for every input but should be reasonable overall. This is an obvious case of optimizing for a benchmark, but that is kind of the goal of the exercise a this point since we've gone way beyond the "simplest solution that works".
- Loading branch information
Showing
2 changed files
with
45 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters