Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf: don't prepare a fix for valid code in key-spacing

Merged
merged 1 commit into from Nov 5, 2021

Conversation

mdjermanovic
Copy link
Member

@mdjermanovic mdjermanovic commented Nov 1, 2021

Prerequisites checklist

What is the purpose of this pull request? (put an "X" next to an item)

[ ] Documentation update
[ ] Bug fix (template)
[ ] New rule (template)
[ ] Changes an existing rule (template)
[ ] Add autofixing to a rule
[ ] Add a CLI option
[ ] Add something to the core
[x] Other, please explain:

Improves the performance of key-spacing rule.

I noticed that key-spacing takes significantly more time than other core rules (except for indent) while linting eslint codebase.

Rule                                          | Time (ms) | Relative
:---------------------------------------------|----------:|--------:
indent                                        |  8932.883 |    14.9%
jsdoc/check-line-alignment                    |  2495.443 |     4.2%
jsdoc/valid-types                             |  2189.563 |     3.6%
jsdoc/check-values                            |  1740.889 |     2.9%
jsdoc/check-syntax                            |  1739.052 |     2.9%
jsdoc/check-types                             |  1727.834 |     2.9%
jsdoc/check-tag-names                         |  1648.792 |     2.7%
jsdoc/newline-after-description               |  1605.039 |     2.7%
jsdoc/require-asterisk-prefix                 |  1565.982 |     2.6%
jsdoc/require-hyphen-before-param-description |  1557.490 |     2.6%
jsdoc/tag-lines                               |  1534.903 |     2.6%
jsdoc/check-access                            |  1528.069 |     2.5%
jsdoc/require-property-description            |  1515.929 |     2.5%
jsdoc/check-property-names                    |  1513.363 |     2.5%
jsdoc/empty-tags                              |  1508.546 |     2.5%
jsdoc/multiline-blocks                        |  1508.153 |     2.5%
jsdoc/check-alignment                         |  1507.435 |     2.5%
jsdoc/require-property-name                   |  1499.975 |     2.5%
jsdoc/no-multi-asterisks                      |  1489.551 |     2.5%
jsdoc/require-property                        |  1489.115 |     2.5%
jsdoc/require-property-type                   |  1484.048 |     2.5%
node/no-missing-require                       |  1055.094 |     1.8%
node/no-extraneous-require                    |   973.506 |     1.6%
node/no-unpublished-require                   |   914.645 |     1.5%
key-spacing                                   |   899.327 |     1.5%
eslint-plugin/no-identical-tests              |   805.156 |     1.3%
comma-style                                   |   485.955 |     0.8%
max-len                                       |   462.454 |     0.8%
node/no-restricted-require                    |   424.574 |     0.7%
no-loss-of-precision                          |   314.663 |     0.5%
no-dupe-keys                                  |   283.553 |     0.5%
object-curly-newline                          |   278.970 |     0.5%
...

What changes did you make? (Give an overview)

It turned out that the rule spends the majоrity of time in calculating data that would be needed to auto-fix invalid code, but isn't needed for valid code, so I moved those lines into the conditional that handles invalid code. This change improved the performance of this rule by ~80%.

key-spacing                                   |   186.664 |     0.3%

Is there anything you'd like reviewers to focus on?

@mdjermanovic mdjermanovic added rule accepted chore labels Nov 1, 2021
nzakas
nzakas approved these changes Nov 2, 2021
Copy link
Member

@nzakas nzakas left a comment

LGTM. Can you also post the after numbers? (In general for perf-related commits we should include a before and after for easier reference later.)

@mdjermanovic
Copy link
Member Author

mdjermanovic commented Nov 2, 2021

Oh, I posted after only for that rule. Here's a complete output from TIMING=all node Makefile lint command:

