Skip to content

Commit 7708975

Browse files
authored
[test] Measure gzip sizes without metadata. NFC (#24612)
Writing to a temporary gzip file, measuring and then deleting is both inefficient, but also results in a slightly larger reported size because it then also writes extra metadata like the original filename. That metadata is not something we care about measuring, as more often than not compression on the Web happens on the fly anyway.
1 parent d8a6db2 commit 7708975

File tree

57 files changed

+94
-99
lines changed

Some content is hidden

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

57 files changed

+94
-99
lines changed
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"a.html": 519,
3-
"a.html.gz": 364,
3+
"a.html.gz": 357,
44
"a.js": 3853,
5-
"a.js.gz": 2050,
5+
"a.js.gz": 2045,
66
"a.wasm": 1288,
7-
"a.wasm.gz": 867,
7+
"a.wasm.gz": 860,
88
"total": 5660,
9-
"total_gz": 3281
9+
"total_gz": 3262
1010
}

test/code_size/embind_hello_wasm.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"a.html": 552,
3-
"a.html.gz": 380,
3+
"a.html.gz": 373,
44
"a.js": 7266,
5-
"a.js.gz": 3321,
5+
"a.js.gz": 3316,
66
"a.wasm": 7294,
7-
"a.wasm.gz": 3346,
7+
"a.wasm.gz": 3339,
88
"total": 15112,
9-
"total_gz": 7047
9+
"total_gz": 7028
1010
}

test/code_size/embind_val_wasm.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"a.html": 552,
3-
"a.html.gz": 380,
3+
"a.html.gz": 373,
44
"a.js": 5367,
5-
"a.js.gz": 2540,
5+
"a.js.gz": 2535,
66
"a.wasm": 7468,
7-
"a.wasm.gz": 3468,
7+
"a.wasm.gz": 3461,
88
"total": 13387,
9-
"total_gz": 6388
9+
"total_gz": 6369
1010
}
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"a.html": 519,
3-
"a.html.gz": 364,
3+
"a.html.gz": 357,
44
"a.js": 830,
5-
"a.js.gz": 530,
5+
"a.js.gz": 525,
66
"a.wasm": 1885,
7-
"a.wasm.gz": 1079,
7+
"a.wasm.gz": 1072,
88
"total": 3234,
9-
"total_gz": 1973
9+
"total_gz": 1954
1010
}

test/code_size/hello_webgl2_wasm.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"a.html": 454,
3-
"a.html.gz": 328,
3+
"a.html.gz": 321,
44
"a.js": 4386,
5-
"a.js.gz": 2252,
5+
"a.js.gz": 2247,
66
"a.wasm": 8278,
7-
"a.wasm.gz": 5627,
7+
"a.wasm.gz": 5620,
88
"total": 13118,
9-
"total_gz": 8207
9+
"total_gz": 8188
1010
}
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
22
"a.html": 346,
3-
"a.html.gz": 262,
3+
"a.html.gz": 255,
44
"a.js": 18103,
5-
"a.js.gz": 9771,
5+
"a.js.gz": 9766,
66
"total": 18449,
7-
"total_gz": 10033
7+
"total_gz": 10021
88
}

test/code_size/hello_webgl_wasm.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"a.html": 454,
3-
"a.html.gz": 328,
3+
"a.html.gz": 321,
44
"a.js": 3924,
5-
"a.js.gz": 2092,
5+
"a.js.gz": 2087,
66
"a.wasm": 8278,
7-
"a.wasm.gz": 5627,
7+
"a.wasm.gz": 5620,
88
"total": 12656,
9-
"total_gz": 8047
9+
"total_gz": 8028
1010
}
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
22
"a.html": 346,
3-
"a.html.gz": 262,
3+
"a.html.gz": 255,
44
"a.js": 17630,
5-
"a.js.gz": 9603,
5+
"a.js.gz": 9598,
66
"total": 17976,
7-
"total_gz": 9865
7+
"total_gz": 9853
88
}

test/code_size/hello_world_wasm.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"a.html": 552,
3-
"a.html.gz": 380,
3+
"a.html.gz": 373,
44
"a.js": 287,
5-
"a.js.gz": 247,
5+
"a.js.gz": 242,
66
"a.wasm": 95,
7-
"a.wasm.gz": 108,
7+
"a.wasm.gz": 101,
88
"total": 934,
9-
"total_gz": 735
9+
"total_gz": 716
1010
}
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
22
"a.html": 323,
3-
"a.html.gz": 253,
3+
"a.html.gz": 246,
44
"a.js": 965,
5-
"a.js.gz": 593,
5+
"a.js.gz": 588,
66
"total": 1288,
7-
"total_gz": 846
7+
"total_gz": 834
88
}

0 commit comments

Comments
 (0)