_gfortran_caf_register_accessor
— Register an accessor for remote access ¶void _gfortran_caf_register_accessor (const int hash,
void (*accessor)(void **, int32_t *, void *, void *, size_t *,
size_t *))
Identification of access funtions across images is done using a unique hash.
For each given hash an accessor has to be registered. This routine is expected
to register an accessor function pointer for the given hash in nearly constant
time. I.e. it is expected to add the hash and accessor to a buffer and return.
Sorting shall be done in _gfortran_caf_register_accessors_finish
.
hash | intent(in) The unique hash value this accessor is to be identified by. |
accessor | intent(in) A pointer to the function on this image.
The function has the signature void accessor (void **dst_ptr,
int32_t *free_dst, void *src_ptr, void *get_data, size_t *opt_src_charlen,
size_t *opt_dst_charlen) . GFortran ensures that functions provided to
_gfortran_caf_register_accessor adhere to this interface. |
This function is required to have a nearly constant runtime complexity, because
it will be called to register multiple accessor in a sequence. GFortran ensures
that before the first remote accesses commences
_gfortran_caf_register_accessors_finish
is called at least once. It is
valid to register further accessors after a call to
_gfortran_caf_register_accessors_finish
. It is invalid to call
_gfortran_caf_register_accessor
after the first remote access has been
done. See also _gfortran_caf_register_accessors_finish
— Finish registering accessor functions and
_gfortran_caf_get_remote_function_index
— Get the index of an accessor