Commit graph

6810 commits

Author SHA1 Message Date
bors-servo
2bc4ffe5cf auto merge of #3744 : cgaebel/servo/efficient-preorder-traversal, r=pcwalton
This also tackles some nearby FIXMEs. `traverse_preorder` is used in a LOT of
DOM functions..

r? @pcwalton
2014-10-21 13:09:38 -06:00
bors-servo
018146b1a8 auto merge of #3728 : cgaebel/servo/dump-flow-tree-with-println, r=mrobinson
r? @mrobinson
2014-10-21 11:27:40 -06:00
Clark Gaebel
a5bb2f299f more efficient preorder DOM traversals 2014-10-21 10:01:15 -07:00
bors-servo
156ca98236 auto merge of #3722 : pcwalton/servo/flow-construction-overhaul, r=glennw
This is a grab bag of performance improvements that significantly improve style recalculation, layout, and painting on a few static pages.

Let me know if you'd like me to split this PR up.

r? @glennw
2014-10-21 10:06:37 -06:00
bors-servo
983d180a43 auto merge of #3754 : Ms2ger/servo/enable-script-tests, r=Manishearth 2014-10-21 06:39:38 -06:00
Ms2ger
7cc8ff93ec Enable Opera's script scheduling tests. 2014-10-21 14:08:19 +02:00
bors-servo
1690a40bf4 auto merge of #3750 : glennw/servo/fix-3703, r=pcwalton
r? @pcwalton @metajack
2014-10-21 02:12:38 -06:00
Patrick Walton
cd42c28f5b gfx: Don't needlessly push and pop clip rects all the time.
15% painting improvement on CNN.
2014-10-20 22:05:38 -07:00
Patrick Walton
79f84a62fe gfx: Make fonts that fail to match hit the cache too.
50%-100% layout perf improvement on CNN.
2014-10-20 22:05:38 -07:00
Patrick Walton
e9a61c1ccf layout: Don't destroy the flow tree when resizing the window 2014-10-20 22:05:38 -07:00
Patrick Walton
bb6f557276 layout: Rewrite text and inline fragment handling during flow
construction to avoid cloning and moving flows so much.

Besides amounting to a 5%-10% win on a page with a lot of text, this
simplifies and refactors the text layout code.
2014-10-20 22:05:38 -07:00
Glenn Watson
cf3d9dffd1 Update rust-core-text, handle empty font collections. Fixes #3703. 2014-10-21 14:54:37 +10:00
bors-servo
d8cb901f6a auto merge of #3745 : glennw/servo/update-cssparser, r=jdm
r? @jdm
2014-10-20 19:00:37 -06:00
Glenn Watson
298fc08e6f Update rust-cssparser to revision required by cssom branch. 2014-10-21 08:53:32 +10:00
bors-servo
f6941b35e3 auto merge of #3715 : cgaebel/servo/fix-table-percentage-width, r=pcwalton
This also enables incremental reflow by default. \o/

r? @pcwalton
2014-10-20 12:54:34 -06:00
Clark Gaebel
174975061e Dump the flow tree with println, instead of error 2014-10-20 11:14:03 -07:00
Clark Gaebel
81bd3cbd9d Fixes the table_percentage_width_a.html reftest with incremental reflow turned on. 2014-10-20 11:13:31 -07:00
bors-servo
852378209b auto merge of #3729 : glennw/servo/opts-cleanup, r=mbrubeck 2014-10-19 21:33:25 -06:00
Glenn Watson
076495db94 Use opts as a global, to avoid cloning and passing the struct all over the code. 2014-10-20 10:48:47 +10:00
bors-servo
a983debaf1 auto merge of #3711 : glennw/servo/cleanup-opts, r=pcwalton
r? @pcwalton @metajack
2014-10-19 18:00:30 -06:00
Glenn Watson
b816550a17 Remove render backend option as it doesn't work and confuses people. 2014-10-20 07:39:36 +10:00
bors-servo
c123f75558 auto merge of #3712 : Ms2ger/servo/parser-crash, r=Manishearth
This was regressed by the html5ever landing.
2014-10-19 06:03:27 -06:00
Ms2ger
b9d8533760 Don't crash on invalid utf-8 in the HTML parser.
This was regressed by the html5ever landing.
2014-10-19 13:18:25 +02:00
bors-servo
65856dd00a auto merge of #3720 : gilles-leblanc/servo/fix-grammatical-errors, r=jdm
This corrects and improves the dom/bindings/DESIGN.md document and also
corrects a grammatical error in a tests/reftest.rs message.
2014-10-18 00:24:25 -06:00
Gilles Leblanc
8b727e3680 Edits dom/bindings/DESIGN.md
This corrects and improves the dom/bindings/DESIGN.md document and also
corrects a grammatical error in a tests/reftest.rs message.
2014-10-17 23:12:58 -04:00
bors-servo
3906cecd16 auto merge of #3719 : mrobinson/servo/flow-dump, r=pcwalton
The flow tree is currently dumped for debugging purposes early on in
the flow process, so many values are still zero. If we wait to dump it
until later, the output will more accurately reflect the real flow tree.
2014-10-17 19:51:24 -06:00
Martin Robinson
e7c79906bd Wait to dump flow tree until flow is complete
The flow tree is currently dumped for debugging purposes early on in
the flow process, so many values are still zero. If we wait to dump it
until later, the output will more accurately reflect the real flow tree.
2014-10-17 18:48:09 -07:00
bors-servo
b86344b697 auto merge of #3706 : cgaebel/servo/fix-image-dynamic-remove, r=pcwalton
This also adds some extra debugging infrastructure which I found useful tracking
this bug down. A regression in the br reftests is also uncovered by this patch,
which I'll work on fixing next.

