-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
no-cycle performance in 2.30 is even worse than 2.27.5 #3060
Comments
It depends on the size of the codebase and a number of other factors - try setting the disableScc option to true? |
@ljharb this project has around 500 files and 156k lines of code. Rule | Time (ms) | Relative
:-----------------------------------------------|----------:|--------:
import/no-cycle | 5751.410 | 20.6% ===============================================================================
Language Files Lines Code Comments Blanks
===============================================================================
JavaScript 5 86 69 6 11
TypeScript 550 169737 156696 6472 6569
===============================================================================
Total 555 169823 156765 6478 6580
=============================================================================== |
oh, I just found another similar issue. #3047 |
cc @soryy708 |
btw, in another project that has more than 7800 files. a 16 cores 32 GB memory server cannot finish in 1 hour, and the node(lint) process took almost 8G memory |
I had a project where SCC clearly made a significant good impact: With 7k files, and almost 400kloc, So what is it about your project's configuration that makes it so slow and resource-intensive? |
I posted a result when setting And this comment might be the reason: un-ts#113 (comment) Our project is pretty huge, with over 2 million lines of code... it's quite hard to put it here. eslint version is |
The linked comment is in I doubt that the impact of their proposed replacing of As for your 2mloc project, is that the same that has only 7800 files? |
Created an issue to add |
our project is a mono repo, including many projects. the whole repo is over 2mloc. and one of the largest one is over 7800 files. I'm using a smaller project to test(544 files, the profiling file generated from this project) here is the profiling file. and using https://www.speedscope.app/ (please let me know once you downloaded, I'll delete it): isolate-0x51a8150-1444136-v8.log.json |
Why are we spending so much time in SCC? It's a linear algorithm. Are we running it many times? |
@AnnatarHe Please try version 2.31.0, it includes the fix from #3068. |
@soryy708 no significant difference. so it looks like the new version brings the performance back to previous version disableScc: trueRule | Time (ms) | Relative
:-----------------------------------------------|-----------:|--------:
import/no-cycle | 110489.719 | 90.2%
prettier/prettier | 9351.288 | 7.6%
import/namespace | 834.045 | 0.7%
unused-imports/no-unused-imports | 531.654 | 0.4%
Executed in 137.36 secs fish external
usr time 163.09 secs 306.00 micros 163.09 secs
sys time 11.42 secs 173.00 micros 11.42 secs disableScc: falseRule | Time (ms) | Relative
:-----------------------------------------------|-----------:|--------:
import/no-cycle | 116099.013 | 90.8%
prettier/prettier | 8842.955 | 6.9%
import/namespace | 924.044 | 0.7%
unused-imports/no-unused-imports | 561.242 | 0.4%
Executed in 143.02 secs fish external
usr time 171.97 secs 327.00 micros 171.97 secs
sys time 11.48 secs 184.00 micros 11.48 secs
|
@AnnatarHe pardon I think I don't follow, which one of the multiple projects mentioned was this recent benchmark in? When you say
which version do you mean? |
|
Hey, Is there any benchmark for the new SCC algorithm?
In a project I am maintaining, 2x more time is used compared with 2.27.5.
it has 544 files project(in monorepo).
2.30.0
2.27.5
The text was updated successfully, but these errors were encountered: