Closed Bug 1877273 Opened 2 years ago Closed 2 years ago

Remove Telemetry Use Counter probes

Categories

(Core :: DOM: Core & HTML, task, P1)

task

Tracking

()

RESOLVED FIXED
124 Branch
Tracking Status
firefox123 --- wontfix
firefox124 --- fixed

People

(Reporter: chutten, Assigned: chutten)

References

Details

Attachments

(1 file, 1 obsolete file)

bug 1874439 validated that the Glean implementation of reporting use counter metrics is good enough compared to the Telemetry one that we can now drop the Telemetry one (because it's rather more expensive).

Let's be about that, shall we?

Glean-based Use Counter metrics are cheaper and work as well,
so let's use them instead.

Blocks: 1877752
Pushed by chutten@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/f334593f5b54 Remove Telemetry-based Use Counters r=emilio

Backed out for causing non-unified build bustages on UseCounterMetrics.cpp.
Later, this build base toolchains has failed.

[task 2024-01-31T16:39:00.607Z] 16:39:00     INFO -  gmake[4]: Entering directory '/builds/worker/workspace/obj-build/dom/base'
[task 2024-01-31T16:39:00.612Z] 16:39:00     INFO -  /builds/worker/fetches/sccache/sccache /builds/worker/fetches/clang/bin/clang-cl -fms-compatibility-version=19.29 -Xclang -std=c++17 -Xclang -ivfsoverlay -Xclang /builds/worker/fetches/vs/overlay.yaml -FoUseCounterMetrics.obj -c  -I/builds/worker/workspace/obj-build/dist/stl_wrappers -guard:cf -DNDEBUG=1 -DTRIMMED=1 -DUNICODE -D_UNICODE -D_CRT_RAND_S -DCERT_CHAIN_PARA_HAS_EXTRA_FIELDS -D_SECURE_ATL -DCHROMIUM_BUILD -DU_STATIC_IMPLEMENTATION -DWIN32 -D_WIN32 -D_WINDOWS -DWIN32_LEAN_AND_MEAN -DWINAPI_NO_BUNDLED_LIBRARIES -DMOZ_HAS_MOZGLUE -DMOZILLA_INTERNAL_API -DIMPL_LIBXUL -DSTATIC_EXPORTABLE_JS_API -I/builds/worker/checkouts/gecko/dom/base -I/builds/worker/workspace/obj-build/dom/base -I/builds/worker/checkouts/gecko/dom/battery -I/builds/worker/checkouts/gecko/dom/events -I/builds/worker/checkouts/gecko/dom/media -I/builds/worker/checkouts/gecko/dom/network -I/builds/worker/checkouts/gecko/caps -I/builds/worker/checkouts/gecko/docshell/base -I/builds/worker/checkouts/gecko/dom/base -I/builds/worker/checkouts/gecko/dom/file -I/builds/worker/checkouts/gecko/dom/geolocation -I/builds/worker/checkouts/gecko/dom/html -I/builds/worker/checkouts/gecko/dom/ipc -I/builds/worker/checkouts/gecko/dom/storage -I/builds/worker/checkouts/gecko/dom/svg -I/builds/worker/checkouts/gecko/dom/xml -I/builds/worker/checkouts/gecko/dom/xslt/xpath -I/builds/worker/checkouts/gecko/dom/xul -I/builds/worker/checkouts/gecko/extensions/spellcheck/src -I/builds/worker/checkouts/gecko/gfx/2d -I/builds/worker/checkouts/gecko/image -I/builds/worker/checkouts/gecko/js/xpconnect/loader -I/builds/worker/checkouts/gecko/js/xpconnect/src -I/builds/worker/checkouts/gecko/js/xpconnect/wrappers -I/builds/worker/checkouts/gecko/layout/base -I/builds/worker/checkouts/gecko/layout/forms -I/builds/worker/checkouts/gecko/layout/generic -I/builds/worker/checkouts/gecko/layout/style -I/builds/worker/checkouts/gecko/layout/xul -I/builds/worker/checkouts/gecko/netwerk/base -I/builds/worker/checkouts/gecko/netwerk/protocol/http -I/builds/worker/checkouts/gecko/netwerk/url-classifier -I/builds/worker/checkouts/gecko/parser/htmlparser -I/builds/worker/checkouts/gecko/security/manager/ssl -I/builds/worker/checkouts/gecko/third_party/xsimd/include -I/builds/worker/checkouts/gecko/widget -I/builds/worker/checkouts/gecko/xpcom/ds -I/builds/worker/checkouts/gecko/netwerk/sctp/datachannel -I/builds/worker/workspace/obj-build/ipc/ipdl/_ipdlheaders -I/builds/worker/checkouts/gecko/ipc/chromium/src -I/builds/worker/workspace/obj-build/dist/include -I/builds/worker/workspace/obj-build/dist/include/nspr -I/builds/worker/workspace/obj-build/dist/include/nss -MD -FI /builds/worker/workspace/obj-build/mozilla-config.h -DMOZILLA_CLIENT -fcrash-diagnostics-dir=/builds/worker/artifacts -TP -Zc:sizedDealloc- -D_HAS_EXCEPTIONS=0 -Gy -Zc:inline -Gw -D_SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING -GR- -Z7 -Xclang -load -Xclang /builds/worker/workspace/obj-build/build/clang-plugin/libclang-plugin.so -Xclang -add-plugin -Xclang moz-check -O2 -Oy- -Werror -W3 -Wbitfield-enum-conversion -Wdeprecated-this-capture -Wempty-body -Wformat-type-confusion -Wignored-qualifiers -Wpointer-arith -Wshadow-field-in-constructor-modified -Wsign-compare -Wtautological-constant-in-range-compare -Wtype-limits -Wno-error=tautological-type-limit-compare -Wunreachable-code -Wunreachable-code-return -Wunused-but-set-parameter -Wno-invalid-offsetof -Wclass-varargs -Wempty-init-stmt -Wfloat-overflow-conversion -Wfloat-zero-conversion -Wloop-analysis -Wno-range-loop-analysis -Wc++2a-compat -Wenum-compare-conditional -Wenum-float-conversion -Wvolatile -Wno-error=deprecated -Wno-error=deprecated-anon-enum-enum-conversion -Wno-error=deprecated-enum-enum-conversion -Wno-error=deprecated-pragma -Wno-error=deprecated-this-capture -Wcomma -Wimplicit-fallthrough -Wstring-conversion -Wno-inline-new-delete -Wno-error=deprecated-declarations -Wno-error=array-bounds -Wno-error=free-nonheap-object -Wno-error=atomic-alignment -Wno-error=deprecated-builtins -Wno-unknown-pragmas -Wno-ignored-pragmas -Wno-deprecated-declarations -Wno-microsoft-enum-value -Wno-microsoft-include -Wno-invalid-noreturn -Wno-inconsistent-missing-override -Wno-implicit-exception-spec-mismatch -Wno-microsoft-exception-spec -Wno-unused-local-typedef -Wno-ignored-attributes -Wno-used-but-marked-unused -Wno-psabi -Wthread-safety -Wno-error=builtin-macro-redefined -Wno-vla-cxx-extension -Wno-unknown-warning-option -fno-strict-aliasing -Xclang -ffp-contract=off  -Xclang -MP -Xclang -dependency-file -Xclang .deps/UseCounterMetrics.obj.pp -Xclang -MT -Xclang UseCounterMetrics.obj   /builds/worker/workspace/obj-build/dom/base/UseCounterMetrics.cpp
[task 2024-01-31T16:39:00.613Z] 16:39:00    ERROR -  /builds/worker/workspace/obj-build/dom/base/UseCounterMetrics.cpp(6983,14): error: 'return' will never be executed [-Werror,-Wunreachable-code-return]
[task 2024-01-31T16:39:00.613Z] 16:39:00     INFO -   6983 |       return "";
[task 2024-01-31T16:39:00.613Z] 16:39:00     INFO -        |              ^~
[task 2024-01-31T16:39:00.613Z] 16:39:00     INFO -  1 error generated.
[task 2024-01-31T16:39:00.613Z] 16:39:00    ERROR -  gmake[4]: *** [/builds/worker/checkouts/gecko/config/rules.mk:688: UseCounterMetrics.obj] Error 1
[task 2024-01-31T16:39:00.613Z] 16:39:00     INFO -  gmake[4]: Leaving directory '/builds/worker/workspace/obj-build/dom/base'
Flags: needinfo?(chutten)

Ah, a simple fix.

Flags: needinfo?(chutten)
Pushed by chutten@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/2ee5ce9b3c67 Remove Telemetry-based Use Counters r=emilio

Okay, I need to figure out what's going on with that function, because on my machine it doesn't complain a whit.

As for browser_date_telemetry.js, I wonder why that didn't get hit in my mach try auto run.

Flags: needinfo?(chutten)
Pushed by chutten@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/a44037bc960c Remove Telemetry-based Use Counters r=emilio
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 124 Branch

Glean-based Use Counter metrics are cheaper and work as well,
so let's use them instead.

Though we do have metric name strings available in a string table in GleanJSMetrics.cpp,
access is through metric_entry_t which has information not available to usecounters.py.
So for now we return char* literals from the use counter increment fns.

Original Revision: https://phabricator.services.mozilla.com/D199933

Attachment #9378003 - Flags: approval-mozilla-beta?

Uplift Approval Request

  • Risk associated with taking this patch: Low
  • String changes made/needed: None
  • Is Android affected?: no
  • Fix verified in Nightly: yes
  • Needs manual QE test: no
  • Explanation of risk level: Removes a data collection mechanism. Is covered by tests.
  • Code covered by automated testing: yes
  • Steps to reproduce for manual QE testing: N/A
  • User impact if declined: Wasted bandwidth, mostly
Attachment #9378003 - Flags: approval-mozilla-beta? → approval-mozilla-beta-

Comment on attachment 9378003 [details]
Bug 1877273 - Remove Telemetry-based Use Counters r?emilio!

The patch is large and does not apply to the beta branch, it is also not fixing a problem for users, let's have it ride the 124 train. Thanks.

Attachment #9378003 - Attachment is obsolete: true
Regressions: 1865538
Depends on: 1852098
No longer depends on: 1866834
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: