Skip to content

Commit

Permalink
perf(es/lexer): Do not use memchr::memmem in parser (#9118)
Browse files Browse the repository at this point in the history
Reverts #9096.
I'm reverting this as this regressed performance in `linux-x86_64`.
  • Loading branch information
kdy1 authored Jul 1, 2024
1 parent 226617e commit 72021de
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 23 deletions.
1 change: 0 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion crates/swc_ecma_parser/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ verify = ["swc_ecma_visit"]

[dependencies]
either = { workspace = true }
memchr = { workspace = true, features = ["use_std"] }
num-bigint = { workspace = true }
num-traits = { workspace = true }
serde = { workspace = true, features = ["derive"] }
Expand Down
46 changes: 25 additions & 21 deletions crates/swc_ecma_parser/src/lexer/util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
//! [babylon/util/identifier.js]:https://github.com/babel/babel/blob/master/packages/babylon/src/util/identifier.js
use std::char;

use ::memchr::memmem;
use swc_common::{
comments::{Comment, CommentKind},
BytePos, Span, SyntaxContext,
Expand Down Expand Up @@ -261,36 +260,41 @@ impl<'a> Lexer<'a> {

// jsdoc
let slice_start = self.cur_pos();
let mut was_star = if self.input.is_byte(b'*') {
self.bump();
true
} else {
false
};

let mut is_for_next = self.state.had_line_break || !self.state.can_have_trailing_comment();

if let Some(idx) = memmem::find(self.input.as_str().as_bytes(), b"*/") {
if !self.state.had_line_break {
self.state.had_line_break = self.input.as_str()[0..idx]
.chars()
.any(|c| c.is_line_terminator());
}

self.input.bump_bytes(idx + 2);
let end = self.cur_pos();
while let Some(c) = self.cur() {
if was_star && c == '/' {
debug_assert_eq!(self.cur(), Some('/'));
self.bump(); // '/'

self.skip_space::<false>();
let end = self.cur_pos();

if self.input.is_byte(b';') {
is_for_next = false;
}
self.skip_space::<false>();

self.store_comment(is_for_next, start, end, slice_start);
if self.input.is_byte(b';') {
is_for_next = false;
}

return;
}
self.store_comment(is_for_next, start, end, slice_start);

let len = self.input.as_str().bytes().len();
self.input.bump_bytes(len);
return;
}
if c.is_line_terminator() {
self.state.had_line_break = true;
}

let span = self.span(start);
was_star = c == '*';
self.bump();
}

self.emit_error_span(span, SyntaxError::UnterminatedBlockComment)
self.emit_error(start, SyntaxError::UnterminatedBlockComment)
}

#[inline(never)]
Expand Down

2 comments on commit 72021de

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark

Benchmark suite Current: 72021de Previous: 18d6277 Ratio
es/full/bugs-1 272335 ns/iter (± 2727) 274740 ns/iter (± 8567) 0.99
es/full/minify/libraries/antd 1724835960 ns/iter (± 58060489) 1948297984 ns/iter (± 33267501) 0.89
es/full/minify/libraries/d3 340045412 ns/iter (± 870659) 384738228 ns/iter (± 13589212) 0.88
es/full/minify/libraries/echarts 1435851206 ns/iter (± 12040633) 1639546636 ns/iter (± 28497956) 0.88
es/full/minify/libraries/jquery 102815548 ns/iter (± 220552) 105395923 ns/iter (± 660487) 0.98
es/full/minify/libraries/lodash 113749511 ns/iter (± 243817) 115909767 ns/iter (± 493973) 0.98
es/full/minify/libraries/moment 59522593 ns/iter (± 85565) 60702174 ns/iter (± 476059) 0.98
es/full/minify/libraries/react 18336958 ns/iter (± 29028) 18615965 ns/iter (± 41358) 0.99
es/full/minify/libraries/terser 272388301 ns/iter (± 930541) 286995454 ns/iter (± 3836126) 0.95
es/full/minify/libraries/three 462083117 ns/iter (± 2270938) 507712694 ns/iter (± 21354769) 0.91
es/full/minify/libraries/typescript 3202671056 ns/iter (± 22731960) 3419915940 ns/iter (± 32964641) 0.94
es/full/minify/libraries/victory 719319124 ns/iter (± 6809019) 826069187 ns/iter (± 25635564) 0.87
es/full/minify/libraries/vue 144947049 ns/iter (± 1063717) 148922429 ns/iter (± 793042) 0.97
es/full/codegen/es3 58755 ns/iter (± 206) 59605 ns/iter (± 105) 0.99
es/full/codegen/es5 58745 ns/iter (± 225) 59983 ns/iter (± 1690) 0.98
es/full/codegen/es2015 58466 ns/iter (± 197) 59522 ns/iter (± 166) 0.98
es/full/codegen/es2016 58735 ns/iter (± 253) 59645 ns/iter (± 144) 0.98
es/full/codegen/es2017 58744 ns/iter (± 156) 59972 ns/iter (± 254) 0.98
es/full/codegen/es2018 58363 ns/iter (± 176) 59618 ns/iter (± 100) 0.98
es/full/codegen/es2019 58508 ns/iter (± 162) 59763 ns/iter (± 1062) 0.98
es/full/codegen/es2020 58705 ns/iter (± 151) 59546 ns/iter (± 1178) 0.99
es/full/all/es3 163424759 ns/iter (± 1005045) 159553812 ns/iter (± 905569) 1.02
es/full/all/es5 158426007 ns/iter (± 1493677) 153043409 ns/iter (± 723650) 1.04
es/full/all/es2015 117604551 ns/iter (± 984880) 112861039 ns/iter (± 609274) 1.04
es/full/all/es2016 116202382 ns/iter (± 946912) 111768427 ns/iter (± 1034658) 1.04
es/full/all/es2017 115740294 ns/iter (± 770813) 112165530 ns/iter (± 1081088) 1.03
es/full/all/es2018 113406523 ns/iter (± 1039223) 109805908 ns/iter (± 634892) 1.03
es/full/all/es2019 113354168 ns/iter (± 670419) 108902441 ns/iter (± 780108) 1.04
es/full/all/es2020 109095980 ns/iter (± 688540) 104683768 ns/iter (± 559821) 1.04
es/full/parser 474232 ns/iter (± 2698) 436866 ns/iter (± 1935) 1.09
es/full/base/fixer 15136 ns/iter (± 55) 17283 ns/iter (± 824) 0.88
es/full/base/resolver_and_hygiene 80537 ns/iter (± 229) 81889 ns/iter (± 242) 0.98
serialization of serde 277 ns/iter (± 0) 270 ns/iter (± 5) 1.03
css/minify/libraries/bootstrap 22951827 ns/iter (± 183071) 21990984 ns/iter (± 131861) 1.04
css/visitor/compare/clone 1356283 ns/iter (± 10300) 1371283 ns/iter (± 12823) 0.99
css/visitor/compare/visit_mut_span 1497859 ns/iter (± 6560) 1478290 ns/iter (± 6105) 1.01
css/visitor/compare/visit_mut_span_panic 1487081 ns/iter (± 27306) 1510477 ns/iter (± 16035) 0.98
css/visitor/compare/fold_span 1995532 ns/iter (± 7308) 2003608 ns/iter (± 10308) 1.00
css/visitor/compare/fold_span_panic 2131429 ns/iter (± 6420) 2145437 ns/iter (± 6830) 0.99
css/lexer/bootstrap_5_1_3 3522443 ns/iter (± 7434) 3458837 ns/iter (± 12978) 1.02
css/lexer/foundation_6_7_4 2832742 ns/iter (± 3005) 2790187 ns/iter (± 4442) 1.02
css/lexer/tailwind_3_1_1 543945 ns/iter (± 656) 537061 ns/iter (± 521) 1.01
css/parser/bootstrap_5_1_3 16064470 ns/iter (± 22162) 16137376 ns/iter (± 98003) 1.00
css/parser/foundation_6_7_4 12816874 ns/iter (± 17701) 12988299 ns/iter (± 63968) 0.99
css/parser/tailwind_3_1_1 2542378 ns/iter (± 12042) 2543914 ns/iter (± 7843) 1.00
es/codegen/colors 728033 ns/iter (± 396832) 735510 ns/iter (± 403388) 0.99
es/codegen/large 2951631 ns/iter (± 1589634) 2989078 ns/iter (± 1584256) 0.99
es/codegen/with-parser/colors 41569 ns/iter (± 341) 39447 ns/iter (± 276) 1.05
es/codegen/with-parser/large 451960 ns/iter (± 8704) 454670 ns/iter (± 4369) 0.99
es/minify/libraries/antd 1385792162 ns/iter (± 31216808) 1448232247 ns/iter (± 24687433) 0.96
es/minify/libraries/d3 279026617 ns/iter (± 5042436) 287371487 ns/iter (± 7836728) 0.97
es/minify/libraries/echarts 1126090911 ns/iter (± 6274531) 1191837645 ns/iter (± 14943779) 0.94
es/minify/libraries/jquery 82258672 ns/iter (± 377962) 82932976 ns/iter (± 162882) 0.99
es/minify/libraries/lodash 104162208 ns/iter (± 596914) 104399876 ns/iter (± 611631) 1.00
es/minify/libraries/moment 48195233 ns/iter (± 810318) 48245432 ns/iter (± 109828) 1.00
es/minify/libraries/react 16245445 ns/iter (± 37969) 16315928 ns/iter (± 77910) 1.00
es/minify/libraries/terser 215329352 ns/iter (± 793154) 219701700 ns/iter (± 1591565) 0.98
es/minify/libraries/three 356934503 ns/iter (± 1487228) 368266889 ns/iter (± 7037697) 0.97
es/minify/libraries/typescript 2658798345 ns/iter (± 19130704) 2767943228 ns/iter (± 22357250) 0.96
es/minify/libraries/victory 552631217 ns/iter (± 3199814) 601433534 ns/iter (± 10630027) 0.92
es/minify/libraries/vue 120792962 ns/iter (± 884874) 121631023 ns/iter (± 459248) 0.99
es/visitor/compare/clone 1708421 ns/iter (± 4013) 1710043 ns/iter (± 18132) 1.00
es/visitor/compare/visit_mut_span 2053725 ns/iter (± 14644) 2045916 ns/iter (± 20932) 1.00
es/visitor/compare/visit_mut_span_panic 2058175 ns/iter (± 28870) 2056342 ns/iter (± 32630) 1.00
es/visitor/compare/fold_span 2760493 ns/iter (± 9680) 2756945 ns/iter (± 16628) 1.00
es/visitor/compare/fold_span_panic 2802428 ns/iter (± 4424) 2799645 ns/iter (± 6798) 1.00
es/lexer/colors 9311 ns/iter (± 57) 8898 ns/iter (± 70) 1.05
es/lexer/angular 4968964 ns/iter (± 28920) 4186576 ns/iter (± 5146) 1.19
es/lexer/backbone 653376 ns/iter (± 4309) 634084 ns/iter (± 1125) 1.03
es/lexer/jquery 3597779 ns/iter (± 14281) 3577237 ns/iter (± 10068) 1.01
es/lexer/jquery mobile 5450195 ns/iter (± 51567) 5266734 ns/iter (± 14817) 1.03
es/lexer/mootools 2913494 ns/iter (± 4935) 2807805 ns/iter (± 5367) 1.04
es/lexer/underscore 522349 ns/iter (± 1922) 532429 ns/iter (± 1478) 0.98
es/lexer/three 15933031 ns/iter (± 21242) 16131636 ns/iter (± 45210) 0.99
es/lexer/yui 2906602 ns/iter (± 12942) 2775643 ns/iter (± 37225) 1.05
es/lexer/cal-com 13021787 ns/iter (± 47142) 13385284 ns/iter (± 98489) 0.97
es/lexer/typescript 90834042 ns/iter (± 405864) 103756650 ns/iter (± 647125) 0.88
es/parser/colors 23479 ns/iter (± 118) 22605 ns/iter (± 111) 1.04
es/parser/angular 12483878 ns/iter (± 61579) 11655483 ns/iter (± 68557) 1.07
es/parser/backbone 1821928 ns/iter (± 8396) 1804203 ns/iter (± 17655) 1.01
es/parser/jquery 10110040 ns/iter (± 60625) 10055616 ns/iter (± 53488) 1.01
es/parser/jquery mobile 15176476 ns/iter (± 98173) 15112127 ns/iter (± 116665) 1.00
es/parser/mootools 7864687 ns/iter (± 16477) 7802864 ns/iter (± 10720) 1.01
es/parser/underscore 1585310 ns/iter (± 6217) 1576190 ns/iter (± 6259) 1.01
es/parser/three 43598313 ns/iter (± 307769) 43014491 ns/iter (± 234644) 1.01
es/parser/yui 7414818 ns/iter (± 43494) 7189589 ns/iter (± 34439) 1.03
es/parser/cal-com 39618934 ns/iter (± 171637) 38652414 ns/iter (± 182698) 1.03
es/parser/typescript 267337264 ns/iter (± 564503) 265000460 ns/iter (± 800091) 1.01
es/preset-env/usage/builtin_type 135236 ns/iter (± 34725) 136319 ns/iter (± 34714) 0.99
es/preset-env/usage/property 15657 ns/iter (± 42) 16083 ns/iter (± 80) 0.97
es/resolver/typescript 99957613 ns/iter (± 2883052) 103553980 ns/iter (± 2976955) 0.97
es/fixer/typescript 81017386 ns/iter (± 2302792) 79832907 ns/iter (± 2574057) 1.01
es/hygiene/typescript 183885913 ns/iter (± 6513705) 190303783 ns/iter (± 2795659) 0.97
es/resolver_with_hygiene/typescript 300836345 ns/iter (± 2682568) 325451363 ns/iter (± 7879877) 0.92
es/visitor/base-perf/module_clone 57427 ns/iter (± 701) 57881 ns/iter (± 1219) 0.99
es/visitor/base-perf/fold_empty 61126 ns/iter (± 600) 60973 ns/iter (± 364) 1.00
es/visitor/base-perf/fold_noop_impl_all 60788 ns/iter (± 883) 61056 ns/iter (± 1478) 1.00
es/visitor/base-perf/fold_noop_impl_vec 60928 ns/iter (± 400) 61111 ns/iter (± 262) 1.00
es/visitor/base-perf/boxing_boxed_clone 59 ns/iter (± 0) 60 ns/iter (± 0) 0.98
es/visitor/base-perf/boxing_unboxed_clone 47 ns/iter (± 0) 47 ns/iter (± 0) 1
es/visitor/base-perf/boxing_boxed 108 ns/iter (± 0) 106 ns/iter (± 0) 1.02
es/visitor/base-perf/boxing_unboxed 80 ns/iter (± 0) 82 ns/iter (± 0) 0.98
es/visitor/base-perf/visit_contains_this 2586 ns/iter (± 28) 2739 ns/iter (± 11) 0.94
es/base/parallel/resolver/typescript 2491978804 ns/iter (± 100610535) 2545495557 ns/iter (± 218623266) 0.98
es/base/parallel/hygiene/typescript 3179590068 ns/iter (± 39557995) 3283963704 ns/iter (± 69321561) 0.97
babelify-only 496542 ns/iter (± 5838) 492618 ns/iter (± 5560) 1.01
parse_and_babelify_angular 39699833 ns/iter (± 2232737) 44727452 ns/iter (± 657754) 0.89
parse_and_babelify_backbone 4378453 ns/iter (± 155597) 4385044 ns/iter (± 45874) 1.00
parse_and_babelify_jquery 28518290 ns/iter (± 498358) 29300559 ns/iter (± 393196) 0.97
parse_and_babelify_jquery_mobile 51413647 ns/iter (± 826484) 51752659 ns/iter (± 649453) 0.99
parse_and_babelify_mootools 26185116 ns/iter (± 706007) 27044816 ns/iter (± 251025) 0.97
parse_and_babelify_underscore 3690196 ns/iter (± 19737) 3653977 ns/iter (± 28305) 1.01
parse_and_babelify_yui 23928254 ns/iter (± 263364) 24716782 ns/iter (± 922336) 0.97
html/minify/document/css_spec 48468547 ns/iter (± 886890) 45608888 ns/iter (± 1088551) 1.06
html/minify/document/github 19479785 ns/iter (± 352566) 18468444 ns/iter (± 280104) 1.05
html/minify/document/stackoverflow 17867759 ns/iter (± 438940) 16735653 ns/iter (± 274584) 1.07
html/minify/document_fragment/css_spec 47331668 ns/iter (± 283301) 44976586 ns/iter (± 136966) 1.05
html/minify/document_fragment/github 18037849 ns/iter (± 349989) 18171367 ns/iter (± 45763) 0.99
html/minify/document_fragment/stackoverflow 18064496 ns/iter (± 315318) 16610583 ns/iter (± 19545) 1.09
html/document/visitor/compare/clone 163498 ns/iter (± 1061) 165777 ns/iter (± 1342) 0.99
html/document/visitor/compare/visit_mut_span 180776 ns/iter (± 751) 183637 ns/iter (± 468) 0.98
html/document/visitor/compare/visit_mut_span_panic 184220 ns/iter (± 4237) 187471 ns/iter (± 5322) 0.98
html/document/visitor/compare/fold_span 227694 ns/iter (± 1512) 231184 ns/iter (± 1540) 0.98
html/document/visitor/compare/fold_span_panic 276571 ns/iter (± 1584) 282060 ns/iter (± 898) 0.98
html/document_fragment/visitor/compare/clone 165259 ns/iter (± 1677) 166545 ns/iter (± 1020) 0.99
html/document_fragment/visitor/compare/visit_mut_span 180450 ns/iter (± 1005) 183231 ns/iter (± 861) 0.98
html/document_fragment/visitor/compare/visit_mut_span_panic 186050 ns/iter (± 1243) 189998 ns/iter (± 1469) 0.98
html/document_fragment/visitor/compare/fold_span 227932 ns/iter (± 1219) 232548 ns/iter (± 582) 0.98
html/document_fragment/visitor/compare/fold_span_panic 277613 ns/iter (± 718) 284245 ns/iter (± 1041) 0.98
html/lexer/css_2021_spec 12889712 ns/iter (± 166222) 12827379 ns/iter (± 27769) 1.00
html/lexer/github_com_17_05_2022 4976380 ns/iter (± 11172) 4922650 ns/iter (± 10119) 1.01
html/lexer/stackoverflow_com_17_05_2022 4688151 ns/iter (± 10757) 4665970 ns/iter (± 18863) 1.00
html/parser/parser_document/css_2021_spec 25486561 ns/iter (± 77399) 25698328 ns/iter (± 72293) 0.99
html/parser/parser_document/github_com_17_05_2022 8489090 ns/iter (± 14441) 8555125 ns/iter (± 20440) 0.99
html/parser/parser_document/stackoverflow_com_17_05_2022 7450230 ns/iter (± 24948) 7515865 ns/iter (± 14226) 0.99
html/parser/parser_document_fragment/css_2021_spec 25043343 ns/iter (± 52490) 25590750 ns/iter (± 31142) 0.98
html/parser/parser_document_fragment/github_com_17_05_2022 8447319 ns/iter (± 15738) 8539925 ns/iter (± 11771) 0.99
html/parser/parser_document_fragment/stackoverflow_com_17_05_2022 7488510 ns/iter (± 22899) 7538176 ns/iter (± 9423) 0.99

This comment was automatically generated by workflow using github-action-benchmark.

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark

Benchmark suite Current: 72021de Previous: fc4735c Ratio
es/full/bugs-1 271524 ns/iter (± 5144) 292062 ns/iter (± 14026) 0.93
es/full/minify/libraries/antd 1972320497 ns/iter (± 44760327) 1939680850 ns/iter (± 38747923) 1.02
es/full/minify/libraries/d3 364460341 ns/iter (± 3783037) 375421980 ns/iter (± 6053850) 0.97
es/full/minify/libraries/echarts 1573283082 ns/iter (± 61406967) 1673538304 ns/iter (± 15854438) 0.94
es/full/minify/libraries/jquery 102932139 ns/iter (± 399880) 105554739 ns/iter (± 1301147) 0.98
es/full/minify/libraries/lodash 113684561 ns/iter (± 5222504) 116446516 ns/iter (± 585146) 0.98
es/full/minify/libraries/moment 59606558 ns/iter (± 169781) 60434827 ns/iter (± 334339) 0.99
es/full/minify/libraries/react 18324796 ns/iter (± 34496) 18497043 ns/iter (± 94312) 0.99
es/full/minify/libraries/terser 280056428 ns/iter (± 4055851) 292940305 ns/iter (± 2498100) 0.96
es/full/minify/libraries/three 477273833 ns/iter (± 4875234) 515941833 ns/iter (± 9453726) 0.93
es/full/minify/libraries/typescript 3258055504 ns/iter (± 28032949) 3381165543 ns/iter (± 26067903) 0.96
es/full/minify/libraries/victory 739959873 ns/iter (± 14613604) 894375626 ns/iter (± 29377766) 0.83
es/full/minify/libraries/vue 146498471 ns/iter (± 607108) 152943005 ns/iter (± 955335) 0.96
es/full/codegen/es3 57646 ns/iter (± 200) 59156 ns/iter (± 266) 0.97
es/full/codegen/es5 58010 ns/iter (± 234) 58996 ns/iter (± 167) 0.98
es/full/codegen/es2015 57604 ns/iter (± 178) 59041 ns/iter (± 234) 0.98
es/full/codegen/es2016 57881 ns/iter (± 225) 58815 ns/iter (± 183) 0.98
es/full/codegen/es2017 57679 ns/iter (± 201) 58853 ns/iter (± 303) 0.98
es/full/codegen/es2018 57748 ns/iter (± 284) 58906 ns/iter (± 280) 0.98
es/full/codegen/es2019 57729 ns/iter (± 123) 58908 ns/iter (± 254) 0.98
es/full/codegen/es2020 57769 ns/iter (± 891) 59048 ns/iter (± 570) 0.98
es/full/all/es3 162947325 ns/iter (± 652713) 162675866 ns/iter (± 932399) 1.00
es/full/all/es5 157896613 ns/iter (± 875741) 157337474 ns/iter (± 1299928) 1.00
es/full/all/es2015 116741816 ns/iter (± 4398266) 117203995 ns/iter (± 1844706) 1.00
es/full/all/es2016 115893272 ns/iter (± 906602) 116029504 ns/iter (± 751343) 1.00
es/full/all/es2017 115229758 ns/iter (± 575122) 115574002 ns/iter (± 764804) 1.00
es/full/all/es2018 112942626 ns/iter (± 861306) 113913449 ns/iter (± 770729) 0.99
es/full/all/es2019 112501031 ns/iter (± 824366) 113438690 ns/iter (± 979015) 0.99
es/full/all/es2020 108760770 ns/iter (± 808861) 109052341 ns/iter (± 983643) 1.00
es/full/parser 477279 ns/iter (± 2715) 481778 ns/iter (± 2512) 0.99
es/full/base/fixer 15782 ns/iter (± 106) 15401 ns/iter (± 38) 1.02
es/full/base/resolver_and_hygiene 80422 ns/iter (± 369) 80603 ns/iter (± 172) 1.00
serialization of serde 277 ns/iter (± 5) 263 ns/iter (± 6) 1.05
css/minify/libraries/bootstrap 22173833 ns/iter (± 115040) 21803063 ns/iter (± 34521) 1.02
css/visitor/compare/clone 1367445 ns/iter (± 15892) 1354906 ns/iter (± 7575) 1.01
css/visitor/compare/visit_mut_span 1483294 ns/iter (± 13036) 1477108 ns/iter (± 6603) 1.00
css/visitor/compare/visit_mut_span_panic 1508233 ns/iter (± 37740) 1498681 ns/iter (± 31813) 1.01
css/visitor/compare/fold_span 1998847 ns/iter (± 8077) 1983430 ns/iter (± 3336) 1.01
css/visitor/compare/fold_span_panic 2137787 ns/iter (± 4608) 2123139 ns/iter (± 4171) 1.01
css/lexer/bootstrap_5_1_3 3457409 ns/iter (± 14762) 3523858 ns/iter (± 10967) 0.98
css/lexer/foundation_6_7_4 2796574 ns/iter (± 4750) 2826309 ns/iter (± 1100) 0.99
css/lexer/tailwind_3_1_1 535378 ns/iter (± 965) 548044 ns/iter (± 879) 0.98
css/parser/bootstrap_5_1_3 16071300 ns/iter (± 41198) 16143202 ns/iter (± 39306) 1.00
css/parser/foundation_6_7_4 12850239 ns/iter (± 518418) 12934581 ns/iter (± 26619) 0.99
css/parser/tailwind_3_1_1 2553433 ns/iter (± 1433) 2662075 ns/iter (± 4724) 0.96
es/codegen/colors 715718 ns/iter (± 392110) 738610 ns/iter (± 397091) 0.97
es/codegen/large 2872136 ns/iter (± 1567307) 2965265 ns/iter (± 1605612) 0.97
es/codegen/with-parser/colors 42623 ns/iter (± 279) 41467 ns/iter (± 177) 1.03
es/codegen/with-parser/large 472727 ns/iter (± 3781) 452312 ns/iter (± 1933) 1.05
es/minify/libraries/antd 1414912541 ns/iter (± 24070671) 1416091336 ns/iter (± 27447048) 1.00
es/minify/libraries/d3 279806368 ns/iter (± 1233674) 281388501 ns/iter (± 3577704) 0.99
es/minify/libraries/echarts 1142665046 ns/iter (± 8049108) 1152210106 ns/iter (± 21166133) 0.99
es/minify/libraries/jquery 82310561 ns/iter (± 384768) 82543899 ns/iter (± 221882) 1.00
es/minify/libraries/lodash 105063406 ns/iter (± 2616340) 104703144 ns/iter (± 178255) 1.00
es/minify/libraries/moment 48368388 ns/iter (± 179356) 48446828 ns/iter (± 74408) 1.00
es/minify/libraries/react 16551085 ns/iter (± 60396) 16300467 ns/iter (± 9021) 1.02
es/minify/libraries/terser 221468316 ns/iter (± 1833435) 217907504 ns/iter (± 2882035) 1.02
es/minify/libraries/three 438267567 ns/iter (± 14441075) 367606034 ns/iter (± 11688541) 1.19
es/minify/libraries/typescript 2886370341 ns/iter (± 20972344) 2741807158 ns/iter (± 36270389) 1.05
es/minify/libraries/victory 665944661 ns/iter (± 23666504) 577715656 ns/iter (± 4006972) 1.15
es/minify/libraries/vue 122872661 ns/iter (± 1432037) 121647125 ns/iter (± 328151) 1.01
es/visitor/compare/clone 1874666 ns/iter (± 19678) 1699828 ns/iter (± 5927) 1.10
es/visitor/compare/visit_mut_span 2263643 ns/iter (± 28527) 2035384 ns/iter (± 22404) 1.11
es/visitor/compare/visit_mut_span_panic 2251252 ns/iter (± 80084) 2046059 ns/iter (± 26780) 1.10
es/visitor/compare/fold_span 3019248 ns/iter (± 30380) 2749257 ns/iter (± 11720) 1.10
es/visitor/compare/fold_span_panic 3088356 ns/iter (± 43512) 2795792 ns/iter (± 13482) 1.10
es/lexer/colors 9750 ns/iter (± 209) 9605 ns/iter (± 48) 1.02
es/lexer/angular 5166637 ns/iter (± 49110) 4904346 ns/iter (± 29084) 1.05
es/lexer/backbone 675962 ns/iter (± 7628) 647288 ns/iter (± 2202) 1.04
es/lexer/jquery 3812012 ns/iter (± 31917) 3792398 ns/iter (± 17561) 1.01
es/lexer/jquery mobile 5665483 ns/iter (± 62693) 5485021 ns/iter (± 14070) 1.03
es/lexer/mootools 2982346 ns/iter (± 22800) 2814040 ns/iter (± 10665) 1.06
es/lexer/underscore 556604 ns/iter (± 4153) 519016 ns/iter (± 2484) 1.07
es/lexer/three 16711324 ns/iter (± 129650) 16066998 ns/iter (± 112531) 1.04
es/lexer/yui 2978973 ns/iter (± 10647) 2959732 ns/iter (± 86378) 1.01
es/lexer/cal-com 13664471 ns/iter (± 50148) 12860915 ns/iter (± 18389) 1.06
es/lexer/typescript 96255669 ns/iter (± 583731) 90288924 ns/iter (± 205781) 1.07
es/parser/colors 24782 ns/iter (± 230) 23550 ns/iter (± 123) 1.05
es/parser/angular 13578513 ns/iter (± 286663) 12428613 ns/iter (± 47278) 1.09
es/parser/backbone 1929620 ns/iter (± 22168) 1819913 ns/iter (± 9007) 1.06
es/parser/jquery 10679140 ns/iter (± 226899) 10064030 ns/iter (± 75868) 1.06
es/parser/jquery mobile 16035610 ns/iter (± 149650) 15163048 ns/iter (± 97081) 1.06
es/parser/mootools 8280698 ns/iter (± 91738) 7843490 ns/iter (± 44931) 1.06
es/parser/underscore 1654689 ns/iter (± 12962) 1571313 ns/iter (± 8733) 1.05
es/parser/three 54850552 ns/iter (± 1900653) 42904051 ns/iter (± 280033) 1.28
es/parser/yui 7938074 ns/iter (± 82752) 7404698 ns/iter (± 36293) 1.07
es/parser/cal-com 46574014 ns/iter (± 2189089) 39147787 ns/iter (± 307063) 1.19
es/parser/typescript 351312226 ns/iter (± 7152242) 266392463 ns/iter (± 904026) 1.32
es/preset-env/usage/builtin_type 138135 ns/iter (± 33521) 136512 ns/iter (± 34895) 1.01
es/preset-env/usage/property 15999 ns/iter (± 52) 16372 ns/iter (± 96) 0.98
es/resolver/typescript 101476837 ns/iter (± 4263386) 104613862 ns/iter (± 2442881) 0.97
es/fixer/typescript 83822747 ns/iter (± 1209348) 85398291 ns/iter (± 1766747) 0.98
es/hygiene/typescript 181247857 ns/iter (± 3490947) 191315311 ns/iter (± 3225826) 0.95
es/resolver_with_hygiene/typescript 308093764 ns/iter (± 2468624) 330382299 ns/iter (± 3742757) 0.93
es/visitor/base-perf/module_clone 57371 ns/iter (± 465) 57065 ns/iter (± 1980) 1.01
es/visitor/base-perf/fold_empty 60404 ns/iter (± 579) 60529 ns/iter (± 958) 1.00
es/visitor/base-perf/fold_noop_impl_all 60493 ns/iter (± 455) 60193 ns/iter (± 897) 1.00
es/visitor/base-perf/fold_noop_impl_vec 60480 ns/iter (± 683) 60317 ns/iter (± 705) 1.00
es/visitor/base-perf/boxing_boxed_clone 60 ns/iter (± 0) 60 ns/iter (± 0) 1
es/visitor/base-perf/boxing_unboxed_clone 47 ns/iter (± 0) 47 ns/iter (± 0) 1
es/visitor/base-perf/boxing_boxed 106 ns/iter (± 0) 105 ns/iter (± 1) 1.01
es/visitor/base-perf/boxing_unboxed 81 ns/iter (± 0) 80 ns/iter (± 0) 1.01
es/visitor/base-perf/visit_contains_this 2553 ns/iter (± 14) 2579 ns/iter (± 25) 0.99
es/base/parallel/resolver/typescript 2492870513 ns/iter (± 203658326) 2557646004 ns/iter (± 158125654) 0.97
es/base/parallel/hygiene/typescript 3234292144 ns/iter (± 57805393) 3183469193 ns/iter (± 44074971) 1.02
babelify-only 495413 ns/iter (± 14393) 510833 ns/iter (± 11477) 0.97
parse_and_babelify_angular 39465892 ns/iter (± 3274611) 54293129 ns/iter (± 1845522) 0.73
parse_and_babelify_backbone 4342691 ns/iter (± 179282) 5349470 ns/iter (± 417109) 0.81
parse_and_babelify_jquery 28366112 ns/iter (± 234120) 36576684 ns/iter (± 2175233) 0.78
parse_and_babelify_jquery_mobile 49576024 ns/iter (± 921956) 61917207 ns/iter (± 2483830) 0.80
parse_and_babelify_mootools 25989630 ns/iter (± 323282) 31982872 ns/iter (± 1084978) 0.81
parse_and_babelify_underscore 3659551 ns/iter (± 21596) 3916649 ns/iter (± 50311) 0.93
parse_and_babelify_yui 24766075 ns/iter (± 536094) 30734285 ns/iter (± 870089) 0.81
html/minify/document/css_spec 45902773 ns/iter (± 2524738) 45543246 ns/iter (± 300537) 1.01
html/minify/document/github 18099531 ns/iter (± 219157) 18100097 ns/iter (± 13924) 1.00
html/minify/document/stackoverflow 16791927 ns/iter (± 306988) 16450228 ns/iter (± 533161) 1.02
html/minify/document_fragment/css_spec 44613332 ns/iter (± 523328) 45168528 ns/iter (± 183493) 0.99
html/minify/document_fragment/github 17951449 ns/iter (± 146035) 17937429 ns/iter (± 54150) 1.00
html/minify/document_fragment/stackoverflow 16389425 ns/iter (± 278288) 16386972 ns/iter (± 283152) 1.00
html/document/visitor/compare/clone 166259 ns/iter (± 1541) 166721 ns/iter (± 3637) 1.00
html/document/visitor/compare/visit_mut_span 183874 ns/iter (± 1527) 182534 ns/iter (± 1226) 1.01
html/document/visitor/compare/visit_mut_span_panic 190046 ns/iter (± 2901) 188164 ns/iter (± 2816) 1.01
html/document/visitor/compare/fold_span 230600 ns/iter (± 972) 230693 ns/iter (± 985) 1.00
html/document/visitor/compare/fold_span_panic 279523 ns/iter (± 3001) 283257 ns/iter (± 1112) 0.99
html/document_fragment/visitor/compare/clone 171313 ns/iter (± 4198) 167369 ns/iter (± 1005) 1.02
html/document_fragment/visitor/compare/visit_mut_span 184542 ns/iter (± 792) 181742 ns/iter (± 638) 1.02
html/document_fragment/visitor/compare/visit_mut_span_panic 187954 ns/iter (± 644) 188766 ns/iter (± 1045) 1.00
html/document_fragment/visitor/compare/fold_span 229181 ns/iter (± 1725) 231045 ns/iter (± 1007) 0.99
html/document_fragment/visitor/compare/fold_span_panic 280705 ns/iter (± 1573) 282579 ns/iter (± 1116) 0.99
html/lexer/css_2021_spec 12797658 ns/iter (± 114536) 12900555 ns/iter (± 30006) 0.99
html/lexer/github_com_17_05_2022 4911636 ns/iter (± 80173) 4948918 ns/iter (± 129121) 0.99
html/lexer/stackoverflow_com_17_05_2022 4662069 ns/iter (± 5695) 4691813 ns/iter (± 3055) 0.99
html/parser/parser_document/css_2021_spec 25254353 ns/iter (± 316240) 25531025 ns/iter (± 159932) 0.99
html/parser/parser_document/github_com_17_05_2022 8364899 ns/iter (± 15102) 8533172 ns/iter (± 80992) 0.98
html/parser/parser_document/stackoverflow_com_17_05_2022 7334983 ns/iter (± 21969) 7457514 ns/iter (± 86224) 0.98
html/parser/parser_document_fragment/css_2021_spec 24955204 ns/iter (± 73293) 25794183 ns/iter (± 135929) 0.97
html/parser/parser_document_fragment/github_com_17_05_2022 8366364 ns/iter (± 10557) 8489092 ns/iter (± 25927) 0.99
html/parser/parser_document_fragment/stackoverflow_com_17_05_2022 7328629 ns/iter (± 17170) 7488572 ns/iter (± 15642) 0.98

This comment was automatically generated by workflow using github-action-benchmark.

Please sign in to comment.