Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-20037

High CPU usage and long build times using XCode 1.4 olugin

      When building a huge iOS or OSX project with lots of files we get very long build times. Using plugin version 1.33 build time is around 9 minutes and using plugin version 1.4 it takes about 40 minutes (everything else is the same). From my research, the build itself is finished after the same 9 minutes (output exists in the workspace) but the job is not reported as finished due to very big xcodebuild output that is still being processed on the Jenkins server. During this whole time the thread responsible for the slave connection is busy 100% taking whole core(also, console is in lag - you can see as if build is still running).

      Looks like the xcode output parser feature (using regex) that was introduced in 1.4 is not very efficient in terms of CPU usage. That creates the lag in console output and the job end time itself.

          [JENKINS-20037] High CPU usage and long build times using XCode 1.4 olugin

          Jay Graves added a comment -

          I can confirm that 1.4 drastically increases build time. I had a build go from 4 min to 45 min. Reverting back to 1.3.3 brought the faster builds back.

          Jay Graves added a comment - I can confirm that 1.4 drastically increases build time. I had a build go from 4 min to 45 min. Reverting back to 1.3.3 brought the faster builds back.

          John Wu added a comment -

          I've went from 1 minute to around 4 minutes. I am using cocoapods though, not sure if that affects anything.

          John Wu added a comment - I've went from 1 minute to around 4 minutes. I am using cocoapods though, not sure if that affects anything.

          Mike Simons added a comment -

          I am also seeing this issue with our iOS builds. Our builds have gone from ~4 minutes to ~40 minutes.

          Mike Simons added a comment - I am also seeing this issue with our iOS builds. Our builds have gone from ~4 minutes to ~40 minutes.

          Mike Simons added a comment -

          I created a pull request that will revert the change that caused the performance regression: https://github.com/jenkinsci/xcode-plugin/pull/36

          This basically makes the plugin unusuable and needs to be address/released ASAP.

          Mike Simons added a comment - I created a pull request that will revert the change that caused the performance regression: https://github.com/jenkinsci/xcode-plugin/pull/36 This basically makes the plugin unusuable and needs to be address/released ASAP.

          Justin Kerr added a comment -

          Can also verify a dramatic slow-down with the 1.4 update. Builds go from ~4 minutes up to ~35 minutes. Reverting to 1.3.3 brought the speed back.

          Justin Kerr added a comment - Can also verify a dramatic slow-down with the 1.4 update. Builds go from ~4 minutes up to ~35 minutes. Reverting to 1.3.3 brought the speed back.

          Code changed in jenkins
          User: Mike Simons
          Path:
          src/main/java/au/com/rayh/XCodeBuildOutputParser.java
          http://jenkins-ci.org/commit/xcode-plugin/9aca950d237f718fd471fcd937e4883cec90fa2d
          Log:
          Revert 46f1770 to address a huge performance regression. [FIXED JENKINS-20037]

          46f1770 caused the regression in performance seen this issue: https://issues.jenkins-ci.org/browse/JENKINS-20037

          Reverting to use the more conservative .matches reduces parse time back to a reasonable level.

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Mike Simons Path: src/main/java/au/com/rayh/XCodeBuildOutputParser.java http://jenkins-ci.org/commit/xcode-plugin/9aca950d237f718fd471fcd937e4883cec90fa2d Log: Revert 46f1770 to address a huge performance regression. [FIXED JENKINS-20037] 46f1770 caused the regression in performance seen this issue: https://issues.jenkins-ci.org/browse/JENKINS-20037 Reverting to use the more conservative .matches reduces parse time back to a reasonable level.

          Code changed in jenkins
          User: Mike Simons
          Path:
          src/main/java/au/com/rayh/XCodeBuildOutputParser.java
          http://jenkins-ci.org/commit/xcode-plugin/151afdc8049a6f163f466ea47d08c3a8d2337b2d
          Log:
          Merge pull request #36 from waltflanagan/master

          [FIXED JENKINS-20037]

          Compare: https://github.com/jenkinsci/xcode-plugin/compare/932a64261045...151afdc8049a

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Mike Simons Path: src/main/java/au/com/rayh/XCodeBuildOutputParser.java http://jenkins-ci.org/commit/xcode-plugin/151afdc8049a6f163f466ea47d08c3a8d2337b2d Log: Merge pull request #36 from waltflanagan/master [FIXED JENKINS-20037] Compare: https://github.com/jenkinsci/xcode-plugin/compare/932a64261045...151afdc8049a

            waltflanagan Mike Simons
            eakraly Pavel Punsky
            Votes:
            2 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: