aboutsummaryrefslogtreecommitdiffstats
path: root/libibex
diff options
context:
space:
mode:
authorNot Zed <NotZed@HelixCode.com>2000-11-28 21:05:01 +0800
committerMichael Zucci <zucchi@src.gnome.org>2000-11-28 21:05:01 +0800
commitce4905721c40da7acbdb02caa5d2e24476590e4b (patch)
treeccb1be553fffc570f6da2e8f89e12f293f9346d3 /libibex
parent00890b71cf68d861e9ec72a459fa7e43464f4569 (diff)
downloadgsoc2013-evolution-ce4905721c40da7acbdb02caa5d2e24476590e4b.tar.gz
gsoc2013-evolution-ce4905721c40da7acbdb02caa5d2e24476590e4b.tar.zst
gsoc2013-evolution-ce4905721c40da7acbdb02caa5d2e24476590e4b.zip
Turn off index stats by default.
2000-11-28 Not Zed <NotZed@HelixCode.com> * index.h: Turn off index stats by default. * ibex_block.c (ibex_save): And here. (ibex_close): Debug out printfs. * wordindexmem.c (ibex_create_word_index_mem): And here. (num): Made buf static. * block.c (ibex_block_cache_open): Debug out some printfs. (ibex_block_read): And here. svn path=/trunk/; revision=6691
Diffstat (limited to 'libibex')
-rw-r--r--libibex/ChangeLog13
-rw-r--r--libibex/block.c12
-rw-r--r--libibex/ibex_block.c4
-rw-r--r--libibex/index.h2
-rw-r--r--libibex/wordindexmem.c17
5 files changed, 31 insertions, 17 deletions
diff --git a/libibex/ChangeLog b/libibex/ChangeLog
index 1d74b73898..fa7e3dc48a 100644
--- a/libibex/ChangeLog
+++ b/libibex/ChangeLog
@@ -1,3 +1,16 @@
+2000-11-28 Not Zed <NotZed@HelixCode.com>
+
+ * index.h: Turn off index stats by default.
+
+ * ibex_block.c (ibex_save): And here.
+ (ibex_close): Debug out printfs.
+
+ * wordindexmem.c (ibex_create_word_index_mem): And here.
+ (num): Made buf static.
+
+ * block.c (ibex_block_cache_open): Debug out some printfs.
+ (ibex_block_read): And here.
+
2000-11-17 Not Zed <NotZed@HelixCode.com>
* wordindexmem.c (add_list): If we have the namecache active, and
diff --git a/libibex/block.c b/libibex/block.c
index 3f637d4422..b9057bc109 100644
--- a/libibex/block.c
+++ b/libibex/block.c
@@ -420,7 +420,7 @@ ibex_block_read(struct _memcache *block_cache, blockid_t blockid)
if (old->flags & BLOCK_DIRTY) {
/* are we about to un-sync the file? update root and sync it */
if (block_cache->root.flags & IBEX_ROOT_SYNCF) {
- printf("Unsyncing root block\n");
+ d(printf("Unsyncing root block\n"));
block_cache->root.flags &= ~IBEX_ROOT_SYNCF;
if (ibex_block_sync_root(block_cache) != 0) {
@@ -480,7 +480,7 @@ ibex_block_cache_open(const char *name, int flags, int mode)
if (block_cache->root.roof == 0
|| memcmp(block_cache->root.version, IBEX_VERSION, 4)
|| ((block_cache->root.flags & IBEX_ROOT_SYNCF) == 0)) {
- (printf("Initialising superblock\n"));
+ d(printf("Initialising superblock\n"));
/* reset root data */
memcpy(block_cache->root.version, IBEX_VERSION, 4);
block_cache->root.roof = 1024;
@@ -493,10 +493,10 @@ ibex_block_cache_open(const char *name, int flags, int mode)
/* reset the file contents */
ftruncate(block_cache->fd, 1024);
} else {
- (printf("superblock already initialised:\n"
- " roof = %d\n free = %d\n words = %d\n names = %d\n tail = %d\n",
- block_cache->root.roof, block_cache->root.free,
- block_cache->root.words, block_cache->root.names, block_cache->root.tail));
+ d(printf("superblock already initialised:\n"
+ " roof = %d\n free = %d\n words = %d\n names = %d\n tail = %d\n",
+ block_cache->root.roof, block_cache->root.free,
+ block_cache->root.words, block_cache->root.names, block_cache->root.tail));
}
/* FIXME: this should be moved higher up in the object tree */
{
diff --git a/libibex/ibex_block.c b/libibex/ibex_block.c
index 7a5864ea32..565b8f02dc 100644
--- a/libibex/ibex_block.c
+++ b/libibex/ibex_block.c
@@ -251,7 +251,7 @@ ibex *ibex_open (char *file, int flags, int mode)
int ibex_save (ibex *ib)
{
- printf("syncing database\n");
+ d(printf("syncing database\n"));
if (ib->predone) {
ib->words->klass->index_post(ib->words);
ib->predone = FALSE;
@@ -266,7 +266,7 @@ int ibex_close (ibex *ib)
{
int ret = 0;
- printf("closing database\n");
+ d(printf("closing database\n"));
if (ib->predone) {
ib->words->klass->index_post(ib->words);
diff --git a/libibex/index.h b/libibex/index.h
index 0cef7948b3..442cba8e25 100644
--- a/libibex/index.h
+++ b/libibex/index.h
@@ -25,7 +25,7 @@
/* an indexing 'class' maps a key to 1 piece of info */
-#define INDEX_STAT
+/*#define INDEX_STAT*/
struct _IBEXCursor {
struct _IBEXCursorClass *klass;
diff --git a/libibex/wordindexmem.c b/libibex/wordindexmem.c
index 9d26bb3697..0959c2be21 100644
--- a/libibex/wordindexmem.c
+++ b/libibex/wordindexmem.c
@@ -146,20 +146,20 @@ ibex_create_word_index_mem(struct _memcache *bc, blockid_t *wordroot, blockid_t
/* but not the same indexes! */
if (*wordroot) {
- printf("opening wordindex root = %d\n", *wordroot);
+ d(printf("opening wordindex root = %d\n", *wordroot));
idx->wordindex = ibex_hash_class.open(bc, *wordroot);
} else {
idx->wordindex = ibex_hash_class.create(bc, 2048);
*wordroot = idx->wordindex->root;
- printf("creating wordindex root = %d\n", *wordroot);
+ d(printf("creating wordindex root = %d\n", *wordroot));
}
if (*nameroot) {
- printf("opening nameindex root = %d\n", *nameroot);
+ d(printf("opening nameindex root = %d\n", *nameroot));
idx->nameindex = ibex_hash_class.open(bc, *nameroot);
} else {
idx->nameindex = ibex_hash_class.create(bc, 2048);
*nameroot = idx->nameindex->root;
- printf("creating nameindex root = %d\n", *nameroot);
+ d(printf("creating nameindex root = %d\n", *nameroot));
}
return idx;
}
@@ -198,7 +198,7 @@ static void word_index_pre(struct _IBEXWord *idx)
return;
/* want to load all words into the cache lookup table */
- printf("pre-loading all word info into memory\n");
+ d(printf("pre-loading all word info into memory\n"));
idc = idx->wordindex->klass->get_cursor(idx->wordindex);
while ( (wordid = idc->klass->next(idc)) ) {
key = idc->index->klass->get_key(idc->index, wordid, &len);
@@ -220,7 +220,7 @@ static void word_index_pre(struct _IBEXWord *idx)
idc->klass->close(idc);
- printf("done\n");
+ d(printf("done\n"));
}
static gboolean
@@ -357,7 +357,7 @@ static gboolean contains_name(struct _IBEXWord *idx, const char *name)
in the same list, not in buckets of keys for the same hash (among other reasons) */
if (!idx->nameinit) {
- printf("pre-loading all name info into memory\n");
+ d(printf("pre-loading all name info into memory\n"));
idc = idx->nameindex->klass->get_cursor(idx->nameindex);
while ( (wordid = idc->klass->next(idc)) ) {
key = idc->index->klass->get_key(idc->index, wordid, &len);
@@ -821,7 +821,8 @@ static char *
num(int num)
{
int n;
- char buf[256], *p = buf;
+ static char buf[256];
+ char *p = buf;
char type = 0;
n = num;
mit/?h=gstreamer0.10-removal&id=8b45497590c3d2adc6367d969420f90b3785a968'>Uncomment www/py-plone.app.blob dependency since it was just imported intorm2012-01-031-2/+3 * Import plone4 dependencies part 11/15rm2012-01-0342-0/+1368 * Add reload function to rc scriptcrees2012-01-032-0/+2 * Remove an unnecessaty patch.thierry2012-01-031-12/+0 * Import plone4 dependencies part 10/15rm2012-01-0346-0/+1287 * Make sure to exit if there is a problem setting up the desktop session.marcus2012-01-032-9/+10 * Correctly populate usb_device.device_revision_bcd.marcus2012-01-032-3/+12 * Update to lastest security patchset 20120103: added max_input_vars directiverm2012-01-032-4/+4 * - Update to 0.33culot2012-01-032-3/+3 * - Accommodate upgrade of major version of devel/gdcm from 2.0 to 2.2.stephen2012-01-031-3/+9 * - Fix build with clangdhn2012-01-032-4/+9 * This module adds x-reproxy-url header support to Apache/2.x.kuriyama2012-01-034-0/+28 * Update to 0.48.2.marcus2012-01-032-5/+4 * Add some missing headers in strategic places to remove text relocations andmarcus2012-01-031-0/+21 * Add some missing headers in strategic places to remove text relocations andmarcus2012-01-031-1/+1 * Update to 1.082.marcus2012-01-032-3/+3 * - Update to 2.2.0gahr2012-01-037-19/+173 * Tarantool/Box, or simply Tarantool, is a high performance key/valueeadler2012-01-0217-0/+1006 * - update to 2.0.1leeym2012-01-026-65/+35 * Net::STF::Client implements the STF protocol to talk to STF servers.kuriyama2012-01-025-0/+43 * - fix SQUID_ICAP option by integrating additional vendor patcheseadler2012-01-022-2/+9 * Update to 2.1uqs2012-01-022-3/+3 * - Fix pkg-install.in for users with custom INSTALL [1]scheidell2012-01-022-2/+2 * - fix WITH_CLAMAV option handling, that was done before inclusion of bsd.port...rm2012-01-021-10/+10 * Fix the stop of the daemon.thierry2012-01-022-1/+2 * - Update to 20111213martymac2012-01-024-4/+144 * New port, by special request: GNU edjohans2012-01-024-0/+40 * remove unneeded entries from distinfobf2012-01-021-2/+0 * - Update to 20111230.0beat2012-01-022-3/+3 * - Update to 5.2.9beat2012-01-022-3/+3 * Add kktdirect 0.5, a direct solver package for saddle-point (KKT)bf2012-01-024-0/+134 * Import plone4 dependencies part 9/15rm2012-01-0240-0/+1252 * update to 2.5bf2012-01-022-7/+11 * - Update to 0.50 [1]culot2012-01-023-6/+7 * Import plone4 dependencies part 8/15rm2012-01-0243-0/+2041 * - Update to 0.18 [1]culot2012-01-022-16/+8 * DBIx::QueryLog is logs each execution time and the actual query.kuriyama2012-01-025-0/+38 * Ports modules update at Monday 02 January 2012 at 06:51edwin2012-01-021-146/+2 * - update to 1.10eadler2012-01-023-4/+13 * Update p4web to 2011.1/389946.gordon2012-01-025-9/+9 * Update p4ftpd to 2011.1/389946.gordon2012-01-025-9/+9 * - Take mbr's commit bit in for safe keepingtabthorpe2012-01-021-1/+0 * - Reassign to the heaptabthorpe2012-01-026-6/+6 * Update p4 client to 2011.1/389946gordon2012-01-025-9/+9 * - Add two new runtime dependencieseadler2012-01-022-1/+4 * - Update to 2.2.4tota2012-01-022-3/+3 * - Update to 0.3sunpoet2012-01-023-16/+18 * - Update to 2012.01.02sunpoet2012-01-022-3/+3 * - Update to 2012.01.01sunpoet2012-01-026-9/+9 * - Update to 20120101sunpoet2012-01-022-3/+3 * - Update to 0.5.11sunpoet2012-01-022-3/+3 * - Update to 6.5.1tota2012-01-023-13/+32 * - Update to 0.7.0avl2012-01-024-13/+13 * - update to 1.0danger2012-01-022-3/+3 * - remove support for apache version < 20 (mod_perl)ohauer2012-01-021-19/+11 * - disable mod_perl which is gone together with apache13ohauer2012-01-021-7/+9 * - Portsbump to make sure pkg builders get fixed pkg-install.in [1]scheidell2012-01-021-1/+1 * - remove apache13 and ports depending on apache13 from portstreeohauer2012-01-029-886/+6 * - remove apache13 and ports depending on apache13 from portstreeohauer2012-01-025-92/+3 * - remove apache13 and ports depending on apache13 from portstreeohauer2012-01-02505-15096/+107 * - Move all the fetching into fetch phasepav2012-01-022-1/+41 * - rewrite mod_rpaf2 so it is not a subport of mod_rpafohauer2012-01-023-3/+26 * update to 2.1.2.23; add LICENSE and test targets; respect CXX andbf2012-01-028-6/+151 * - Update to 1.241swills2012-01-023-8/+14 * - Update to 1.222swills2012-01-022-4/+3 * - change required APACHE version from 13+ to 20+ohauer2012-01-0265-266/+119 * Deprecate with 2 months timeout, I haven't developed/used it for years.rene2012-01-021-0/+3 * - add new monospaced fontrm2012-01-013-1/+5 * Upgrade to 1.6.4.adamw2012-01-012-5/+5 * Remove expired ports:rene2012-01-0127-1100/+4 * Remove expired unmaintained ports:rene2012-01-0113-285/+2 * - Update to 2011.12.31dhn2012-01-013-7/+12 * Put down my glass of Champagne just long enough to update libocas to 0.94 --bf2012-01-012-4/+4 * Proc::Guard runs process, and destroys it when the perl script exits.kuriyama2012-01-015-0/+38 * Forgotten to add pkg-message filedaichi2012-01-011-0/+7 * Ports modules update at Sunday 01 January 2012 at 00:09edwin2012-01-011-1/+23 * - Upgrade to 1.3091.kuriyama2012-01-013-4/+18 * - update to 2.0.3scheidell2012-01-014-58/+61 * - Add startup script for rdnssdbeech2012-01-014-5/+60 * - Upgrade to 1.1.4scheidell2012-01-012-4/+4 * Add qpopper.inbeech2012-01-011-0/+26 * - Add USE_RC_SUBR with WITH_STANDALONE_MODEbeech2012-01-012-5/+4 * Add entry about the recent lang/newlisp changes (unified MYSQL option).olgeni2012-01-011-0/+13 * - Remove version specific MySQL options. [1]olgeni2012-01-012-20/+7 * - Finish off the year by fixing permissions on the eepg config dirnox2012-01-013-1/+20 * - Update to 0.15amdmi32012-01-013-1154/+2088 * - Update to 1.3.2swills2012-01-013-36/+6 * - Update to 0.0.7.32swills2012-01-013-5/+13 * - Update to 12.7dhn2012-01-013-3/+4 * - Fix the situation where kern.smp.maxid > hw.ncpu by using the former value,rene2012-01-012-16/+29 * - Update to 0.16.6crees2012-01-012-21/+10 * - add Japanese support via option (default off)rm2012-01-012-5/+153 * - Update to 0.6.10dhn2012-01-013-3/+4 * update to 1.8.8.1flo2011-12-312-3/+3 * update to 1.0.2flo2011-12-312-4/+3 * update libmowgli to 1.0.0oliver2011-12-314-5/+5 * update multimedia/audacious to 3.1.1oliver2011-12-3116-306/+154 * - Update to 1.9tabthorpe2011-12-313-8/+8 * Update to 2.4.13.ume2011-12-312-5/+5 * - Update to 1.14tabthorpe2011-12-312-3/+3 * - Update to 3.2tabthorpe2011-12-312-3/+3 * - Built packages were not passing INSTALL var [1]scheidell2011-12-313-75/+93 * Fix directory name for sysrc, which was erroneously added as sysrc+.se2011-12-311-1/+1 * Add sysutils/sysrc port.se2011-12-311-0/+1 * The sysrc utility performs easy and safe editing of rc.conf style enriesse2011-12-313-0/+0 * Update to clive 0.4.9johans2011-12-312-3/+3 * The sysrc utility performs easy and safe editing of rc.conf style enriesse2011-12-314-0/+40 * Fix missing : in RUN_DEPENDS for (non-default) WITH_LV2CORE case.nox2011-12-311-1/+1 * - Upgrade to 0.05.kuriyama2011-12-312-4/+5 * - Upgrade to 0.11.kuriyama2011-12-312-3/+3 * - Upgrade to 0.04.kuriyama2011-12-312-3/+3 * - Upgrade to 1.60.kuriyama2011-12-313-4/+8 * - Upgrade to 1.5007.kuriyama2011-12-312-3/+3 * - Upgrade to 0.06.kuriyama2011-12-312-4/+7 * Bump the copyright year. Happy 2012.bz2011-12-311-1/+1 * - Upgrade to 0.06.kuriyama2011-12-312-3/+3 * - Upgrade to 1.11.kuriyama2011-12-312-4/+4 * This module generates a Clover compatible coverage xml file which cankuriyama2011-12-315-0/+53 * - Update to 2.13.4.10culot2011-12-312-6/+6 * - Update to 4.3.7culot2011-12-312-4/+4 * STF::Dispatcher::PSGI implements the basic STF Protocolkuriyama2011-12-315-0/+61 * Test::mysqld automatically setups a mysqld instance in a temporarykuriyama2011-12-315-0/+37 * Take over maintainership.mandree2011-12-311-1/+1 * Using output of /dev/urandom. Simply convert bytes into 8-bitkuriyama2011-12-315-0/+38 * Perl::Metrics::Simple provides just enough methods to run statickuriyama2011-12-316-0/+71 * Plack::Middleware::Reproxy implements a simple reproxy mechanism viakuriyama2011-12-315-0/+42 * Parallel::Scoreboard is a pure-perl implementation of a processkuriyama2011-12-315-0/+53 * This is a wrapper to Furl for asynchronous HTTP requests with Coro.kuriyama2011-12-315-0/+44 * The murmur hash algorithm by Austin Appleby is an exteremely fastkuriyama2011-12-315-0/+36 * - respect CC/CFLAGS, now build with clangwen2011-12-312-17/+18 * - Update to 1.3.1wen2011-12-313-10/+104 * The most common action that a crawler takes is to follow links on akuriyama2011-12-315-0/+76 * Perl::Metrics::Lite is the pluggable perl code metrics system.kuriyama2011-12-315-0/+73 * Update to the latest development build (now same as primary port).cy2011-12-312-3/+4 * Fix a few build issues with clang.rakuco2011-12-313-0/+28 * Update to 1.7.22.jsa2011-12-312-3/+3 * update to 5.10bf2011-12-312-3/+3 * Fix build with clang.rakuco2011-12-312-0/+44 * Ports modules update at Saturday 31 December 2011 at 00:09edwin2011-12-311-0/+3 * - Update to 1.242swills2011-12-312-3/+3 * Update 5.0.0 --> 5.0.1cy2011-12-313-4/+5 * - Update to 1.2003swills2011-12-312-3/+3 * - Update to 18.2swills2011-12-312-3/+3 * - Add eepg plugin.nox2011-12-311-1/+5 * This VDR plugin parses the extended (2 to 10 day) EPG data which is send bynox2011-12-316-0/+72 * Update to xbmc-pvr-ppa-odk-58, which corresponds to Eden-pvr_beta1.nox2011-12-313-5/+15 * Change build target to avoid its 'make check' part,johans2011-12-311-1/+1 * - Update to 2.7.9swills2011-12-312-4/+3 * - Update to 1.8.10,2crees2011-12-318-18/+8 * - Mark BROKEN: incomplete plistpav2011-12-311-0/+2 * - Mark BROKEN (at least) on amd64: does not packagepav2011-12-311-0/+1 * - Remove unneeded libungif dep. The program bundles the parts of libungifswills2011-12-311-2/+1 * Improve rc.d scriptpawel2011-12-311-6/+5 * A simple Ruby API for command-line interaction. Provides a novel 'rewinding'swills2011-12-314-0/+29 * - Mark MAKE_JOBS_UNSAFE as I experienced build issues with MAKE_JOBSswills2011-12-311-0/+2 * - Update to 2.14.1pav2011-12-314-15/+100 * - Add BUILD_DEPENDS to silence build warnings and enable testingswills2011-12-312-3/+4 * - Reassignment of ECHO_MSG breaks 'make readme', so remove and reformat IGNORE.jgh2011-12-311-4/+5 * - Reassignment of ECHO_MSG breaks 'make readme', so remove and reformat IGNORE.jgh2011-12-311-12/+6 * Update to 0.11.6jgh2011-12-312-4/+4 * Update to 20110201 release.ale2011-12-303-14/+6 * Add three new third-party modules:osa2011-12-306-0/+124 * Upgrade to avr-libc 1.8.0joerg2011-12-303-4/+30 * Installs built jars that were previously not installed.jgh2011-12-301-1/+2 * Installs built jars that were previously not installed.jgh2011-12-301-0/+2 * - Add TEST_DEPENDS to enable testingswills2011-12-301-0/+1 * - Add missing BUILD_DEPENDS to silence build warnings and allow testingswills2011-12-301-1/+2 * Update to 1.7.8.2.wxs2011-12-303-21/+9 * Add additional MITKRB5 reference.cy2011-12-301-1/+1 * Update maintainer's email address.linimon2011-12-302-2/+2 * Replace local patch file with identical MIT patch.cy2011-12-303-13/+4 * Ports modules update at Friday 30 December 2011 at 00:09edwin2011-12-300-0/+0 * - Fix to properly check dependenciesbeech2011-12-301-4/+4 * - Update to 20111221sunpoet2011-12-302-3/+3 * - Turn over to gnome team since it's used by Gnome portsswills2011-12-303-3/+3 * - Fix build on 10-CURRENTswills2011-12-304-16/+23 * - Update to 7.2sunpoet2011-12-302-4/+4 * - Update to 7.2sunpoet2011-12-303-4/+9 * Update to version 0.2.8pawel2011-12-307-46/+37 * - Add missing BUILD_DEPENDS to silence build warningsswills2011-12-301-1/+4 * - correct download url for turbogears.orgrm2011-12-303-6/+6 * Update last entry. As of FreeBSD-SA-11:07.chroot the port may be used onmm2011-12-301-3/+3 * As of FreeBSD-SA-11:07.chroot, the port now works on both patched andmm2011-12-302-9/+39 * Update to version 0.6.6pawel2011-12-303-5/+116 * - Install expunge script with right permissions [1]scheidell2011-12-306-102/+110 * This is a serial-over-lan (sol) client for Intel AMT. Includes a terminal andcrees2011-12-30