Skip to content

./scripts/igt_doc.py: speedup check logic

Mauro Carvalho Chehab igt-dev 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest4 patches 6 repliesIn review
  2. v23 patches 0 repliesSuperseded
  3. v13 patches 0 repliesSuperseded

v4 from the cover letter

- added a patch to disable Sphinx build by default, reducing even further the build time with the defaults.

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4scripts/igt_doc.py: cleanup some pylint warningsscripts/igt_doc.py scripts/test_list.py+3 -21 reply
2/4scripts/igt_doc.py: don't depend on igt_runner anymoredocs/testplan/meson.build scripts/igt_doc.py scripts/test_list.py+41 -291 reply
3/4scripts/test_list.py: use a compiled regex for checkscripts/test_list.py+11 -51 reply
4/4meson_options.txt: disable Sphinx by defaultmeson_options.txt+1 -03 replies

Reviews trailers per patch

All 4 patches have a Reviewed-by or Acked-by.

PatchKamil Konieczny
1/4A-b
2/4A-b
3/4A-b
4/4A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [igt-dev] [PATCH i-g-t v3 0/4] ./scripts/igt_doc.py: speedup check logic

From: Mauro Carvalho Chehab <[email protected]>

From: Mauro Carvalho Chehab <[email protected]>

The logic which checks for missing/obsolete documentation is too slow. Currently, on my notebook it takes 12 seconds:

	$ time ./scripts/igt_doc.py --check --config tests/xe/xe_*json
	real	0m12.085s
	user	0m10.468s
	sys	0m1.457s

Implent it on a different way, in order to speedup the build process.

After the change, it now takes less than 500ms:

	$ time ./scripts/igt_doc.py --check --config tests/xe/xe_*json
	real	0m0.460s
	user	0m0.357s
	sys	0m0.102s

It should be noticed that it is possible to speed it up even further by running:

	 build/tests/* --list-subtests

tasks in parallel. I did some tests: the improvements weren't so relevant on my notebook with 8 CPUs, and, on my tests with python 3.11 it seemed a little too fragile when using multithreading, as it was not hard to mess with it, not having threads or subprocess forks not happening, and without triggering an error.

As the benefit of such optimization was marginal, let's avoid the additional complexity of multithreading.

---

v4:
- added a patch to disable Sphinx build by default, reducing even further the build time with the defaults.

Mauro Carvalho Chehab (4):
scripts/igt_doc.py: cleanup some pylint warnings scripts/igt_doc.py: don't depend on igt_runner anymore scripts/test_list.py: use a compiled regex for check meson_options.txt: disable Sphinx by default

 docs/testplan/meson.build |  7 ++--
 meson_options.txt         |  1 +
 scripts/igt_doc.py        | 11 +++---
 scripts/test_list.py      | 73 ++++++++++++++++++++++++++-------------
 4 files changed, 56 insertions(+), 36 deletions(-)
Signature · 1 line
2.39.2