On Thu, Dec 24, 2009 at 1:28 PM, bheemesh v <bheem...@gmail.com> wrote:

> On Thu, Dec 24, 2009 at 2:53 PM, Bart Van Assche <bart.vanass...@gmail.com
> > wrote:
>
>> On Fri, Dec 11, 2009 at 11:20 AM, bheemesh v <bheem...@gmail.com> wrote:
>> > Attaching call graph of the profiled snmpd daemon.
>> > Find the graph in attachment.
>>
>> (replying to an e-mail of two weeks ago)
>>
>> The call graph is interesting. What you did not yet tell us, and what
>> is important in order to interpret the call graph correctly, is how
>> many rows are present on your setup in ipAddressTable.
>>
>> As you can see in the source code of netsnmp_binary_array_insert(),
>> this function adds a new entry at the end of the array and sets the
>> dirty flag. Setting the dirty flag will make the next call of
>> netsnmp_binary_array_get() (which is called by
>> netsnmp_binary_array_insert() to check for duplicate entries) sort the
>> array. It will probably help to modify netsnmp_binary_array_insert()
>> such that if the dirty flag is not set upon entry, it does not set the
>> dirty flag upon exit but instead inserts the new entry at the right
>> position in the array such that it remains sorted.
>>
>
> Thanks very much for your inputs.
>
> In fact we have 500+ IP's configured on this machine.
> Meanwhile as a optimization i tried was to avoid the
> netsnmp_binary_array_get() call from "netsnmp_binary_array_insert()", so
> that sort will be called only when the last entry in the container is being
> checked.
>
> Because this only checks for duplicate entries.
> Let me know whether this change makes it better?
>

You are welcome to submit a patch that fixes this issue on the Net-SNMP
patch tracker.

Bart.
------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Net-snmp-users mailing list
Net-snmp-users@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to