-
-
Notifications
You must be signed in to change notification settings - Fork 429
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
Uninitialised algorithms, move using std::memcpy #6271
Uninitialised algorithms, move using std::memcpy #6271
Conversation
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Performance test reportHPX PerformanceComparison
Info
Comparison
Info
Comparison
Info
Explanation of Symbols
|
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you replace all the try { /* do loop */ } catch(...) { /*cleanup */}
with loop_with_cleanup
?
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
Signed-off-by: Hari Hara Naveen S <[email protected]>
@hkaiser requested changes have been made, only existing |
libs/core/algorithms/include/hpx/parallel/algorithms/uninitialized_default_construct.hpp
Outdated
Show resolved
Hide resolved
libs/core/algorithms/include/hpx/parallel/algorithms/uninitialized_fill.hpp
Outdated
Show resolved
Hide resolved
libs/core/algorithms/include/hpx/parallel/algorithms/uninitialized_move.hpp
Outdated
Show resolved
Hide resolved
Signed-off-by: Hari Hara Naveen S <[email protected]>
@hkaiser can you clarify what does hpx/libs/core/algorithms/include/hpx/parallel/util/loop.hpp Lines 129 to 148 in 15e8964
|
@Johan511 The code in question fails compiling when using nvcc. The |
Signed-off-by: Hari Hara Naveen S <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks better now. One question, though: you seem to have removed the cancellation tokens altogether. Can you explain the rationale for doing so, please?
@hkaiser can you please point out to the lines you are referring to? In most places I have tried not to change the implementations much. In some cases where I wrote a function which calls loop_with_cleanup, I have used the loop without any cancellation tokens, I don't see a point to cancellation tokens in this context as the only case we end the loop prematurely is when an error is thrown. This is taken case by Is there something I am missing or would you suggest I do away with tokens completely? |
So I guess your rationale of removing the cancellation tokens was that those would matter only in case of errors. That means we were slowing down the success path in order to speed up the error path. I agree to remove them in this case. |
loop_with_cleanup was checking for tok only at the start. Not sure how having tok was speeding up the error path, we were still throwing the error not doing cleanup with token. |
The token was used to stop doing work on the partitions that were not erroneous. |
Signed-off-by: Hari Hara Naveen S <[email protected]>
We don't seem to explicitly cancel the token in the catch block. |
As I said, I'm fine with removing the token if we were using it just to speed up the error path without helping the success path. |
Signed-off-by: Hari Hara Naveen S <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's get this in now. Thanks a lot!
bors merge |
Build succeeded! The publicly hosted instance of bors-ng is deprecated and will go away soon. If you want to self-host your own instance, instructions are here. If you want to switch to GitHub's built-in merge queue, visit their help page. |
In case of triviably copyable types we copy using std::memcpy. Performance improvement is almost 10x