[CVS] RPM: rpm/rpmio/ rpmio.c
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Per Øyvind Karlsen Root: /v/rpm/cvs Email: pkarl...@rpm5.org Module: rpm Date: 12-May-2009 15:44:07 Branch: HEAD Handle: 2009051213440700 Modified files: rpm/rpmio rpmio.c Log: free _rpmsyckPool at exit Summary: RevisionChanges Path 1.193 +2 -0 rpm/rpmio/rpmio.c patch -p0 '@@ .' Index: rpm/rpmio/rpmio.c $ cvs diff -u -r1.192 -r1.193 rpmio.c --- rpm/rpmio/rpmio.c 17 Apr 2009 16:10:23 - 1.192 +++ rpm/rpmio/rpmio.c 12 May 2009 13:44:07 - 1.193 @@ -3132,6 +3132,7 @@ /*...@-shadow@*/ extern rpmioPool _mirePool; extern rpmioPool _htPool; +extern rpmioPool _rpmsyckPool; /*...@=shadow@*/ extern rpmioPool _rpmmgPool; extern rpmioPool _rpmluavPool; @@ -3175,6 +3176,7 @@ _mirePool = rpmioFreePool(_mirePool); _rpmmgPool = rpmioFreePool(_rpmmgPool); _htPool = rpmioFreePool(_htPool); +_rpmsyckPool = rpmioFreePool(_rpmsyckPool); _rpmiobPool = rpmioFreePool(_rpmiobPool); _digPool = rpmioFreePool(_digPool); _xarPool = rpmioFreePool(_xarPool); @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/lib/ rpmrc.c
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Per Øyvind Karlsen Root: /v/rpm/cvs Email: pkarl...@rpm5.org Module: rpm Date: 12-May-2009 16:48:27 Branch: HEAD Handle: 2009051214482700 Modified files: rpm/lib rpmrc.c Log: fix breakage with cpu aliases introduced in previous commit Summary: RevisionChanges Path 2.281 +7 -9 rpm/lib/rpmrc.c patch -p0 '@@ .' Index: rpm/lib/rpmrc.c $ cvs diff -u -r2.280 -r2.281 rpmrc.c --- rpm/lib/rpmrc.c 12 May 2009 13:35:21 - 2.280 +++ rpm/lib/rpmrc.c 12 May 2009 14:48:27 - 2.281 @@ -583,9 +583,6 @@ htGetEntry(arch[j].value.map, Alias, tmp, NULL, NULL); alias = tmp[0]-value.seq; } - else { - alias = tmp[0]; - } htAddEntry(cpus, name, alias); } } @@ -594,15 +591,16 @@ htGetEntry(node[i].value.map, Priority, tmp, NULL, NULL); rpmsyck_node priority = tmp[0]-value.seq; int j; - for(j = 0; (j == 0 || priority[j].type == T_SEQ) priority[j].type != T_END; j++) + for(j = 0; priority[j].type != T_END; j++) if(htHasEntry(cpus, priority[j].value.key)) { xx = mireAppend(RPMMIRE_REGEX, 0, priority[j].value.key, NULL, mi_re, mi_nre); - htGetEntry(cpus, priority[j].value.key, tmp, NULL, NULL); - rpmsyck_node alias = tmp[0]; - int k; - for(k = 0; alias[k].type != T_END; k++) - xx = mireAppend(RPMMIRE_REGEX, 0, alias[k].value.key, NULL, mi_re, mi_nre); + if(tmp[0]) { + rpmsyck_node alias = tmp[0]; + int k; + for(k = 0; alias[k].type != T_END; k++) + xx = mireAppend(RPMMIRE_REGEX, 0, alias[k].value.key, NULL, mi_re, mi_nre); + } } } } @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/ CHANGES configure.ac
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Jeff Johnson Root: /v/rpm/cvs Email: j...@rpm5.org Module: rpm Date: 12-May-2009 17:29:57 Branch: HEAD Handle: 2009051215295601 Modified files: rpm CHANGES configure.ac Log: - don't reset to -O0 with --enable-build-debug and GCC. Summary: RevisionChanges Path 1.2979 +1 -0 rpm/CHANGES 2.375 +1 -1 rpm/configure.ac patch -p0 '@@ .' Index: rpm/CHANGES $ cvs diff -u -r1.2978 -r1.2979 CHANGES --- rpm/CHANGES 12 May 2009 13:35:22 - 1.2978 +++ rpm/CHANGES 12 May 2009 15:29:56 - 1.2979 @@ -1,5 +1,6 @@ 5.2b1 - 5.3a1 +- jbj: don't reset to -O0 with --enable-build-debug and GCC. - proyvind: rpmsyck: clean up, use rpmioPool and add destructor. - proyvind: rpmhash: add htGetKeys() for retrieving the keys of the hash table. - jbj: bash: wire-up internal bash build with RPM AutoFu. @@ . patch -p0 '@@ .' Index: rpm/configure.ac $ cvs diff -u -r2.374 -r2.375 configure.ac --- rpm/configure.ac 9 May 2009 19:55:46 - 2.374 +++ rpm/configure.ac 12 May 2009 15:29:57 - 2.375 @@ -176,7 +176,7 @@ if test .$enableval = .yes; then if test .`$CC --version 21 | grep 'GCC'` != .; then dnl # GNU GCC (usually gcc) -CFLAGS=$CFLAGS -O0 -g3 +CFLAGS=$CFLAGS -g3 elif test .`$CC -V 21 | grep 'Sun C'` != .; then dnl # Sun Studio (usually cc) CFLAGS=$CFLAGS -xO0 -g @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm-5_2: rpm/ CHANGES configure.ac
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Jeff Johnson Root: /v/rpm/cvs Email: j...@rpm5.org Module: rpm Date: 12-May-2009 17:30:49 Branch: rpm-5_2 Handle: 2009051215304900 Modified files: (Branch: rpm-5_2) rpm CHANGES configure.ac Log: - don't reset to -O0 with --enable-build-debug and GCC. Summary: RevisionChanges Path 1.2970.2.3 +1 -0 rpm/CHANGES 2.372.2.2 +1 -1 rpm/configure.ac patch -p0 '@@ .' Index: rpm/CHANGES $ cvs diff -u -r1.2970.2.2 -r1.2970.2.3 CHANGES --- rpm/CHANGES 9 May 2009 15:51:58 - 1.2970.2.2 +++ rpm/CHANGES 12 May 2009 15:30:49 - 1.2970.2.3 @@ -1,5 +1,6 @@ 5.2a4 - 5.2b1: +- jbj: don't reset to -O0 with --enable-build-debug and GCC. - jbj: grep: fix: don't segfault if no usage mutex or pool attached. - rse: align semantics of Lua function rpm.hostname() with the C API function buildHost() - proyvind: cpuinfo: move out cpuinfo feature dependencies to YAML. @@ . patch -p0 '@@ .' Index: rpm/configure.ac $ cvs diff -u -r2.372.2.1 -r2.372.2.2 configure.ac --- rpm/configure.ac 6 May 2009 17:17:42 - 2.372.2.1 +++ rpm/configure.ac 12 May 2009 15:30:49 - 2.372.2.2 @@ -176,7 +176,7 @@ if test .$enableval = .yes; then if test .`$CC --version 21 | grep 'GCC'` != .; then dnl # GNU GCC (usually gcc) -CFLAGS=$CFLAGS -O0 -g3 +CFLAGS=$CFLAGS -g3 elif test .`$CC -V 21 | grep 'Sun C'` != .; then dnl # Sun Studio (usually cc) CFLAGS=$CFLAGS -xO0 -g @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/lib/ Makefile.am
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Jeff Johnson Root: /v/rpm/cvs Email: j...@rpm5.org Module: rpm Date: 12-May-2009 17:51:24 Branch: HEAD Handle: 2009051215512300 Modified files: rpm/lib Makefile.am Log: - fix: add syck.h search paths. Summary: RevisionChanges Path 2.189 +1 -0 rpm/lib/Makefile.am patch -p0 '@@ .' Index: rpm/lib/Makefile.am $ cvs diff -u -r2.188 -r2.189 Makefile.am --- rpm/lib/Makefile.am 15 Jan 2009 02:11:44 - 2.188 +++ rpm/lib/Makefile.am 12 May 2009 15:51:23 - 2.189 @@ -20,6 +20,7 @@ @WITH_LUA_CPPFLAGS@ \ @WITH_FILE_CPPFLAGS@ \ @WITH_PCRE_CPPFLAGS@ \ + @WITH_SYCK_CPPFLAGS@ \ @WITH_XAR_CPPFLAGS@ RPM_LDADD = \ @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm-5_2: rpm/ CHANGES rpm/scripts/ find-debuginfo.sh
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Bernhard Rosenkraenzer Root: /v/rpm/cvs Email: b...@rpm5.org Module: rpm Date: 12-May-2009 18:02:39 Branch: rpm-5_2 Handle: 2009051216023801 Modified files: (Branch: rpm-5_2) rpm CHANGES rpm/scripts find-debuginfo.sh Log: Adjust find-debuginfo.sh to new location of debugedit (/usr/lib/rpm - /usr/lib/rpm/bin) Summary: RevisionChanges Path 1.2970.2.4 +1 -0 rpm/CHANGES 1.11.6.1+1 -1 rpm/scripts/find-debuginfo.sh patch -p0 '@@ .' Index: rpm/CHANGES $ cvs diff -u -r1.2970.2.3 -r1.2970.2.4 CHANGES --- rpm/CHANGES 12 May 2009 15:30:49 - 1.2970.2.3 +++ rpm/CHANGES 12 May 2009 16:02:38 - 1.2970.2.4 @@ -1,5 +1,6 @@ 5.2a4 - 5.2b1: +- bero: adjust find-debuginfo.sh to new location of debugedit - jbj: don't reset to -O0 with --enable-build-debug and GCC. - jbj: grep: fix: don't segfault if no usage mutex or pool attached. - rse: align semantics of Lua function rpm.hostname() with the C API function buildHost() @@ . patch -p0 '@@ .' Index: rpm/scripts/find-debuginfo.sh $ cvs diff -u -r1.11 -r1.11.6.1 find-debuginfo.sh --- rpm/scripts/find-debuginfo.sh 6 Sep 2007 07:36:38 - 1.11 +++ rpm/scripts/find-debuginfo.sh 12 May 2009 16:02:39 - 1.11.6.1 @@ -199,7 +199,7 @@ fi echo extracting debug info from $f - id=$(/usr/lib/rpm/debugedit -b $RPM_BUILD_DIR -d /usr/src/debug \ + id=$(/usr/lib/rpm/bin/debugedit -b $RPM_BUILD_DIR -d /usr/src/debug \ -i -l $SOURCEFILE $f) || exit if [ -z $id ]; then echo 2 *** ${strict_error}: No build ID note found in $f @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/ CHANGES configure.ac debug.h devtool.conf
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Jeff Johnson Root: /v/rpm/cvs Email: j...@rpm5.org Module: rpm Date: 12-May-2009 20:07:44 Branch: HEAD Handle: 2009051218074400 Modified files: rpm CHANGES configure.ac debug.h devtool.conf Log: - add --with-valgrind homeopathy to measure existing RPM insturmentation effects on performance Summary: RevisionChanges Path 1.2980 +2 -0 rpm/CHANGES 2.376 +8 -0 rpm/configure.ac 2.3 +11 -0 rpm/debug.h 2.297 +1 -0 rpm/devtool.conf patch -p0 '@@ .' Index: rpm/CHANGES $ cvs diff -u -r1.2979 -r1.2980 CHANGES --- rpm/CHANGES 12 May 2009 15:29:56 - 1.2979 +++ rpm/CHANGES 12 May 2009 18:07:44 - 1.2980 @@ -1,5 +1,7 @@ 5.2b1 - 5.3a1 +- jbj: add --with-valgrind homeopathy to measure existing RPM + insturmentation effects on performance. - jbj: don't reset to -O0 with --enable-build-debug and GCC. - proyvind: rpmsyck: clean up, use rpmioPool and add destructor. - proyvind: rpmhash: add htGetKeys() for retrieving the keys of the hash table. @@ . patch -p0 '@@ .' Index: rpm/configure.ac $ cvs diff -u -r2.375 -r2.376 configure.ac --- rpm/configure.ac 12 May 2009 15:29:57 - 2.375 +++ rpm/configure.ac 12 May 2009 18:07:44 - 2.376 @@ -198,6 +198,14 @@ fi ]) +dnl # optional valgrind/cachegrind support +AC_ARG_WITH(valgrind, AS_HELP_STRING([--with-valgrind], [build RPM insturmented for valgrind tools]), [ +if test .$withval = .yes; then + AC_CHECK_HEADERS(valgrind/valgrind.h) +AC_DEFINE(WITH_VALGRIND, 1, [Build with valgrind support?]) +fi +]) + dnl # RPM tries hard to use adaptive feature tests instead of dnl # problematic platform tests. Nevertheless for some extremely dnl # platform specific parts of the code, we have to know for what @@ . patch -p0 '@@ .' Index: rpm/debug.h $ cvs diff -u -r2.2 -r2.3 debug.h --- rpm/debug.h 20 Jun 2007 21:10:19 - 2.2 +++ rpm/debug.h 12 May 2009 18:07:44 - 2.3 @@ -17,4 +17,15 @@ #include dmalloc.h #endif +#if defined(WITH_VALGRIND) defined(HAVE_VALGRIND_VALGRIND_H) +#include valgrind/valgrind.h +#else +#define CALLGRIND_DUMP_STATS +#define CALLGRIND_DUMP_STATS_AT(pos_str) +#define CALLGRIND_ZERO_STATS +#define CALLGRIND_TOGGLE_COLLECT +#define CALLGRIND_START_INSTRUMENTATION +#define CALLGRIND_STOP_INSTRUMENTATION +#endif + #endif /* H_DEBUG */ @@ . patch -p0 '@@ .' Index: rpm/devtool.conf $ cvs diff -u -r2.296 -r2.297 devtool.conf --- rpm/devtool.conf 10 May 2009 14:05:01 - 2.296 +++ rpm/devtool.conf 12 May 2009 18:07:44 - 2.297 @@ -107,6 +107,7 @@ --with-ruby=/usr/lib/ruby/1.8/i386-linux \ --with-build-extlibdep \ --with-build-maxextlibdep \ +--with-valgrind \ --enable-build-pic \ --enable-build-versionscript \ --enable-build-warnings \ @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/lib/ rpmrc.c
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Per Øyvind Karlsen Root: /v/rpm/cvs Email: pkarl...@rpm5.org Module: rpm Date: 12-May-2009 21:17:53 Branch: HEAD Handle: 2009051219175300 Modified files: rpm/lib rpmrc.c Log: leak a bit less memory in rpmCpuinfo().. Summary: RevisionChanges Path 2.282 +5 -2 rpm/lib/rpmrc.c patch -p0 '@@ .' Index: rpm/lib/rpmrc.c $ cvs diff -u -r2.281 -r2.282 rpmrc.c --- rpm/lib/rpmrc.c 12 May 2009 14:48:27 - 2.281 +++ rpm/lib/rpmrc.c 12 May 2009 19:17:53 - 2.282 @@ -538,6 +538,8 @@ Fread(yaml, 1, st.st_size, fd); Fclose(fd); +/* XXX: Probably not right..? */ +cpuinfo = rpmdsSingle(RPMTAG_PROVIDENAME, , , RPMSENSE_PROBE); xx = rpmdsCpuinfo(cpuinfo, NULL); cpuinfoYaml = rpmSyckLoad(yaml); @@ -611,9 +613,10 @@ cpuinfoYaml = rpmSyckFree(cpuinfoYaml); -xx = mireAppend(RPMMIRE_REGEX, 0, noarch, NULL, mi_re, mi_nre); +(void)rpmdsFree(cpuinfo); +cpuinfo = NULL; -cpuinfo = rpmdsFree(cpuinfo); +xx = mireAppend(RPMMIRE_REGEX, 0, noarch, NULL, mi_re, mi_nre); cpu = mi_re[0].pattern; if(cpu != NULL) @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/lib/ rpmds.c
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Per Øyvind Karlsen Root: /v/rpm/cvs Email: pkarl...@rpm5.org Module: rpm Date: 12-May-2009 23:15:32 Branch: HEAD Handle: 2009051221153200 Modified files: rpm/lib rpmds.c Log: s/endianness/endian/ in rpmdsCpuinfo() Summary: RevisionChanges Path 2.156 +5 -5 rpm/lib/rpmds.c patch -p0 '@@ .' Index: rpm/lib/rpmds.c $ cvs diff -u -r2.155 -r2.156 rpmds.c --- rpm/lib/rpmds.c 6 May 2009 02:09:57 - 2.155 +++ rpm/lib/rpmds.c 12 May 2009 21:15:32 - 2.156 @@ -1204,7 +1204,7 @@ unsigned char uc[4]; }; static union _dbswap orderedbytes = { .ui = 0x11223344 }; -const char * endian = NULL; +const char * endianness = NULL; snprintf(tmp, 19, %d, cpuinfo_get_frequency(cip)); tmp[19] = '\0'; @@ -1215,12 +1215,12 @@ rpmdsNSAdd(dsp, NS, cpu_threads, tmp, RPMSENSE_PROBE|RPMSENSE_EQUAL); if(orderedbytes.uc[0] == 0x44) - endian = little; + endianness = little; else if(orderedbytes.uc[0] == 0x11) - endian = big; + endianness = big; else if(orderedbytes.uc[0] == 0x22) - endian = pdp; -rpmdsNSAdd(dsp, NS, endian, endian, RPMSENSE_PROBE|RPMSENSE_EQUAL); + endianness = pdp; +rpmdsNSAdd(dsp, NS, endianness, endianness, RPMSENSE_PROBE|RPMSENSE_EQUAL); for (feature = cpuinfo_feature_common; feature != cpuinfo_feature_architecture_max; feature++) { if(feature == cpuinfo_feature_common_max) @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/lib/ depends.c rpmrc.c
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Per Øyvind Karlsen Root: /v/rpm/cvs Email: pkarl...@rpm5.org Module: rpm Date: 12-May-2009 23:16:45 Branch: HEAD Handle: 2009051221164500 Modified files: rpm/lib depends.c rpmrc.c Log: make cpuinfoP in lib/depends.c non-static and reuse it rather than recreating another in rpmCpuinfo() Summary: RevisionChanges Path 1.442 +1 -1 rpm/lib/depends.c 2.283 +4 -10 rpm/lib/rpmrc.c patch -p0 '@@ .' Index: rpm/lib/depends.c $ cvs diff -u -r1.441 -r1.442 depends.c --- rpm/lib/depends.c 6 Apr 2009 00:21:21 - 1.441 +++ rpm/lib/depends.c 12 May 2009 21:16:45 - 1.442 @@ -821,7 +821,7 @@ /*...@refcounted@*/ /*...@null@*/ /*...@unchecked@*/ static rpmds rpmlibP = NULL; /*...@refcounted@*/ /*...@null@*/ /*...@unchecked@*/ -static rpmds cpuinfoP = NULL; +rpmds cpuinfoP = NULL; /*...@refcounted@*/ /*...@null@*/ /*...@unchecked@*/ static rpmds getconfP = NULL; /*...@refcounted@*/ /*...@null@*/ /*...@unchecked@*/ @@ . patch -p0 '@@ .' Index: rpm/lib/rpmrc.c $ cvs diff -u -r2.282 -r2.283 rpmrc.c --- rpm/lib/rpmrc.c 12 May 2009 19:17:53 - 2.282 +++ rpm/lib/rpmrc.c 12 May 2009 21:16:45 - 2.283 @@ -509,6 +509,7 @@ { rpmds cpufeature = rpmdsSingle(RPMTAG_REQUIRENAME, feature, EVR, RPMSENSE_PROBE); int ret = rpmdsMatch(cpufeature, cpuinfo); + (void)rpmdsFree(cpufeature); cpufeature = NULL; return ret; @@ -521,7 +522,7 @@ miRE mi_re = NULL; int mi_nre = 0, xx, i; CVOG_t cvog = NULL; -rpmds cpuinfo = NULL; +extern rpmds cpuinfoP; struct stat st; char *yaml; rpmsyck_node *tmp, node; @@ -538,10 +539,6 @@ Fread(yaml, 1, st.st_size, fd); Fclose(fd); -/* XXX: Probably not right..? */ -cpuinfo = rpmdsSingle(RPMTAG_PROVIDENAME, , , RPMSENSE_PROBE); -xx = rpmdsCpuinfo(cpuinfo, NULL); - cpuinfoYaml = rpmSyckLoad(yaml); yaml = _free(yaml); htGetEntry(cpuinfoYaml-firstNode-value.map, cpuinfo, tmp, NULL, NULL); @@ -556,7 +553,7 @@ const char *family = tmp[0]-value.key; int j; hashTable cpus = NULL; - if(rpmCpuinfoMatch(family, , cpuinfo)) { + if(rpmCpuinfoMatch(family, , cpuinfoP)) { if(htHasEntry(node[i].value.map, Arch)) { htGetEntry(node[i].value.map, Arch, tmp, NULL, NULL); rpmsyck_node arch = tmp[0]-value.seq; @@ -573,7 +570,7 @@ rpmsyck_node features = tmp[0]-value.seq; int k, match = 0; for(k = 0; features[k].type != T_END; k++) - if(features[k].type == T_STR !(match = rpmCpuinfoMatch(features[k].value.key, , cpuinfo))) break; + if(features[k].type == T_STR !(match = rpmCpuinfoMatch(features[k].value.key, , cpuinfoP))) break; if(!match) continue; } if(htHasEntry(arch[j].value.map, Name)) { @@ -613,9 +610,6 @@ cpuinfoYaml = rpmSyckFree(cpuinfoYaml); -(void)rpmdsFree(cpuinfo); -cpuinfo = NULL; - xx = mireAppend(RPMMIRE_REGEX, 0, noarch, NULL, mi_re, mi_nre); cpu = mi_re[0].pattern; @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org
[CVS] RPM: rpm/ CHANGES rpm/rpmio/ librpmio.vers rpmlog.c rpmlog.h
RPM Package Manager, CVS Repository http://rpm5.org/cvs/ Server: rpm5.org Name: Jeff Johnson Root: /v/rpm/cvs Email: j...@rpm5.org Module: rpm Date: 12-May-2009 23:17:11 Branch: HEAD Handle: 2009051221171100 Modified files: rpm CHANGES rpm/rpmio librpmio.vers rpmlog.c rpmlog.h Log: - inline rpmlog() to avoid arglist overhead when -O2 is used. Summary: RevisionChanges Path 1.2981 +1 -0 rpm/CHANGES 2.117 +2 -1 rpm/rpmio/librpmio.vers 2.46+2 -2 rpm/rpmio/rpmlog.c 2.23+25 -1 rpm/rpmio/rpmlog.h patch -p0 '@@ .' Index: rpm/CHANGES $ cvs diff -u -r1.2980 -r1.2981 CHANGES --- rpm/CHANGES 12 May 2009 18:07:44 - 1.2980 +++ rpm/CHANGES 12 May 2009 21:17:11 - 1.2981 @@ -1,5 +1,6 @@ 5.2b1 - 5.3a1 +- jbj: inline rpmlog() to avoid arglist overhead when -O2 is used. - jbj: add --with-valgrind homeopathy to measure existing RPM insturmentation effects on performance. - jbj: don't reset to -O0 with --enable-build-debug and GCC. @@ . patch -p0 '@@ .' Index: rpm/rpmio/librpmio.vers $ cvs diff -u -r2.116 -r2.117 librpmio.vers --- rpm/rpmio/librpmio.vers 12 May 2009 13:35:21 - 2.116 +++ rpm/rpmio/librpmio.vers 12 May 2009 21:17:11 - 2.117 @@ -349,7 +349,8 @@ rpmPubkeyUnlink; rpmLoadMacroFile; rpmLoadMacros; -rpmlog; +_rpmlog; +vrpmlog; rpmlogClose; rpmlogCode; rpmlogGetNrecs; @@ . patch -p0 '@@ .' Index: rpm/rpmio/rpmlog.c $ cvs diff -u -r2.45 -r2.46 rpmlog.c --- rpm/rpmio/rpmlog.c11 Dec 2008 21:55:14 - 2.45 +++ rpm/rpmio/rpmlog.c12 May 2009 21:17:11 - 2.46 @@ -210,7 +210,7 @@ /*...@-modfilesys@*/ /*...@-compmempass@*/ /* FIX: rpmlogMsgPrefix[] dependent, not unqualified */ /*...@-nullstate@*/ /* FIX: rpmlogMsgPrefix[] may be NULL */ -static void vrpmlog (unsigned code, const char *fmt, va_list ap) +void vrpmlog (unsigned code, const char *fmt, va_list ap) /*...@globals nrecs, recs, internalState @*/ /*...@modifies nrecs, recs, internalState @*/ { @@ -291,7 +291,7 @@ /*...@=compmempass =nullst...@*/ /*...@=modfilesys@*/ -void rpmlog (int code, const char *fmt, ...) +void _rpmlog (int code, const char *fmt, ...) { va_list ap; @@ . patch -p0 '@@ .' Index: rpm/rpmio/rpmlog.h $ cvs diff -u -r2.22 -r2.23 rpmlog.h --- rpm/rpmio/rpmlog.h20 Feb 2008 00:39:15 - 2.22 +++ rpm/rpmio/rpmlog.h12 May 2009 21:17:11 - 2.23 @@ -277,14 +277,38 @@ /** * Generate a log message using FMT string and option arguments. + * Note: inline'd to avoid debugging insturmentation overhead. */ -/*...@mayexit@*/ /*...@printflike@*/ void rpmlog (int code, const char *fmt, ...) +/*...@mayexit@*/ /*...@printflike@*/ +void _rpmlog (int code, const char *fmt, ...) #if defined(__GNUC__) __GNUC__ = 2 /* issue a warning if the format string doesn't match arguments */ __attribute__((format (printf, 2, 3))) #endif /*...@*/; +/** + * Same as _rpmlog with stdarg argument list. + */ +void vrpmlog (unsigned code, const char * fmt, va_list ap) + /*...@*/; + +/*...@mayexit@*/ /*...@printflike@*/ +static inline +void rpmlog (int code, const char *fmt, ...) + /*...@*/ +{ +unsigned pri = RPMLOG_PRI(code); +unsigned mask = RPMLOG_MASK(pri); + +if (mask rpmlogSetMask(0)) { + va_list ap; + va_start(ap, fmt); + vrpmlog(code, fmt, ap); + va_end(ap); +} +} + /*...@-exportlocal@*/ /** * Return text of last rpmError() message. @@ . __ RPM Package Managerhttp://rpm5.org CVS Sources Repositoryrpm-cvs@rpm5.org