Change in vdsm[master]: virt: Optimize guest agent string filtering
danken at redhat.com
danken at redhat.com
Tue Jan 20 11:16:54 UTC 2015
Dan Kenigsberg has submitted this change and it was merged.
Change subject: virt: Optimize guest agent string filtering
......................................................................
virt: Optimize guest agent string filtering
The filtering gains a bit of speed by:
- NO more calling 'ord'
- Moving all possible restricted chars to the set
- Mapped the chars to unichr and put then into a frozenset
- Having only one if
- Using an array to iterate over the unicode string
- And remove the function call for each element
This brought up a performance gain of ~43%
Change-Id: Ief8da73dc180212b594937e658ae8f5f57c63bac
Bug-Url: https://bugzilla.redhat.com/1179696
Signed-off-by: Vinzenz Feenstra <vfeenstr at redhat.com>
Reviewed-on: http://gerrit.ovirt.org/36630
Reviewed-by: Nir Soffer <nsoffer at redhat.com>
Reviewed-by: Francesco Romani <fromani at redhat.com>
Reviewed-by: Dan Kenigsberg <danken at redhat.com>
---
M vdsm/virt/guestagent.py
1 file changed, 14 insertions(+), 18 deletions(-)
Approvals:
Nir Soffer: Looks good to me, but someone else must approve
Vinzenz Feenstra: Verified
Dan Kenigsberg: Looks good to me, approved
Francesco Romani: Looks good to me, but someone else must approve
--
To view, visit http://gerrit.ovirt.org/36630
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ief8da73dc180212b594937e658ae8f5f57c63bac
Gerrit-PatchSet: 9
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Vinzenz Feenstra <vfeenstr at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Michal Skrivanek <mskrivan at redhat.com>
Gerrit-Reviewer: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: Vinzenz Feenstra <vfeenstr at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
More information about the vdsm-patches
mailing list