Re: more profiling

From: Adrian Chadd <adrian@dont-contact.us>
Date: Tue, 19 Sep 2006 13:22:33 +0800

And here's why clean/getStats are being called so often!

#0 0x08106a5a in MemPool::clean (this=0x846f7e0, maxage=555555) at MemPool.cc:651
#1 0x08105632 in MemPool::getStats (this=0x846f7e0, stats=0xbf845450) at MemPool.cc:720
#2 0x080b5ca8 in mem_node::InUseCount () at mem_node.cc:82
#3 0x080cac07 in storeGetMemSpace (size=4094) at store.cc:1215
#4 0x080cad4e in StoreEntry::write (this=0xe18366c, writeBuffer=
      {flags = {error = 0}, length = 4094, offset = 7782, data = 0xb6e9d008
+".^mJ9u6C7.O&(Q-ky@dJ*b_c7/(dJhs5TF]VV:W3F~6nzHZ(7BTJc^E#l\\JZW;-'dteHHc)M3#Q^PclS9u,v@x6:YM-\\V5}nr2LI_nftwRJW&ZE*xU;[:#fA6`d;#\\~fc3iM]WwC{B+`k,L-gF+(}mc
+SN_3*tc2o.:PvF}nR*3]>4~xg/SX$8wz7a$=e=\\5QW,QUFbL&"...}) at store.cc:852

(gdb) frame 2
#2 0x080b5ca8 in mem_node::InUseCount () at mem_node.cc:82
82 Pool().getStats (&stats);
(gdb) frame 3
#3 0x080cac07 in storeGetMemSpace (size=4094) at store.cc:1215
1215 if (mem_node::InUseCount() + pages_needed < store_pages_max)

from storeGetMemSpace() :

    /* XXX what to set as max_scan here? */
    walker = mem_policy->PurgeInit(mem_policy, 100000);

    while ((e = walker->Next(walker))) {
        storePurgeMem(e);
        released++;

        if (mem_node::InUseCount() + pages_needed < store_pages_max)
            break;
    }

    walker->Done(walker);

You did say the getStats() call was very expensive.

Aha! Could someone please beat me to fixing this? I need to attend to studies
for a few days.

Adrian
Received on Mon Sep 18 2006 - 23:22:28 MDT

This archive was generated by hypermail pre-2.1.9 : Sun Oct 01 2006 - 12:00:06 MDT