Closed Bug 462184 Opened 16 years ago Closed 16 years ago

TM: Make INCLUDE_VERSBOSE_OUTPUT actually work in non-debug buildsx

Categories

(Core :: JavaScript Engine, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: bzbarsky, Assigned: bzbarsky)

References

Details

Attachments

(1 file, 1 obsolete file)

Attached patch Like so (obsolete) — Splinter Review
Patch attached.
Attachment #345315 - Flags: review?(brendan)
Summary: Make INCLUDE_VERSBOSE_OUTPUT actually work in non-debug builds → TM: Make INCLUDE_VERSBOSE_OUTPUT actually work in non-debug buildsx
Attachment #345315 - Flags: review?(brendan) → review-
Comment on attachment 345315 [details] [diff] [review]
Like so

>diff --git a/js/src/jsopcode.cpp b/js/src/jsopcode.cpp
>--- a/js/src/jsopcode.cpp
>+++ b/js/src/jsopcode.cpp
>@@ -99,27 +99,25 @@ uintN js_NumCodeSpecs = JS_ARRAY_LENGTH(
>  */
> static const char *CodeToken[] = {
> #define OPDEF(op,val,name,token,length,nuses,ndefs,prec,format) \
>     token,
> #include "jsopcode.tbl"
> #undef OPDEF
> };
> 
>-#ifdef DEBUG
>-/*
>- * Array of JS bytecode names used by DEBUG-only js_Disassemble.
>+/*
>+ * Array of JS bytecode names.
>  */
> const char *js_CodeName[] = {
> #define OPDEF(op,val,name,token,length,nuses,ndefs,prec,format) \
>     name,
> #include "jsopcode.tbl"
> #undef OPDEF
> };
>-#endif

We took these out to save some space. Can you test #if defined DEBUG || defind INCLUDE_VERBOSE_OUTPUT?

INCLUDE_VERBOSE_OUTPUT is too generic a name. How about JS_JIT_SPEW? I'm not kidding :-P.

>+#ifdef DEBUG
>+#define INCLUDE_VERBOSE_OUTPUT
>+#endif

Want #if defined DEBUG && !defined JS_JIT_SPEW to avoid whinage if someone defines via -D (which gives the macro "1" as its value, which is not the same as a defined to empty body macro).

/be
Assignee: general → bzbarsky
Attachment #345315 - Attachment is obsolete: true
Status: NEW → ASSIGNED
Attachment #345417 - Flags: review?(brendan)
Comment on attachment 345417 [details] [diff] [review]
Updated to comments

Looks good to me, trust it works built both ways (DEBUG and JS_JIT_SPEW). Thanks,

/be
Attachment #345417 - Flags: review?(brendan) → review+
Pushed changeset 9994733fb845.
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Flags: in-testsuite-
Flags: in-litmus-
Depends on: 463956
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: