lkml.org 
[lkml]   [2013]   [Oct]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] scripts/checkkconfig.py: find unused Kconfig parameters
Hi Yann,

Thank you for your review!

On 10/29/2013 07:06 PM, Yann E. MORIN wrote:

> I guess all these grep spawning are what makes it slow.
>
> I wonder if it would not be possible to invert the loop (in pseudo
> Python code):
>
> for f in all_interesting_files:
> read f in memory
> for s in all_symbols:
> if symbol is in f:
> remove f from all_symbols
> break the inner-most loop
You probably meant "remove s from all_symbols", but I got it.
>
> This way:
> - you scan the tree only once
> - as soon as a symbol is matched, it is removed, thus decreasing
> the amount of checks done in further loops.
This sounds like a very good idea, thanks! I hope to have time to
implement a mix of it and Michal's proposal later this week, or at least
next week.

Thanks again,

Michael.

--
Michael Opdenacker, CEO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
+33 484 258 098



\
 
 \ /
  Last update: 2013-10-30 04:41    [W:0.074 / U:2.424 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site