run-leaks should run leaks with --list (on Mojave)
authorap@apple.com <ap@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 4 Sep 2018 21:06:31 +0000 (21:06 +0000)
committerap@apple.com <ap@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 4 Sep 2018 21:06:31 +0000 (21:06 +0000)
commit0e55e49a280d7e314ddad1da404310e97171702d
treec60324115e6d1b42f2ff7d94a64d66b88cc22206
parent545acc89f5333d296a8ef61026ba84f0366f2715
run-leaks should run leaks with --list (on Mojave)
https://bugs.webkit.org/show_bug.cgi?id=187716
<rdar://problem/42261676>

Reviewed by Lucas Forschler.

Also enabled dumping memgraphs. We'll be pruning these aggressively, as they take
significant space.

* Scripts/run-leaks:
(main): Added an option to store memgraphs.
(runLeaks): As there is no way to test whether the new format is supported in advance,
we have to try with --list first, and retry if that fails. Also, made leaks operate
on a memgraph file if we are saving it anyway.

* Scripts/webkitpy/port/leakdetector.py:
(LeakDetector._leaks_args): Pass --memgraph-file to run-leaks.
(LeakDetector.leaks_file_name): Removed an incorrect comment.
(LeakDetector.memgraph_file_name): Added.
(LeakDetector.check_for_leaks): Changed how arguments are passed to _leaks_args.
It is a bit ugly that leaks path ends up being computed twice, but this is the least
ugly approach that I could find.

* Scripts/webkitpy/port/leakdetector_unittest.py: Updated for _leaks_args changes.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@235633 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Tools/ChangeLog
Tools/Scripts/run-leaks
Tools/Scripts/webkitpy/port/leakdetector.py
Tools/Scripts/webkitpy/port/leakdetector_unittest.py