Closed Bug 1933057 Opened 1 year ago Closed 4 days ago

Pass `--use-local-debuginfo` to minidump-stackwalk in mozcrash.py to use local symbols already present in binaries without requiring users to invoke `mach buildsymbols` after every build

Categories

(Toolkit :: Crash Reporting, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
156 Branch
Tracking Status
firefox156 --- fixed

People

(Reporter: asuth, Assigned: schopin)

References

Details

Attachments

(3 files)

In this message in the crashreporting channel of chat.mozilla.org :gsvelto said:

Well, we could just pass --use-local-debuginfo to minidump-stackwalk and it should work out of the box
It should be just a matter of tweaking mozcrash.py. I'll give it a spin tomorrow.

Having looked at this a bit, it appears that this would obsolete the need for developers to manually run mach buildsymbols after every mach build if they want crashes in local test runs symbolicated. (Noting that until bug 1924260 is fixed, it's also necessary to manually pass --symbols-path to mach wpt to symbolicate successfully at all for wpt tests run locally.)

I finally figured why we haven't done this yet: I forgot to update the stackwalker we use in automation, so that needs to happen first.

Depends on: 1933629

(In reply to Gabriele Svelto [:gsvelto] from comment #1)

I finally figured why we haven't done this yet: I forgot to update the stackwalker we use in automation, so that needs to happen first.

I'm confused by whether https://bugzilla.mozilla.org/show_bug.cgi?id=1933629#c5 means there's still more to do or if that dependency is solved, but if there's more to do there, on the patch attached here I keyed use of the flag on the heuristic that decides we're on a local machine and that works on my local machine (but of course I have no clue what it might do to the automation).

The dependency is solved but since there's more to do for that bug we're leaving it open. I'm removing the dependency since this can go forward now.

No longer depends on: 1933629

I'm wondering if we even need to make this conditional? AFAICT minidump-stackwalk gracefully handles missing local files.

If the data is already available locally, we might as well use it, as
the .sym files might not have all data, e.g. system libraries, or not be
there at all if the user hasn't run ./mach buildsymbols.

Assignee: nobody → schopin
Status: NEW → ASSIGNED

minidump-stackwalk might print spurious warnings or errors that aren't
fatal, it shouldn't suppress the entire output of mozcrash. In
particular, the next patch will have it emit warning when crashes involve
system libraries that don't have symbols.

Once you land this please send an e-mail to dev-platform to describe the change since it's going to be useful to pretty much anybody doing native development.

I'll just wait for a bit to make sure it doesn't get backed out, then I'll write the email.

Flags: needinfo?(schopin)
Status: ASSIGNED → RESOLVED
Closed: 4 days ago
Resolution: --- → FIXED
Target Milestone: --- → 156 Branch

This is great! I guess no more piping through fix_stacks?

Not for local builds

Flags: needinfo?(schopin)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: