[poky] [PATCH 0/2][RFC] bitbake: optimize file parsing speed
Dongxiao Xu
dongxiao.xu at intel.com
Mon Dec 13 06:52:51 PST 2010
Hi Richard,
This RFC/pull request aims to speed up the bb file parsing speed.
Please help to review it, thanks!
We observed that the ??= operator costs a lot of cycles when parsing bb
files, this patchset implement the ??= in getVar() function. If the
normal getVar returns None, it will check the defaultval flag and
return its value.
Besides, 0001 patch also fixes a bug that if foo_OVERA[bar] = "x" and
foo is never set as a variable directly, the override is never expanded.
I slightly modified 0001 patch compared with the previous discussion
version. If simply copy the setVar logic into setVarFlag, I found
that variable "do_install_append_virtclass-native" will both exist in
self._special_values and self._seen_overrides, this is because when
setting "content" for "do_install_append_virtclass-native", the variable
will be recorded in self._special_values, and when setting "func" flag
for "do_install_append_virtclass-native", the variable will be recorded
in self._seen_overrides. This version of patch could fix the issue.
Pull URL: git://git.pokylinux.org/poky-contrib.git
Branch: dxu4/parsefile
Browse: http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=dxu4/parsefile
Thanks,
Dongxiao Xu <dongxiao.xu at intel.com>
---
Dongxiao Xu (2):
bitbake: Make setVar a special case of setVarFlag
bitbake: Change the way to implement ??= operator
bitbake/lib/bb/data_smart.py | 63 ++++++++++++++++++++---------------------
bitbake/lib/bb/parse/ast.py | 7 ----
2 files changed, 31 insertions(+), 39 deletions(-)
More information about the poky
mailing list