Consider expanding Glean's architecture detection
Categories
(Toolkit :: Telemetry, task, P2)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox139 | --- | fixed |
People
(Reporter: chutten|PTO, Assigned: chutten|PTO)
References
Details
(Whiteboard: [fog-migration])
Attachments
(3 files)
Glean's client_info.architecture doesn't have the same fine resolution as Legacy Telemetry's environment.build.architecture.
Glean's value comes from rustc supplying us with the target_arch cfg attribute. At present we detect aarch64, arm, x86, and x86_64, letting the rest be Unknown.
Legacy's value comes from, eventually, the sysinfo define _PR_SI_ARCHITECTURE which has a lot of different values.
A 1-day 1% sample of "main" pings comes up with the following reported values (by ping count):
x86-64 3,638,856
x86 349,965
aarch64 108,900
arm 3,607
amd64 25
ppc64 5
riscv64 5
Looks like maybe we look into amd64, ppc64, and riscv64? I don't know what the full list of values for target_arch are. The docs supply a list of examples which includes powerpc64 which we could add, I suppose.
ni?janerik -- is there a way to know what target_arch values there are, or at least the ones we're likely to see in a Firefox Desktop build? Are they discernable from the Cargo.toml or some other build config?
Comment 1•1 year ago
|
||
Teeechnically target_arch could be anything, but should most likely somewhat match the first part of the platform target (see https://doc.rust-lang.org/nightly/rustc/platform-support.html).
Our compile-time hardcoded list is based on the platforms crate.
We didn't use that crate directly and instead copied just the minimal parts we needed because ... we didn't plan on supporting much more initially!
They do have a nice list though and we could extend our code based on that.
Essentially just adding the few more architectures you listed above from the 1% sample.
| Assignee | ||
Updated•1 year ago
|
Updated•1 year ago
|
| Assignee | ||
Comment 2•1 year ago
|
||
Hrm, no amd64, guess it gets rolled into x86_64. Probably fine.
Comment 3•1 year ago
|
||
| Assignee | ||
Comment 4•1 year ago
|
||
chutten merged PR [mozilla/glean]: bug 1944694 - Add more target_arch based on those seen in the Legacy Telemetry Environment (#3058) in 5d533c0.
Gonna leave this open to remind us to increment Glean Count by one when a release with this code is vendored into m-c.
| Assignee | ||
Comment 5•1 year ago
|
||
| Assignee | ||
Comment 6•1 year ago
|
||
Comment 8•1 year ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/0d95bc64afa2
https://hg.mozilla.org/mozilla-central/rev/77694b81d50c
Updated•1 year ago
|
Description
•