EDIT: nevermind. no regression, I just tested that before a rebase.

r? @pcwalton
2014-10-17 12:15:23 -06:00
Clark Gaebel
8496c056e7 Fixed the inline_element_border_a reftest with incremental layout turned on. 2014-10-17 11:11:14 -07:00
Clark Gaebel
2faf5b270f Fix image_dynamic_remove reftest with incremental layout turned out
This also adds some extra debugging infrastructure which I found useful tracking
this bug down. A regression in the br reftests is also uncovered by this patch,
which I'll work on fixing next.

r? @pcwalton
2014-10-17 11:11:14 -07:00
bors-servo
a1efb79cf4 auto merge of #3700 : Ms2ger/servo/update-wptrunner, r=jdm 2014-10-17 06:33:19 -06:00
Ms2ger
da50824655 Update wptrunner to pick up crash-detection fixes. 2014-10-17 13:37:23 +02:00
bors-servo
9ee87b9cea auto merge of #3709 : glennw/servo/update-mozjs, r=jdm 2014-10-16 20:24:19 -06:00
bors-servo
de2178bbc0 auto merge of #3710 : gilles-leblanc/servo/issue-3677, r=jdm
...of a boolean

Fixes #3677
2014-10-16 19:45:22 -06:00
Gilles Leblanc
a31849df11 Make HTMLFormElementHelpers::submit take an enumerated argument instead of a boolean
Fixes #3677
2014-10-16 20:57:55 -04:00
Glenn Watson
a63ed9d2a2 Update SHA1 for rust-mozjs. Also update the android Cargo.lock file for recent changes. 2014-10-17 10:30:23 +10:00
bors-servo
6ab8f4611f auto merge of #3705 : mbrubeck/servo/rm-hubbub, r=kmcallister
Unused after #3702. r? @kmcallister
2014-10-16 16:18:19 -06:00
Matt Brubeck
578cb94fa8 Remove old hubbub HTML parsing code 2014-10-16 14:45:30 -07:00
bors-servo
83196ddb26 auto merge of #3697 : pcwalton/servo/get-layout-font-group, r=glennw
Seems to be a 38% layout win on a site I tested with a lot of text.

Other browser engines typically do not duplicate the information in the font style struct. `FontStyle` actually predates @SimonSapin's CSS selector matching library. It's time to get rid of it!

r? @glennw
2014-10-16 15:06:19 -06:00
bors-servo
8d3b107568 auto merge of #3670 : kmcallister/servo/h5e-take2, r=jdm
r? @Ms2ger, @jdm

The parser is now a JS-managed object and we use hooks in html5ever to trace its internal state.  This should be memory-safe even if arbitrary JavaScript can run during a parse.  Please let me know if you think of a reason it wouldn't be!

I think the likely outcome of a garbage collection during parsing is a dynamic `RefCell` borrow failure, but I'm going to look into that after this lands.  It should be safe to trace the parser while it's mutably borrowed, as long as it's not shared between threads, so we can probably switch to `UnsafeCell`.
2014-10-16 14:15:21 -06:00
Keegan McAllister
c9b7d1f8df Add a reftest for #1324
Closes #1324, fixed by html5ever.
2014-10-16 13:06:34 -07:00
Keegan McAllister
9da7679367 Use html5ever for HTML parsing 2014-10-16 13:06:34 -07:00
Keegan McAllister
3fbb25cc43 Update test expectations
The hubbub bindings set document.characterSet but we don't use it for anything.
html5ever doesn't parse charsets from <meta> tags yet, and I'd rather add that
as part of adding actual support for other encodings (which Servo never had
with hubbub).

Switching to html5ever also changes attribute parsing slightly (bringing it in
line with the current spec) and this breaks some of the <img srcset> tests.  We
don't support this feature at all.

Some other things change due to bugs in hubbub not present in html5ever.
2014-10-16 13:06:04 -07:00
bors-servo
5be4f40bef auto merge of #3699 : Ms2ger/servo/jsstring_to_str, r=jdm
This appears to be a more sensible location for them.

Relevant to #433.
2014-10-16 08:45:19 -06:00
bors-servo
b80b18f1cb auto merge of #3698 : ema-fox/servo/remove-monocache, r=jdm 2014-10-16 07:33:21 -06:00
Ms2ger
b60a601f56 Move jsstring_to_str and jsid_to_str to conversions.rs.
This appears to be a more sensible location for them.

Relevant to #433.
2014-10-16 10:42:09 +02:00
Emanuel Rylke
62595ff448 Remove unused implementation of MonoCache 2014-10-16 08:39:51 +02:00
bors-servo
1de2fb3721 auto merge of #3695 : saneyuki/servo/cell, r=jdm
#3050
2014-10-16 00:03:18 -06:00
bors-servo
9af0900060 auto merge of #3684 : Manishearth/servo/dom_struct, r=jdm
This attribute implies #[jstraceable], #[privatize], and #[must_root].
2014-10-15 23:24:20 -06:00
Patrick Walton
a6fcec468f layout: Remove FontStyle in favor of using the font style struct
directly, and optimize `get_layout_font_group()` to use a small vector.

Seems to be a 38% layout win on a site I tested with a lot of text.
2014-10-15 22:17:57 -07:00