Martin Robinson
f5ef8aaed3
config: Remove legacy-layout and unused Preferences
and Opts
( #34994 )
...
There are some preferences and options that are only used by legacy
layout or not used at all. This PR removes them.
Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2025-01-14 20:12:14 +00:00
Delan Azabani
aa7116c75d
Plumb time profiler output into tracing ( #34238 )
...
* Plumb time profiler output into tracing
Signed-off-by: Delan Azabani <dazabani@igalia.com>
* Enter the span tightly around the callback
Signed-off-by: Delan Azabani <dazabani@igalia.com>
* Use `info_span!()` shorthand
Signed-off-by: Delan Azabani <dazabani@igalia.com>
---------
Signed-off-by: Delan Azabani <dazabani@igalia.com>
2024-11-15 09:10:01 +00:00
eri
a6e25d555b
clippy: Fix warnings in components/layout
( #31612 )
...
* clippy: fix warnings in components/layout
* fix: formatting
2024-03-11 10:24:36 +00:00
eri
3a5ca785d3
clippy: fix warnings in various modules in components ( #31568 )
...
* clippy: fix warnings in various modules in components
* fix: unit tests
* fix: build on android
* fix: all samplers use new_boxed
2024-03-08 14:28:04 +00:00
Oriol Brufau
f7ead9bcb6
Lint layout_2013 with clippy ( #31221 )
...
* Lint layout_2013 with clippy
CARGO_BUILD_RUSTC=rustc cargo clippy --fix -p layout_2013 --broken-code
* ./mach fmt
* Cosmetic adjustments
2024-01-30 11:46:35 +00:00
Samson
aad2dccc9c
Strict import formatting (grouping and granularity) ( #30325 )
...
* strict imports formatting
* Reformat all imports
2023-09-11 19:16:54 +00:00
Martin Robinson
dc192172ad
Clean up debug options
2023-05-01 14:09:28 +02:00
Bastien Orivel
28fa0f8009
Update rayon to dedupe crossbeam-epoch
...
As a bonus this also removes one version of crossbeam-utils
2019-07-12 21:01:33 +02:00
Jan Andre Ikenmeyer
1d6fe65401
Update MPL license to https (part 4)
2018-11-19 14:47:27 +01:00
Simon Sapin
9f977c5287
Remove useless use crate_name;
imports.
...
A `crate_name::foo` path always works in 2018
2018-11-08 09:29:52 +01:00
Simon Sapin
2012be4a8b
cargo fix --edition-idioms
2018-11-08 09:28:00 +01:00
Pyfisch
9e92eb205a
Reorder imports
2018-11-06 22:35:07 +01:00
Simon Sapin
76e59a46d3
Sort use
statements
2018-11-06 15:26:02 +01:00
Simon Sapin
45f7199eee
cargo fix --edition
2018-11-06 15:26:02 +01:00
Pyfisch
349047b096
Rustfmt layout crate
2018-09-01 13:24:57 +02:00
Matt Brubeck
c60cfc5a9f
Turn flow::base and friends into methods
2017-12-14 12:16:45 -06:00
Matt Brubeck
ae67eb5fe3
Use raw pointers instead of transmute for UnsafeFlow
2017-10-04 20:00:31 -07:00
Emilio Cobos Álvarez
e3c58df155
style: Remove UnsafeNode.
...
No longer needed since a while ago.
2017-09-25 01:58:52 +02:00
Bobby Holley
707ab455bb
Eliminate the sequential/traversal parallel distinction in favor of a unified adaptive driver.
...
MozReview-Commit-ID: ADVTNJntzmp
2017-08-25 10:00:27 -07:00
Matt Brubeck
832b811198
Change the mis-named 'traverse_flow_tree_preorder' to 'reflow'
2017-08-08 10:53:20 -07:00
Matt Brubeck
ee697a926d
Fix spelling of bottom_up_flow
2017-08-08 10:53:20 -07:00
Matt Brubeck
d1a37f1ea3
Code organization: Move all generic traversal code to layout::traversal
2017-08-08 10:53:19 -07:00
Emilio Cobos Álvarez
1c5d522742
layout: Make -Z show-parallel-layout show something useful again.
2017-07-23 01:47:47 +02:00
Matt Brubeck
7fd1626901
Reduce allocations during parallel layout
2017-06-06 12:34:36 -07:00
Matt Brubeck
ea154d8278
Reduce parallel layout chunk size to 16
2017-06-06 11:50:57 -07:00
Bobby Holley
a182ae46f6
Rewrite parallel.rs to be not slow.
2017-05-21 07:45:39 +02:00
Pu Xingyu
336aa795b4
Remove cached thread local context from LayoutContext
...
Remove cached thread local context from LayoutContext, use LayoutContext for
assign_inline_sizes(), and simplify the parallel flow traversal code.
2017-02-08 08:47:54 +08:00
Bobby Holley
c5f01fe3b8
Introduce and use Scoped TLS.
...
It turns out that it's problematic to embed ThreadLocalStyleContext within
LayoutContext, because parameterizing the former on TElement (which we do
in the next patch) infects all the traversal stuff with the trait parameters,
which we don't really want.
In general, it probably makes sense to use separate scoped TLS types for
the separate DOM and Flow tree passes, so we can add a different ScopedTLS
type for the Flow pass if we ever need it.
We also reorder the |scope| and |shared| parameters in parallel.rs, because
it aligns more with the order in style/parallel.rs. I did this when I was
adding a TLS parameter to all these functions, which I realized we don't need
for now.
2016-12-21 11:10:39 -08:00
Bobby Holley
648ce1e44e
Make the DomTraversalContext own the SharedStyleContext and share it immutably across the traversal.
...
This allows us to get rid of a bunch of lifetimes and simplify a lot of code. It
also lets us get rid of that nasty lifetime transmute, which is awesome.
The situation with thread-local contexts is still suboptimal, but we fix that in
subsequent patches.
2016-12-16 10:57:27 -08:00
Alan Jeffrey
9be4fd56ce
Removed util.
2016-12-14 18:04:37 -06:00
Emilio Cobos Álvarez
73917cce83
style: Use rayon instead of our custom work queue.
2016-11-14 21:24:19 +01:00
UK992
93a103ba73
Reorder use
statements
2016-09-09 04:55:19 +02:00
Ms2ger
fa0e198c8f
Pass a &mut Flow to traverse_flow_tree_preorder.
2016-08-25 09:21:35 +02:00
Anthony Ramine
bf34fdde1f
Move util::workqueue to style
2016-07-04 21:56:09 +02:00
Ms2ger
577c2d2078
Store SharedStyleContext in AssignISizes.
2016-06-22 15:02:06 +02:00
Cullen Rhodes
40acd24e8f
Report use statements that use {} with only one entry
2016-05-27 10:18:44 +01:00
Per Lundberg
2f7ed1d73e
Removed unused imports
...
This fixes #11185 .
2016-05-15 22:24:26 +03:00
malayaleecoder
d4dcaf3167
Rename imm_child_iter() and child_iter(). Fixes #10286
2016-04-09 01:18:00 +05:30
David Bonet
57df260f9d
Removed overflow references on AssignBSizesAndStoreOverflow code
2016-03-17 21:14:50 +01:00
Martin Robinson
630a9d4255
Remove parallel display list construction
...
Parallel display list construction hasn't been shown to give any
performance gains. It is also incompatible with the current flat display
list implementation. Once flat display lists have landed, we can explore
possible benefits of parallel construction once again.
2016-02-19 15:53:12 -08:00
Bobby Holley
29987a6715
Bonus Fix - Rename traverse_dom_preorder to traverse_dom.
...
The incorrect naming here was bugging me - the dom traversal has both pre- and post-order
processing steps.
2016-01-06 19:21:13 -08:00
Bobby Holley
60b3c66b28
Hoist the style parts of parallel.rs into style/.
2016-01-06 19:21:07 -08:00
Bobby Holley
f9a02f0aba
Hoist the style parts of traversal.rs into style/.
2016-01-06 18:50:16 -08:00
Bobby Holley
bf1a7d243f
Remove the dependency of parallel DOM traversal and style calculation on LayoutContext.
2016-01-06 18:24:18 -08:00
Bobby Holley
ebc5eb1b98
Make parallel DOM traversal and style calculation operate on TNode instead of LayoutNode.
2016-01-06 17:58:53 -08:00
Bobby Holley
947134949a
Refactor parallel dom traversal to be agnostic to the processing steps themselves.
2016-01-04 09:38:04 -08:00
Bobby Holley
47059d2d26
Separate style+layout and layout-specific wrapper functionality.
...
This patch does a number of things, unfortunately all at once:
* Hoists a large subset of the layout wrapper functionality into the style system.
* Merges TElementAttributes into the newly-created TElement.
* Reorganizes LayoutData by style vs layout, and removes LayoutDataShared.
* Simplifies the API for borrowing style/layout data.
There's still more to do to make the style system usable standalone, but
this is a good start.
2015-12-29 11:50:03 -08:00
Bobby Holley
cf33f00018
Generalize the rest of layout to operate on generic Layout*.
...
There wasn't a good way to split this up, unfortunately.
With this change, the only remaining usage of the Servo-specific structures is
in layout_task, where the root node is received from the script task. \o/
2015-11-28 18:01:02 -08:00
Bobby Holley
2f6e94943a
Rename Layout*Trait to Layout*.
...
The next step will be to remote the Servo-specificity of the layout code we want
to share by making it operate generically on Layout*.
2015-11-18 17:24:36 -08:00
Bobby Holley
9dd45b9f2a
Prefix concrete types with 'Servo'.
2015-11-18 17:23:46 -08:00