Make it easier to get frame dumps in Opt builds

RESOLVED FIXED in mozilla29

Status

()

Core
Layout
--
enhancement
RESOLVED FIXED
4 years ago
4 years ago

People

(Reporter: mats, Assigned: mats)

Tracking

unspecified
mozilla29
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Assignee)

Description

4 years ago
Created attachment 8355700 [details] [diff] [review]
wip

I hacked this up to get frame dumps in Opt builds (for bug 946929).
It puts nsIFrame::List() and related methods under a separate #ifdef
than DEBUG.  It's off by default, except in DEBUG builds:

#ifdef DEBUG
#define DEBUG_Frame_Dump 1
#endif

The idea is that if you want frame dumps in Opt builds, you simply change
that to be unconditional, or define it in a mozconfig or whatever,
and then rebuild.

Let me know if you would find this useful and I'll land it...
Landing it seems fine with me, though it might bitrot a bit once landed.  The macro name should probably be all-uppercase, though, and it wouldn't be a bad idea if:

>+#ifdef DEBUG
>+#define DEBUG_Frame_Dump 1
>+#endif

had a comment explaining why it's separate from DEBUG (i.e., so that it can be defined in non-DEBUG builds).
(Assignee)

Comment 2

4 years ago
Created attachment 8355896 [details] [diff] [review]
fix

With dbaron's nits addressed.
Attachment #8355700 - Attachment is obsolete: true
Attachment #8355896 - Flags: review?(roc)
https://hg.mozilla.org/mozilla-central/rev/794680b9599d
Status: NEW → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla29
You need to log in before you can comment on or make changes to this bug.