{"action":"created","issue":{"url":"https://api.github.com/repos/ericniebler/range-v3/issues/700","repository_url":"https://api.github.com/repos/ericniebler/range-v3","labels_url":"https://api.github.com/repos/ericniebler/range-v3/issues/700/labels{/name}","comments_url":"https://api.github.com/repos/ericniebler/range-v3/issues/700/comments","events_url":"https://api.github.com/repos/ericniebler/range-v3/issues/700/events","html_url":"https://github.com/ericniebler/range-v3/issues/700","id":243395234,"number":700,"title":"view::join is quite slow","user":{"login":"h-2","id":2996863,"avatar_url":"https://avatars2.githubusercontent.com/u/2996863?v=4","gravatar_id":"","url":"https://api.github.com/users/h-2","html_url":"https://github.com/h-2","followers_url":"https://api.github.com/users/h-2/followers","following_url":"https://api.github.com/users/h-2/following{/other_user}","gists_url":"https://api.github.com/users/h-2/gists{/gist_id}","starred_url":"https://api.github.com/users/h-2/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/h-2/subscriptions","organizations_url":"https://api.github.com/users/h-2/orgs","repos_url":"https://api.github.com/users/h-2/repos","events_url":"https://api.github.com/users/h-2/events{/privacy}","received_events_url":"https://api.github.com/users/h-2/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":19,"created_at":"2017-07-17T13:27:25Z","updated_at":"2017-08-29T18:26:10Z","closed_at":null,"body":"```cpp\r\nstd::vector<std::vector<char>> two_dim;\r\n// fill two_dim with lots of data\r\n\r\nstd::vector<char> foo = two_dim | view::join;\r\n```\r\nis more than three times slower than:\r\n```cpp\r\nstd::vector<std::vector<char>> two_dim;\r\n// fill two_dim with lots of data\r\n\r\nstd::vector<char> foo;\r\nfor (auto && s : two_dim)\r\n     foo.insert(foo.end(), s.begin(), s.end());\r\n```\r\n\r\nIs this\r\n* unexpected; *or*\r\n* expected and unavoidable; *or*\r\n* expected, but avoidable?\r\n"},"comment":{"url":"https://api.github.com/repos/ericniebler/range-v3/issues/comments/325752523","html_url":"https://github.com/ericniebler/range-v3/issues/700#issuecomment-325752523","issue_url":"https://api.github.com/repos/ericniebler/range-v3/issues/700","id":325752523,"user":{"login":"CaseyCarter","id":456873,"avatar_url":"https://avatars2.githubusercontent.com/u/456873?v=4","gravatar_id":"","url":"https://api.github.com/users/CaseyCarter","html_url":"https://github.com/CaseyCarter","followers_url":"https://api.github.com/users/CaseyCarter/followers","following_url":"https://api.github.com/users/CaseyCarter/following{/other_user}","gists_url":"https://api.github.com/users/CaseyCarter/gists{/gist_id}","starred_url":"https://api.github.com/users/CaseyCarter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CaseyCarter/subscriptions","organizations_url":"https://api.github.com/users/CaseyCarter/orgs","repos_url":"https://api.github.com/users/CaseyCarter/repos","events_url":"https://api.github.com/users/CaseyCarter/events{/privacy}","received_events_url":"https://api.github.com/users/CaseyCarter/received_events","type":"User","site_admin":false},"created_at":"2017-08-29T18:26:10Z","updated_at":"2017-08-29T18:26:10Z","body":"> In addition, the join view reuses memory by storing things in a variant. That probably kills alias analysis.\r\n\r\nOnly the \"join and inject delimiters\" specialization uses a variant, so that fact isn't germane to these numbers. That said, using a variant to reduce the total size of the join view iterators was likely a poor choice, it would be an improvement to move all of that state from the iterators into the view itself."}}
{"actor":{"display_login":"CaseyCarter"}}