[Gammaray-interest] Thoughts about the problem scanner
Christian Gagneraud
chgans at gmail.com
Wed Mar 6 17:59:24 CET 2019
Hi there,
A few quick random thoughts, sorry for the "dump" style.
First thing first:
Have you seen the PR "ObjectInspector: Add thread affinity checker"
(https://github.com/KDAB/GammaRay/pull/538/)?
What do you think? Do you like it? Could we add more scanners like that?
Second:
Wouldn't it be nice to run the problem scanner in an automated way?
The idea would be to use gammaray as an automated dynamic-analyzer (as
oppose to, eg, clang static analyser).
To achieve that it would be nice to run an app under gammaray control,
and tell gammaray to run the "scan for problems", report on stdout (or
in a file), and then call QCoreApplication::quit().
What i have in mind is to use that in a test/validation process,
manual or automated.
For example, We use blocking PR, if your PR doesn't pass some
buildtime/runtime test, the PR cannot be merged. This could be used,
for example, to check that no cross-thread signal/slot connections are
introduced in a project (prevention is better than cure)
Third:
I've been thinking about adding a new feature to the signal inspector.
The ability to export a dot file that graph all the signal/slot
connections b/w a set of objects.
The idea would be to add a new action to the signal menu. From there
the user select s the objects of interest, and then the graph is
generated as a graphviz dot file.
The graph would contains all connections b/w the set of objects, plus
the objects that have a first degree connections with the original
set.
Ideally the graph would contains these information (might be optional):
- QObject thread affinity (using graphviz cluster [1])
- connection type (eg, using style or color)
- signal/slot names
Thanks,
Chris
[1] https://graphviz.gitlab.io/_pages/Gallery/directed/cluster.html
More information about the Gammaray-interest
mailing list