Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Excessive copies of lambdas #17

Open
DaoWen opened this issue Jun 22, 2016 · 0 comments
Open

Excessive copies of lambdas #17

DaoWen opened this issue Jun 22, 2016 · 0 comments
Assignees
Labels

Comments

@DaoWen
Copy link
Contributor

DaoWen commented Jun 22, 2016

We need to refactor the C++ API to avoid passing function objects by value.

Currently, functions like async accept their function object arguments by value, which results in a lot of extra copies. For a typical async (see test copies0), there are two or three extra copies. When using the forasync family of functions, the issue is much worse, with thousands of unneeded copies for a single 3D loop in from of our tests (see test copies1).

DaoWen added a commit that referenced this issue Jun 22, 2016
This should eliminate some duplicate logic and simplify the C++ API.
This should also eliminate some functor copies that were being caused by
by-value parameter passing of user functors (see issue #17).
DaoWen added a commit that referenced this issue Jun 22, 2016
This should eliminate some duplicate logic and simplify the C++ API.
This should also eliminate a significant number of functor copies that
were caused by by-value parameter passing and captures of user functors
(see issue #17).
@DaoWen DaoWen added the bug label Jun 22, 2016
@DaoWen DaoWen self-assigned this Jun 22, 2016
DaoWen added a commit that referenced this issue Jun 27, 2016
This should eliminate some duplicate logic and simplify the C++ API.
This should also eliminate some functor copies that were being caused by
by-value parameter passing of user functors (see issue #17).
DaoWen added a commit that referenced this issue Jun 27, 2016
This should eliminate some duplicate logic and simplify the C++ API.
This should also eliminate a significant number of functor copies that
were caused by by-value parameter passing and captures of user functors
(see issue #17).
DaoWen added a commit that referenced this issue Aug 14, 2016
This should eliminate some duplicate logic and simplify the C++ API.
This should also eliminate some functor copies that were being caused by
by-value parameter passing of user functors (see issue #17).
DaoWen added a commit that referenced this issue Aug 14, 2016
This should eliminate some duplicate logic and simplify the C++ API.
This should also eliminate a significant number of functor copies that
were caused by by-value parameter passing and captures of user functors
(see issue #17).
DaoWen added a commit that referenced this issue Aug 18, 2016
This should eliminate some duplicate logic and simplify the C++ API.
This should also eliminate a significant number of functor copies that
were caused by by-value parameter passing and captures of user functors
(see issue #17).
DaoWen added a commit that referenced this issue Aug 19, 2016
This should eliminate some duplicate logic and simplify the C++ API.
This should also eliminate some functor copies that were being caused by
by-value parameter passing of user functors (see issue #17).
DaoWen added a commit that referenced this issue Aug 19, 2016
This should eliminate some duplicate logic and simplify the C++ API.
This should also eliminate a significant number of functor copies that
were caused by by-value parameter passing and captures of user functors
(see issue #17).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant