Граф коммитов

158 Коммитов

Автор SHA1 Сообщение Дата
Ricky Stewart 31755b431d Bug 1657650 - Require that Mach command providers subclass MachCommandBase. r=remote-protocol-reviewers,marionette-reviewers,maja_zf,mhentges,froydnj
Today we don't require that `mach` `CommandProvider`s subclass from any particular parent class and we're very lax about the requirements they must meet. While that's convenient in certain circumstances, it has some unfortunate implications for feature development.

Today the only requirements that we have for `CommandProvider`s are that they have an `__init__()` method that takes either 1 or 2 arguments, the second of which must be called `context` and is populated with the `mach` `CommandContext`. Again, while this flexibility is occasionally convenient, it is limiting. As we add features to `mach`, having a better idea what the shape of our `CommandProvider`s are and how we can instantiate them and use them is increasingly important, and this gives us additional control when having `mach` configure `CommandProvider`s based on data that is only available at the `mach` level. In particular, we plan to leverage this in bugs 985141 and 1654074.

Here we add validation to the `CommandProvider` decorator to ensure all classes inherit from `MachCommandBase`, update all `CommandProvider`s in-tree to inherit from `MachCommandBase`, and update source and test code accordingly.

Follow-up work: we now require (de facto) that the `context` be populated with a `topdir` attribute by the `populate_context_handler` function, since instantiating the `MachCommandBase` requires a `topdir` be provided. This is fine for now in the interest of keeping this patch reasonably sized, but some additional refactoring could make this cleaner.

Differential Revision: https://phabricator.services.mozilla.com/D86255
2020-08-07 18:24:59 +00:00
Mike Hommey 8fdf2cb6ce Bug 1655921 - Stop running `make check` in valgrind builds. r=froydnj
This has the side effect of not initializing fontconfig before the
valgrind test itself runs, which changes the code path leading to
`FcConfigAddDirList`, which eventually leads to suppressed leaks.
Those leaks are then not discarded because the caller doesn't match what
is in the suppression file anymore, so we remove the caller.

Differential Revision: https://phabricator.services.mozilla.com/D85353
2020-07-30 20:27:14 +00:00
Mike Hommey 81697e521f Bug 1632735 - Upgrade valgrind builds to the same rust version as other builds. r=erahm
And add suppressions for the new errors that this adds to the valgrind
run. It's not clear if it's a legitimate thing that LLVM does that
valgrind doesn't cope with, like many others, but the fact is running
valgrind on a PGO/LTO build doesn't show these errors, so we're not
actually shipping them anyways (but does show _different_ errors that we
don't see on the build the valgrind jobs do)

Differential Revision: https://phabricator.services.mozilla.com/D81016
2020-06-25 22:29:59 +00:00
Jonathan Kew 3a6bfefb64 Bug 1533462 - Suppress spurious valgrind errors due to fontconfig's internal caching trickery. r=njn
Differential Revision: https://phabricator.services.mozilla.com/D80169
2020-06-22 08:32:39 +00:00
Ricky Stewart a24b65434d Bug 1638995 - Run `mach valgrind-test` with Python 3 r=firefox-build-system-reviewers,glandium
Differential Revision: https://phabricator.services.mozilla.com/D76057
2020-05-20 05:31:58 +00:00
Rob Lemley bd812fce54 Bug 1631197 - Make mach valgrind-test work for Thunderbird builds. r=froydnj
Create a new MachCommandCondition, "is_firefox_or_thunderbird" which is then used
to allow mach valgrind-test work for Thunderbird builds.

Differential Revision: https://phabricator.services.mozilla.com/D73153
2020-05-19 00:10:06 +00:00
Mike Hommey 47ab5edf18 Bug 1636003 - Add suppression for libfontconfig1 leak in Debian 8 and 9. r=njn
Differential Revision: https://phabricator.services.mozilla.com/D74176
2020-05-07 04:28:56 +00:00
Tooru Fujisawa 2108f90fcf Bug 1623965 - Improve error message when binary not found while testing. r=glandium,remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,Bebe,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D67726
2020-04-21 11:58:04 +00:00
Chris Manchester 08f94ebcd3 Bug 1595218 - Update valgrind supressions for rustc 1.39. r=emilio
Depends on D53901

Differential Revision: https://phabricator.services.mozilla.com/D55909

--HG--
extra : moz-landing-system : lando
2019-12-05 17:15:28 +00:00
Nathan Froyd a36959414d Bug 1600771 - turn on --show-mismatched-frees=no for valgrind tests; r=jseward
Otherwise, Valgrind is liable to see false positives from mismatched
`new` where the `delete` has been inlined to `free` or vice versa.

Differential Revision: https://phabricator.services.mozilla.com/D55553

--HG--
extra : moz-landing-system : lando
2019-12-03 13:32:27 +00:00
Emilio Cobos Álvarez 0140a5576c Bug 1577439 - Shutdown Servo's thread-pool in leak-checking builds, leak the atom table elsewhere. r=bholley
Differential Revision: https://phabricator.services.mozilla.com/D44217

--HG--
extra : moz-landing-system : lando
2019-09-09 22:39:46 +00:00
Dustin J. Mitchell 23d547abce Bug 1562686 - revert remaining unnecessary bit of bug 1187245; r=glandium
Differential Revision: https://phabricator.services.mozilla.com/D42644

--HG--
extra : moz-landing-system : lando
2019-08-23 12:32:02 +00:00
Razvan Maries 3d74e341f9 Backed out 2 changesets (bug 1562686) as per glandium's request. CLOSED TREE
Backed out changeset 0ce37eda652a (bug 1562686)
Backed out changeset fe7b9445e1d3 (bug 1562686)
2019-08-22 02:43:16 +03:00
Dustin J. Mitchell be3fd44f98 Bug 1562686 - revert remaining unnecessary bit of bug 1187245; r=glandium
Depends on D41454

Differential Revision: https://phabricator.services.mozilla.com/D42644

--HG--
extra : moz-landing-system : lando
2019-08-21 03:32:05 +00:00
Gerald Squelart b601187bf1 Bug 1492121 - Suppress dlopen leak triggered by next patch - r=njn
Valgrind report:
```
TEST-UNEXPECTED-FAIL | valgrind-test | 192 bytes in 3 blocks are definitely lost at malloc / dl_open_worker / _dl_catch_error / _dl_open
==2561== 192 bytes in 3 blocks are definitely lost in loss record 348 of 399
==2561==    at 0x4C2B240: malloc+112 (vg_replace_malloc.c:298)
==2561==    by 0x4012919: dl_open_worker+1977 (dl-open.c:457)
==2561==    by 0x400DD55: _dl_catch_error+101 (dl-error.c:178)
==2561==    by 0x4011CC9: _dl_open+185 (dl-open.c:633)
==2561==    by 0x5051F65: dlopen_doit+101 (dlopen.c:67)
==2561==    by 0x400DD55: _dl_catch_error+101 (dl-error.c:178)
==2561==    by 0x50522EB: _dlerror_run+123 (dlerror.c:164)
==2561==    by 0x5051EE0: dlopen@@GLIBC_2.2.5+48 (dlopen.c:88)
==2561==    by 0x1148FC: GetLibHandle (xpcom/glue/standalone/nsXPCOMGlue.cpp:86)
==2561==    by 0x1148FC: ReadDependentCB (xpcom/glue/standalone/nsXPCOMGlue.cpp:136)
==2561==    by 0x1148FC: XPCOMGlueLoad (xpcom/glue/standalone/nsXPCOMGlue.cpp:306)
==2561==    by 0x1148FC: mozilla::GetBootstrap(char const*, mozilla::LibLoadingStrategy)+572 (xpcom/glue/standalone/nsXPCOMGlue.cpp:374)
==2561==    by 0x114213: InitXPCOMGlue(mozilla::LibLoadingStrategy)+131 (browser/app/nsBrowserApp.cpp:223)
==2561==    by 0x113E6B: main+219 (browser/app/nsBrowserApp.cpp:284)
```

Nothing due directly to this patch, so it is likely a dlopen issue.

Differential Revision: https://phabricator.services.mozilla.com/D33904

--HG--
extra : moz-landing-system : lando
2019-06-06 06:20:23 +00:00
Mike Hommey 69fe19f2a6 Bug 1554043 - Make the valgrind-test error when valgrind exits with a non-zero code slightly more useful. r=dmajor
The exit code from valgrind may subtly indicate how it failed (like, if
it's 139 or 137, which would mean respectively segfault or killed by
something external), which is currently completely hidden, making
diagnostics of things like bug 1545094 harder.

Differential Revision: https://phabricator.services.mozilla.com/D32412

--HG--
extra : moz-landing-system : lando
2019-05-24 11:47:13 +00:00
Gijs Kruitbosch c14acdeadd Bug 1548941 - remove e10s force-enable and force-disable prefs, and on desktop restrict 'normal' e10s pref to automation and unofficial builds, r=bholley,ahal
Differential Revision: https://phabricator.services.mozilla.com/D29892

--HG--
extra : moz-landing-system : lando
2019-05-09 21:55:46 +00:00
Andreea Pavel 0a95eec6ae Backed out changeset 4e2250bbaed3 (bug 1548941) for failing test_gpuprocess.js on a CLOSED TREE 2019-05-08 22:55:45 +03:00
Gijs Kruitbosch 65eb7a47aa Bug 1548941 - remove e10s force-enable and force-disable prefs, and on desktop restrict 'normal' e10s pref to automation and unofficial builds, r=bholley,ahal
Differential Revision: https://phabricator.services.mozilla.com/D29892

--HG--
extra : moz-landing-system : lando
2019-05-08 15:56:53 +00:00
Mike Hommey 7356a2707c Bug 1507340 - Update suppression for bug 966673 to match the libresolv path in the valgrind docker image. r=njn
Differential Revision: https://phabricator.services.mozilla.com/D11960

--HG--
extra : moz-landing-system : lando
2018-11-15 01:15:51 +00:00
Mike Hommey 26010ce920 Bug 1507092 - Add a third variation of the suppression for bug 1231701. r=njn
Differential Revision: https://phabricator.services.mozilla.com/D11956

--HG--
extra : moz-landing-system : lando
2018-11-15 00:02:45 +00:00
Emilio Cobos Álvarez 2b00830e55 Bug 1496486 - Valgrind suppression. rs=froydnj
I rewrote the computed value implementation to avoid allocating and this tricked
Valgrind.

There's nothing uninitialized or unsafe from the code in:

  https://hg.mozilla.org/integration/autoland/rev/4dd15fa31474#l28.68
2018-10-09 19:08:42 +02:00
Mike Hommey a6d35e4199 Bug 1481670 - Add a non-mangled version of the valgrind suppression for SaveWordToEnv. r=njn
This is similar to what was done with SaveToEnv in bug 1457999.
2018-08-24 21:44:12 +09:00
Mike Hommey 89dfab93fc Bug 1485210 - Add --sym-offsets=yes to valgrind command line. r=njn
When valgrind prints out backtraces, it prints raw addresses and symbol
names, but that doesn't help find the exact code that caused the errors,
because we don't know where the libraries are loaded.

With --sym-offsets=yes, it adds the offset from the symbol, which allows
to find the relevant code in the binary.
2018-08-22 13:44:38 +09:00
Julian Seward 2a6490bec0 Bug 1479055 - Suppress Valgrind false positive in style::properties::longhands::clip_path::cascade_property. r=emilio.
--HG--
extra : rebase_source : 161c7fdcef4c242accb8d9894118d24318b9f39f
2018-08-15 07:19:20 +02:00
Sylvestre Ledru dcfef841a7 bug 1463425 - Fix flake8/pep8 issue by hand in build/ r=gps
MozReview-Commit-ID: AZdcEWyVV6e

--HG--
extra : rebase_source : b1c45028c8d46be5ba590a27a2f9f20e248a26b1
2018-05-21 23:58:19 +02:00
Sylvestre Ledru 8cd16bb55b bug 1463425 - autopep8 on build/ r=gps
MozReview-Commit-ID: ETzx4HsjbEF

--HG--
extra : rebase_source : 7e27a4cfe2bb358d513a18a33c245bcc6d559c46
2018-05-21 23:56:34 +02:00
Andrew Halberstadt ac08b89a81 Bug 1459598 - Use profiles.json file to map test suites to the base profiles they use, r=jgraham
This serves two purposes:

1) It makes web-platform-tests pref downloading/handling a little more robust. When
run externally, it now downloads the entire testing/profiles directory. When loading
prefs it will look for both prefs_general.js (to support older versions of Firefox)
and profiles.json (for support moving forward).

This way we can add/remove/rename pref files under these directories without needing
to worry about breaking upstream wpt.

2) It provides developers an overview of which harnesses are using which base profiles.
Instead of hunting through test harness code to find this information, they can glance
at profiles.json.

MozReview-Commit-ID: AMzdnD8aGA2

--HG--
extra : rebase_source : 6fa0a802680417e49fcef99f3d03de7458a8fcba
2018-05-07 09:43:12 -04:00
Aaron Klotz 3cfbbae4f0 Bug 1457999: Update Valgrind intentional leak whitelist to include undecorated SaveToEnv; r=bustage
--HG--
extra : rebase_source : f8282bdfb2c831cd086f0e5c61b80afaeb46e393
2018-05-07 17:07:52 -06:00
Aaron Klotz 92651e3581 Bug 1457999: Follow-up - update Valgrind intentional leak whitelist to reflect updated name of mozilla::SaveToEnv; r=bustage
--HG--
extra : amend_source : 437cd75dc2ea3d8b3b625b7f78dbe861c3f610c9
2018-05-07 16:17:24 -06:00
Andrew Halberstadt c9bdbe0a32 Bug 1451159 - [testing/profiles] Use 'format' for interpolation instead of %s r=gbrown
MozReview-Commit-ID: EbDS1fYDe1X

