Commit ab460c8d authored by Mathieu Faverge's avatar Mathieu Faverge

Add Starpu migration function

parent fe80ed24
...@@ -388,6 +388,26 @@ void RUNTIME_data_flush( const MORSE_sequence_t *sequence, ...@@ -388,6 +388,26 @@ void RUNTIME_data_flush( const MORSE_sequence_t *sequence,
(void)sequence; (void)sequence;
} }
#if defined(CHAMELEON_USE_MIGRATE)
void RUNTIME_data_migrate( const MORSE_sequence_t *sequence,
const MORSE_desc_t *A, int Am, int An, int new_rank )
{
starpu_data_handle_t *handle = (starpu_data_handle_t*)(A->schedopt);
starpu_data_handle_t lhandle;
handle += ((int64_t)(A->lmt) * (int64_t)An + (int64_t)Am);
lhandle = *handle;
if ( lhandle == NULL ) {
/* Register the data */
lhandle = RUNTIME_data_getaddr( A, Am, An );
}
starpu_mpi_data_migrate( MPI_COMM_WORLD, lhandle, new_rank );
(void)sequence;
}
#endif
/******************************************************************************* /*******************************************************************************
* Get data addr * Get data addr
**/ **/
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment