Details
Diff Detail
Event Timeline
All right, so we have multiprocessing SATestBuild to run multiprocessing scan-build that intercepts the multiprocessing buildsystem, nice gj =)
Does it get interrupted gracefully with Ctrl+C?
utils/analyzer/SATestBuild.py | ||
---|---|---|
750–754 | Does this really need a separate code path? |
All right, so we have multiprocessing SATestBuild
No, it's multithreaded.
That's why logging to stdin/stderr from multiple projects at the same time works (python logging is thread-safe).
Does it get interrupted gracefully with Ctrl+C?
Yeah I went to some trouble to make sure it does: all threads are daemon threads, so killing the main thread suffices.
utils/analyzer/SATestBuild.py | ||
---|---|---|
750–754 | I wanted to ensure no multithreaded stuff accidentally kicks in, but now that you're asking I guess it could be changed. |
...and the previous version was way to good to be true.
Turns out, the -j argument was not honored, and I had to actually implement a simple threading pool.
Additionally, logging was racing, and the "print" calls had to be replaced.
Ew, i need to look at stuff more carefully :) Anyway, it still looks good.
utils/analyzer/SATestBuild.py | ||
---|---|---|
729–730 | Yeah, despite using an undocumented feature, i guess it's the most pythonic way of doing this we currently have. |
Yeah, despite using an undocumented feature, i guess it's the most pythonic way of doing this we currently have.