Title: [282572] branches/safari-612-branch/PerformanceTests
- Revision
- 282572
- Author
- repst...@apple.com
- Date
- 2021-09-16 11:48:20 -0700 (Thu, 16 Sep 2021)
Log Message
Cherry-pick r282111. rdar://problem/83183795
Add a PerformanceTest for some common FontFaceSet style update operations
https://bugs.webkit.org/show_bug.cgi?id=229913
Reviewed by Stephanie Lewis.
This is similar to some of the operations we've seen in the wild.
We want to make sure we can do these fast.
* CSS/FontFaceSetUpdateStyle.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@282111 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Modified Paths
Added Paths
Diff
Added: branches/safari-612-branch/PerformanceTests/CSS/FontFaceSetUpdateStyle.html (0 => 282572)
--- branches/safari-612-branch/PerformanceTests/CSS/FontFaceSetUpdateStyle.html (rev 0)
+++ branches/safari-612-branch/PerformanceTests/CSS/FontFaceSetUpdateStyle.html 2021-09-16 18:48:20 UTC (rev 282572)
@@ -0,0 +1,33 @@
+<!DOCTYPE html>
+<html>
+<head id="head">
+<script src=""
+<style id="style">
+</style>
+</head>
+<body id="body">
+<div id="test"></div>
+</body>
+<script>
+let head = document.getElementById("head");
+let style = document.getElementById("style");
+let body = document.getElementById("body");
+let styleString = "";
+let elementCount = 1000;
+for (let i = 0; i < elementCount; ++i) {
+ let div = document.createElement("div");
+ let id = `div${i}`;
+ div.id = id;
+ body.appendChild(div);
+ styleString = styleString + `#${id} { font-weight: ${i}; }`;
+}
+style.innerText = styleString;
+PerfTestRunner.measureRunsPerSecond({run:function() {
+ style.innerText = `${styleString}`;
+ let fontFace = new FontFace("WebFont", "url('MyCoolWebFont.ttf') format('truetype')");
+ if (!document.fonts.has(fontFace))
+ document.fonts.add(fontFace)
+ document.fonts.clear();
+}});
+</script>
+</html>
Modified: branches/safari-612-branch/PerformanceTests/ChangeLog (282571 => 282572)
--- branches/safari-612-branch/PerformanceTests/ChangeLog 2021-09-16 18:48:18 UTC (rev 282571)
+++ branches/safari-612-branch/PerformanceTests/ChangeLog 2021-09-16 18:48:20 UTC (rev 282572)
@@ -1,3 +1,32 @@
+2021-09-16 Russell Epstein <repst...@apple.com>
+
+ Cherry-pick r282111. rdar://problem/83183795
+
+ Add a PerformanceTest for some common FontFaceSet style update operations
+ https://bugs.webkit.org/show_bug.cgi?id=229913
+
+ Reviewed by Stephanie Lewis.
+
+ This is similar to some of the operations we've seen in the wild.
+ We want to make sure we can do these fast.
+
+ * CSS/FontFaceSetUpdateStyle.html: Added.
+
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@282111 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2021-09-07 Myles C. Maxfield <mmaxfi...@apple.com>
+
+ Add a PerformanceTest for some common FontFaceSet style update operations
+ https://bugs.webkit.org/show_bug.cgi?id=229913
+
+ Reviewed by Stephanie Lewis.
+
+ This is similar to some of the operations we've seen in the wild.
+ We want to make sure we can do these fast.
+
+ * CSS/FontFaceSetUpdateStyle.html: Added.
+
2021-08-06 Michael Catanzaro <mcatanz...@gnome.org>
MallocBench: fix ODR violation
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes