{"action":"created","issue":{"url":"https://api.github.com/repos/composer/composer/issues/5785","repository_url":"https://api.github.com/repos/composer/composer","labels_url":"https://api.github.com/repos/composer/composer/issues/5785/labels{/name}","comments_url":"https://api.github.com/repos/composer/composer/issues/5785/comments","events_url":"https://api.github.com/repos/composer/composer/issues/5785/events","html_url":"https://github.com/composer/composer/pull/5785","id":183029996,"number":5785,"title":"Enhance performance by removing count() from Solver's main loop","user":{"login":"nicolas-grekas","id":243674,"avatar_url":"https://avatars.githubusercontent.com/u/243674?v=3","gravatar_id":"","url":"https://api.github.com/users/nicolas-grekas","html_url":"https://github.com/nicolas-grekas","followers_url":"https://api.github.com/users/nicolas-grekas/followers","following_url":"https://api.github.com/users/nicolas-grekas/following{/other_user}","gists_url":"https://api.github.com/users/nicolas-grekas/gists{/gist_id}","starred_url":"https://api.github.com/users/nicolas-grekas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nicolas-grekas/subscriptions","organizations_url":"https://api.github.com/users/nicolas-grekas/orgs","repos_url":"https://api.github.com/users/nicolas-grekas/repos","events_url":"https://api.github.com/users/nicolas-grekas/events{/privacy}","received_events_url":"https://api.github.com/users/nicolas-grekas/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/composer/composer/labels/Reviewed","name":"Reviewed","color":"009800"}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/composer/composer/milestones/16","html_url":"https://github.com/composer/composer/milestones/1.3","labels_url":"https://api.github.com/repos/composer/composer/milestones/16/labels","id":1861319,"number":16,"title":"1.3","description":"","creator":{"login":"Seldaek","id":183678,"avatar_url":"https://avatars.githubusercontent.com/u/183678?v=3","gravatar_id":"","url":"https://api.github.com/users/Seldaek","html_url":"https://github.com/Seldaek","followers_url":"https://api.github.com/users/Seldaek/followers","following_url":"https://api.github.com/users/Seldaek/following{/other_user}","gists_url":"https://api.github.com/users/Seldaek/gists{/gist_id}","starred_url":"https://api.github.com/users/Seldaek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Seldaek/subscriptions","organizations_url":"https://api.github.com/users/Seldaek/orgs","repos_url":"https://api.github.com/users/Seldaek/repos","events_url":"https://api.github.com/users/Seldaek/events{/privacy}","received_events_url":"https://api.github.com/users/Seldaek/received_events","type":"User","site_admin":false},"open_issues":10,"closed_issues":20,"state":"open","created_at":"2016-07-02T16:26:42Z","updated_at":"2016-10-14T14:31:14Z","due_on":null,"closed_at":null},"comments":12,"created_at":"2016-10-14T11:45:26Z","updated_at":"2016-10-14T16:33:23Z","closed_at":"2016-10-14T14:31:13Z","pull_request":{"url":"https://api.github.com/repos/composer/composer/pulls/5785","html_url":"https://github.com/composer/composer/pull/5785","diff_url":"https://github.com/composer/composer/pull/5785.diff","patch_url":"https://github.com/composer/composer/pull/5785.patch"},"body":"Thanks to [blackfire.io](https://blackfire.io), I spotted that `count()` is hurting performance for no reason here. It was called 730023965 times in the case I was working on, not unusual.\r\n\r\nUsing `time` to \"profile\" the patch, `composer up` dropped from 290s to 140s (PHP7.1)!"},"comment":{"url":"https://api.github.com/repos/composer/composer/issues/comments/253852744","html_url":"https://github.com/composer/composer/pull/5785#issuecomment-253852744","issue_url":"https://api.github.com/repos/composer/composer/issues/5785","id":253852744,"user":{"login":"stof","id":439401,"avatar_url":"https://avatars.githubusercontent.com/u/439401?v=3","gravatar_id":"","url":"https://api.github.com/users/stof","html_url":"https://github.com/stof","followers_url":"https://api.github.com/users/stof/followers","following_url":"https://api.github.com/users/stof/following{/other_user}","gists_url":"https://api.github.com/users/stof/gists{/gist_id}","starred_url":"https://api.github.com/users/stof/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stof/subscriptions","organizations_url":"https://api.github.com/users/stof/orgs","repos_url":"https://api.github.com/users/stof/repos","events_url":"https://api.github.com/users/stof/events{/privacy}","received_events_url":"https://api.github.com/users/stof/received_events","type":"User","site_admin":false},"created_at":"2016-10-14T16:33:23Z","updated_at":"2016-10-14T16:33:23Z","body":"@naderman memory consumption is the same in the blackfire comparison ( ``+0.018%`` is not relevant IMO).\r\n\r\nRegarding the calls to ``add``, this is because ``selectAndInstall`` (one of the way to alter rules) is called twice, but only one of the recomputes the ``$ruleCount``. Btw, ``setPropagateLearn`` is also called once outside ``selectAndInstall``, and this also misses the recomputation"}}
{"actor":{"display_login":"stof"}}