--HG--
extra : rebase_source : e8e179f97fb3df492b2fcc690616157254e49fdd
extra : source : 03f43cb6ab42e55f475c6f6a99c7da547b0aa6f8
2018-04-20 11:03:38 -04:00
Andrew Halberstadt ee69aa133e Bug 1451159 - [testing/profiles] Store profile data in actual profile look alike folders r=gbrown
This moves testing/profiles/prefs_general.js to
testing/profiles/common/user.js. It also adds an 'extensions' folder to the
common profile. Dropping extension files here will get them installed in all
test harnesses (useful for testing on try).

The idea is that all test harnesses will eventually use this 'common' profile.
We'll also create some new per harness profiles, e.g testing/profiles/mochitest
and testing/profiles/reftest. This way there will be a single location
developers can go to set preferences, both for a specific harness, and across
all harnesses.

MozReview-Commit-ID: 8sqBqLiypgU

--HG--
rename : testing/profiles/prefs_general.js => testing/profiles/common/user.js
extra : rebase_source : 72a4a4b691e93c77479c7e70647b0ca373862c51
2018-04-19 16:12:26 -04:00
Bogdan Tara b7924c2ed2 Backed out 4 changesets (bug 1451159) for linux build bustages CLOSED TREE
Backed out changeset 72926ae685af (bug 1451159)
Backed out changeset f90a99682382 (bug 1451159)
Backed out changeset 3914937893de (bug 1451159)
Backed out changeset 79931e4a2bfb (bug 1451159)

--HG--
rename : testing/profiles/common/user.js => testing/profiles/prefs_general.js
2018-05-04 00:25:56 +03:00
Andrew Halberstadt 6a9ff8c01b Bug 1451159 - [testing/profiles] Use 'format' for interpolation instead of %s r=gbrown
MozReview-Commit-ID: EbDS1fYDe1X

--HG--
extra : rebase_source : 791be1fb4939ca72408fa9044dac8765ceffd806
extra : source : 03f43cb6ab42e55f475c6f6a99c7da547b0aa6f8
2018-04-20 11:03:38 -04:00
Andrew Halberstadt fd23fd839b Bug 1451159 - [testing/profiles] Store profile data in actual profile look alike folders r=gbrown
This moves testing/profiles/prefs_general.js to
testing/profiles/common/user.js. It also adds an 'extensions' folder to the
common profile. Dropping extension files here will get them installed in all
test harnesses (useful for testing on try).

The idea is that all test harnesses will eventually use this 'common' profile.
We'll also create some new per harness profiles, e.g testing/profiles/mochitest
and testing/profiles/reftest. This way there will be a single location
developers can go to set preferences, both for a specific harness, and across
all harnesses.

