[poky] [PATCH 0/1][RFC] Optimize file parsing speed

Richard Purdie rpurdie at linux.intel.com
Thu Dec 9 06:40:14 PST 2010


On Wed, 2010-12-08 at 14:53 +0800, Xu, Dongxiao wrote:
> Xu, Dongxiao wrote:
> > Richard Purdie wrote:
> >> On Mon, 2010-11-29 at 13:45 +0800, Xu, Dongxiao wrote:
> >>> Richard Purdie wrote:
> > Like the whole d.keys(), exported variables are also different among
> > recipes, since recipe may export or unset certain variables for
> > itself. So to implement this, we need to keep a common list, and then
> > handle recipe specific export/unset variables.  
> > 
> > Does my understanding correct?
> 
> Here I mean even the exported variables may be different among
> different recipes, since each recipe may export or unset certain
> variables for itself. So is it possible for us to keep a common
> exported variable list?

The reason these functions are slow is that our dictionary is huge and
d.keys() takes time to construct and then iterate over.

Instead, if we make a cache in setVarFlag of anything with an export
flag set, we then have a pregenerated list.

Yes, the list is different between recipes but that doesn't mean we
can't prebuild the list when parsing.

Cheers,

Richard




More information about the poky mailing list