Date: Tue, 13 Aug 1996 17:22:32 -0700 (PDT) From: Wolfram Schneider <wosch> To: CVS-committers, cvs-all, cvs-usrbin Subject: cvs commit: src/usr.bin/locate Makefile.inc Makefile src/usr.bin/locate/bigram Makefile locate.bigram.c src/usr.bin/locate/code Makefile locate.code.c src/usr.bin/locate/locate concatdb.sh locate.rc mklocatedb.sh Makefile locate.h updatedb.sh Message-ID: <199608140022.RAA22450@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
wosch 96/08/13 17:22:32 Modified: usr.bin/locate Makefile usr.bin/locate/bigram Makefile locate.bigram.c usr.bin/locate/code Makefile locate.code.c usr.bin/locate/locate Makefile locate.h updatedb.sh Added: usr.bin/locate Makefile.inc usr.bin/locate/locate concatdb.sh locate.rc mklocatedb.sh Log: bigram Bigram does not remove newline at end of filename. This break particulary the bigram algorithm and /var/db/locate.database grow up 15 %. Bigram does not check for characters outside 32-127. The bigram output is silly and need ~1/2 CPU time of database rebuilding. old: locate.bigram < $filelist | sort | uniq -c | sort -nr ^^^^^^^^^^^^^^ this can easy made bigram new: bigram < $filelist | sort -nr code Code does not check for char 31. Use a lookup array instead a function. 3 x faster. updatedb rewritten sync with bigram changes read config file /etc/locate.rc if exists submitted by: guido@gvr.win.tue.nl (Guido van Rooij) concatdb - concatenate locate databases mklocatedb - build locate database Revision Changes Path 1.2 +1 -0 src/usr.bin/locate/Makefile 1.2 +3 -1 src/usr.bin/locate/bigram/Makefile 1.3 +44 -11 src/usr.bin/locate/bigram/locate.bigram.c 1.2 +3 -2 src/usr.bin/locate/code/Makefile 1.3 +42 -16 src/usr.bin/locate/code/locate.code.c 1.5 +11 -1 src/usr.bin/locate/locate/Makefile 1.2 +26 -0 src/usr.bin/locate/locate/locate.h 1.3 +54 -71 src/usr.bin/locate/locate/updatedb.sh
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199608140022.RAA22450>