aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/performance.rs
Commit message (Collapse)AuthorAgeFilesLines
* Strict import formatting (grouping and granularity) (#30325)Samson2023-09-111-7/+8
| | | | | * strict imports formatting * Reformat all imports
* Add trait DomObjectWrap to provide WRAP functionYUAN LYU2020-03-201-2/+0
|
* Auto merge of #25590 - pshaughn:perfobs, r=jdmbors-servo2020-02-121-20/+45
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make performance observers take "type" and "buffered" options without panicking. <!-- Please describe your changes on the following line: --> I updated the observe() method to align with spec, and fixed the borrow duration bug @jdm pointed out in #25589 so it wouldn't cause a hard crash. Some tests go from failing to passing, but others go from early failing to later timeout; performance observers still aren't doing the right thing in all cases. --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: --> - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #24781 and fix #25589 and fix #23225 <!-- Either: --> - [X] There are tests for these changes <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
| * w3c/performance-timeline#159Patrick Shaughnessy2020-01-291-10/+5
| |
| * Performance observers better, not perfectPatrick Shaughnessy2020-01-271-20/+50
| |
* | Expose DOMHighResTimeStamps at lower resPatrick Shaughnessy2020-02-031-2/+13
|/
* #23330 fix clear_entries_by_name_and_type bugShinichi Morimoto2019-12-131-2/+2
|
* #24468 add a update_entry method to PerformanceShinichi Morimoto2019-12-131-0/+6
|
* #24468 Performance::queue_entries return the index of the added performance ↵Shinichi Morimoto2019-12-131-20/+15
| | | | entry
* performance: clear and disable buffer on pipeline exitGregory Terzian2019-09-041-13/+27
| | | | use existing buffer max size
* Implement PerformanceNavigation interfaceIulian Gabriel Radu2019-06-261-0/+6
|
* Implement performance interface extension for PerformanceResourceTimingadit2019-01-091-0/+96
|
* Rustfmt has changed its default style :/Simon Sapin2018-12-281-6/+8
|
* refactored performance timing to align with updated specddh2018-11-201-39/+25
| | | | | | | | | | | | refactoring with ResourceFetchMetadata implemented deprecated window.timing functionality created ResourceTimingListener trait fixed w3c links in navigation timing updated include.ini to run resource timing tests on ci
* Update MPL license to https (part 3)Jan Andre Ikenmeyer2018-11-191-1/+1
|
* Remove useless `use crate_name;` imports.Simon Sapin2018-11-081-1/+0
| | | | A `crate_name::foo` path always works in 2018
* Reorder importsPyfisch2018-11-061-2/+4
|
* Format remaining filesPyfisch2018-11-061-2/+4
|
* `cargo fix --edition`Simon Sapin2018-11-061-17/+17
|
* Format script componentchansuke2018-09-191-83/+145
|
* Do not fire pending callbacks on disconnected performance observerFernando Jiménez Moreno2018-01-151-8/+0
|
* Fix float conversion of paint timing metricsFernando Jiménez Moreno2017-12-071-1/+2
|
* changed f64 to u64 for navigation start timing until it had to be floatddh2017-11-011-4/+4
|
* Replace all uses of the `heapsize` crate with `malloc_size_of`.Nicholas Nethercote2017-10-181-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Servo currently uses `heapsize`, but Stylo/Gecko use `malloc_size_of`. `malloc_size_of` is better -- it handles various cases that `heapsize` does not -- so this patch changes Servo to use `malloc_size_of`. This patch makes the following changes to the `malloc_size_of` crate. - Adds `MallocSizeOf` trait implementations for numerous types, some built-in (e.g. `VecDeque`), some external and Servo-only (e.g. `string_cache`). - Makes `enclosing_size_of_op` optional, because vanilla jemalloc doesn't support that operation. - For `HashSet`/`HashMap`, falls back to a computed estimate when `enclosing_size_of_op` isn't available. - Adds an extern "C" `malloc_size_of` function that does the actual heap measurement; this is based on the same functions from the `heapsize` crate. This patch makes the following changes elsewhere. - Converts all the uses of `heapsize` to instead use `malloc_size_of`. - Disables the "heapsize"/"heap_size" feature for the external crates that provide it. - Removes the `HeapSizeOf` implementation from `hashglobe`. - Adds `ignore` annotations to a few `Rc`/`Arc`, because `malloc_size_of` doesn't derive those types, unlike `heapsize`.
* Fix commonmark Markdown warnings in docs, part 1Matt Brubeck2017-10-171-2/+2
| | | | | | | | Fixes warnings from rust-lang/rust#44229 when `--enable-commonmark` is passed to rustdoc. This is mostly a global find-and-replace for bare URIs on lines by themselves in doc comments.
* Remove use of unstable box syntax.Simon Sapin2017-10-161-5/+5
| | | | | | | | | | | | | | | | | | | | http://www.robohornet.org gives a score of 101.36 on master, and 102.68 with this PR. The latter is slightly better, but probably within noise level. So it looks like this PR does not affect DOM performance. This is expected since `Box::new` is defined as: ```rust impl<T> Box<T> { #[inline(always)] pub fn new(x: T) -> Box<T> { box x } } ``` With inlining, it should compile to the same as box syntax.
* Rename Root<T> to DomRoot<T>Anthony Ramine2017-09-261-15/+15
| | | | | | | In a later PR, DomRoot<T> will become a type alias of Root<Dom<T>>, where Root<T> will be able to handle all the things that need to be rooted that have a stable traceable address that doesn't move for the whole lifetime of the root. Stay tuned.
* Rename DOMRefCell<T> to DomRefCell<T>Anthony Ramine2017-09-261-5/+5
| | | | | | | | I don't want to do such a gratuitous rename, but with all the other types now having "Dom" as part of their name, and especially with "DomOnceCell", I feel like the other cell type that we already have should also follow the convention. That argument loses weight though when we realise there is still DOMString and other things.
* Rename JS<T> to Dom<T>Anthony Ramine2017-09-261-3/+3
|
* Rename dom::bindings::js to dom::bindings::rootAnthony Ramine2017-09-261-1/+1
|
* Auto merge of #18372 - tigercosmos:userTimingApi, r=ferjmbors-servo2017-09-111-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TEST: fix and add case of po-observe.any.js <!-- Please describe your changes on the following line: --> 1. implementing step 3 from the [`PerformanceObserver.observe()`](https://w3c.github.io/performance-timeline/#dom-performanceobserver-observe()) method spec properly. 2. also add cases about step 1 & 2 work on the top of #18283 r? @ferjm --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: --> - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #18285 (github issue number if applicable). <!-- Either: --> - [ ] There are tests for these changes OR - [ ] These changes do not require tests because _____ <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. --> <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/18372) <!-- Reviewable:end -->
| * fix observer comparing and testtigercosmos2017-09-091-1/+1
| |
* | Observer receives pending marks before removedP. Albrecht2017-09-081-0/+9
|/
* User Timing APIFernando Jiménez Moreno2017-09-061-9/+123
|
* Make Performance Timeline API work in WorkersFernando Jiménez Moreno2017-09-051-36/+27
|
* move name implementation as default implementation to the trait and remove ↵toidiu2017-09-031-2/+0
| | | | overrides.
* Use `Filter buffer by name and type` algorithm implementation (fixes #18186)Raphaël Lustin2017-08-281-21/+3
|
* implement PerformanceObserverInit.buffered (fixes #18108)Remi THEBAULT2017-08-241-1/+22
|
* Performance Timeline APIFernando Jiménez Moreno2017-08-171-3/+194
|
* Make #[dom_struct] a proc_macro attributeAnthony Ramine2017-02-241-0/+1
|
* Make reflect_dom_object take a &GlobalScopeAnthony Ramine2016-10-061-2/+1
|
* Most of the code refactoring needed to be done is done with this commit.Arthur Marble2016-09-181-2/+2
|
* Remove JS::from_rootedAnthony Ramine2016-05-311-1/+1
|
* merge from masterrohan.prinja2015-11-031-1/+1
|\
| * Removed JS::root Fixes #8251nxnfufunezn2015-10-311-1/+1
| |
* | more refactoringrohan.prinja2015-10-301-1/+1
|/
* Do not root Performance::timingAnthony Ramine2015-10-191-1/+1
|
* Make the traits for the IDL interfaces take &selfAnthony Ramine2015-08-271-3/+3
|
* Remove helper traitsAnthony Ramine2015-08-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that JSRef<T> is gone, there is no need to have helper traits. On components/script/*.rs: # Remove imports. /^ *use dom::[a-z]+::\{.*Helpers/ { s/\{(Raw[^L]|[^L][^a])[a-zA-Z]+Helpers, /\{/ s/, (Raw[^L]|[^L][^a])[a-zA-Z]+Helpers([,}])/\2/g s/\{([a-zA-Z]+)\}/\1/ /\{\}/d s/::self;$/;/ } /^ *use dom::[a-z]+::\{?(Raw[^L]|[^L][^a])[a-zA-Z]+Helpers\}?;$/d On components/script/dom/*.rs: # Ignore layout things. /^(pub )?(impl|trait).*Layout.* \{/,/^}$/ { P; D; } # Delete helpers traits. /^(pub )?trait ([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? \{$/,/^\}$/D # Patch private helpers. /^impl.*Private.*Helpers/,/^\}$/ { s/^impl<'a> Private([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? for &'a ([^ ]+) \{$/impl \3 {/ /^ *(unsafe )?fn .*\(self.*[<&]'a/ { s/&'a /\&/g s/<'a, /</g } /^ *(unsafe )?fn /s/\(self([,)])/\(\&self\1/ } # Patch public helpers. /^impl.*Helpers/,/^\}$/ { s/^impl(<'a>)? ([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? for (&'a )?([^ ]+) \{$/impl \5 {/ /^ *(unsafe )?fn .*\(self.*[<&]'a/ { s/&'a /\&/g s/<'a, /</g } /^ *(unsafe )?fn .*\(&?self[,)]/s/(unsafe )?fn/pub &/ /^ *pub (unsafe )?fn /s/\(self([,)])/\(\&self\1/ } The few error cases were then fixed by hand.
* make dom_struct derive HeapSizeOf,João Oliveira2015-08-271-2/+0
| | | | closes #7357