Before
Validating JavaScript files
Rule                                          | Time (ms) | Relative
:---------------------------------------------|----------:|--------:
indent                                        |  8932.883 |    14.9%
jsdoc/check-line-alignment                    |  2495.443 |     4.2%
jsdoc/valid-types                             |  2189.563 |     3.6%
jsdoc/check-values                            |  1740.889 |     2.9%
jsdoc/check-syntax                            |  1739.052 |     2.9%
jsdoc/check-types                             |  1727.834 |     2.9%
jsdoc/check-tag-names                         |  1648.792 |     2.7%
jsdoc/newline-after-description               |  1605.039 |     2.7%
jsdoc/require-asterisk-prefix                 |  1565.982 |     2.6%
jsdoc/require-hyphen-before-param-description |  1557.490 |     2.6%
jsdoc/tag-lines                               |  1534.903 |     2.6%
jsdoc/check-access                            |  1528.069 |     2.5%
jsdoc/require-property-description            |  1515.929 |     2.5%
jsdoc/check-property-names                    |  1513.363 |     2.5%
jsdoc/empty-tags                              |  1508.546 |     2.5%
jsdoc/multiline-blocks                        |  1508.153 |     2.5%
jsdoc/check-alignment                         |  1507.435 |     2.5%
jsdoc/require-property-name                   |  1499.975 |     2.5%
jsdoc/no-multi-asterisks                      |  1489.551 |     2.5%
jsdoc/require-property                        |  1489.115 |     2.5%
jsdoc/require-property-type                   |  1484.048 |     2.5%
node/no-missing-require                       |  1055.094 |     1.8%
node/no-extraneous-require                    |   973.506 |     1.6%
node/no-unpublished-require                   |   914.645 |     1.5%
key-spacing                                   |   899.327 |     1.5%
eslint-plugin/no-identical-tests              |   805.156 |     1.3%
comma-style                                   |   485.955 |     0.8%
max-len                                       |   462.454 |     0.8%
node/no-restricted-require                    |   424.574 |     0.7%
no-loss-of-precision                          |   314.663 |     0.5%
no-dupe-keys                                  |   283.553 |     0.5%
object-curly-newline                          |   278.970 |     0.5%
jsdoc/require-param                           |   270.099 |     0.4%
camelcase                                     |   261.738 |     0.4%
padding-line-between-statements               |   256.263 |     0.4%
object-shorthand                              |   251.778 |     0.4%
comma-dangle                                  |   236.592 |     0.4%
jsdoc/require-description                     |   231.809 |     0.4%
jsdoc/check-param-names                       |   218.371 |     0.4%
keyword-spacing                               |   209.978 |     0.3%
object-curly-spacing                          |   208.125 |     0.3%
quote-props                                   |   204.342 |     0.3%
jsdoc/require-returns                         |   194.683 |     0.3%
comma-spacing                                 |   187.666 |     0.3%
jsdoc/require-throws                          |   185.471 |     0.3%
jsdoc/require-returns-check                   |   183.494 |     0.3%
no-trailing-spaces                            |   180.046 |     0.3%
no-script-url                                 |   174.976 |     0.3%
space-infix-ops                               |   164.080 |     0.3%
jsdoc/require-param-description               |   159.156 |     0.3%
no-whitespace-before-property                 |   156.548 |     0.3%
jsdoc/require-yields-check                    |   148.755 |     0.2%
function-paren-newline                        |   147.340 |     0.2%
jsdoc/implements-on-classes                   |   146.429 |     0.2%
internal-rules/multiline-comment-style        |   139.164 |     0.2%
jsdoc/require-returns-description             |   136.971 |     0.2%
func-call-spacing                             |   136.479 |     0.2%
space-in-parens                               |   134.810 |     0.2%
no-useless-return                             |   134.497 |     0.2%
array-bracket-spacing                         |   132.694 |     0.2%
jsdoc/require-param-name                      |   131.932 |     0.2%
no-useless-escape                             |   131.103 |     0.2%
no-alert                                      |   127.650 |     0.2%
jsdoc/require-param-type                      |   127.561 |     0.2%
no-underscore-dangle                          |   125.667 |     0.2%
jsdoc/require-returns-type                    |   125.492 |     0.2%
no-regex-spaces                               |   122.928 |     0.2%
max-statements-per-line                       |   117.014 |     0.2%
operator-linebreak                            |   116.828 |     0.2%
no-unexpected-multiline                       |   113.961 |     0.2%
node/no-unsupported-features/es-builtins      |   110.662 |     0.2%
semi-spacing                                  |   106.682 |     0.2%
no-control-regex                              |   106.680 |     0.2%
no-octal-escape                               |   106.158 |     0.2%
grouped-accessor-pairs                        |   103.604 |     0.2%
no-multi-spaces                               |   103.476 |     0.2%
no-multi-str                                  |   100.181 |     0.2%
no-redeclare                                  |    98.287 |     0.2%
quotes                                        |    93.318 |     0.2%
no-unused-vars                                |    85.729 |     0.1%
prefer-template                               |    83.159 |     0.1%
computed-property-spacing                     |    81.741 |     0.1%
object-property-newline                       |    75.022 |     0.1%
no-unmodified-loop-condition                  |    74.272 |     0.1%
no-nonoctal-decimal-escape                    |    73.156 |     0.1%
no-floating-decimal                           |    71.098 |     0.1%
node/no-unsupported-features/node-builtins    |    68.060 |     0.1%
function-call-argument-newline                |    67.462 |     0.1%
node/no-unpublished-import                    |    63.682 |     0.1%
no-restricted-properties                      |    61.955 |     0.1%
dot-location                                  |    61.700 |     0.1%
new-cap                                       |    61.570 |     0.1%
no-undef-init                                 |    60.560 |     0.1%
no-multiple-empty-lines                       |    58.583 |     0.1%
block-spacing                                 |    58.173 |     0.1%
semi-style                                    |    57.150 |     0.1%
no-unsafe-optional-chaining                   |    57.003 |     0.1%
node/no-deprecated-api                        |    56.793 |     0.1%
no-misleading-character-class                 |    56.308 |     0.1%
node/no-unsupported-features/es-syntax        |    56.179 |     0.1%
no-useless-computed-key                       |    54.690 |     0.1%
no-unreachable                                |    54.199 |     0.1%
no-mixed-spaces-and-tabs                      |    53.989 |     0.1%
eslint-plugin/prefer-message-ids              |    53.318 |     0.1%
semi                                          |    52.742 |     0.1%
no-self-compare                               |    47.617 |     0.1%
brace-style                                   |    47.333 |     0.1%
lines-around-comment                          |    47.299 |     0.1%
no-eval                                       |    47.097 |     0.1%
no-tabs                                       |    46.503 |     0.1%
consistent-return                             |    45.013 |     0.1%
constructor-super                             |    44.092 |     0.1%
eslint-plugin/prefer-replace-text             |    43.784 |     0.1%
no-this-before-super                          |    42.877 |     0.1%
space-before-blocks                           |    40.188 |     0.1%
no-octal                                      |    37.894 |     0.1%
arrow-spacing                                 |    37.585 |     0.1%
space-unary-ops                               |    36.488 |     0.1%
node/callback-return                          |    34.765 |     0.1%
eslint-plugin/report-message-format           |    33.612 |     0.1%
eslint-plugin/no-only-tests                   |    33.432 |     0.1%
node/no-mixed-requires                        |    32.885 |     0.1%
no-useless-backreference                      |    32.496 |     0.1%
array-callback-return                         |    32.275 |     0.1%
no-unreachable-loop                           |    31.619 |     0.1%
eslint-plugin/fixer-return                    |    31.348 |     0.1%
no-unused-expressions                         |    31.171 |     0.1%
jsdoc/no-bad-blocks                           |    30.666 |     0.1%
no-use-before-define                          |    30.241 |     0.1%
dot-notation                                  |    29.233 |     0.0%
node/handle-callback-err                      |    28.587 |     0.0%
no-shadow                                     |    27.885 |     0.0%
no-lone-blocks                                |    27.579 |     0.0%
no-implied-eval                               |    27.432 |     0.0%
eslint-plugin/prefer-output-null              |    27.084 |     0.0%
no-useless-call                               |    25.886 |     0.0%
prefer-promise-reject-errors                  |    25.108 |     0.0%
space-before-function-paren                   |    24.536 |     0.0%
no-iterator                                   |    24.364 |     0.0%
no-caller                                     |    23.890 |     0.0%
no-const-assign                               |    23.770 |     0.0%
node/no-path-concat                           |    23.343 |     0.0%
node/no-extraneous-import                     |    23.179 |     0.0%
prefer-spread                                 |    22.879 |     0.0%
no-setter-return                              |    22.569 |     0.0%
eslint-plugin/test-case-property-ordering     |    22.454 |     0.0%
no-param-reassign                             |    22.241 |     0.0%
spaced-comment                                |    22.103 |     0.0%
no-dupe-else-if                               |    22.041 |     0.0%
eslint-plugin/require-meta-fixable            |    21.535 |     0.0%
eslint-plugin/prefer-placeholders             |    21.489 |     0.0%
getter-return                                 |    21.144 |     0.0%
no-shadow-restricted-names                    |    21.062 |     0.0%
eslint-plugin/no-deprecated-report-api        |    20.949 |     0.0%
node/no-unpublished-bin                       |    20.205 |     0.0%
curly                                         |    20.102 |     0.0%
eslint-plugin/require-meta-has-suggestions    |    19.965 |     0.0%
template-curly-spacing                        |    19.682 |     0.0%
eslint-plugin/no-missing-placeholders         |    19.449 |     0.0%
no-prototype-builtins                         |    19.254 |     0.0%
wrap-iife                                     |    18.895 |     0.0%
jsdoc/require-jsdoc                           |    18.794 |     0.0%
no-extend-native                              |    18.753 |     0.0%
eslint-plugin/no-unused-placeholders          |    17.711 |     0.0%
prefer-const                                  |    17.474 |     0.0%
strict                                        |    17.114 |     0.0%
prefer-numeric-literals                       |    17.083 |     0.0%
no-invalid-this                               |    15.763 |     0.0%
no-proto                                      |    15.712 |     0.0%
no-extra-boolean-cast                         |    15.361 |     0.0%
eslint-comments/require-description           |    15.194 |     0.0%
prefer-exponentiation-operator                |    15.110 |     0.0%
no-loop-func                                  |    14.923 |     0.0%
no-extra-bind                                 |    14.906 |     0.0%
no-invalid-regexp                             |    14.820 |     0.0%
no-constructor-return                         |    14.814 |     0.0%
no-sparse-arrays                              |    14.474 |     0.0%
eslint-plugin/no-deprecated-context-methods   |    14.252 |     0.0%
arrow-body-style                              |    14.189 |     0.0%
class-methods-use-this                        |    14.121 |     0.0%
no-constant-condition                         |    14.035 |     0.0%
no-array-constructor                          |    13.847 |     0.0%
no-unsafe-finally                             |    13.435 |     0.0%
func-style                                    |    13.386 |     0.0%
eslint-plugin/require-meta-schema             |    13.312 |     0.0%
no-return-assign                              |    13.193 |     0.0%
eslint-plugin/consistent-output               |    13.145 |     0.0%
no-obj-calls                                  |    13.119 |     0.0%
eslint-plugin/no-useless-token-range          |    12.624 |     0.0%
use-isnan                                     |    12.281 |     0.0%
prefer-arrow-callback                         |    12.140 |     0.0%
eqeqeq                                        |    11.491 |     0.0%
no-inner-declarations                         |    11.069 |     0.0%
yoda                                          |    10.827 |     0.0%
eslint-plugin/test-case-shorthand-strings     |     9.718 |     0.0%
eslint-comments/no-unlimited-disable          |     9.374 |     0.0%
eslint-plugin/require-meta-docs-url           |     9.196 |     0.0%
no-dupe-args                                  |     9.132 |     0.0%
no-useless-concat                             |     8.939 |     0.0%
no-fallthrough                                |     8.533 |     0.0%
one-var-declaration-per-line                  |     8.511 |     0.0%
default-param-last                            |     8.457 |     0.0%
no-undefined                                  |     8.312 |     0.0%
eslint-plugin/require-meta-docs-description   |     7.657 |     0.0%
node/no-exports-assign                        |     7.604 |     0.0%
no-func-assign                                |     7.372 |     0.0%
no-global-assign                              |     7.159 |     0.0%
prefer-regex-literals                         |     7.099 |     0.0%
no-self-assign                                |     6.827 |     0.0%
no-empty                                      |     6.583 |     0.0%
no-new-object                                 |     6.424 |     0.0%
prefer-rest-params                            |     6.388 |     0.0%
no-compare-neg-zero                           |     6.284 |     0.0%
require-unicode-regexp                        |     5.785 |     0.0%
template-tag-spacing                          |     5.570 |     0.0%
no-console                                    |     5.528 |     0.0%
no-unsafe-negation                            |     5.328 |     0.0%
no-var                                        |     5.135 |     0.0%
no-confusing-arrow                            |     5.084 |     0.0%
internal-rules/no-invalid-meta                |     4.739 |     0.0%
no-else-return                                |     4.725 |     0.0%
eslint-plugin/require-meta-type               |     4.359 |     0.0%
no-cond-assign                                |     4.099 |     0.0%
no-duplicate-case                             |     3.998 |     0.0%
arrow-parens                                  |     3.888 |     0.0%
eol-last                                      |     3.883 |     0.0%
valid-typeof                                  |     3.824 |     0.0%
require-yield                                 |     3.734 |     0.0%
radix                                         |     3.248 |     0.0%
no-dupe-class-members                         |     3.227 |     0.0%
switch-colon-spacing                          |     2.952 |     0.0%
node/no-missing-import                        |     2.841 |     0.0%
operator-assignment                           |     2.733 |     0.0%
new-parens                                    |     2.447 |     0.0%
no-new-func                                   |     2.279 |     0.0%
no-useless-rename                             |     2.057 |     0.0%
eslint-comments/no-aggregating-enable         |     2.033 |     0.0%
generator-star-spacing                        |     2.007 |     0.0%
eslint-comments/no-duplicate-disable          |     1.993 |     0.0%
no-new-symbol                                 |     1.989 |     0.0%
no-new-wrappers                               |     1.807 |     0.0%
eslint-comments/disable-enable-pair           |     1.753 |     0.0%
no-empty-character-class                      |     1.589 |     0.0%
unicode-bom                                   |     1.577 |     0.0%
symbol-description                            |     1.547 |     0.0%
sort-keys                                     |     1.516 |     0.0%
no-extra-semi                                 |     1.420 |     0.0%
node/no-new-require                           |     1.211 |     0.0%
node/shebang                                  |     1.203 |     0.0%
rest-spread-spacing                           |     1.114 |     0.0%
eslint-comments/no-unused-enable              |     1.057 |     0.0%
no-delete-var                                 |     1.037 |     0.0%
no-unneeded-ternary                           |     0.984 |     0.0%
no-undef                                      |     0.919 |     0.0%
default-case                                  |     0.915 |     0.0%
no-empty-pattern                              |     0.805 |     0.0%
no-nested-ternary                             |     0.764 |     0.0%
no-ex-assign                                  |     0.656 |     0.0%
no-case-declarations                          |     0.595 |     0.0%
no-throw-literal                              |     0.570 |     0.0%
eslint-plugin/prefer-object-rule              |     0.555 |     0.0%
for-direction                                 |     0.547 |     0.0%
no-useless-constructor                        |     0.502 |     0.0%
no-irregular-whitespace                       |     0.478 |     0.0%
no-labels                                     |     0.401 |     0.0%
yield-star-spacing                            |     0.374 |     0.0%
no-useless-catch                              |     0.364 |     0.0%
no-class-assign                               |     0.317 |     0.0%
no-new                                        |     0.291 |     0.0%
guard-for-in                                  |     0.241 |     0.0%
default-case-last                             |     0.237 |     0.0%
no-sequences                                  |     0.224 |     0.0%
no-unused-labels                              |     0.189 |     0.0%
no-label-var                                  |     0.000 |     0.0%
no-async-promise-executor                     |     0.000 |     0.0%
no-debugger                                   |     0.000 |     0.0%
no-import-assign                              |     0.000 |     0.0%
no-with                                       |     0.000 |     0.0%
no-restricted-syntax                          |     0.000 |     0.0%
Validating JSON Files
Validating Markdown Files
Rule | Time (ms) | Relative
:----|----------:|--------:
After
Validating JavaScript files
Rule                                          | Time (ms) | Relative
:---------------------------------------------|----------:|--------:
indent                                        |  9467.591 |    15.8%
jsdoc/check-line-alignment                    |  2449.424 |     4.1%
jsdoc/valid-types                             |  2167.588 |     3.6%
jsdoc/check-types                             |  1740.262 |     2.9%
jsdoc/check-values                            |  1712.303 |     2.9%
jsdoc/check-syntax                            |  1697.657 |     2.8%
jsdoc/check-tag-names                         |  1656.283 |     2.8%
jsdoc/newline-after-description               |  1619.878 |     2.7%
jsdoc/require-asterisk-prefix                 |  1570.765 |     2.6%
jsdoc/check-access                            |  1564.098 |     2.6%
jsdoc/require-hyphen-before-param-description |  1553.111 |     2.6%
jsdoc/tag-lines                               |  1543.352 |     2.6%
jsdoc/check-property-names                    |  1542.808 |     2.6%
jsdoc/check-alignment                         |  1541.468 |     2.6%
jsdoc/empty-tags                              |  1534.615 |     2.6%
jsdoc/require-property-description            |  1522.751 |     2.5%
jsdoc/require-property-name                   |  1507.119 |     2.5%
jsdoc/require-property-type                   |  1504.555 |     2.5%
jsdoc/no-multi-asterisks                      |  1479.541 |     2.5%
jsdoc/multiline-blocks                        |  1475.984 |     2.5%
jsdoc/require-property                        |  1463.328 |     2.4%
node/no-missing-require                       |  1110.890 |     1.9%
node/no-extraneous-require                    |   974.432 |     1.6%
node/no-unpublished-require                   |   906.495 |     1.5%
eslint-plugin/no-identical-tests              |   781.189 |     1.3%
comma-style                                   |   490.879 |     0.8%
max-len                                       |   472.658 |     0.8%
node/no-restricted-require                    |   433.035 |     0.7%
no-loss-of-precision                          |   298.683 |     0.5%
no-dupe-keys                                  |   298.324 |     0.5%
object-curly-newline                          |   287.020 |     0.5%
jsdoc/require-param                           |   276.975 |     0.5%
jsdoc/require-description                     |   258.627 |     0.4%
padding-line-between-statements               |   229.046 |     0.4%
object-shorthand                              |   227.006 |     0.4%
camelcase                                     |   218.937 |     0.4%
jsdoc/check-param-names                       |   218.258 |     0.4%
comma-dangle                                  |   213.184 |     0.4%
object-curly-spacing                          |   212.821 |     0.4%
jsdoc/require-throws                          |   210.461 |     0.4%
keyword-spacing                               |   202.797 |     0.3%
jsdoc/require-returns                         |   199.541 |     0.3%
key-spacing                                   |   186.664 |     0.3%
quote-props                                   |   186.214 |     0.3%
comma-spacing                                 |   185.491 |     0.3%
no-trailing-spaces                            |   178.481 |     0.3%
space-infix-ops                               |   176.094 |     0.3%
jsdoc/require-returns-check                   |   170.534 |     0.3%
jsdoc/implements-on-classes                   |   167.888 |     0.3%
jsdoc/require-yields-check                    |   157.939 |     0.3%
no-whitespace-before-property                 |   150.965 |     0.3%
no-script-url                                 |   150.806 |     0.3%
jsdoc/require-param-description               |   150.534 |     0.3%
space-in-parens                               |   146.927 |     0.2%
jsdoc/require-returns-description             |   146.339 |     0.2%
internal-rules/multiline-comment-style        |   146.206 |     0.2%
jsdoc/require-returns-type                    |   139.285 |     0.2%
no-useless-escape                             |   138.304 |     0.2%
jsdoc/require-param-type                      |   136.701 |     0.2%
function-paren-newline                        |   135.482 |     0.2%
no-alert                                      |   133.549 |     0.2%
array-bracket-spacing                         |   125.649 |     0.2%
jsdoc/require-param-name                      |   125.613 |     0.2%
no-useless-return                             |   123.798 |     0.2%
no-multi-spaces                               |   122.174 |     0.2%
no-regex-spaces                               |   119.168 |     0.2%
func-call-spacing                             |   118.379 |     0.2%
node/no-unsupported-features/es-builtins      |   115.136 |     0.2%
operator-linebreak                            |   113.357 |     0.2%
no-underscore-dangle                          |   113.157 |     0.2%
no-unexpected-multiline                       |   107.740 |     0.2%
no-control-regex                              |   101.440 |     0.2%
grouped-accessor-pairs                        |   100.349 |     0.2%
max-statements-per-line                       |    99.740 |     0.2%
no-octal-escape                               |    99.218 |     0.2%
semi-spacing                                  |    99.175 |     0.2%
no-unused-vars                                |    99.071 |     0.2%
no-multi-str                                  |    97.792 |     0.2%
no-redeclare                                  |    92.644 |     0.2%
quotes                                        |    88.344 |     0.1%
node/no-unsupported-features/node-builtins    |    77.163 |     0.1%
computed-property-spacing                     |    75.018 |     0.1%
no-unmodified-loop-condition                  |    74.346 |     0.1%
prefer-template                               |    70.312 |     0.1%
object-property-newline                       |    68.797 |     0.1%
no-mixed-spaces-and-tabs                      |    65.018 |     0.1%
no-nonoctal-decimal-escape                    |    62.284 |     0.1%
new-cap                                       |    62.012 |     0.1%
function-call-argument-newline                |    61.346 |     0.1%
no-multiple-empty-lines                       |    60.591 |     0.1%
no-misleading-character-class                 |    60.174 |     0.1%
no-floating-decimal                           |    59.704 |     0.1%
no-restricted-properties                      |    58.057 |     0.1%
dot-location                                  |    57.851 |     0.1%
semi-style                                    |    56.146 |     0.1%
block-spacing                                 |    56.116 |     0.1%
node/no-unpublished-import                    |    56.056 |     0.1%
no-unsafe-optional-chaining                   |    53.339 |     0.1%
no-unreachable                                |    51.669 |     0.1%
eslint-plugin/prefer-message-ids              |    50.855 |     0.1%
node/no-unsupported-features/es-syntax        |    49.894 |     0.1%
no-undef-init                                 |    48.736 |     0.1%
no-useless-computed-key                       |    48.656 |     0.1%
no-eval                                       |    48.296 |     0.1%
brace-style                                   |    47.560 |     0.1%
no-tabs                                       |    46.212 |     0.1%
no-this-before-super                          |    45.570 |     0.1%
consistent-return                             |    45.217 |     0.1%
constructor-super                             |    44.315 |     0.1%
semi                                          |    43.796 |     0.1%
eslint-plugin/prefer-replace-text             |    43.589 |     0.1%
lines-around-comment                          |    40.843 |     0.1%
node/no-deprecated-api                        |    40.121 |     0.1%
eslint-plugin/no-only-tests                   |    39.708 |     0.1%
space-before-blocks                           |    39.224 |     0.1%
eslint-plugin/prefer-output-null              |    38.794 |     0.1%
no-octal                                      |    35.287 |     0.1%
arrow-spacing                                 |    35.282 |     0.1%
no-useless-backreference                      |    33.319 |     0.1%
node/no-mixed-requires                        |    33.254 |     0.1%
no-self-compare                               |    32.856 |     0.1%
node/callback-return                          |    32.666 |     0.1%
array-callback-return                         |    32.438 |     0.1%
no-use-before-define                          |    32.008 |     0.1%
eslint-plugin/fixer-return                    |    32.006 |     0.1%
node/no-extraneous-import                     |    31.336 |     0.1%
no-unreachable-loop                           |    31.135 |     0.1%
no-unused-expressions                         |    29.482 |     0.0%
no-useless-call                               |    29.336 |     0.0%
no-lone-blocks                                |    28.769 |     0.0%
eslint-plugin/report-message-format           |    28.678 |     0.0%
no-shadow                                     |    28.022 |     0.0%
space-unary-ops                               |    27.946 |     0.0%
node/no-path-concat                           |    26.686 |     0.0%
eslint-plugin/require-meta-fixable            |    26.670 |     0.0%
jsdoc/no-bad-blocks                           |    26.501 |     0.0%
no-implied-eval                               |    26.279 |     0.0%
no-iterator                                   |    25.608 |     0.0%
node/handle-callback-err                      |    25.598 |     0.0%
eslint-plugin/prefer-placeholders             |    24.183 |     0.0%
no-dupe-else-if                               |    23.725 |     0.0%
getter-return                                 |    23.195 |     0.0%
dot-notation                                  |    23.019 |     0.0%
space-before-function-paren                   |    22.761 |     0.0%
no-const-assign                               |    22.704 |     0.0%
prefer-promise-reject-errors                  |    22.486 |     0.0%
no-setter-return                              |    22.320 |     0.0%
prefer-spread                                 |    22.109 |     0.0%
no-param-reassign                             |    22.072 |     0.0%
spaced-comment                                |    22.037 |     0.0%
eslint-plugin/test-case-property-ordering     |    20.972 |     0.0%
curly                                         |    20.545 |     0.0%
no-caller                                     |    20.542 |     0.0%
no-prototype-builtins                         |    20.356 |     0.0%
node/no-unpublished-bin                       |    20.142 |     0.0%
prefer-exponentiation-operator                |    19.884 |     0.0%
eslint-plugin/no-deprecated-report-api        |    19.879 |     0.0%
eslint-plugin/no-unused-placeholders          |    19.223 |     0.0%
eslint-plugin/no-missing-placeholders         |    19.026 |     0.0%
eslint-plugin/require-meta-has-suggestions    |    18.614 |     0.0%
jsdoc/require-jsdoc                           |    18.429 |     0.0%
no-shadow-restricted-names                    |    18.281 |     0.0%
template-curly-spacing                        |    17.778 |     0.0%
strict                                        |    17.770 |     0.0%
no-extend-native                              |    17.629 |     0.0%
eslint-plugin/consistent-output               |    17.460 |     0.0%
prefer-const                                  |    17.407 |     0.0%
prefer-numeric-literals                       |    17.285 |     0.0%
wrap-iife                                     |    17.238 |     0.0%
eslint-plugin/no-deprecated-context-methods   |    16.091 |     0.0%
no-invalid-this                               |    15.767 |     0.0%
no-proto                                      |    15.673 |     0.0%
no-loop-func                                  |    15.245 |     0.0%
no-constructor-return                         |    14.728 |     0.0%
no-invalid-regexp                             |    14.577 |     0.0%
no-constant-condition                         |    14.477 |     0.0%
no-sparse-arrays                              |    14.350 |     0.0%
arrow-body-style                              |    14.219 |     0.0%
no-extra-boolean-cast                         |    14.047 |     0.0%
class-methods-use-this                        |    13.990 |     0.0%
no-extra-bind                                 |    13.811 |     0.0%
eslint-plugin/no-useless-token-range          |    13.298 |     0.0%
no-return-assign                              |    13.206 |     0.0%
func-style                                    |    13.198 |     0.0%
no-unsafe-finally                             |    13.023 |     0.0%
no-array-constructor                          |    12.929 |     0.0%
prefer-arrow-callback                         |    12.844 |     0.0%
eslint-plugin/require-meta-schema             |    12.470 |     0.0%
eslint-comments/require-description           |    11.766 |     0.0%
use-isnan                                     |    11.692 |     0.0%
eqeqeq                                        |    11.461 |     0.0%
no-obj-calls                                  |    10.687 |     0.0%
eslint-comments/no-unlimited-disable          |    10.638 |     0.0%
yoda                                          |    10.555 |     0.0%
no-inner-declarations                         |    10.246 |     0.0%
eslint-plugin/test-case-shorthand-strings     |    10.029 |     0.0%
no-undefined                                  |     9.712 |     0.0%
no-useless-concat                             |     9.204 |     0.0%
eslint-plugin/require-meta-docs-url           |     8.808 |     0.0%
no-dupe-args                                  |     8.776 |     0.0%
one-var-declaration-per-line                  |     8.145 |     0.0%
prefer-regex-literals                         |     8.120 |     0.0%
default-param-last                            |     7.816 |     0.0%
no-func-assign                                |     7.507 |     0.0%
node/no-exports-assign                        |     7.457 |     0.0%
no-fallthrough                                |     7.354 |     0.0%
prefer-rest-params                            |     6.830 |     0.0%
no-global-assign                              |     6.763 |     0.0%
require-unicode-regexp                        |     6.593 |     0.0%
no-new-object                                 |     6.566 |     0.0%
no-compare-neg-zero                           |     6.543 |     0.0%
no-self-assign                                |     6.533 |     0.0%
no-empty                                      |     5.854 |     0.0%
no-console                                    |     5.738 |     0.0%
template-tag-spacing                          |     5.491 |     0.0%
no-else-return                                |     5.235 |     0.0%
no-unsafe-negation                            |     4.957 |     0.0%
eslint-plugin/require-meta-type               |     4.838 |     0.0%
eslint-plugin/require-meta-docs-description   |     4.713 |     0.0%
no-var                                        |     4.634 |     0.0%
internal-rules/no-invalid-meta                |     4.616 |     0.0%
no-duplicate-case                             |     4.554 |     0.0%
no-confusing-arrow                            |     4.396 |     0.0%
arrow-parens                                  |     4.108 |     0.0%
eol-last                                      |     4.085 |     0.0%
valid-typeof                                  |     4.059 |     0.0%
no-cond-assign                                |     3.953 |     0.0%
require-yield                                 |     3.354 |     0.0%
no-dupe-class-members                         |     3.292 |     0.0%
radix                                         |     3.117 |     0.0%
node/no-missing-import                        |     2.882 |     0.0%
new-parens                                    |     2.720 |     0.0%
switch-colon-spacing                          |     2.689 |     0.0%
operator-assignment                           |     2.641 |     0.0%
generator-star-spacing                        |     2.203 |     0.0%
no-useless-rename                             |     2.070 |     0.0%
no-new-func                                   |     1.924 |     0.0%
no-new-wrappers                               |     1.909 |     0.0%
no-new-symbol                                 |     1.869 |     0.0%
no-extra-semi                                 |     1.849 |     0.0%
eslint-comments/no-aggregating-enable         |     1.754 |     0.0%
eslint-comments/disable-enable-pair           |     1.667 |     0.0%
rest-spread-spacing                           |     1.602 |     0.0%
node/no-new-require                           |     1.539 |     0.0%
unicode-bom                                   |     1.538 |     0.0%
symbol-description                            |     1.524 |     0.0%
no-empty-character-class                      |     1.469 |     0.0%
eslint-comments/no-duplicate-disable          |     1.391 |     0.0%
no-delete-var                                 |     1.182 |     0.0%
no-undef                                      |     1.165 |     0.0%
sort-keys                                     |     1.062 |     0.0%
node/shebang                                  |     1.035 |     0.0%
no-unneeded-ternary                           |     1.029 |     0.0%
eslint-comments/no-unused-enable              |     1.001 |     0.0%
default-case                                  |     0.919 |     0.0%
no-nested-ternary                             |     0.783 |     0.0%
no-empty-pattern                              |     0.742 |     0.0%
eslint-plugin/prefer-object-rule              |     0.658 |     0.0%
no-throw-literal                              |     0.604 |     0.0%
for-direction                                 |     0.590 |     0.0%
no-useless-constructor                        |     0.554 |     0.0%
no-case-declarations                          |     0.545 |     0.0%
no-ex-assign                                  |     0.498 |     0.0%
no-irregular-whitespace                       |     0.457 |     0.0%
no-labels                                     |     0.440 |     0.0%
no-new                                        |     0.421 |     0.0%
yield-star-spacing                            |     0.418 |     0.0%
no-useless-catch                              |     0.343 |     0.0%
no-class-assign                               |     0.303 |     0.0%
guard-for-in                                  |     0.263 |     0.0%
no-sequences                                  |     0.238 |     0.0%
default-case-last                             |     0.220 |     0.0%
no-unused-labels                              |     0.195 |     0.0%
no-label-var                                  |     0.000 |     0.0%
no-async-promise-executor                     |     0.000 |     0.0%
no-debugger                                   |     0.000 |     0.0%
no-import-assign                              |     0.000 |     0.0%
no-with                                       |     0.000 |     0.0%
no-restricted-syntax                          |     0.000 |     0.0%
Validating JSON Files
Validating Markdown Files
Rule | Time (ms) | Relative
:----|----------:|--------:

key-spacing is 899.327ms (1.5%) before, 186.664ms (0.3%) after.

@nzakas
Copy link
Member

nzakas commented Nov 3, 2021

Awesome work!

Copy link
Member

@aladdin-add aladdin-add left a comment

LGTM 💯

@mdjermanovic mdjermanovic merged commit 4fd7a6c into main Nov 5, 2021
14 checks passed
@mdjermanovic mdjermanovic deleted the keyspacing-perf-calcfix branch Nov 5, 2021
@eslint-github-bot eslint-github-bot bot locked and limited conversation to collaborators May 5, 2022
@eslint-github-bot eslint-github-bot bot added the archived due to age label May 5, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
accepted archived due to age chore rule
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants