diff options
| author | Paul Eggert | 2013-02-11 15:37:18 -0800 |
|---|---|---|
| committer | Paul Eggert | 2013-02-11 15:37:18 -0800 |
| commit | a84b7c5334e232913111b840f2283d0138a6f5fb (patch) | |
| tree | 8ee4e55f7059d1eb918fb5966cd81ee3f84153bc /admin | |
| parent | 71d4202f204ea5fad93eb34406f0ef671630f271 (diff) | |
| download | emacs-a84b7c5334e232913111b840f2283d0138a6f5fb.tar.gz emacs-a84b7c5334e232913111b840f2283d0138a6f5fb.zip | |
Tune by using memchr and memrchr.
* .bzrignore: Add string.h.
* admin/merge-gnulib (GNULIB_MODULES): Add memrchr.
* lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
* lib/memrchr.c, lib/string.in.h, m4/memrchr.m4, m4/string_h.m4:
New files, from gnulib.
* src/doc.c (Fsnarf_documentation):
* src/fileio.c (Fsubstitute_in_file_name):
* src/search.c (find_newline, scan_newline):
* src/xdisp.c (pos_visible_p, display_count_lines):
Use memchr and memrchr rather than scanning byte-by-byte.
* src/search.c (find_newline): Rename from scan_buffer.
Omit first arg TARGET, as it's always '\n'. All callers changed.
Diffstat (limited to 'admin')
| -rw-r--r-- | admin/ChangeLog | 5 | ||||
| -rwxr-xr-x | admin/merge-gnulib | 3 |
2 files changed, 7 insertions, 1 deletions
diff --git a/admin/ChangeLog b/admin/ChangeLog index 76ac11446a3..7e72e10cd9f 100644 --- a/admin/ChangeLog +++ b/admin/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2013-02-11 Paul Eggert <eggert@cs.ucla.edu> | ||
| 2 | |||
| 3 | Tune by using memchr and memrchr. | ||
| 4 | * merge-gnulib (GNULIB_MODULES): Add memrchr. | ||
| 5 | |||
| 1 | 2013-02-01 Paul Eggert <eggert@cs.ucla.edu> | 6 | 2013-02-01 Paul Eggert <eggert@cs.ucla.edu> |
| 2 | 7 | ||
| 3 | Use fdopendir, fstatat and readlinkat, for efficiency (Bug#13539). | 8 | Use fdopendir, fstatat and readlinkat, for efficiency (Bug#13539). |
diff --git a/admin/merge-gnulib b/admin/merge-gnulib index e90e2e23b29..b43f2bd9bb8 100755 --- a/admin/merge-gnulib +++ b/admin/merge-gnulib | |||
| @@ -31,7 +31,8 @@ GNULIB_MODULES=' | |||
| 31 | dtoastr dtotimespec dup2 environ execinfo faccessat | 31 | dtoastr dtotimespec dup2 environ execinfo faccessat |
| 32 | fcntl-h fdopendir filemode fstatat getloadavg getopt-gnu gettime gettimeofday | 32 | fcntl-h fdopendir filemode fstatat getloadavg getopt-gnu gettime gettimeofday |
| 33 | ignore-value intprops largefile lstat | 33 | ignore-value intprops largefile lstat |
| 34 | manywarnings mktime pselect pthread_sigmask putenv readlink readlinkat | 34 | manywarnings memrchr mktime |
| 35 | pselect pthread_sigmask putenv readlink readlinkat | ||
| 35 | sig2str socklen stat-time stdalign stdarg stdbool stdio | 36 | sig2str socklen stat-time stdalign stdarg stdbool stdio |
| 36 | strftime strtoimax strtoumax symlink sys_stat | 37 | strftime strtoimax strtoumax symlink sys_stat |
| 37 | sys_time time timer-time timespec-add timespec-sub unsetenv utimens | 38 | sys_time time timer-time timespec-add timespec-sub unsetenv utimens |