On Sun, Dec 17, 2023 at 9:03 PM Ilya Maximets <[email protected]> wrote:
>
> While counting strong references current code first generates a
> difference between old and new datums and only after it checks
> the types of the atoms to be strong references.
>
> Similar thing happens while assessing weak references.  First
> the added/removed are generated and then we check for atoms
> to be weak references.
>
> Check the type first to avoid unnecessary work.  This change
> doubles the performance of transactions that modify large sets
> of references.
>
> For example, with this change applied, initial read of OVSDB
> file containing 136K transactions of large OVN port groups
> and address sets on my laptop takes 24 seconds vs 43 seconds
> without.
>
> Fixes: 4dbff9f0a685 ("ovsdb: transaction: Incremental reassessment of weak 
> refs.")
> Fixes: b2712d026eae ("ovsdb: transaction: Use diffs for strong reference 
> counting.")
> Signed-off-by: Ilya Maximets <[email protected]>

Acked-by: Mike Pattrick <[email protected]>

_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to