WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
115684
ftp branch: Fix broken 32-bit build + clean up JITStubs.cpp a bit.
https://bugs.webkit.org/show_bug.cgi?id=115684
Summary
ftp branch: Fix broken 32-bit build + clean up JITStubs.cpp a bit.
Mark Lam
Reported
2013-05-06 17:06:06 PDT
Remedy minor bit rotting in DFGSpeculativeJIT32_64.cpp. JITStubs.cpp has a case for CPU(X86_64) && USE(JSVALUE32_64) which doesn't make sense. Will delete this block of unnecessary code. Also will add some line breaks and update some comments to more clearly delineate between the sections of code in JITStubs.cpp.
Attachments
the patch.
(5.12 KB, patch)
2013-05-06 17:10 PDT
,
Mark Lam
ggaren
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Mark Lam
Comment 1
2013-05-06 17:10:11 PDT
Created
attachment 200857
[details]
the patch.
Geoffrey Garen
Comment 2
2013-05-06 17:14:45 PDT
Comment on
attachment 200857
[details]
the patch. View in context:
https://bugs.webkit.org/attachment.cgi?id=200857&action=review
> Source/JavaScriptCore/jit/JITStubs.cpp:312 > -#else // USE(JSVALUE32_64) > +#else // !USE(JSVALUE32_64) > > #if COMPILER(GCC) && CPU(X86_64) >
I believe the style in other WebKit code is to annotate a dependent preprocessor macro with the heading for the macro's start. So, in this case, "USE(JSVALUE32_64)" is correct.
Mark Lam
Comment 3
2013-05-06 17:42:18 PDT
(In reply to
comment #2
)
> (From update of
attachment 200857
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=200857&action=review
> > > Source/JavaScriptCore/jit/JITStubs.cpp:312 > > -#else // USE(JSVALUE32_64) > > +#else // !USE(JSVALUE32_64) > > > > #if COMPILER(GCC) && CPU(X86_64) > > > > I believe the style in other WebKit code is to annotate a dependent preprocessor macro with the heading for the macro's start. So, in this case, "USE(JSVALUE32_64)" is correct.
I'll revert this !USE(JSVALUE32_64) change for this commit, but for future reference, what is the right thing to do then when we have a case like the following? #if CPU(x86) ... #elif CPU(X86_64) ... #else // what comment is appropriate here? #endif // whacomment is appropriate here?
Mark Lam
Comment 4
2013-05-06 17:47:01 PDT
Thanks for the review. Landed in
r149655
: <
http://trac.webkit.org/changeset/149655
>.
Geoffrey Garen
Comment 5
2013-05-06 22:06:32 PDT
> what is the right thing to do then when we have a case like the following? > > #if CPU(x86) > ... > #elif CPU(X86_64) > ... > #else // what comment is appropriate here? > #endif // whacomment is appropriate here?
I don't think we have a clear guideline on this. Thinking about it now, I might choose not to use #elif, and instead: #if CPU(X86) #endif // CPU(X86) #if CPU(X86_64) #endif // CPU(X86_64) #if !CPU(X86) && !CPU(X86_64) #endif // !CPU(X86) && !CPU(X86_64) The phrase "else" is hard to decipher when it flows hundred of lines after an "if", possibly with intervening "#elif".
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug