summaryrefslogtreecommitdiff
path: root/datapath-windows
diff options
context:
space:
mode:
authorTerry Wilson <twilson@redhat.com>2021-10-12 14:13:31 -0500
committerIlya Maximets <i.maximets@ovn.org>2021-11-09 00:27:10 +0100
commit04b017e3a2102e7fe056f7ac1afbd0bd789e315e (patch)
treec42f7ad676c29019cdfaa14b870b9488d7f5542d /datapath-windows
parent695530d8fb07eb15adbc3506bb7abe2c7f5681d8 (diff)
downloadopenvswitch-04b017e3a2102e7fe056f7ac1afbd0bd789e315e.tar.gz
python: db: Avoid allocation of an attr dict/row+column.
Python objects normally have a dictionary named __dict__ allocated for handling dynamically assigned attributes. Depending on architecture and Python version, that empty dict may be between 64 and 280 bytes. Seeing as Atom and Datum objects do not need dynamic attribute support and there can be millions of rows in a database, avoiding this allocation with __slots__ can save 100s of MBs of memory per Idl process. Signed-off-by: Terry Wilson <twilson@redhat.com> Acked-by: Timothy Redaelli <tredaelli@redhat.com> Tested-by: Timothy Redaelli <tredaelli@redhat.com> Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
Diffstat (limited to 'datapath-windows')
0 files changed, 0 insertions, 0 deletions