diff options
| author | Alexey Dobriyan <[email protected]> | 2016-10-11 13:51:30 -0700 |
|---|---|---|
| committer | Linus Torvalds <[email protected]> | 2016-10-11 15:06:30 -0700 |
| commit | 1204c77f9b6ab8ba8cc6cfe00342f5e64a740cdf (patch) | |
| tree | 7c48ad22c756dc7b6215ac5aca362bc192efd35a /tools/perf/scripts/python/bin | |
| parent | bf90e56e467ed5766722972d483e6711889ed1b0 (diff) | |
include/linux/ctype.h: make isdigit() table lookupless
Make isdigit into a simple range checking inline function:
return '0' <= c && c <= '9';
This code is 1 branch, not 2 because any reasonable compiler can
optimize this code into SUB+CMP, so the code
while (isdigit((c = *s++)))
...
remains 1 branch per iteration HOWEVER it suddenly doesn't do table
lookup priming cacheline nobody cares about.
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Alexey Dobriyan <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/bin')
0 files changed, 0 insertions, 0 deletions