You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@groovy.apache.org by "Sterling Greene (Jira)" <ji...@apache.org> on 2021/03/04 00:58:00 UTC

[jira] [Created] (GROOVY-9964) Groovy 3 compilation is much slower than Groovy 2 compilation for Gradle build scripts

Sterling Greene created GROOVY-9964:
---------------------------------------

             Summary: Groovy 3 compilation is much slower than Groovy 2 compilation for Gradle build scripts
                 Key: GROOVY-9964
                 URL: https://issues.apache.org/jira/browse/GROOVY-9964
             Project: Groovy
          Issue Type: Improvement
          Components: Compiler
    Affects Versions: 3.0.7
            Reporter: Sterling Greene


We've seen a large increase in Groovy compilation time from Groovy 2.5.12 -> 3.0.7 for Groovy DSL based build scripts.

In this generated 500 project Gradle build, you'll see...

5s script compilation time with Groovy 2.5:
https://scans.gradle.com/s/vslkwp76qhdpu/performance/configuration?details=summary-script-compile

18-19s script compilation time with Groovy 3.0 (3-4x worse):
https://scans.gradle.com/s/pfudiyxhmtjfa/performance/configuration?details=summary-script-compile

Please try the attached project with Gradle 7.0-milestone-2 (it uses Groovy 3.0.7).
https://services.gradle.org/distributions/gradle-7.0-milestone-2-bin.zip

The simplest way to force script compilation is to delete the script cache directory in ~/.gradle/caches/<gradle version>.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)