Closed Bug 1485260 Opened 6 years ago Closed 6 years ago

5.04 - 6.78% compiler_metrics num_static_constructors (linux32, linux64) regression on push fbe65340170cbaa1c77c45730f1ae0f8afd44d6b (Tue Aug 21 2018)

Categories

(Toolkit :: Crash Reporting, defect)

All
Linux
defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: igoldan, Unassigned)

References

Details

(Keywords: regression)

We have detected a build metrics regression from push:

https://hg.mozilla.org/integration/autoland/pushloghtml?changeset=fbe65340170cbaa1c77c45730f1ae0f8afd44d6b

As author of one of the patches included in that push, we need your help to address this regression.

Regressions:

  7%  compiler_metrics num_static_constructors linux64 pgo      118.00 -> 126.00
  5%  compiler_metrics num_static_constructors linux32 pgo      119.00 -> 125.00


You can find links to graphs and comparison views for each of the above tests at: https://treeherder.mozilla.org/perf.html#/alerts?id=15173

On the page above you can see an alert for each affected platform as well as a link to a graph showing the history of scores for this test. There is also a link to a treeherder page showing the jobs in a pushlog format.

To learn more about the regressing test(s), please see: https://developer.mozilla.org/en-US/docs/Mozilla/Performance/Automated_Performance_Testing_and_Sheriffing/Build_Metrics
Component: General → Crash Reporting
Product: Testing → Toolkit
Flags: needinfo?(gsvelto)
I went through the entire patch a couple of times and I really don't see where this might be coming from. There's no new static variable being declared and none of the other changes seem like they would cause an implicit static constructor to be emitted. Ted, any idea of what might have caused this? Anyway, this is third party code so there's not much we can do until we replace it.
Flags: needinfo?(gsvelto) → needinfo?(ted)
The code that counts these is here, it's literally just grepping FUNC names from symbol files:
https://dxr.mozilla.org/mozilla-central/rev/56b988a937689d5599400afa59b72c390b40abf2/toolkit/crashreporter/tools/symbolstore.py#589

It should be easy enough to grab symbols from a build before and after your change, grep for '^FUNC .*_GLOBAL__sub_', strip off everything but the function names, pipe them through `sort -u` and diff the results.
Flags: needinfo?(ted)
OK, that explains everything then: it's not a regression, we weren't printing those symbols out before because we didn't support DW_AT_ranges! Simply put before bug 1440282 those PGO builds were missing some symbols (probably because of hot/cold code placement) and now we're printing them out correctly hence the apparent regression. I'm closing this as WFM.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WORKSFORME
Oh geez, that didn't even occur to me as I was writing that comment!
To clarify: if there was an actual regression here, it almost certainly happened during one of our toolchain updates. I couldn't find anywhere that we had figured out when our compiler started emitting `DW_AT_ranges`, but I'm pretty sure it was one of our GCC updates that did it.
You need to log in before you can comment on or make changes to this bug.