Bug 130939 - Make RenderStyle's non inherited flags more JSC friendly
Summary: Make RenderStyle's non inherited flags more JSC friendly
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Benjamin Poulain
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-29 22:55 PDT by Benjamin Poulain
Modified: 2014-03-31 11:45 PDT (History)
11 users (show)

See Also:


Attachments
Patch (67.42 KB, patch)
2014-03-29 22:59 PDT, Benjamin Poulain
kling: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Benjamin Poulain 2014-03-29 22:55:49 PDT
Make RenderStyle's non inherited flags more JSC friendly
Comment 1 Benjamin Poulain 2014-03-29 22:59:47 PDT
Created attachment 228120 [details]
Patch
Comment 2 WebKit Commit Bot 2014-03-29 23:02:41 PDT
Attachment 228120 [details] did not pass style-queue:


ERROR: Source/WebCore/rendering/style/RenderStyle.h:471:  noninherited_flags is incorrectly named. Don't use underscores in your identifier names.  [readability/naming/underscores] [4]
Total errors found: 1 in 7 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Andreas Kling 2014-03-30 00:23:52 PDT
Comment on attachment 228120 [details]
Patch

r=me!

Would it be possible to mash the ref count together with the flag bits somehow in the future?
Comment 4 Andreas Kling 2014-03-30 00:24:36 PDT
Comment on attachment 228120 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=228120&action=review

> Source/WebCore/rendering/style/RenderStyle.h:165
> +            // Only a subset i copied because NonInheritedFlags contains a bunch of stuff other than real style data.

i copied -> is copied
Comment 5 Benjamin Poulain 2014-03-30 13:33:36 PDT
Committed r166465: <http://trac.webkit.org/changeset/166465>
Comment 6 Benjamin Poulain 2014-03-30 13:34:51 PDT
(In reply to comment #3)
> (From update of attachment 228120 [details])
> r=me!
> 
> Would it be possible to mash the ref count together with the flag bits somehow in the future?


Looks like there are only 24 bits left in total. A bit short for the ref count.

If we use TBI we can get rid of tons of stuff. The change would be big though :)
Comment 7 Andreas Kling 2014-03-30 13:46:48 PDT
(In reply to comment #6)
> (In reply to comment #3)
> > (From update of attachment 228120 [details] [details])
> > r=me!
> > 
> > Would it be possible to mash the ref count together with the flag bits somehow in the future?
> 
> 
> Looks like there are only 24 bits left in total. A bit short for the ref count.
> 
> If we use TBI we can get rid of tons of stuff. The change would be big though :)

We could also move some of the rarely-used flags to substructures. Anyways, NABD, but something to consider in the future.
Comment 8 Csaba Osztrogonác 2014-03-31 07:51:13 PDT
It broke the Apple Windows debug build.
Comment 9 Brent Fulgham 2014-03-31 11:45:26 PDT
This broke the Windows build, probably because it is 32-bit:

12>c:\projects\webkit\opensource\source\webcore\rendering\style\RenderStyle.cpp(78): error C2338: RenderStyle_should_stay_small (..\rendering\style\StyleAllInOne.cpp)