[Webkit-unassigned] [Bug 27511] Add WinCE specific platform/graphics files to WebCore

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Aug 10 07:41:18 PDT 2009


--- Comment #75 from Eric Seidel <eric at webkit.org>  2009-08-10 07:41:16 PDT ---
(In reply to comment #74)
> (In reply to comment #71)
> > (From update of attachment 34398 [details] [details])
> > Neat that you wrote your own Path implementation.  Sad that you had to. :(
> > 
> > We avoid using "default:" when switching enums so that the compiler can catch
> > modifications to that enum/missing case statements:
> > 15     //case PathCloseSubpath:
> >  316     default:
> > 
> Not all ports use same compiler. I've seen some coding rules (not webkit one)
> saying "default:" should always present in a switch block, and like this idea.
> In this case, the compiler won't generate code to compare the value with
> PathCloseSubpath. Condition checks are expensive on ARM. Probably I should add
> ASSERT ( ... == PathCloseSubpath); after "default:". Then that looks perfect.

Sounds like pre-mature optimization to me. :)

The "default:" logic used in WebKit is about trying to catch errors at runtime
instead of compile time.

I don't think it's a big deal either way.  But I don't think optimizing for
some one compiler that you've used at one point in your lifetime is ever good
plan.  This code will be read by many people (hence the style guidelines),
compiled by many different compilers and run on many different CPUs before it's
removed form the WebKit repository. :)  If testing show that this is slow in a
certain configuration then we certainly should change it.  But before then, I
wouldn't worry about the compiler much.  Perf testing is likely to show that we
have much larger fish to fry.

Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

More information about the webkit-unassigned mailing list