3 ms·
it may be easier to apply `tolower()` to a bigger chunk of data: instead of processing lines, say, and using the function at that step; lowercase the entire buf
by h2odragon 2y ago
it may be easier to apply `tolower()` to a bigger chunk of data: instead of processing lines, say, and using the function at that step; lowercase the entire buffer before you break out lines.
The combination of speculative execution and multitasking means the noise floor for benchmarking is higher than it used to be. You've gotta go a long way now to ensure an environment where just your code is running; and then the real world where it actually needs to run is a quite different environment and your optimizations may not be at all applicable.