MozReview-Commit-ID: 8sqBqLiypgU

--HG--
rename : testing/profiles/prefs_general.js => testing/profiles/common/user.js
extra : rebase_source : 7599913e547533f2f57b597ad0f238c6cd391c82
2018-04-19 16:12:26 -04:00
Bobby Holley 1da6139753 Bug 1454511 - Widen valgrind suppression for selector parsing. r=njn
The existing suppression tries to be specific about the callstack that
arrives at the function, but that breaks when we rejigger the machinery
up the callstack. In practice, the existing suppressions cover most of
the ways we would arrive at selector parsing, and so I think the
specificity here is more trouble than it's worth.

MozReview-Commit-ID: 2k52xq64SQX
2018-04-16 17:11:49 -07:00
Julian Seward 4f24ba0ebe Bug 1447137 - Valgrind errors building with rust 1.25: Conditional jump or move depends on uninitialised value in various parsing functions. r=njn
This patch adds suppressions as needed on automation, for Servo-in-Gecko as
compiled by rustc 1.25.  It appears there are only three false error sites

  fun:*style*values*specified*color*Color*style*parser*Parse*parse*
  fun:*selectors*parser*SelectorList*Impl*parse*
  fun:*style*properties*shorthands*

but there are a number of different paths leading to them, especially the
first, hence the use of 17 suppressions in total, so as to remain specific.

Following some investigation of the machine code involved, I think these are
all Valgrind/Memcheck false positives, unfortunately, and probably to do
with (legitimate) operand swapping in && or || expressions by rustc+LLVM.

MozReview-Commit-ID: EpDmb4PEyoy
2018-03-26 11:00:59 +02:00
Julian Seward babba9b13b Bug 1447405 - Valgrind cries at nsFrame::ComputeSize in stylo-only builds. r=emilio.
In nsFrame::ComputeSize and nsFrame::ComputeSizeWithIntrinsicDimensions, the
following expressions

  isFlexItem && usingFlexBasisForISize
  isFlexItem && !usingFlexBasisForISize

are sometimes compiled by recent gcc/clang in the opposite order, viz
[!]usingFlexBasisForISize && isFlexItem.  In this case the transformation is
correct as can be seen by analysing code earlier in these functions.
Unfortunately this causes Valgrind/Memcheck to report a branch on undefined
data which, in this case, is a false positive.

A simple fix is simply to initialise usingFlexBasisForISize to false at its
declaration point.

--HG--
extra : rebase_source : 39877e4ea8ec678288e6b49af120445c96ef8c0a
2018-03-13 07:37:25 +01:00
Emilio Cobos Álvarez cc9f814770 Bug 1447405: Add a valgrind suppression on a CLOSED TREE. rpending=jseward
MozReview-Commit-ID: 1DppZjKZEwf
2018-03-20 19:54:24 +01:00
Xidorn Quan 46929192a9 Bug 1437796 - Add two valgrind suppressions for stylo-chrome. r=jseward
MozReview-Commit-ID: Cj5Dv4z3Lkc

--HG--
extra : rebase_source : b0ae49e14c88e8de4f0d1c227a00b87607eaa640
2018-02-14 11:21:23 +11:00
Mike Hommey 1d38c4309b Bug 1432398 - Remove the desktop-build docker image and related files. r=dustin
--HG--
extra : rebase_source : 158e14474ce049343105d2be95aabc03ec0b7854
2018-01-27 11:04:23 +09:00
Mike Hommey 508bccd7c7 Bug 1432395 - Add valgrind suppressions for system libraries on Debian. r=njn
The first two are variants of existing ones, with a slightly different
signature, and tha last one is well known and found in glib-related
suppression files like https://github.com/flatpak/flatpak/blob/master/tests/glib.supp

--HG--
extra : rebase_source : 2a209cc5987405e7ff638bbf69e1b74202b0357e
2018-01-27 10:31:31 +09:00
Mike Hommey 478ce5d0b3 Bug 1432395 - Rename valgrind suppressions files to something more generic. r=froydnj
The MACHTYPE bash variable is an odd thing that returns e.g.
x86_64-redhat-linux-gnu on a CentOS system, but x86_64-pc-linux-gnu
on a Debian system, and possibly something different on other distros.

