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

Add a customization point for put_parcel so we can override actions (… #2377

Closed
wants to merge 1 commit into from

Conversation

biddisco
Copy link
Contributor

…e.g. rdma)

Copy link
Member

@sithhell sithhell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just thinking out loud here, but shouldn't the customization point be added after the target GID was split? That would be somwhere in parcelset/put_parcel.hpp maybe allow to customize which parcelport function to choose to send the parcel?

{
if (components::component_invalid == addr.type_)
{
addr.type_ = components::get_component_type<
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The setting of component type should be done in the put_parcel functions already.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this mean that this line can be removed?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, that means it should happen one layer above.

@biddisco
Copy link
Contributor Author

The specialization at this level was intended to bypas the generation of a 'parcel' altogether. I wanted to intercept things before put_parcel, but since I've not actually implemented the rdma actions yet, I'm open to these suggestions. I will play some more and start implementing it and see where it leads...

@sithhell
Copy link
Member

sithhell commented Nov 9, 2016

While thinking about this a little more, we already have this specialization in place: It's the message_handler that can be overriden for a given kind of action (we already do this for parcel coalescing). This message handler could then perform the necessary rdma action given the specific parcel (the creation of a parcel mainly involves the construction of a transfer_action).

@hkaiser
Copy link
Member

hkaiser commented Nov 9, 2016

While thinking about this a little more, we already have this specialization in place: It's the message_handler that can be overriden for a given kind of action (we already do this for parcel coalescing). This message handler could then perform the necessary rdma action given the specific parcel (the creation of a parcel mainly involves the construction of a transfer_action).

The advantage of the proposed customization point is that it avoids to create a parcel at all. Also, we already know that the message handler hook is very inefficient as it has to look up the action based on its name (string). Why add this overhead to the RDMA operations if not needed? This kind of defeats the purpose.

@biddisco biddisco force-pushed the action_customization branch 3 times, most recently from a69bf54 to 90fe626 Compare November 13, 2016 23:05
@sithhell
Copy link
Member

Well, improving the message handler hook might be something to look into then. I am just saying that this might be the perfect place to hook those RDMA operations in. It is about handling messages in a special way. The overhead of creating a parcel should be very minimal (just one allocation for the transfer action), despite the advantages you have when having a parcel: calculated message size, zero copy buffers and the target GID properly reference counted.

@biddisco biddisco force-pushed the action_customization branch 3 times, most recently from a9f9466 to 2ec2b85 Compare November 14, 2016 09:16
@hkaiser
Copy link
Member

hkaiser commented Nov 14, 2016

Well, improving the message handler hook might be something to look into then

Yes, this is on my list of things to do. Doing the hooking based on a type trait instead of the action name looks like the right thing to so.

However, handling the RDMA actions further down the chain requires to create a parcel instance which is not necessary in the first place. We don't need any transfer actions either as we want to circumvent the need for any serialization. That means there is no need to calculate the message sizes (would be trivial for the very selected set of arguments we would support anyways), no need to have zero-copy buffers either. I admit, I don't completely understand the consequences wrt the target GID, though.

Copy link
Member

@hkaiser hkaiser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM now. Thanks!

@hkaiser
Copy link
Member

hkaiser commented Nov 15, 2016

@sithhell would you be ok now to go ahead and merge this?

@hkaiser
Copy link
Member

hkaiser commented Apr 18, 2017

@sithhell, @biddisco Should this still go into the V1.0 release?

@hkaiser hkaiser modified the milestones: 1.0.0, 1.1.0 Apr 23, 2017
@msimberg
Copy link
Contributor

@sithhell, @biddisco Repeating @hkaiser's question, but for v1.1.0.

@biddisco
Copy link
Contributor Author

I use this customization point in my testing with RMA stuff, so I'd like to see it added to 1.2.0

@msimberg msimberg modified the milestones: 1.1.0, 1.2.0 Nov 17, 2017
@hkaiser
Copy link
Member

hkaiser commented Jan 26, 2018

@biddisco, @sithhell what should happen to this PR? Will you be able to agree on a path forward? Otherwise I'd suggest to abandon the proposed changes.

@biddisco
Copy link
Contributor Author

biddisco commented Jan 26, 2018

As mentioned before, I have been using this customization point in my RDMA branch, so when that get's merged, I'll revisit the problem. For now, we can delete this PR and forget about it.

@biddisco biddisco closed this Jan 26, 2018
@biddisco biddisco deleted the action_customization branch January 26, 2018 12:32
@msimberg msimberg removed this from the 1.2.0 milestone Sep 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging this pull request may close these issues.

None yet

4 participants