Skip to content

allow an Accessor type to return a known receive size #12

@jjwilke

Description

@jjwilke

to receive values, you need the following steps:

MPI_Probe(); //might not be called until quite late in the progress engine
getSize();
MPI_Irecv();
....
MPI_Wait(...);
unpack();

Even if the application knows ahead of time how large the receive should be, it just has to wait for the packed message to arrive.

if would be very useful to be able to do this:

if (Accessor::canPrecomputeSize()){
  int size = Accessor::precomputeSize(...);
  void* buf = allocate_temp_buf(size);
  MPI_Irecv(...);
}
...
MPI_Wait(...);
unpack...);

This probably makes the most sense to do using SFINAE on the Accessor to see if it has a static function "precompute_size()"

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions