Open Misoder opened 4 years ago
Thanks for the report @Misoder, have you tried invalidating the cache? Also can you provide a sample project that can replicate the issue?
@Misoder @raniejade this may not be spek but Kotlin itself. I've experienced the same with large files (1k+ code) and heavy usage of lambdas, lambdas with receivers and when expressions. Spek's nature is to use many lambdas. How large are your files?
I've seen similar things @arturbosch - have you opened an issue with JetBrains? Seems like it might be an issue in the IDE or compiler like you suggest.
@charleskorn I haven't but I saw a lot of similar performance issues last time I checked in 2019. Hopefully the new compiler frontend (FIR) will resolve these issues.
I'm currently on IntelliJ IDEA 2020.1.2 (Ultimate Edition) Build #IU-201.7846.76 (although the problem has been present on earlier versions) and Spek 2.0.9. OS is macOS 10.15.5 Catalina.
When writing Spek tests there's a high CPU load up to the point where it's almost unbearable. Auto completion and code inspection takes several seconds. This is not an issue when writing code elsewhere. Looking at the IntelliJ Activity Monitor there's usually two things that eats CPU:
<unidentified: JobScheduler FJ Pool>
and<JIT Compiler>