{"action":"created","issue":{"url":"https://api.github.com/repos/ReactiveCocoa/ReactiveCocoa/issues/2521","labels_url":"https://api.github.com/repos/ReactiveCocoa/ReactiveCocoa/issues/2521/labels{/name}","comments_url":"https://api.github.com/repos/ReactiveCocoa/ReactiveCocoa/issues/2521/comments","events_url":"https://api.github.com/repos/ReactiveCocoa/ReactiveCocoa/issues/2521/events","html_url":"https://github.com/ReactiveCocoa/ReactiveCocoa/pull/2521","id":113952208,"number":2521,"title":"refactored and re-implemented combineLatest() to use a single OSSpinLock regardless of tuple size","user":{"login":"mishagray","id":303665,"avatar_url":"https://avatars.githubusercontent.com/u/303665?v=3","gravatar_id":"","url":"https://api.github.com/users/mishagray","html_url":"https://github.com/mishagray","followers_url":"https://api.github.com/users/mishagray/followers","following_url":"https://api.github.com/users/mishagray/following{/other_user}","gists_url":"https://api.github.com/users/mishagray/gists{/gist_id}","starred_url":"https://api.github.com/users/mishagray/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mishagray/subscriptions","organizations_url":"https://api.github.com/users/mishagray/orgs","repos_url":"https://api.github.com/users/mishagray/repos","events_url":"https://api.github.com/users/mishagray/events{/privacy}","received_events_url":"https://api.github.com/users/mishagray/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-10-29T00:04:32Z","updated_at":"2015-10-29T01:41:19Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/ReactiveCocoa/ReactiveCocoa/pulls/2521","html_url":"https://github.com/ReactiveCocoa/ReactiveCocoa/pull/2521","diff_url":"https://github.com/ReactiveCocoa/ReactiveCocoa/pull/2521.diff","patch_url":"https://github.com/ReactiveCocoa/ReactiveCocoa/pull/2521.patch"},"body":"Added simple Tuple extensions for packing and unpacking Tuples into Arrays.\r\n    \r\ncompletely reimplemented  the combineLatest(signals : [Signal<Value,Error]) -> Signal<[Value],Error> to use a single array of values, and and a single spin lock, regardless of the number of elements in the array.   \r\n    \r\nNo more 'climbing' chain of   .combineLatest().combineLatestWith().map(repack) for each additional tuple size.\r\n\r\nOld Solution had  O(N) NSLocks, and copies of the 'latestValue' (where N = tuple or array size).\r\n\r\nNew solution uses a single array of latest Values, a single spin lock, a won't create a set of blocks that could overflow the stack.  O(1) stack depth!\r\n"},"comment":{"url":"https://api.github.com/repos/ReactiveCocoa/ReactiveCocoa/issues/comments/152048690","html_url":"https://github.com/ReactiveCocoa/ReactiveCocoa/pull/2521#issuecomment-152048690","issue_url":"https://api.github.com/repos/ReactiveCocoa/ReactiveCocoa/issues/2521","id":152048690,"user":{"login":"NachoSoto","id":685609,"avatar_url":"https://avatars.githubusercontent.com/u/685609?v=3","gravatar_id":"","url":"https://api.github.com/users/NachoSoto","html_url":"https://github.com/NachoSoto","followers_url":"https://api.github.com/users/NachoSoto/followers","following_url":"https://api.github.com/users/NachoSoto/following{/other_user}","gists_url":"https://api.github.com/users/NachoSoto/gists{/gist_id}","starred_url":"https://api.github.com/users/NachoSoto/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NachoSoto/subscriptions","organizations_url":"https://api.github.com/users/NachoSoto/orgs","repos_url":"https://api.github.com/users/NachoSoto/repos","events_url":"https://api.github.com/users/NachoSoto/events{/privacy}","received_events_url":"https://api.github.com/users/NachoSoto/received_events","type":"User","site_admin":false},"created_at":"2015-10-29T01:41:19Z","updated_at":"2015-10-29T01:41:19Z","body":"Thanks for the PR! There are a few very important issues with the new implementation though that I'm afraid we would not be able to accept.\r\nThe idea of reducing the number of copies and locks is important, however. Did you happen to measure the impact of this change?"}}