Skip to content

Commit cc5e0bd

Browse files
committed
Merge remote-tracking branch 'upstream/main'
2 parents 9b9cfbc + 06433d3 commit cc5e0bd

File tree

445 files changed

+154356
-7508
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

445 files changed

+154356
-7508
lines changed

JSTests/microbenchmarks/for-of-vs-for-each-hole.js

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//@ $skipModes << :lockdown
22
"use strict"
3+
const DEBUG = false;
34
const consoleStub = console || {
45
log: print
56
}
@@ -94,11 +95,15 @@ for (let i = 0; i < warmup; i++) {
9495
}
9596
run = 1_000_000
9697

97-
console.log("Warmup complete")
98+
globalThis.log = function (v) { };
99+
if (DEBUG)
100+
log = console.log.bind(console);
101+
102+
log("Warmup complete")
98103

99104
let [resultsTotal, resultsFor, resultsForOf, resultsForEach] = runTest()
100105

101-
console.log("Total:", resultsTotal)
102-
console.log("For:", resultsFor)
103-
console.log("ForOf:", resultsForOf)
104-
console.log("ForEach:", resultsForEach)
106+
log("Total:", resultsTotal)
107+
log("For:", resultsFor)
108+
log("ForOf:", resultsForOf)
109+
log("ForEach:", resultsForEach)

JSTests/stress/map-getOrInsert.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
//@ requireOptions("--useMapGetOrInsert=1")
2-
31
function assert(a, text) {
42
if (!a)
53
throw new Error(`Failed assertion: ${text}`);

JSTests/stress/map-getOrInsertComputed.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
//@ requireOptions("--useMapGetOrInsert=1")
2-
31
function assert(a, text) {
42
if (!a)
53
throw new Error(`Failed assertion: ${text}`);

JSTests/stress/test-getOrInsert-selfmodify.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
//@ requireOptions("--useMapGetOrInsert=1")
2-
31
let map = new Map();
42
for (let i = 0; i < 100; ++i) {
53
map.set("a" + i, 1);

JSTests/stress/weakmap-getOrInsert.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
//@ requireOptions("--useMapGetOrInsert=1")
2-
31
function assert(a, text) {
42
if (!a)
53
throw new Error(`Failed assertion: ${text}`);

JSTests/stress/weakmap-getOrInsertComputed.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
//@ requireOptions("--useMapGetOrInsert=1")
2-
31
function assert(a, text) {
42
if (!a)
53
throw new Error(`Failed assertion: ${text}`);

JSTests/test262/config.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ flags:
99
json-parse-with-source: useJSONSourceTextAccess
1010
iterator-sequencing: useIteratorSequencing
1111
explicit-resource-management: useExplicitResourceManagement
12-
upsert: useMapGetOrInsert
1312
skip:
1413
features:
1514
- callable-boundary-realms

LayoutTests/compositing/animation/layer-for-filling-animation.html

Lines changed: 14 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -13,32 +13,26 @@
1313
}
1414

1515
.animating {
16-
-webkit-animation: spin 1 0.1s forwards;
16+
animation: spin 1 0.1s forwards;
1717
}
1818

19-
@-webkit-keyframes spin {
20-
from { -webkit-transform: rotate(0); }
21-
to { -webkit-transform: rotate(3deg); }
19+
@keyframes spin {
20+
from { transform: rotate(0); }
21+
to { transform: rotate(3deg); }
2222
}
2323
</style>
24+
<script src="../../webanimations/threaded-animations/threaded-animations-utils.js"></script>
2425
<script>
25-
if (window.testRunner) {
26-
testRunner.dumpAsText();
27-
testRunner.waitUntilDone();
28-
}
26+
window.testRunner?.dumpAsText();
27+
window.testRunner?.waitUntilDone();
2928

30-
function doTest()
31-
{
32-
document.getElementById('box').addEventListener('webkitAnimationEnd', function() {
33-
requestAnimationFrame(() => {
34-
if (window.testRunner) {
35-
document.getElementById('results').innerText = window.internals.layerTreeAsText(document);
36-
testRunner.notifyDone();
37-
}
38-
});
39-
})
40-
}
41-
window.addEventListener('load', doTest, false);
29+
window.addEventListener('load', async () => {
30+
const animation = document.getElementById('box').getAnimations()[0];
31+
await animation.finished;
32+
await threadedAnimationsCommit();
33+
document.getElementById('results').innerText = window.internals?.layerTreeAsText(document);
34+
window.testRunner?.notifyDone();
35+
});
4236
</script>
4337
</head>
4438
<body>

LayoutTests/compositing/backing/animate-into-view-with-descendant.html

Lines changed: 14 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -43,19 +43,6 @@
4343
100% { transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1); }
4444
}
4545
</style>
46-
<script>
47-
if (window.testRunner) {
48-
testRunner.dumpAsText();
49-
testRunner.waitUntilDone();
50-
}
51-
52-
function dumpLayers()
53-
{
54-
var layersResult = document.getElementById('layers');
55-
if (window.testRunner)
56-
layersResult.innerText = window.internals.layerTreeAsText(document, internals.LAYER_TREE_INCLUDES_BACKING_STORE_ATTACHED);
57-
}
58-
</script>
5946
</head>
6047
<body>
6148

@@ -67,15 +54,21 @@
6754

6855
<pre id="layers">Layer tree goes here in DRT</pre>
6956

57+
<script src="../../webanimations/threaded-animations/threaded-animations-utils.js"></script>
7058
<script>
71-
let animator = document.getElementById('target');
72-
animator.addEventListener('animationstart', () => {
73-
requestAnimationFrame(() => {
74-
dumpLayers();
75-
if (window.testRunner)
76-
testRunner.notifyDone();
77-
});
78-
});
59+
60+
(async function () {
61+
window.testRunner?.dumpAsText();
62+
window.testRunner?.waitUntilDone();
63+
64+
const animation = document.getElementById('target').getAnimations()[0];
65+
await animationAcceleration(animation);
66+
67+
document.getElementById('layers').innerText = window.internals?.layerTreeAsText(document, window.internals?.LAYER_TREE_INCLUDES_BACKING_STORE_ATTACHED);
68+
69+
window.testRunner?.notifyDone();
70+
})();
71+
7972
</script>
8073
</body>
8174
</html>

LayoutTests/compositing/backing/animate-into-view.html

Lines changed: 19 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -46,31 +46,6 @@
4646
100% { transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1); }
4747
}
4848
</style>
49-
<script>
50-
if (window.testRunner) {
51-
testRunner.dumpAsText();
52-
testRunner.waitUntilDone();
53-
}
54-
55-
function dumpLayers()
56-
{
57-
var layersResult = document.getElementById('layers');
58-
if (window.testRunner)
59-
layersResult.innerText = window.internals.layerTreeAsText(document, internals.LAYER_TREE_INCLUDES_BACKING_STORE_ATTACHED);
60-
}
61-
62-
window.addEventListener('load', () => {
63-
let animator = document.getElementById('target');
64-
animator.addEventListener('animationstart', () => {
65-
requestAnimationFrame(() => {
66-
dumpLayers();
67-
if (window.testRunner)
68-
testRunner.notifyDone();
69-
});
70-
});
71-
animator.classList.add('animating');
72-
}, false);
73-
</script>
7449
</head>
7550
<body>
7651

@@ -82,5 +57,24 @@
8257

8358
<pre id="layers">Layer tree goes here in DRT</pre>
8459

60+
<script src="../../webanimations/threaded-animations/threaded-animations-utils.js"></script>
61+
<script>
62+
63+
(async function () {
64+
window.testRunner?.dumpAsText();
65+
window.testRunner?.waitUntilDone();
66+
67+
const target = document.getElementById('target');
68+
target.classList.add('animating');
69+
const animation = target.getAnimations()[0];
70+
await animationAcceleration(animation);
71+
72+
document.getElementById('layers').innerText = window.internals?.layerTreeAsText(document, window.internals?.LAYER_TREE_INCLUDES_BACKING_STORE_ATTACHED);
73+
74+
window.testRunner?.notifyDone();
75+
})();
76+
77+
</script>
78+
8579
</body>
8680
</html>

0 commit comments

Comments
 (0)