Closed Bug 904869 Opened 11 years ago Closed 7 years ago

We should always build with -funwind-tables to support native stack unwinding on B2G

Categories

(Firefox OS Graveyard :: General, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: huseby, Assigned: jld)

References

Details

Attachments

(1 file)

This discussion needs to happen. This bug is to track the decision making process. We'll email dev-b2g as well.
Before: -rw-r--r-- 1 jld jld 119730808 Sep 13 18:13 out/target/product/keon/system.img -rwxr-xr-x 1 jld jld 26096900 Sep 13 18:13 out/target/product/keon/system/b2g/libxul.so After: -rw-r--r-- 1 jld jld 120795768 Sep 13 18:33 out/target/product/keon/system.img -rwxr-xr-x 1 jld jld 27096916 Sep 13 18:33 out/target/product/keon/system/b2g/libxul.so Difference: 1064960 system.img 1000016 libxul.so This lets people get native stack unwinding without having to wait for a full Gecko rebuild, which is a recurring pain point for users of profiling. It costs no RAM or CPU when not in use, and ~1 MiB of secondary storage added to the 114 MiB system.img (as measured on keon/master/m-c). It's not the entire story yet, because the profile symbolication script isn't elfhack-clean, but we know how to fix that, and in any case making the compiler flags the same between "profiling" and "not profiling" should allow ccache to take away most of the rebuild time. Also of possible relevance: it looks as if we should be able to use objcopy to strip out those sections, as an alternative to not building them. This may be useful with ccache.
Assignee: nobody → jld
Summary: Decide if we should always build with -funwind-tables to support native stacks on B2G → We should always build with -funwind-tables to support native stack unwinding on B2G
Whiteboard: [c=profiling s=2013.09.06 p=2] → [c=profiling s=2013.09.20 p=2]
I don't entirely like this patch — we probably want to make a separate decision about Firefox For Android, and as for B2G I expect to receive comments about having this conditional on build variant (which effectively means controlled by the mozconfig somehow). But it's straightforward and it's what I got the above numbers with.
Status: NEW → ASSIGNED
Keywords: perf
Whiteboard: [c=profiling s=2013.09.20 p=2] → [c=profiling p=2 s= u=]
Will this allow us to configure the unwinding mode at runtime? I've found that I keep two gecko objdir's around; one with pseudo stacks and one with native stacks. When I'm trying to hunt down reflows it seems easier to use pseudo stacks. At other times, though, I want native stacks. Just my use case and its certainly possible I am doing something sub-optimal.
Keywords: perf
Whiteboard: [c=profiling p=2 s= u=]
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: