aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/exported-sql-viewer.py
diff options
context:
space:
mode:
authorYury Norov <[email protected]>2020-02-03 17:37:34 -0800
committerLinus Torvalds <[email protected]>2020-02-04 03:05:26 +0000
commit2d6261583be005a91e4933aa53bbd678ef98e4c4 (patch)
treeb21a8d78e134d2ac9676c8a2bcaacb92e4c4146c /tools/perf/scripts/python/exported-sql-viewer.py
parente66eda0615c8767694150b3c595f3e9cf9ac4294 (diff)
lib: rework bitmap_parse()
bitmap_parse() is ineffective and full of opaque variables and opencoded parts. It leads to hard understanding and usage of it. This rework includes: - remove bitmap_shift_left() call from the cycle. Now it makes the complexity of the algorithm as O(nbits^2). In the suggested approach the input string is parsed in reverse direction, so no shifts needed; - relax requirement on a single comma and no white spaces between chunks. It is considered useful in scripting, and it aligns with bitmap_parselist(); - split bitmap_parse() to small readable helpers; - make an explicit calculation of the end of input line at the beginning, so users of the bitmap_parse() won't bother doing this. Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Yury Norov <[email protected]> Cc: Amritha Nambiar <[email protected]> Cc: Andy Shevchenko <[email protected]> Cc: Arnaldo Carvalho de Melo <[email protected]> Cc: Chris Wilson <[email protected]> Cc: Kees Cook <[email protected]> Cc: Matthew Wilcox <[email protected]> Cc: Miklos Szeredi <[email protected]> Cc: Rasmus Villemoes <[email protected]> Cc: Steffen Klassert <[email protected]> Cc: "Tobin C . Harding" <[email protected]> Cc: Vineet Gupta <[email protected]> Cc: Will Deacon <[email protected]> Cc: Willem de Bruijn <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions