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
Initial trait definition for relocatable
#6212
Conversation
Can one of the admins verify this patch? |
libs/core/algorithms/include/hpx/algorithms/traits/pointer_category.hpp
Outdated
Show resolved
Hide resolved
libs/core/algorithms/include/hpx/algorithms/traits/pointer_category.hpp
Outdated
Show resolved
Hide resolved
libs/core/algorithms/include/hpx/algorithms/traits/pointer_category.hpp
Outdated
Show resolved
Hide resolved
Maybe adding tests would help :) |
libs/core/algorithms/include/hpx/algorithms/traits/is_relocatable.hpp
Outdated
Show resolved
Hide resolved
libs/core/algorithms/include/hpx/algorithms/traits/is_relocatable.hpp
Outdated
Show resolved
Hide resolved
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.
LGTM, thanks! However, please fix the clang-format and cmake-format issues.
I like it. |
@isidorostsa Wrt testing: I think having a couple of tests would be nice, most likely compile tests using |
Thanks for the hints, I will add the tests later today |
@isidorostsa Please don't think we're ignoring this. Let's wait for the release of HPX V1.9.0 (next week) before merging. |
@hkaiser That's great to hear! I wanted to ask you, was I correct to add my name to the copyrights list section of all the files I changed? |
The rule of thumb we usually apply is that one should add his/her name to the copyrights whenever the person touched on ~20% of the file.
|
@isidorostsa could you please rebase this onto master, now that the release is out? |
Co-authored-by: Hartmut Kaiser <hartmut.kaiser@gmail.com>
(added the dash between last names)
I think I did it, but could you confirm that as this is not something I've done before? Thanks! |
LGTM, thanks. |
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.
I think this is good to be merged. LGTM, thanks!
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.
|
@isidorostsa Congratulations, your first PR to the HPX repository has just been merged! As a 'thank you' we offer a free STE||AR-Group t-shirt to all of our first-time contributors. If you are interested in receiving one, please get back to me directly so we can set up the delivery. |
@isidorostsa after merging your PR, compilation is failing across the board, see for instance here: https://github.com/STEllAR-GROUP/hpx/actions/runs/4893500203/jobs/8736534493. Would you have the time to investigate? |
Please see #6233 for a possible fix. |
Hello, yes, getting to it rn |
This is a draft pr to implement the basic traits for P1144 (relocatable).
I defined a meta function (
is_relocatable
) andpointer_relocate_category
allongside the existingpointer_copy_category
andpointer_move_category
.A type is
relocatable
if it is not tied to a specific location in memory. (An example object that is not relocatable is std::mutex)The aim of this branch is to implement the trivially relocatable trait and the faster data transfer algorithms it allows us to use.
To move forward I ask if this is the right file to the
is_relocatable
definitions.I believe the
trivially_copyable_pointer
part of this file focuses on if an iterator is suitable for a contiguousmemcpy
, and not in determining if the underlying object istrivially_copyable
; it usesstd::is_trivially_copyable
for that. At the moment however there is nostd::is_trivially_relocatable
orstd::is_relocatable
, so these have to be implemented first.At the moment I have placed
hpx::is_relocatable
in this file, should I place it somewhere else?Thanks!