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

2649 Коммитов

Автор SHA1 Сообщение Дата
Gerald Squelart dab57bac1d Bug 1774329 - Make BaseProfileJSONWriter single-lined - r=florian
Differential Revision: https://phabricator.services.mozilla.com/D152603
2022-07-28 12:41:54 +00:00
Jan de Mooij 4606b0a55c Bug 1780383 - Add profiler sub-category for Wasm frames. r=gerald,rhunt
Differential Revision: https://phabricator.services.mozilla.com/D152272
2022-07-21 06:52:44 +00:00
Jan de Mooij f18ab02529 Bug 1780091 - Use LR register value in the profiler in Mac/Windows ARM64 builds. r=mstange
The Wasm profiling frame iterator uses the return address in the LR register when
interrupting during the prologue. The Linux/Android code was correctly initializing it,
but on Mac and Windows we always used 0.

Differential Revision: https://phabricator.services.mozilla.com/D152268
2022-07-21 06:12:36 +00:00
Gerald Squelart 65ed91b027 Bug 1779685 - Factor ChunkedJSONWriteFunc::Length() out of CopyDataIntoLazilyAllocatedBuffer() - r=florian
This will be useful to see how big profiles get during gathering, and
potentially to avoid making them too big if possible.

Differential Revision: https://phabricator.services.mozilla.com/D151901
2022-07-20 12:52:57 +00:00
Doug Thayer 67331b011d Bug 1776013 - Add SIMD memchr-like implementations to MFBT r=iain
Differential Revision: https://phabricator.services.mozilla.com/D150067
2022-07-14 18:30:27 +00:00
Norisz Fay 9112cf321e Backed out 2 changesets (bug 1776013) for causing spidermonkey bustages on SIMD.cpp CLOSED TREE
Backed out changeset bb467568da37 (bug 1776013)
Backed out changeset 9669cd465518 (bug 1776013)
2022-07-14 03:53:22 +03:00
Doug Thayer 2778034398 Bug 1776013 - Add SIMD memchr-like implementations to MFBT r=iain
Differential Revision: https://phabricator.services.mozilla.com/D150067
2022-07-14 00:39:22 +00:00
Matthew Gaudet edb3b93ed6 Bug 1777529 - Remove Profiler Support for TraceLogger r=gerald
Differential Revision: https://phabricator.services.mozilla.com/D150768
2022-07-13 15:26:47 +00:00
Gerald Squelart 12a671a4c4 Bug 1692934 - Record meta.profilingEndTime in each process - r=canaltinova
This profilingEndTime is the time when this property is actually written, which
corresponds to the end of the profiling session.
If it's a shutdown profile, the exact same time is used for the existing
`meta.shutdownTime` property.

Depends on D151355

Differential Revision: https://phabricator.services.mozilla.com/D151356
2022-07-08 14:23:37 +00:00
Gerald Squelart 29a5385f1e Bug 1692934 - Record meta.contentEarliestTime in each process - r=canaltinova
This contentEarliestTime is the time when the earliest (and oldest) surviving
chunk was prepared to start receiving data.
It should be a good hint to the front-end about where the profiling data
actually starts.

Differential Revision: https://phabricator.services.mozilla.com/D151355
2022-07-08 14:23:36 +00:00
Gerald Squelart 1bc597cb95 Bug 1692934 - Record meta.profilingStartTime in each process - r=canaltinova
This profilingStartTime is the time (relative to the process absolute start
time) when the profiling session started.

Differential Revision: https://phabricator.services.mozilla.com/D151354
2022-07-08 14:23:36 +00:00
Gerald Squelart 5b1832118f Bug 1778591 - Assert that the main-thread buffer, if alive, should always be in-session - r=canaltinova
Some test failures suggest that somehow the main-thread pre-allocated buffer
was available, but not in-session (because its chunk manager pointer was null).
The code shouldn't allow this situation:
- EnsureBufferForMainThreadAddMarker() creates the buffer with a
  non-fallibly-allocated chunk manager.
- ReleaseBufferForMainThreadAddMarker() destroys the whole buffer, including
  its chunk manager.
- In GetClearedBufferForMainThreadAddMarker(), Clear() should not destroy the
  chunk manager.

So this patch adds some more asserts, to verify my assumptions, and potentially
catch the issue closer to where it happens.

Differential Revision: https://phabricator.services.mozilla.com/D151351
2022-07-08 13:23:29 +00:00
Mike Hommey dba3a210e5 Bug 1777436 - Update builders to rustc 1.62. r=firefox-build-system-reviewers,andi
Differential Revision: https://phabricator.services.mozilla.com/D150733
2022-07-07 21:49:05 +00:00
Julien Wajsberg de361e620c Bug 1776721 - Add a new sub-category for javascript builtins r=canaltinova,jandem
Differential Revision: https://phabricator.services.mozilla.com/D150614
2022-07-06 16:52:18 +00:00
Julien Wajsberg af7ecd3fc8 Bug 1776721 - Improve a few comments around the category generating script r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D150613
2022-07-06 16:52:17 +00:00
Julien Wajsberg f2cc927a5c Bug 1777473 - Rename the frame label for PresShell::Destroy and expose to javascript developers r=emilio
The existing frame label was reusing the function name, but we already
have it when using native stacks. Renaming it to a more understandable
name should make it easier for our javascript developers users without
impairing gecko developers.

Differential Revision: https://phabricator.services.mozilla.com/D150976
2022-07-06 14:02:05 +00:00
smolnar 19f9a986ed Backed out 2 changesets (bug 1777436) for causing multiple bustages. CLOSED TREE
Backed out changeset 3949745c066c (bug 1777436)
Backed out changeset 30ff4b58d4b8 (bug 1777436)
2022-07-01 01:39:56 +03:00
Mike Hommey 46039292ed Bug 1777436 - Update builders to rustc 1.62. r=firefox-build-system-reviewers,andi
Differential Revision: https://phabricator.services.mozilla.com/D150733
2022-06-30 20:02:12 +00:00
Florian Quèze 546587141b Bug 1774844 - Record per process power use on Apple Silicon, r=gerald.
Differential Revision: https://phabricator.services.mozilla.com/D150511
2022-06-29 21:24:12 +00:00
Florian Queze e21c8845f3 Bug 1774844 - Add a new 'Power Use' (ie. 'power') profiler feature, r=gerald.
Differential Revision: https://phabricator.services.mozilla.com/D150059
2022-06-29 21:24:11 +00:00
Andreea Pavel 488ec4bffd Backed out 3 changesets (bug 1774844) for failing condprof at test_ext_geckoProfiler_schema.js on a CLOSED TREE
Backed out changeset f33bef1f7d56 (bug 1774844)
Backed out changeset b4b82b6892b3 (bug 1774844)
Backed out changeset d98352922a5c (bug 1774844)
2022-06-29 18:29:18 +03:00
Florian Quèze 89aec958ac Bug 1774844 - Record per process power use on Apple Silicon, r=gerald.
Differential Revision: https://phabricator.services.mozilla.com/D150511
2022-06-29 13:29:45 +00:00
Florian Queze 07bd81efcd Bug 1774844 - Add a new 'Power Use' (ie. 'power') profiler feature, r=gerald.
Differential Revision: https://phabricator.services.mozilla.com/D150059
2022-06-29 13:29:44 +00:00
Kris Maglione 27515a3d83 Bug 1770237: Part 17 - Rename mozJSComponentLoader to mozJSModuleLoader r=mccr8,decoder
Differential Revision: https://phabricator.services.mozilla.com/D148197
2022-06-22 20:31:37 +00:00
serge-sans-paille b122b6d13d Bug 1774865 - extra cleanup mozglue, security, intl and netwerk includes r=sylvestre
Differential Revision: https://phabricator.services.mozilla.com/D149670
2022-06-22 09:51:52 +00:00
Sylvestre Ledru 42f6811d95 Bug 1519636 - Reformat recent changes to the Google coding style r=andi,media-playback-reviewers,necko-reviewers,padenot,dragana
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D148375
2022-06-07 12:32:55 +00:00
Mike Hommey 7ce663eb08 Bug 1772048 - Update rustc_version and semver crates. r=emilio,webdriver-reviewers,kinetik,whimboo
semver 1.0 doesn't and won't support Clone on semver::Error[1], so we
convert the mozversion error type to store the string version of the
error, which is an incompatible change requiring a version bump on the
crate.

