[quagga-dev 9328] Re: [RFC PATCH 00/25] Mostly bgpd optimizations

Paul Jakma paul at jakma.org
Tue May 8 16:44:03 BST 2012


Hi,

Do you have any idea which of the patches contribute what amount of 
savings? Did you take profiles from before and after, or? Some idea of the 
methodology would be useful.

regards,

Paul

On Mon, 7 May 2012, Jorge Boncompte [DTI2] wrote:

> From: "Jorge Boncompte [DTI2]" <jorge at dti2.net>
>
>  This patchset is part of my work in the last weeks to optimize the speed
> and memory usage of the bgpd daemon.
>
>  My test case has been a full internet table loading on a pIII class
> machine. With the patches just the table loading time went from 14 to 10
> seconds. And memory usage it is a lot more stable, due to less heap
> fragmentation.
>
>  Please, take a look at it, comments welcome.
>
> Jorge Boncompte [DTI2] (25):
>  bgpd: optimize aspath string representation and assegments handling
>  bgpd: optimize bgp_nexthop_self()
>  bgpd: debug buffers cleanup and optimization
>  bgpd: remove calls to peer_sort() from fast-path
>  bgpd: optimize loops on [e]community_hash_make()
>  bgpd: optimize bgp_info_cmp()
>  bgpd: remove some useless initializations
>  bgpd: reduce attrhash_make_key() indirections
>  bgpd: use on stack struct attr_extra on bgp_attr_aggregate_intern()
>  bgpd: cleanup bgp_attr_unintern()
>  bgpd: use on stack struct attr_extra in bgp_attr_unintern()
>  bgpd: fix struct attr_extra leak in bgp_default_originate()
>  bgpd: use on stack struct attr_extra in bgp_update_receive()
>  bgpd: bgp_attr_default_set() already allocates a struct attr_extra
>  bgpd: reduce struct attr_extra allocations/freeing
>  bgpd: Remove useless initialization
>  bgpd: optimize holdtime timer cancelling
>  bgpd: optimize bgp_update_main() in the soft_reconfig case
>  bgpd: fix for bgp_node_lookup()
>  bgpd: optimize bgp_aggregate_[increment|decrement]()
>  micro-op bgp_node_[get|lookup]() and route_node_[get|lookup]()
>  lib: remove RUSAGE_T from struct thread
>  lib: micro-op for thread_get()
>  lib: do not allocate/free thread funcnames
>  lib: optimize IPV4_ADDR_[SAME|COPY]()
>
> bgpd/bgp_aspath.c     |  141 ++++++++++---------
> bgpd/bgp_aspath.h     |    1 +
> bgpd/bgp_attr.c       |  121 +++++++++--------
> bgpd/bgp_community.c  |   19 ++-
> bgpd/bgp_ecommunity.c |   21 ++-
> bgpd/bgp_mpath.c      |    2 +-
> bgpd/bgp_network.c    |    4 +-
> bgpd/bgp_nexthop.c    |  108 +++++++++++++---
> bgpd/bgp_nexthop.h    |    3 +-
> bgpd/bgp_packet.c     |   87 +++++++-----
> bgpd/bgp_route.c      |  357 +++++++++++++++++++++++++------------------------
> bgpd/bgp_table.c      |   20 ++-
> bgpd/bgp_vty.c        |    4 +-
> bgpd/bgp_zebra.c      |    8 +-
> bgpd/bgpd.c           |   57 +++++----
> bgpd/bgpd.h           |   24 ++--
> lib/memtypes.c        |    2 +-
> lib/prefix.c          |    2 +-
> lib/prefix.h          |    4 +-
> lib/table.c           |   18 ++-
> lib/thread.c          |   51 +++-----
> lib/thread.h          |    8 +-
> ospfd/ospf_packet.c   |    2 +-
> 23 files changed, 594 insertions(+), 470 deletions(-)
>
>

-- 
Paul Jakma	paul at jakma.org	@pjakma	Key ID: 64A2FF6A
Fortune:
Oliver's Law:
 	Experience is something you don't get until just after you need it.



More information about the Quagga-dev mailing list