Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Optimizations to preprocessor's find_define().
- don't check for __FILE__ and __LINE__ until after we've checked our hash, since this is the less likely case. - Check against the hard-coded hash value of the strings "__FILE__" and "__LINE__" to avoid unnecessary strcmp() calls. This dropped the profile of this function from 20% of our total CPU time to 10%. Of that 10%, 70% is now the hashing function.
- Loading branch information
Showing
1 changed file
with
17 additions
and
10 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