mach valgrind-test is the only place actually relying on MACHTYPE.
Others rely on information from python modules. Uniformize that, and use
the more generic 'pc' rather than 'redhat'.

--HG--
rename : build/valgrind/i386-redhat-linux-gnu.sup => build/valgrind/i386-pc-linux-gnu.sup
rename : build/valgrind/x86_64-redhat-linux-gnu.sup => build/valgrind/x86_64-pc-linux-gnu.sup
extra : rebase_source : ad94ce69e8094d2b9ddae97a3d261945886c0a61
2018-01-27 10:22:56 +09:00
Ryan VanderMeulen bd5f27de6e Bug 1430608 - Loosen the Valgrind MediaList::evaluate suppression to cover both trunk and beta. r=emilio, a=RyanVM on a CLOSED TREE
--HG--
extra : rebase_source : 29985532443d860e4e2552671a780e1f56248f23
extra : amend_source : 3c5a8753d67b32e2aee0ec040cae1dcd1c45cb42
2018-01-19 12:12:11 -05:00
Xidorn Quan 8e13ebbe62 Bug 1430608 followup - Suppress valgrind error in MediaList::evaluate on a CLOSED TREE.
--HG--
extra : source : 18e60905c302ec4c58c1d64247f7d65e9b2fe512
2018-01-18 18:09:02 +11:00
Ralph Giles 8101f5ae52 Bug 1418083 - stylo: Suppress valgrind error. r=jseward
We believe this is another spurious memcheck error triggered
by code from Rust 1.23.0. See also bug 1394696.

For some reason, this error occurs both with and without
the leading underscore on mangled std::sync::once methods,
so this change matches either with a wildcard.

MozReview-Commit-ID: 4upSAPqAtNA

--HG--
extra : rebase_source : 5f697aaa5e170369f08d385d10c1aac9d8c1e50b
2018-01-09 16:18:49 -08:00
Ralph Giles a7c4cd8963 Bug 1394696 - stylo: Suppress valgrind warning. r=jseward
LLVM can optimize code to a form `if B && A` when A is
always false but B is undefined. This triggers a valgrind
memcheck warning since the conditional depends on undefined
data but in practice it can never have side-effects.

Rust 1.20.0 seems to trigger this in the Option code. Since
we believe the transform is correct in these cases and
valgrind is incorrect to warn, we surpress the error.

Thanks to Julian Seward for the analysis and help
writing the suppression entries.

MozReview-Commit-ID: pF1Bmy5PRY
2017-09-20 09:19:18 -07:00
Eric Rahm 030b39d813 Bug 1393230 - Part 3: Convert the xpcom string classes to be templated on char type. r=njn, r=fitzgen, r=sfink
This removes the double-include macro hackery that we use to define two
separate string types (nsAString and nsACString) in favor of a templated
solution.

Annotations for Valgrind and the JS hazard analysis are updated as well as
the rust binding generations for string code.

--HG--
extra : rebase_source : 63ab2c4620cfcd4b764d42d654c82f30f984d016
extra : source : 9115364cd4aa078c49bba7911069f8178e55166f
2017-08-14 14:22:50 -07:00
Wander Lairson Costa 82b8df7dff Bug 1338651 part 2: Add suppression for leaks in libllvm-3.6-mesa. r=jseward
New leaks emerged after updating docker images for new home path [1].

[1] https://treeherder.mozilla.org/#/jobs?repo=try&revision=0477c33232a7&selectedJob=122583760

MozReview-Commit-ID: B1Yu4eSweo7

--HG--
extra : rebase_source : e07a25ea0e8c83eb680b4d3ac7cdbc96964135f8
2017-08-28 08:44:51 -03:00
Wander Lairson Costa 6332ed5b0a Bug 1338651 part 1: Change docker image home dir to /build. r=dustin,mshal
Using /home/worker is the build directory has a 30% talos performance
loss, because test machines has a /home mount directory.

MozReview-Commit-ID: 554IPMRWgzK

--HG--
extra : rebase_source : 00827d3f6bd705419bc801eb05b543af1ddc274f
2017-08-28 08:44:51 -03:00