1. https://github.com/dtolnay/semver/pull/280

Differential Revision: https://phabricator.services.mozilla.com/D147825
2022-06-07 10:01:32 +00:00
Bob Owen e8f0e4a86a Bug 1769845 p3: Remove release assertion in IsWin32kLockedDown. r=handyman
Running in Windows 7 compat mode can currently trigger this.

Differential Revision: https://phabricator.services.mozilla.com/D148403
2022-06-06 16:24:43 +00:00
Gerald Squelart 4d5e7d05a7 Bug 1771213 - mozilla::baseprofiler::baseprofiler_save_profile_to_file now has prefix "base" to avoid lldb call ambiguity - r=mstange
Calling `profiler_save_profile_to_file` from lldb errored with "call to 'profiler_save_profile_to_file' is ambiguous", even though they're in different namespaces.

Differential Revision: https://phabricator.services.mozilla.com/D148360
2022-06-06 00:43:59 +00:00
Mike Hommey 25f84e6a3a Bug 1771826 - Update builders to rustc 1.61. r=firefox-build-system-reviewers,andi
Differential Revision: https://phabricator.services.mozilla.com/D147707
2022-06-02 07:06:47 +00:00
Mike Hommey 13c2bf2b4f Bug 1770894 - Update mozglue to arrayvec 0.7. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D147475
2022-05-31 22:05:04 +00:00
Tyson Smith 08f38dc0db Bug 1751823 - Add UBSan suppression to test. r=glandium
Differential Revision: https://phabricator.services.mozilla.com/D147230
2022-05-26 06:15:35 +00:00
Gabriele Svelto e7bb08dd02 Bug 1766342 - Compute the process creation timestamp lazily r=glandium
This reverts bug 1751041 and adds a separate function to take the first
timestamp that was taken by a process. The latter is then used when
creating JS objects to avoid hazards warnings about allocating memory
when an object is not yet rooted.

Differential Revision: https://phabricator.services.mozilla.com/D144829
2022-05-13 09:27:58 +00:00
Mike Hommey 371a1dd4c0 Bug 1768099 - Workaround ASan failures with clang-trunk. r=decoder
Differential Revision: https://phabricator.services.mozilla.com/D146154
2022-05-13 00:45:53 +00:00
Bob Owen f2a9df286a Bug 1768014 p2: Default to policy win32k lockdown status if in process check fails. r=gcp,cmartin
Depends on D145872

Differential Revision: https://phabricator.services.mozilla.com/D145873
2022-05-10 06:07:17 +00:00
Mike Hommey d067ffd623 Bug 1766561 - Enable MOZ_FORMAT_PRINTF on all clang builds. r=nika
clang-cl doesn't define __GNUC__. Also for some reason, clang-cl doesn't
like the use of MOZ_FORMAT_PRINTF on a function definition (while clang
is apparently happy with it).

Differential Revision: https://phabricator.services.mozilla.com/D144922
2022-05-03 20:49:10 +00:00
Serge Guelton 7648a84eba Bug 1765593 - Cleanup mozilla-unified includes r=sylvestre
Differential Revision: https://phabricator.services.mozilla.com/D144202
2022-05-03 14:57:45 +00:00
Gerald Squelart 8f08153522 Bug 1763176 - Don't move to the next entry after streaming a counter, as it would skip an immediately-adjacent counter - r=canaltinova
If the sampler records more than one counter (e.g.: memory and per-process CPU), both counters could appear right next to each other in the buffer.
But then the current streaming code goes something like this:
1. Read entry
2. If entry is a counter, go to the next entry (which should be a timestamp) and output the full counter.
3. Go to the next entry.
4: Return to step 1 (until there are no more entries).

The problem is this unconditional 3rd step:
If we've just read a counter at step 2, we're located at the entry *past* that counter's data, which could be the start of the next counter, that the 3rd step now effectively skips!

Also:
- After reading the time, we can do e.Next() to skip it before testing if it's too old, this may save one loop.
- After reading the optional "number", we can also do e.Next() to skip it, which will save one loop as well.

Differential Revision: https://phabricator.services.mozilla.com/D145056
2022-04-29 12:30:50 +00:00
Mike Hommey 028ad1b883 Bug 1766377 - Fix remaining sign-compare warnings in Windows builds. r=rkraesig,gsvelto,media-playback-reviewers,gfx-reviewers,bryce,sotaro
browser/components/shell/WindowsUserChoice.cpp(233,23): error: comparison of integers of different signs: 'int' and 'const size_t' (aka 'const unsigned long long') [-Werror,-Wsign-compare]
    for (int j = 0; j < DWORDS_PER_BLOCK; ++j) {
                    ~ ^ ~~~~~~~~~~~~~~~~
browser/components/shell/WindowsUserChoice.cpp(388,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(exts); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~
browser/components/shell/nsWindowsShellService.cpp(1225,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(shortcutCSIDLs); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
browser/components/shell/nsWindowsShellService.cpp(1492,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(folders); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~
dom/media/platforms/wmf/MFTDecoder.cpp(85,23): error: comparison of integers of different signs: 'int' and 'UINT32' (aka 'unsigned int') [-Werror,-Wsign-compare]
    for (int i = 1; i < actsNum; i++) {
                    ~ ^ ~~~~~~~
gfx/2d/Factory.cpp(1276,21): error: comparison of integers of different signs: 'int' and 'uint32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]
  for (int y = 0; y < height; y++) {
                  ~ ^ ~~~~~~
gfx/layers/d3d11/CompositorD3D11.cpp(1096,36): error: comparison of integers of different signs: 'UINT' (aka 'unsigned int') and 'int' [-Werror,-Wsign-compare]
        swapDesc.BufferDesc.Height == mSize.height) ||
        ~~~~~~~~~~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~~
gfx/layers/d3d11/CompositorD3D11.cpp(1095,35): error: comparison of integers of different signs: 'UINT' (aka 'unsigned int') and 'int' [-Werror,-Wsign-compare]
  if (((swapDesc.BufferDesc.Width == mSize.width &&
        ~~~~~~~~~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~
gfx/layers/d3d11/TextureD3D11.cpp(1278,30): error: comparison of integers of different signs: 'UINT' (aka 'unsigned int') and 'int' [-Werror,-Wsign-compare]
          currentDesc.Height != mSize.height ||
          ~~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~~
gfx/layers/d3d11/TextureD3D11.cpp(1277,29): error: comparison of integers of different signs: 'UINT' (aka 'unsigned int') and 'int' [-Werror,-Wsign-compare]
      if (currentDesc.Width != mSize.width ||
          ~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~
gfx/layers/ipc/ContentCompositorBridgeParent.cpp(248,19): error: comparison of integers of different signs: 'const uint32_t' (aka 'const unsigned int') and 'int32_t' (aka 'int') [-Werror,-Wsign-compare]
  if (sequenceNum == status.sequenceNumber() && !dm->HasDeviceReset()) {
      ~~~~~~~~~~~ ^  ~~~~~~~~~~~~~~~~~~~~~~~
gfx/thebes/D3D11Checks.cpp(129,21): error: comparison of integers of different signs: 'int' and 'unsigned int' [-Werror,-Wsign-compare]
    if (resultColor != 0xffffff00) {
        ~~~~~~~~~~~ ^  ~~~~~~~~~~
gfx/thebes/D3D11Checks.cpp(154,23): error: comparison of integers of different signs: 'int' and 'unsigned long long' [-Werror,-Wsign-compare]
    for (int i = 0; i < PR_ARRAY_SIZE(checkModules); i += 1) {
                    ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
gfx/thebes/D3D11Checks.cpp(409,14): error: comparison of integers of different signs: 'int32_t' (aka 'int') and 'UINT' (aka 'unsigned int') [-Werror,-Wsign-compare]
  if (vendor != desc.VendorId) {
      ~~~~~~ ^  ~~~~~~~~~~~~~
gfx/thebes/gfxDWriteFontList.cpp(1248,39): error: comparison of integers of different signs: 'unsigned int' and 'int' [-Werror,-Wsign-compare]
        addFamily(names[index], index != sysLocIndex);
                                ~~~~~ ^  ~~~~~~~~~~~
intl/lwbrk/nsUniscribeBreaker.cpp(121,21): error: comparison of integers of different signs: 'int' and 'uint32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]
  for (int i = 0; i < aLength; ++i) {
                  ~ ^ ~~~~~~~
intl/lwbrk/nsUniscribeBreaker.cpp(132,23): error: comparison of integers of different signs: 'int' and 'uint32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]
    for (int i = 0; i < aLength; ++i) {
                    ~ ^ ~~~~~~~
intl/lwbrk/nsUniscribeBreaker.cpp(138,23): error: comparison of integers of different signs: 'int' and 'uint32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]
    for (int i = 0; i < aLength; ++i) {
                    ~ ^ ~~~~~~~
mozglue/misc/PreXULSkeletonUI.cpp(319,26): error: comparison of integers of different signs: 'std::basic_string<char>::size_type' (aka 'unsigned long long') and 'int' [-Werror,-Wsign-compare]
    while (line.length() > whitespace &&
           ~~~~~~~~~~~~~ ^ ~~~~~~~~~~
mozglue/misc/PreXULSkeletonUI.cpp(1003,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 1; i < noPlaceholderSpans.length(); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
mozglue/misc/PreXULSkeletonUI.cpp(1708,21): error: comparison of integers of different signs: 'int' and 'unsigned long long' [-Werror,-Wsign-compare]
  for (int i = 0; i < dataLen / (2 * sizeof(double)); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
security/sandbox/chromium-shim/sandbox/win/permissionsService.cpp(40,16): error: comparison of integers of different signs: 'int' and 'const std::basic_string<wchar_t>::size_type' (aka 'const unsigned long long') [-Werror,-Wsign-compare]
  if (slashIdx != std::wstring::npos) {
      ~~~~~~~~ ^  ~~~~~~~~~~~~~~~~~~
toolkit/components/aboutthirdparty/tests/gtest/TestAboutThirdParty.cpp(107,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(kDirectoriesUnsorted); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/crashreporter/breakpad-client/windows/crash_generation/crash_generation_server.cc(957,23): error: comparison of integers of different signs: 'int' and 'const size_t' (aka 'const unsigned long long') [-Werror,-Wsign-compare]
    for (int i = 0; i < kExceptionAppMemoryRegions; i++) {
                    ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/crashreporter/client/crashreporter_win.cpp(373,21): error: comparison of integers of different signs: 'int' and 'unsigned long long' [-Werror,-Wsign-compare]
  for (int i = 0; i < sizeof(kDefaultAttachedBottom) / sizeof(UINT); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/crashreporter/client/crashreporter_win.cpp(671,21): error: comparison of integers of different signs: 'int' and 'unsigned long long' [-Werror,-Wsign-compare]
  for (int i = 0; i < sizeof(controls) / sizeof(controls[0]); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/crashreporter/client/crashreporter_win.cpp(1048,21): error: comparison of integers of different signs: 'int' and 'unsigned long long' [-Werror,-Wsign-compare]
  for (int i = 0; i < sizeof(kDefaultAttachedBottom) / sizeof(UINT); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/mozapps/defaultagent/SetDefaultBrowser.cpp(248,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < mozilla::ArrayLength(associations); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/system/windowsproxy/ProxyUtils.cpp(27,36): error: comparison of integers of different signs: 'const int' and 'nsTArray_base::size_type' (aka 'unsigned long long') [-Werror,-Wsign-compare]
                             if (i < addr.Length()) {
                                 ~ ^ ~~~~~~~~~~~~~
toolkit/xre/dllservices/mozglue/interceptor/Arm64.h(178,28): error: comparison of integers of different signs: 'int32_t' (aka 'int') and 'unsigned int' [-Werror,-Wsign-compare]
  if (signbits && signbits != 0xFE000000) {
                  ~~~~~~~~ ^  ~~~~~~~~~~
obj-build/dist/include/gtest/gtest.h(1842,54): note: expanded from macro 'EXPECT_EQ'
  EXPECT_PRED_FORMAT2(::testing::internal::EqHelper::Compare, val1, val2)
                                                     ^
obj-build/dist/include/gtest/gtest.h(1354,11): error: comparison of integers of different signs: 'const unsigned int' and 'const int' [-Werror,-Wsign-compare]
  if (lhs == rhs) {
      ~~~ ^  ~~~
obj-build/dist/include/gtest/gtest.h(1373,12): note: in instantiation of function template specialization 'testing::internal::CmpHelperEQ<unsigned int, int>' requested here
    return CmpHelperEQ(lhs_expression, rhs_expression, lhs, rhs);
           ^
toolkit/xre/dllservices/tests/gtest/TestUntrustedModules.cpp(35,5): note: in instantiation of function template specialization 'testing::internal::EqHelper::Compare<unsigned int, int, nullptr>' requested here
    EXPECT_EQ(mCounters.Count(), N);
    ^
obj-build/dist/include/gtest/gtest.h(1842,54): note: expanded from macro 'EXPECT_EQ'
  EXPECT_PRED_FORMAT2(::testing::internal::EqHelper::Compare, val1, val2)
                                                     ^
toolkit/xre/dllservices/tests/gtest/TestUntrustedModules.cpp(210,28): note: in instantiation of function template specialization 'ModuleLoadCounter::Remains<1>' requested here
    EXPECT_TRUE(waitForOne.Remains({kTestModules[0]}, {0}));
                           ^
toolkit/xre/test/gtest/TestAssembleCommandLineWin.cpp(139,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(kExpectedArgsW); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/xre/test/gtest/TestAssembleCommandLineWin.cpp(151,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(kExpectedArgsW); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/xre/test/gtest/TestAssembleCommandLineWin.cpp(164,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(kExpectedArgsW); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
obj-build/dist/include/gtest/gtest.h(1354,11): error: comparison of integers of different signs: 'const int' and 'const unsigned long long' [-Werror,-Wsign-compare]
  if (lhs == rhs) {
      ~~~ ^  ~~~
obj-build/dist/include/gtest/gtest.h(1373,12): note: in instantiation of function template specialization 'testing::internal::CmpHelperEQ<int, unsigned long long>' requested here
    return CmpHelperEQ(lhs_expression, rhs_expression, lhs, rhs);
           ^
toolkit/xre/test/gtest/TestAssembleCommandLineWin.cpp(138,3): note: in instantiation of function template specialization 'testing::internal::EqHelper::Compare<int, unsigned long long, nullptr>' requested here
  EXPECT_EQ(len, ArrayLength(kExpectedArgsW));
  ^
widget/windows/TSFTextStore.cpp(3455,28): error: comparison of integers of different signs: 'uint32_t' (aka 'unsigned int') and 'long' [-Werror,-Wsign-compare]
          range.mEndOffset == end - mComposition->StartOffset() &&
          ~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
widget/windows/TSFTextStore.cpp(3454,30): error: comparison of integers of different signs: 'uint32_t' (aka 'unsigned int') and 'long' [-Werror,-Wsign-compare]
      if (range.mStartOffset == start - mComposition->StartOffset() &&
          ~~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
xpfe/appshell/AppWindow.cpp(1900,21): error: comparison of integers of different signs: 'int' and 'uint32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]
  for (int i = 0; i < toolbarSprings->Length(); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~

Differential Revision: https://phabricator.services.mozilla.com/D144695
2022-04-29 09:14:12 +00:00
Norisz Fay 6e06e2da92 Backed out 4 changesets (bug 1766377) for causing mochitest failures on HyperTextAccessible.cpp CLOSED TREE
Backed out changeset 6335511477a4 (bug 1766377)
Backed out changeset e8108d6fab9f (bug 1766377)
Backed out changeset 80d16d55c490 (bug 1766377)
Backed out changeset 1a6583d6e52e (bug 1766377)
2022-04-29 07:35:11 +03:00
Mike Hommey 9cd056be1e Bug 1766377 - Fix remaining sign-compare warnings in Windows builds. r=rkraesig,gsvelto,media-playback-reviewers,gfx-reviewers,bryce,sotaro
browser/components/shell/WindowsUserChoice.cpp(233,23): error: comparison of integers of different signs: 'int' and 'const size_t' (aka 'const unsigned long long') [-Werror,-Wsign-compare]
    for (int j = 0; j < DWORDS_PER_BLOCK; ++j) {
                    ~ ^ ~~~~~~~~~~~~~~~~
browser/components/shell/WindowsUserChoice.cpp(388,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(exts); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~
browser/components/shell/nsWindowsShellService.cpp(1225,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(shortcutCSIDLs); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
browser/components/shell/nsWindowsShellService.cpp(1492,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(folders); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~
dom/media/platforms/wmf/MFTDecoder.cpp(85,23): error: comparison of integers of different signs: 'int' and 'UINT32' (aka 'unsigned int') [-Werror,-Wsign-compare]
    for (int i = 1; i < actsNum; i++) {
                    ~ ^ ~~~~~~~
gfx/2d/Factory.cpp(1276,21): error: comparison of integers of different signs: 'int' and 'uint32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]
  for (int y = 0; y < height; y++) {
                  ~ ^ ~~~~~~
gfx/layers/d3d11/CompositorD3D11.cpp(1096,36): error: comparison of integers of different signs: 'UINT' (aka 'unsigned int') and 'int' [-Werror,-Wsign-compare]
        swapDesc.BufferDesc.Height == mSize.height) ||
        ~~~~~~~~~~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~~
gfx/layers/d3d11/CompositorD3D11.cpp(1095,35): error: comparison of integers of different signs: 'UINT' (aka 'unsigned int') and 'int' [-Werror,-Wsign-compare]
  if (((swapDesc.BufferDesc.Width == mSize.width &&
        ~~~~~~~~~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~
gfx/layers/d3d11/TextureD3D11.cpp(1278,30): error: comparison of integers of different signs: 'UINT' (aka 'unsigned int') and 'int' [-Werror,-Wsign-compare]
          currentDesc.Height != mSize.height ||
          ~~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~~
gfx/layers/d3d11/TextureD3D11.cpp(1277,29): error: comparison of integers of different signs: 'UINT' (aka 'unsigned int') and 'int' [-Werror,-Wsign-compare]
      if (currentDesc.Width != mSize.width ||
          ~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~
gfx/layers/ipc/ContentCompositorBridgeParent.cpp(248,19): error: comparison of integers of different signs: 'const uint32_t' (aka 'const unsigned int') and 'int32_t' (aka 'int') [-Werror,-Wsign-compare]
  if (sequenceNum == status.sequenceNumber() && !dm->HasDeviceReset()) {
      ~~~~~~~~~~~ ^  ~~~~~~~~~~~~~~~~~~~~~~~
gfx/thebes/D3D11Checks.cpp(129,21): error: comparison of integers of different signs: 'int' and 'unsigned int' [-Werror,-Wsign-compare]
    if (resultColor != 0xffffff00) {
        ~~~~~~~~~~~ ^  ~~~~~~~~~~
gfx/thebes/D3D11Checks.cpp(154,23): error: comparison of integers of different signs: 'int' and 'unsigned long long' [-Werror,-Wsign-compare]
    for (int i = 0; i < PR_ARRAY_SIZE(checkModules); i += 1) {
                    ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
gfx/thebes/D3D11Checks.cpp(409,14): error: comparison of integers of different signs: 'int32_t' (aka 'int') and 'UINT' (aka 'unsigned int') [-Werror,-Wsign-compare]
  if (vendor != desc.VendorId) {
      ~~~~~~ ^  ~~~~~~~~~~~~~
gfx/thebes/gfxDWriteFontList.cpp(1248,39): error: comparison of integers of different signs: 'unsigned int' and 'int' [-Werror,-Wsign-compare]
        addFamily(names[index], index != sysLocIndex);
                                ~~~~~ ^  ~~~~~~~~~~~
intl/lwbrk/nsUniscribeBreaker.cpp(121,21): error: comparison of integers of different signs: 'int' and 'uint32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]
  for (int i = 0; i < aLength; ++i) {
                  ~ ^ ~~~~~~~
intl/lwbrk/nsUniscribeBreaker.cpp(132,23): error: comparison of integers of different signs: 'int' and 'uint32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]
    for (int i = 0; i < aLength; ++i) {
                    ~ ^ ~~~~~~~
intl/lwbrk/nsUniscribeBreaker.cpp(138,23): error: comparison of integers of different signs: 'int' and 'uint32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]
    for (int i = 0; i < aLength; ++i) {
                    ~ ^ ~~~~~~~
mozglue/misc/PreXULSkeletonUI.cpp(319,26): error: comparison of integers of different signs: 'std::basic_string<char>::size_type' (aka 'unsigned long long') and 'int' [-Werror,-Wsign-compare]
    while (line.length() > whitespace &&
           ~~~~~~~~~~~~~ ^ ~~~~~~~~~~
mozglue/misc/PreXULSkeletonUI.cpp(1003,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 1; i < noPlaceholderSpans.length(); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
mozglue/misc/PreXULSkeletonUI.cpp(1708,21): error: comparison of integers of different signs: 'int' and 'unsigned long long' [-Werror,-Wsign-compare]
  for (int i = 0; i < dataLen / (2 * sizeof(double)); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
security/sandbox/chromium-shim/sandbox/win/permissionsService.cpp(40,16): error: comparison of integers of different signs: 'int' and 'const std::basic_string<wchar_t>::size_type' (aka 'const unsigned long long') [-Werror,-Wsign-compare]
  if (slashIdx != std::wstring::npos) {
      ~~~~~~~~ ^  ~~~~~~~~~~~~~~~~~~
toolkit/components/aboutthirdparty/tests/gtest/TestAboutThirdParty.cpp(107,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(kDirectoriesUnsorted); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/crashreporter/breakpad-client/windows/crash_generation/crash_generation_server.cc(957,23): error: comparison of integers of different signs: 'int' and 'const size_t' (aka 'const unsigned long long') [-Werror,-Wsign-compare]
    for (int i = 0; i < kExceptionAppMemoryRegions; i++) {
                    ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/crashreporter/client/crashreporter_win.cpp(373,21): error: comparison of integers of different signs: 'int' and 'unsigned long long' [-Werror,-Wsign-compare]
  for (int i = 0; i < sizeof(kDefaultAttachedBottom) / sizeof(UINT); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/crashreporter/client/crashreporter_win.cpp(671,21): error: comparison of integers of different signs: 'int' and 'unsigned long long' [-Werror,-Wsign-compare]
  for (int i = 0; i < sizeof(controls) / sizeof(controls[0]); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/crashreporter/client/crashreporter_win.cpp(1048,21): error: comparison of integers of different signs: 'int' and 'unsigned long long' [-Werror,-Wsign-compare]
  for (int i = 0; i < sizeof(kDefaultAttachedBottom) / sizeof(UINT); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/mozapps/defaultagent/SetDefaultBrowser.cpp(248,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < mozilla::ArrayLength(associations); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/system/windowsproxy/ProxyUtils.cpp(27,36): error: comparison of integers of different signs: 'const int' and 'nsTArray_base::size_type' (aka 'unsigned long long') [-Werror,-Wsign-compare]
                             if (i < addr.Length()) {
                                 ~ ^ ~~~~~~~~~~~~~
toolkit/xre/dllservices/mozglue/interceptor/Arm64.h(178,28): error: comparison of integers of different signs: 'int32_t' (aka 'int') and 'unsigned int' [-Werror,-Wsign-compare]
  if (signbits && signbits != 0xFE000000) {
                  ~~~~~~~~ ^  ~~~~~~~~~~
obj-build/dist/include/gtest/gtest.h(1842,54): note: expanded from macro 'EXPECT_EQ'
  EXPECT_PRED_FORMAT2(::testing::internal::EqHelper::Compare, val1, val2)
                                                     ^
obj-build/dist/include/gtest/gtest.h(1354,11): error: comparison of integers of different signs: 'const unsigned int' and 'const int' [-Werror,-Wsign-compare]
  if (lhs == rhs) {
      ~~~ ^  ~~~
obj-build/dist/include/gtest/gtest.h(1373,12): note: in instantiation of function template specialization 'testing::internal::CmpHelperEQ<unsigned int, int>' requested here
    return CmpHelperEQ(lhs_expression, rhs_expression, lhs, rhs);
           ^
toolkit/xre/dllservices/tests/gtest/TestUntrustedModules.cpp(35,5): note: in instantiation of function template specialization 'testing::internal::EqHelper::Compare<unsigned int, int, nullptr>' requested here
    EXPECT_EQ(mCounters.Count(), N);
    ^
obj-build/dist/include/gtest/gtest.h(1842,54): note: expanded from macro 'EXPECT_EQ'
  EXPECT_PRED_FORMAT2(::testing::internal::EqHelper::Compare, val1, val2)
                                                     ^
toolkit/xre/dllservices/tests/gtest/TestUntrustedModules.cpp(210,28): note: in instantiation of function template specialization 'ModuleLoadCounter::Remains<1>' requested here
    EXPECT_TRUE(waitForOne.Remains({kTestModules[0]}, {0}));
                           ^
toolkit/xre/test/gtest/TestAssembleCommandLineWin.cpp(139,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(kExpectedArgsW); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/xre/test/gtest/TestAssembleCommandLineWin.cpp(151,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(kExpectedArgsW); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
toolkit/xre/test/gtest/TestAssembleCommandLineWin.cpp(164,21): error: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long long') [-Werror,-Wsign-compare]
  for (int i = 0; i < ArrayLength(kExpectedArgsW); ++i) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
obj-build/dist/include/gtest/gtest.h(1354,11): error: comparison of integers of different signs: 'const int' and 'const unsigned long long' [-Werror,-Wsign-compare]
  if (lhs == rhs) {
      ~~~ ^  ~~~
obj-build/dist/include/gtest/gtest.h(1373,12): note: in instantiation of function template specialization 'testing::internal::CmpHelperEQ<int, unsigned long long>' requested here
    return CmpHelperEQ(lhs_expression, rhs_expression, lhs, rhs);
           ^
toolkit/xre/test/gtest/TestAssembleCommandLineWin.cpp(138,3): note: in instantiation of function template specialization 'testing::internal::EqHelper::Compare<int, unsigned long long, nullptr>' requested here
  EXPECT_EQ(len, ArrayLength(kExpectedArgsW));
  ^
widget/windows/TSFTextStore.cpp(3455,28): error: comparison of integers of different signs: 'uint32_t' (aka 'unsigned int') and 'long' [-Werror,-Wsign-compare]
          range.mEndOffset == end - mComposition->StartOffset() &&
          ~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
widget/windows/TSFTextStore.cpp(3454,30): error: comparison of integers of different signs: 'uint32_t' (aka 'unsigned int') and 'long' [-Werror,-Wsign-compare]
      if (range.mStartOffset == start - mComposition->StartOffset() &&
          ~~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
xpfe/appshell/AppWindow.cpp(1900,21): error: comparison of integers of different signs: 'int' and 'uint32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]
  for (int i = 0; i < toolbarSprings->Length(); i++) {
                  ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~

Differential Revision: https://phabricator.services.mozilla.com/D144695
2022-04-29 00:43:32 +00:00
Mike Hommey e317b0e119 Bug 1766375 - Disable implicit-fallthrough warnings in Windows builds like other platforms. r=firefox-build-system-reviewers,andi
Also disable it for Windows-specific third-party code.

Differential Revision: https://phabricator.services.mozilla.com/D144667
2022-04-27 22:12:53 +00:00
Mike Hommey 3da3b13f2a Bug 1766359 - Fix unreachable-code-return warnings in Windows builds. r=emilio,mhowell,nika,rkraesig
dom/system/PathUtils.cpp(77,10): error: 'return' will never be executed [-Werror,-Wunreachable-code-return]
  return false;
         ^~~~~
ipc/chromium/src/chrome/common/ipc_channel_win.cc(479,10): error: 'return' will never be executed [-Werror,-Wunreachable-code-return]
  return true;
         ^~~~
mozglue/misc/PreXULSkeletonUI.cpp(1263,10): error: 'return' will never be executed [-Werror,-Wunreachable-code-return]
  return 0;
         ^
mozglue/tests/TestPEExportSection.cpp(348,12): error: 'return' will never be executed [-Werror,-Wunreachable-code-return]
    return 0;
           ^
security/manager/ssl/OSReauthenticator.cpp(428,10): error: 'return' will never be executed [-Werror,-Wunreachable-code-return]
  return NS_OK;
         ^~~~~
toolkit/components/maintenanceservice/maintenanceservice.cpp(214,10): error: 'return' will never be executed [-Werror,-Wunreachable-code-return]
  return 0;
         ^
widget/windows/WindowsUIUtils.cpp(383,10): error: 'return' will never be executed [-Werror,-Wunreachable-code-return]
  return false;
         ^~~~~

Differential Revision: https://phabricator.services.mozilla.com/D144661
2022-04-26 21:44:54 +00:00
Mike Hommey 74147a241d Bug 1742864 - Sanitize the input frame pointer given to DoFramePointerStackWalk. r=gerald
Differential Revision: https://phabricator.services.mozilla.com/D144396
2022-04-26 02:26:45 +00:00
Mike Hommey 0e99daec55 Bug 1765474 - Fix unused-but-set-variable warning in TestBaseProfiler.cpp. r=gerald
mozglue/tests/TestBaseProfiler.cpp:2188:12: error: variable 'chunk1ReuseCount' set but not used [-Werror,-Wunused-but-set-variable]
  unsigned chunk1ReuseCount = 0;
           ^

Differential Revision: https://phabricator.services.mozilla.com/D144146
2022-04-22 01:25:08 +00:00
Mike Hommey c904666e40 Bug 1758780 - Update builders to rustc 1.60. r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D143176
2022-04-21 04:36:24 +00:00
Narcis Beleuzu 0fd7ae053e Backed out 2 changesets (bug 1758780) for jsreftest failure on fp-evaluation-order.js . CLOSED TREE
Backed out changeset 10e2414392ae (bug 1758780)
Backed out changeset 481062597411 (bug 1758780)
2022-04-20 03:03:26 +03:00
Mike Hommey 5a6c42678a Bug 1758780 - Update builders to rustc 1.60. r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D143176
2022-04-19 08:08:45 +00:00
Nika Layzell a268768056 Bug 1761511 - Part 3: Switch builds over to use the new vendoring of gtest, r=ahal
This required some changes to tests to account for the version differences.

Differential Revision: https://phabricator.services.mozilla.com/D142610
2022-04-14 02:09:21 +00:00
Noemi Erli dff8ae5ed1 Backed out 2 changesets (bug 1758780) for causing OSX failures
Backed out changeset 2a3c0204b519 (bug 1758780)
Backed out changeset 330065f83d19 (bug 1758780)
2022-04-13 14:08:51 +03:00
Mike Hommey b7f1482c6d Bug 1758780 - Update builders to rustc 1.60. r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D143176
2022-04-13 05:09:09 +00:00
Butkovits Atila 3ce125b3f7 Backed out 2 changesets (bug 1758780) as per request by dev. CLOSED TREE
Backed out changeset 0f6aff1f340e (bug 1758780)
Backed out changeset e390fac06dae (bug 1758780)
2022-04-13 07:53:43 +03:00
Mike Hommey 49d9388ec2 Bug 1758780 - Update builders to rustc 1.60. r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D143176
2022-04-13 04:35:12 +00:00
Cosmin Sabou 97d21fa167 Backed out 5 changesets (bug 1761511) for causing build bustages. CLOSED TREE
Backed out changeset 687de8c00013 (bug 1761511)
Backed out changeset 88e6cf5c70e5 (bug 1761511)
Backed out changeset 4c40758f54f1 (bug 1761511)
Backed out changeset 8a18abcccda4 (bug 1761511)
Backed out changeset 1afb1f32a6a4 (bug 1761511)
2022-04-07 00:13:00 +03:00
Nika Layzell b48d249a34 Bug 1761511 - Part 3: Switch builds over to use the new vendoring of gtest, r=ahal
This required some changes to tests to account for the version differences.

Differential Revision: https://phabricator.services.mozilla.com/D142610
2022-04-06 20:45:07 +00:00
John Schanck d853a2275f Bug 1607588 - Remove suppression for NSS shutdown race. r=decoder
Differential Revision: https://phabricator.services.mozilla.com/D142351
2022-03-29 18:48:37 +00:00
Hiroyuki Ikezoe a04b6f26a2 Bug 1674776 - Update DocumentTimeline::mLastRefreshDriverTime outside parallel styling. r=boris,decoder
Note that we can probably use mLastRefreshDriverTime directly in
DocumentTimeline::GetCurrentTimeStamp(), i.e. we don't need to use the refresh
driver there, but I'd preserve the current behavior.

Differential Revision: https://phabricator.services.mozilla.com/D97823
2022-03-28 23:29:14 +00:00
Emilio Cobos Álvarez 80fa6eae2f Bug 1680285 - Simplify selector flag setting now that flag setting is atomic. r=nika,decoder
These bits are write-only, actually, and we don't even need to read
them.

Differential Revision: https://phabricator.services.mozilla.com/D141888
2022-03-24 15:09:47 +00:00
Serge Guelton 104d84a205 Bug 1759344 - Cleanup mozglue/ includes r=andi
Differential Revision: https://phabricator.services.mozilla.com/D141460
2022-03-23 15:36:29 +00:00
Norisz Fay 27c6fc75bd Backed out changeset f6004b806180 (bug 1759344) for causing build bustages on Uptime.obj CLOSED TREE 2022-03-23 13:15:14 +02:00
Serge Guelton 23e36b0d2a Bug 1759344 - Cleanup mozglue/ includes r=andi
Differential Revision: https://phabricator.services.mozilla.com/D141460
2022-03-23 10:02:30 +00:00
Randell Jesup 4ab877b67f Bug 1207753 - baseprofiler thread-safety annotations r=gerald
Differential Revision: https://phabricator.services.mozilla.com/D141603
2022-03-22 14:03:33 +00:00
Randell Jesup addf814b52 Bug 1207753 - Base thread-safety attribution support r=nika
Differential Revision: https://phabricator.services.mozilla.com/D130606
2022-03-16 23:01:41 +00:00
Cristian Tuns 43db1804cf Backed out changeset 3b8c7fa73e82 (bug 1207753) for causing build bustages on Monitor.h CLOSED TREE 2022-03-16 16:45:54 -04:00
Randell Jesup e72ce3cd6c Bug 1207753 - Base thread-safety attribution support r=nika
With additions of MOZ_UNANNOTATED for *Mutex/*Monitor/RWLock classes

Differential Revision: https://phabricator.services.mozilla.com/D130606
2022-03-16 20:10:04 +00:00
Randell Jesup fcaf70841e Bug 1207753 - Add MOZ_UNANNOTATED to all Mutexes/Monitors r=nika,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D140849
2022-03-16 18:47:08 +00:00
Noemi Erli 2390d257e6 Backed out changeset 12a59e5a50bf (bug 1207753) for causing build bustage CLOSED TREE 2022-03-16 18:32:51 +02:00
Randell Jesup 4b033a5256 Bug 1207753 - Add MOZ_UNANNOTATED to all Mutexes/Monitors r=nika,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D140849
2022-03-16 16:16:14 +00:00
Butkovits Atila 927ad62c6a Backed out changeset a68ee4b09f92 (bug 1207753) for causing Hazard bustages. CLOSED TREE 2022-03-16 14:38:14 +02:00
Randell Jesup 7d4b5fae04 Bug 1207753 - Add MOZ_UNANNOTATED to all Mutexes/Monitors r=nika,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D140849
2022-03-16 12:01:14 +00:00
Mike Hommey 1cd4e4fcce Bug 1758017 - Disable MOZ_FORMAT_PRINTF in TestPrintf on Android. r=gsvelto
Differential Revision: https://phabricator.services.mozilla.com/D140272
2022-03-09 04:32:29 +00:00
Gerald Squelart 111d3090e1 Bug 1757596 - De-duplicate PROFILER_RAII macros - r=florian
The next patch would have added yet another PROFILERxx_RAII macro, so it makes sense to gather them all into a single header file, to be #included where needed.

Differential Revision: https://phabricator.services.mozilla.com/D140169
2022-03-08 10:32:43 +00:00
Gerald Squelart 51a6a42c9a Bug 1755823 - BaseProfilerSharedMutex and exclusive&shared RAII locks - r=canaltinova
This is a profiler-specific shared lock (aka readers-writer lock) implemented on top of RWLockImpl.
Similar to BaseProfilerMutex, it records which thread is currently holding the exclusive lock.

Differential Revision: https://phabricator.services.mozilla.com/D139916
2022-03-04 06:48:11 +00:00
Butkovits Atila 78f77536c7 Backed out 2 changesets (bug 1755823) for causing cpp failures at TestBaseProfiler.cpp. CLOSED TREE
Backed out changeset d758cab0d5cf (bug 1755823)
Backed out changeset 169754a1f337 (bug 1755823)
2022-03-04 05:36:41 +02:00
Gerald Squelart b204f08834 Bug 1755823 - BaseProfilerSharedMutex and exclusive&shared RAII locks - r=canaltinova
This is a profiler-specific shared lock (aka readers-writer lock) implemented on top of RWLockImpl.
Similar to BaseProfilerMutex, it records which thread is currently holding the exclusive lock.

Differential Revision: https://phabricator.services.mozilla.com/D139916
2022-03-03 23:03:05 +00:00
Gerald Squelart 97bc60386d Bug 1757100 - Move minimal platform-dependent part of RWLock to mozglue/misc/PlatformRWLock.h&cpp - r=glandium,xpcom-reviewers
This is consistent with how xpcom's Mutex has its platform-dependent code in mozglue, and will allow readers-writer locks in mozglue without duplication.

Differential Revision: https://phabricator.services.mozilla.com/D139669
2022-02-27 23:32:55 +00:00
Mike Hommey 545e5d16a9 Bug 1756534 - Update builders to rustc 1.59. r=sylvestre
Differential Revision: https://phabricator.services.mozilla.com/D139353
2022-02-25 08:27:04 +00:00
smolnar b6b47412cb Backed out changeset 54f67e85078b (bug 1751781) for causing bug 1754972. CLOSED TREE 2022-02-16 07:24:33 +02:00
Alessio Placitelli 85788740ea Bug 1754474 - Add a suppresion for the Glean init thread. r=decoder
The init/shutdown sequence and its threads
are being re-evaluated as part of bug 1755449

Depends on D138466

Differential Revision: https://phabricator.services.mozilla.com/D138767
2022-02-15 13:35:09 +00:00
Gerald Squelart 91645977e5 Bug 1745281 - Record base markers whenever the core buffer is in session - r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D137810
2022-02-14 04:17:12 +00:00
Gerald Squelart e73913b166 Bug 1753192 - Use combined core buffer, and transfer ownership of chunk manager from base to gecko profiler - r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D137804
2022-02-13 06:18:29 +00:00
Gerald Squelart 459979eacb Bug 1753192 - ThreadRegistrationInfo reuses the Base Profiler thread registration time if any - r=canaltinova
Once the buffers are combined, some data could be stored in a thread before its registration with the Gecko Profiler.
Without this fix, the front-end would think the thread had not started yet, which could prevent interacting with that early data.

Differential Revision: https://phabricator.services.mozilla.com/D138239
2022-02-13 06:18:29 +00:00
Gerald Squelart 9715dc54ac Bug 1753192 - Fix apparent negative leak of RequestedChunkRefCountedHolder - r=canaltinova
Once the buffers are combined, a RequestedChunkRefCountedHolder could be referenced from the Base Profiler, which is invisible to the leak catcher; then handed over to the Gecko Profiler where it will eventually be dereferenced, which is logged with the leak catcher, resulting in an apparent negative leak.
This is fixed by keeping all (de)references secret.

Differential Revision: https://phabricator.services.mozilla.com/D138238
2022-02-13 06:18:28 +00:00
Gerald Squelart a9eb4e36d5 Bug 1753192 - Make ActivePS::mProfileBufferChunkManager a UniquePtr, to allow transferring it between profilers - r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D137803
2022-02-13 06:18:28 +00:00
Gerald Squelart 56704e0465 Bug 1753192 - Move core ProfileChunkedBuffers to static singletons in profiler_get_core_buffer() - r=canaltinova
Note that they are still separate buffers for now.

Differential Revision: https://phabricator.services.mozilla.com/D137802
2022-02-13 06:18:28 +00:00
Gerald Squelart a46493fc0f Bug 1753192 - Removed unused ProfileChunkedBuffer::ExtractChunkManager() - r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D137801
2022-02-13 06:18:27 +00:00
Gerald Squelart 0db875fdc3 Bug 1753192 - Move InChunkPointer to new header ProfileChunkedBufferDetail.h - r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D137800
2022-02-13 06:18:27 +00:00
Marian-Vasile Laza bb43a35448 Backed out 8 changesets (bug 1753192) for causing Gtest failures on GeckoProfiler.cpp. CLOSED TREE
Backed out changeset 2f0c24b1f049 (bug 1753192)
Backed out changeset 1a71d954b83f (bug 1753192)
Backed out changeset 07a8ffa8d12f (bug 1753192)
Backed out changeset f79cd543e537 (bug 1753192)
Backed out changeset c2f22d8a8fc8 (bug 1753192)
Backed out changeset c8a0d3c41d2f (bug 1753192)
Backed out changeset 1d5d69d92db9 (bug 1753192)
Backed out changeset 5bc8bd033453 (bug 1753192)
2022-02-11 09:39:38 +02:00
Gerald Squelart 9f19f2143b Bug 1753192 - Use combined core buffer, and transfer ownership of chunk manager from base to gecko profiler - r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D137804
2022-02-11 03:13:52 +00:00
Gerald Squelart f811caf3b2 Bug 1753192 - ThreadRegistrationInfo reuses the Base Profiler thread registration time if any - r=canaltinova
Once the buffers are combined, some data could be stored in a thread before its registration with the Gecko Profiler.
Without this fix, the front-end would think the thread had not started yet, which could prevent interacting with that early data.

Differential Revision: https://phabricator.services.mozilla.com/D138239
2022-02-11 03:13:52 +00:00
Gerald Squelart 6906b4d69a Bug 1753192 - Fix apparent negative leak of RequestedChunkRefCountedHolder - r=canaltinova
Once the buffers are combined, a RequestedChunkRefCountedHolder could be referenced from the Base Profiler, which is invisible to the leak catcher; then handed over to the Gecko Profiler where it will eventually be dereferenced, which is logged with the leak catcher, resulting in an apparent negative leak.
This is fixed by keeping all (de)references secret.

Differential Revision: https://phabricator.services.mozilla.com/D138238
2022-02-11 03:13:51 +00:00
Gerald Squelart adf6de3385 Bug 1753192 - Make ActivePS::mProfileBufferChunkManager a UniquePtr, to allow transferring it between profilers - r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D137803
2022-02-11 03:13:51 +00:00
Gerald Squelart f3c4f65d02 Bug 1753192 - Move core ProfileChunkedBuffers to static singletons in profiler_get_core_buffer() - r=canaltinova
Note that they are still separate buffers for now.

Differential Revision: https://phabricator.services.mozilla.com/D137802
2022-02-11 03:13:51 +00:00
Gerald Squelart aa44b10600 Bug 1753192 - Removed unused ProfileChunkedBuffer::ExtractChunkManager() - r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D137801
2022-02-11 03:13:50 +00:00
Gerald Squelart 9d51c7527c Bug 1753192 - Move InChunkPointer to new header ProfileChunkedBufferDetail.h - r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D137800
2022-02-11 03:13:50 +00:00
ahochheiden c5a6f22e14 Bug 1751781 - Intentionally #undef NAN and redefine it with the value from the STL r=glandium
With the latest Windows 10 SDK (10.0.20348.0), the value of NAN has changed
to differ from the STL. We intentionally #undef the value gotten from the SDK
and replace it with the STL value so that the comparison tests pass regardless
of the Windows SDK version.

Differential Revision: https://phabricator.services.mozilla.com/D137598
2022-02-10 22:47:15 +00:00
Gerald Squelart c5b8ff3ca4 Bug 1735397 - Don't start profiler in processes excluded by pid - r=florian
When trying to profile only one process, the profiler should not even start in those processes excluded by the filter, so that they don't use any resources (memory and CPU).
To do that, the filter is checked for "pid:" at the multiple locations it may appear:
- In the parent process, when starting the overall profiler, don't send the "Start" IPC to excluded processes.
- When a new process starts and initializes the profiler, don't start the profiler if the filter excludes this process.
- When a new process then registers itself with the parent, don't (re)start the profiler in excluded processes.

Child processes that don't run the profiler may still be asked for a JSON profile at the end of the profiling session. This is handled by sending an empty string, so that the parent process will correctly remove them from the pending-profile list.

Differential Revision: https://phabricator.services.mozilla.com/D135854
2022-02-08 12:47:53 +00:00
Gerald Squelart ca8a203ae8 Bug 1735397 - mozilla::profiler::detail::FilterHasPid and FiltersExcludePid - r=florian
These will be used to check special thread filter rules around "pid:..." filters.

Differential Revision: https://phabricator.services.mozilla.com/D135853
2022-02-08 12:47:52 +00:00
Gerald Squelart 7e96f5a4d3 Bug 1735397 - Add mozilla/BaseAndGeckoProfilerDetail.h header for shared profiler-only things - r=florian
Differential Revision: https://phabricator.services.mozilla.com/D135852
2022-02-08 12:47:52 +00:00
Kris Wright 51c0acfc7a Bug 1606651 - Remove TSan suppression for nsPluginTag. r=decoder
It looks like this data race might not be hit anymore.

Differential Revision: https://phabricator.services.mozilla.com/D137769
2022-02-08 05:51:10 +00:00