diff --git a/build_all.sh b/build_all.sh index feaa8550..3cb51704 100755 --- a/build_all.sh +++ b/build_all.sh @@ -158,9 +158,9 @@ if [[ $USE_PARSEC -eq 1 ]]; then mkdir -p "$PARSEC_DIR" pushd "$PARSEC_DIR" if [[ $TASKBENCH_USE_HWLOC -eq 1 ]]; then - ../configure --prefix=$PWD --with-mpi --with-hwloc=$HWLOC_DIR --disable-debug + ../configure --prefix=$PWD --with-mpi --with-hwloc=$HWLOC_DIR --disable-debug --with-cuda=no --disable-testing else - ../configure --prefix=$PWD --with-mpi --disable-debug --with-cuda=no + ../configure --prefix=$PWD --with-mpi --disable-debug --with-cuda=no --disable-testing fi make -j$THREADS make install diff --git a/get_deps.sh b/get_deps.sh index 112663db..b0b55a21 100755 --- a/get_deps.sh +++ b/get_deps.sh @@ -181,9 +181,9 @@ export PARSEC_DIR="\$PARSEC_DL_DIR"/build EOF mkdir -p "$PARSEC_DL_DIR" - git clone https://bitbucket.org/icldistcomp/parsec.git "$PARSEC_DL_DIR" + git clone https://github.com/ICLDisco/parsec.git "$PARSEC_DL_DIR" pushd "$PARSEC_DL_DIR" - git reset --hard 242498dd7ce3974c01db888d7e4d759a69e5bcdb + git reset --hard b4e71d696b9f64ad82bf0516c61bd3076b7f53c0 git apply ../../parsec/patch.diff popd fi diff --git a/parsec/benchmark.jdf b/parsec/benchmark.jdf index d2d63b16..2d59de82 100644 --- a/parsec/benchmark.jdf +++ b/parsec/benchmark.jdf @@ -10,7 +10,7 @@ extern "C" %{ %} -descA [ type = "parsec_tiled_matrix_dc_t*" ] +descA [ type = "parsec_tiled_matrix_t*" ] graph [ type = "task_graph_t" ] nb_fields [ type = "int" ] time_steps [ type = "int" ] @@ -88,7 +88,7 @@ END extern "C" %{ parsec_taskpool_t* -parsec_benchmark_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, +parsec_benchmark_New(parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory) { parsec_taskpool_t* benchmark_taskpool; @@ -97,10 +97,10 @@ parsec_benchmark_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fie taskpool = parsec_benchmark_new(A, graph, nb_fields, time_steps, graph_idx, extra_local_memory); benchmark_taskpool = (parsec_taskpool_t*)taskpool; - parsec_matrix_add2arena(&(taskpool->arenas_datatypes[PARSEC_benchmark_DEFAULT_ARENA]), - parsec_datatype_float_t, matrix_UpperLower, - 1, A->mb, A->nb, A->mb, - PARSEC_ARENA_ALIGNMENT_SSE, -1 ); + parsec_add2arena(&(taskpool->arenas_datatypes[PARSEC_benchmark_DEFAULT_ADT_IDX]), + parsec_datatype_float_t, PARSEC_MATRIX_FULL, + 1, A->mb, A->nb, A->mb, + PARSEC_ARENA_ALIGNMENT_SSE, -1 ); return benchmark_taskpool; } @@ -108,13 +108,13 @@ parsec_benchmark_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fie void parsec_benchmark_Destruct(parsec_taskpool_t *taskpool) { parsec_benchmark_taskpool_t *benchmark_taskpool = (parsec_benchmark_taskpool_t *)taskpool; - parsec_matrix_del2arena(&(benchmark_taskpool->arenas_datatypes[PARSEC_benchmark_DEFAULT_ARENA])); + parsec_del2arena(&(benchmark_taskpool->arenas_datatypes[PARSEC_benchmark_DEFAULT_ADT_IDX])); parsec_taskpool_free(taskpool); } int parsec_benchmark(parsec_context_t *parsec, - parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, - int time_steps, int graph_idx, char **extra_local_memory) + parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, + int time_steps, int graph_idx, char **extra_local_memory) { parsec_taskpool_t *parsec_benchmark = NULL; diff --git a/parsec/benchmark_internal.h b/parsec/benchmark_internal.h index 73093eee..80466533 100644 --- a/parsec/benchmark_internal.h +++ b/parsec/benchmark_internal.h @@ -46,31 +46,31 @@ extern int get_num_args_out(task_graph_t g, int t, int x, int out_first, int out extern int nb_tasks_per_node[32]; extern int parsec_stencil_1d(parsec_context_t *parsec, - parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, + parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory); extern int parsec_nearest_radix_5(parsec_context_t *parsec, - parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, + parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory); extern int parsec_spread_radix5_period3(parsec_context_t *parsec, - parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, + parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory); extern int parsec_benchmark(parsec_context_t *parsec, - parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, + parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory); extern parsec_taskpool_t* -parsec_stencil_1d_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, +parsec_stencil_1d_New(parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory); extern parsec_taskpool_t* -parsec_nearest_radix_5_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, +parsec_nearest_radix_5_New(parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory); extern parsec_taskpool_t* -parsec_spread_radix5_period3_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, +parsec_spread_radix5_period3_New(parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory); extern void parsec_stencil_1d_Destruct(parsec_taskpool_t *taskpool); diff --git a/parsec/main.cc b/parsec/main.cc index 18cfbbc3..0445e25b 100644 --- a/parsec/main.cc +++ b/parsec/main.cc @@ -22,7 +22,7 @@ #include //#include #include -#include +#include #include /* timings */ @@ -37,7 +37,7 @@ #define ENABLE_PRUNE_MPI_TASK_INSERT #if defined (ENABLE_PRUNE_MPI_TASK_INSERT) -#include +#include #endif //#define TRACK_NB_TASKS @@ -47,6 +47,8 @@ int nb_tasks_per_node[32]; char **extra_local_memory; +parsec_arena_datatype_t **parsec_dtd_arenas_datatypes; + enum regions { TILE_FULL, }; @@ -63,12 +65,12 @@ dplasma_add2arena_tile( parsec_arena_datatype_t *arena, size_t elem_size, size_t parsec_datatype_t oldtype, unsigned int tile_mb ) { (void)elem_size; - return parsec_matrix_add2arena( arena, oldtype, - matrix_UpperLower, 1, tile_mb, tile_mb, tile_mb, - alignment, -1 ); + return parsec_add2arena( arena, oldtype, + PARSEC_MATRIX_FULL, 1, tile_mb, tile_mb, tile_mb, + alignment, -1 ); } -static int test_task1(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task1(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -102,7 +104,7 @@ static int test_task1(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task2(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task2(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -134,7 +136,7 @@ static int test_task2(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task3(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task3(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -169,7 +171,7 @@ static int test_task3(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task4(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task4(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -205,7 +207,7 @@ static int test_task4(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task5(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task5(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -243,7 +245,7 @@ static int test_task5(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task6(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task6(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -283,7 +285,7 @@ static int test_task6(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task7(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task7(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -325,7 +327,7 @@ static int test_task7(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task8(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task8(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -369,7 +371,7 @@ static int test_task8(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task9(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task9(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -415,7 +417,7 @@ static int test_task9(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task10(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task10(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -464,8 +466,8 @@ static int test_task10(parsec_execution_stream_t *es, parsec_task_t *this_task) } typedef struct matrix_s{ - two_dim_block_cyclic_t *__dcC; - two_dim_block_cyclic_t dcC; + parsec_matrix_block_cyclic_t *__dcC; + parsec_matrix_block_cyclic_t dcC; int M; int N; int K; @@ -513,109 +515,109 @@ void ParsecApp::insert_task(int num_args, payload_t payload, std::vector //#include #include -#include +#include #include /* timings */ @@ -37,7 +37,7 @@ #define ENABLE_PRUNE_MPI_TASK_INSERT #if defined (ENABLE_PRUNE_MPI_TASK_INSERT) -#include +#include #endif //#define TRACK_NB_TASKS @@ -52,6 +52,8 @@ int *extra_local_memory_idx; int memory_block_size = 0; int *extra_local_memory_init_flag; +parsec_arena_datatype_t **parsec_dtd_arenas_datatypes; + enum regions { TILE_FULL, }; @@ -68,12 +70,12 @@ dplasma_add2arena_tile( parsec_arena_datatype_t *arena, size_t elem_size, size_t parsec_datatype_t oldtype, unsigned int tile_mb ) { (void)elem_size; - return parsec_matrix_add2arena( arena, oldtype, - matrix_UpperLower, 1, tile_mb, tile_mb, tile_mb, - alignment, -1 ); + return parsec_add2arena( arena, oldtype, + PARSEC_MATRIX_FULL, 1, tile_mb, tile_mb, tile_mb, + alignment, -1 ); } -static int test_task1(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task1(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -117,7 +119,7 @@ static int test_task1(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task2(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task2(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -159,7 +161,7 @@ static int test_task2(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task3(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task3(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -203,7 +205,7 @@ static int test_task3(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task4(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task4(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -249,7 +251,7 @@ static int test_task4(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task5(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task5(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -297,7 +299,7 @@ static int test_task5(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task6(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task6(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -347,7 +349,7 @@ static int test_task6(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task7(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task7(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -399,7 +401,7 @@ static int test_task7(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task8(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task8(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -453,7 +455,7 @@ static int test_task8(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task9(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task9(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -509,7 +511,7 @@ static int test_task9(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task10(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task10(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -568,8 +570,8 @@ static int test_task10(parsec_execution_stream_t *es, parsec_task_t *this_task) } typedef struct matrix_s{ - two_dim_block_cyclic_t *__dcC; - two_dim_block_cyclic_t dcC; + parsec_matrix_block_cyclic_t *__dcC; + parsec_matrix_block_cyclic_t dcC; int M; int N; int K; @@ -617,109 +619,109 @@ void ParsecApp::insert_task(int num_args, payload_t payload, std::vector max_scratch_bytes_per_task) { max_scratch_bytes_per_task = graph.scratch_bytes_per_task; @@ -262,17 +268,17 @@ void ParsecApp::execute_main_loop() debug_printf(0, "rank %d, pid %d, M %d, N %d, MT %d, NT %d, nb_fields %d, timesteps %d\n", rank, getpid(), mat.M, mat.N, mat.MT, mat.NT, nb_fields, g.timesteps); if (g.dependence == DependenceType::STENCIL_1D) { - //parsec_stencil_1d(parsec, (parsec_tiled_matrix_dc_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); - tp[i] = parsec_stencil_1d_New((parsec_tiled_matrix_dc_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); + //parsec_stencil_1d(parsec, (parsec_tiled_matrix_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); + tp[i] = parsec_stencil_1d_New((parsec_tiled_matrix_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); } else if (g.dependence == DependenceType::NEAREST && g.radix == 5) { - //parsec_nearest_radix_5(parsec, (parsec_tiled_matrix_dc_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); - tp[i] = parsec_nearest_radix_5_New((parsec_tiled_matrix_dc_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); + //parsec_nearest_radix_5(parsec, (parsec_tiled_matrix_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); + tp[i] = parsec_nearest_radix_5_New((parsec_tiled_matrix_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); } else if (g.dependence == DependenceType::SPREAD && g.radix == 5) { - //parsec_spread_radix5_period3(parsec, (parsec_tiled_matrix_dc_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); - tp[i] = parsec_spread_radix5_period3_New((parsec_tiled_matrix_dc_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); + //parsec_spread_radix5_period3(parsec, (parsec_tiled_matrix_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); + tp[i] = parsec_spread_radix5_period3_New((parsec_tiled_matrix_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); } else { assert(0); - parsec_benchmark(parsec, (parsec_tiled_matrix_dc_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); + parsec_benchmark(parsec, (parsec_tiled_matrix_t *)&mat, g, nb_fields, g.timesteps, i, extra_local_memory); } assert(tp[i] != NULL); parsec_enqueue(parsec, tp[i]); diff --git a/parsec/main_shard.cc b/parsec/main_shard.cc index d878c209..344da8df 100644 --- a/parsec/main_shard.cc +++ b/parsec/main_shard.cc @@ -23,7 +23,7 @@ #include //#include #include -#include +#include #include /* timings */ @@ -38,7 +38,7 @@ #define ENABLE_PRUNE_MPI_TASK_INSERT #if defined (ENABLE_PRUNE_MPI_TASK_INSERT) -#include +#include #endif //#define TRACK_NB_TASKS @@ -48,6 +48,8 @@ int nb_tasks_per_node[32]; char **extra_local_memory; +parsec_arena_datatype_t **parsec_dtd_arenas_datatypes; + enum regions { TILE_FULL, }; @@ -64,12 +66,12 @@ dplasma_add2arena_tile( parsec_arena_datatype_t *arena, size_t elem_size, size_t parsec_datatype_t oldtype, unsigned int tile_mb ) { (void)elem_size; - return parsec_matrix_add2arena( arena, oldtype, - matrix_UpperLower, 1, tile_mb, tile_mb, tile_mb, - alignment, -1 ); + return parsec_add2arena( arena, oldtype, + PARSEC_MATRIX_FULL, 1, tile_mb, tile_mb, tile_mb, + alignment, -1 ); } -static int test_task1(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task1(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -103,7 +105,7 @@ static int test_task1(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task2(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task2(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -135,7 +137,7 @@ static int test_task2(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task3(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task3(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -170,7 +172,7 @@ static int test_task3(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task4(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task4(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -206,7 +208,7 @@ static int test_task4(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task5(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task5(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -244,7 +246,7 @@ static int test_task5(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task6(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task6(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -284,7 +286,7 @@ static int test_task6(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task7(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task7(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -326,7 +328,7 @@ static int test_task7(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task8(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task8(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -370,7 +372,7 @@ static int test_task8(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task9(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task9(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -416,7 +418,7 @@ static int test_task9(parsec_execution_stream_t *es, parsec_task_t *this_task) return PARSEC_HOOK_RETURN_DONE; } -static int test_task10(parsec_execution_stream_t *es, parsec_task_t *this_task) +static parsec_hook_return_t test_task10(parsec_execution_stream_t *es, parsec_task_t *this_task) { (void)es; payload_t payload; @@ -465,8 +467,8 @@ static int test_task10(parsec_execution_stream_t *es, parsec_task_t *this_task) } typedef struct matrix_s{ - two_dim_block_cyclic_t *__dcC; - two_dim_block_cyclic_t dcC; + parsec_matrix_block_cyclic_t *__dcC; + parsec_matrix_block_cyclic_t dcC; int M; int N; int K; @@ -514,109 +516,109 @@ void ParsecApp::insert_task(int num_args, payload_t payload, std::vectorarenas_datatypes[PARSEC_nearest_radix_5_DEFAULT_ARENA]), - parsec_datatype_float_t, matrix_UpperLower, - 1, A->mb, A->nb, A->mb, - PARSEC_ARENA_ALIGNMENT_SSE, -1 ); + parsec_add2arena(&(taskpool->arenas_datatypes[PARSEC_nearest_radix_5_DEFAULT_ADT_IDX]), + parsec_datatype_float_t, PARSEC_MATRIX_FULL, + 1, A->mb, A->nb, A->mb, + PARSEC_ARENA_ALIGNMENT_SSE, -1 ); return nearest_radix_5_taskpool; } @@ -96,7 +96,7 @@ parsec_nearest_radix_5_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph, int void parsec_nearest_radix_5_Destruct(parsec_taskpool_t *taskpool) { parsec_nearest_radix_5_taskpool_t *nearest_radix_5_taskpool = (parsec_nearest_radix_5_taskpool_t *)taskpool; - parsec_matrix_del2arena(&(nearest_radix_5_taskpool->arenas_datatypes[PARSEC_nearest_radix_5_DEFAULT_ARENA])); + parsec_del2arena(&(nearest_radix_5_taskpool->arenas_datatypes[PARSEC_nearest_radix_5_DEFAULT_ADT_IDX])); parsec_taskpool_free(taskpool); } @@ -106,7 +106,7 @@ void parsec_nearest_radix_5_Destruct(parsec_taskpool_t *taskpool) * @param [inout] dcY: the data, already distributed and allocated */ int parsec_nearest_radix_5(parsec_context_t *parsec, - parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, + parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory) { parsec_taskpool_t *parsec_nearest_radix_5 = NULL; diff --git a/parsec/patch.diff b/parsec/patch.diff index 12b8db18..19a25099 100644 --- a/parsec/patch.diff +++ b/parsec/patch.diff @@ -1,8 +1,8 @@ diff --git a/parsec/include/parsec/parsec_config_bottom.h b/parsec/include/parsec/parsec_config_bottom.h -index 748c310..8dba995 100644 +index f87a74e6d..de350e4d3 100644 --- a/parsec/include/parsec/parsec_config_bottom.h +++ b/parsec/include/parsec/parsec_config_bottom.h -@@ -102,11 +102,11 @@ typedef int32_t parsec_dependency_t; +@@ -156,11 +156,11 @@ typedef int32_t parsec_dependency_t; * A set of constants defining the capabilities of the underlying * runtime. */ @@ -16,3 +16,18 @@ index 748c310..8dba995 100644 #define MAX_TASK_STRLEN 128 +diff --git a/parsec/parsec_internal.h b/parsec/parsec_internal.h +index 3beb1310f..f5910cc69 100644 +--- a/parsec/parsec_internal.h ++++ b/parsec/parsec_internal.h +@@ -33,6 +33,10 @@ + + #include + ++#ifdef __cplusplus ++#define restrict __restrict ++#endif ++ + BEGIN_C_DECLS + + /** diff --git a/parsec/spread_radix5_period3.jdf b/parsec/spread_radix5_period3.jdf index 9e4922d6..3c83cb90 100644 --- a/parsec/spread_radix5_period3.jdf +++ b/parsec/spread_radix5_period3.jdf @@ -10,7 +10,7 @@ extern "C" %{ %} -descA [ type = "parsec_tiled_matrix_dc_t*" ] +descA [ type = "parsec_tiled_matrix_t*" ] graph [ type = "task_graph_t" ] nb_fields [ type = "int" ] time_steps [ type = "int" ] @@ -107,7 +107,7 @@ END extern "C" %{ parsec_taskpool_t* -parsec_spread_radix5_period3_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, +parsec_spread_radix5_period3_New(parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory) { parsec_taskpool_t* spread_radix5_period3_taskpool; @@ -116,10 +116,10 @@ parsec_spread_radix5_period3_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph taskpool = parsec_spread_radix5_period3_new(A, graph, nb_fields, time_steps, graph_idx, extra_local_memory); spread_radix5_period3_taskpool = (parsec_taskpool_t*)taskpool; - parsec_matrix_add2arena(&(taskpool->arenas_datatypes[PARSEC_spread_radix5_period3_DEFAULT_ARENA]), - parsec_datatype_float_t, matrix_UpperLower, - 1, A->mb, A->nb, A->mb, - PARSEC_ARENA_ALIGNMENT_SSE, -1 ); + parsec_add2arena(&(taskpool->arenas_datatypes[PARSEC_spread_radix5_period3_DEFAULT_ADT_IDX]), + parsec_datatype_float_t, PARSEC_MATRIX_FULL, + 1, A->mb, A->nb, A->mb, + PARSEC_ARENA_ALIGNMENT_SSE, -1 ); return spread_radix5_period3_taskpool; } @@ -130,7 +130,7 @@ parsec_spread_radix5_period3_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph void parsec_spread_radix5_period3_Destruct(parsec_taskpool_t *taskpool) { parsec_spread_radix5_period3_taskpool_t *spread_radix5_period3_taskpool = (parsec_spread_radix5_period3_taskpool_t *)taskpool; - parsec_matrix_del2arena(&(spread_radix5_period3_taskpool->arenas_datatypes[PARSEC_spread_radix5_period3_DEFAULT_ARENA])); + parsec_del2arena(&(spread_radix5_period3_taskpool->arenas_datatypes[PARSEC_spread_radix5_period3_DEFAULT_ADT_IDX])); parsec_taskpool_free(taskpool); } @@ -140,7 +140,7 @@ void parsec_spread_radix5_period3_Destruct(parsec_taskpool_t *taskpool) * @param [inout] dcY: the data, already distributed and allocated */ int parsec_spread_radix5_period3(parsec_context_t *parsec, - parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, + parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory) { parsec_taskpool_t *parsec_spread_radix5_period3 = NULL; diff --git a/parsec/stencil_1d.jdf b/parsec/stencil_1d.jdf index 970a9c5f..72c82d5d 100644 --- a/parsec/stencil_1d.jdf +++ b/parsec/stencil_1d.jdf @@ -38,7 +38,7 @@ static int my_startup_task(parsec_execution_stream_t * es, struct __parsec_stenc %option nb_local_tasks_fn = pretermined_nb_tasks -descA [ type = "parsec_tiled_matrix_dc_t*" ] +descA [ type = "parsec_tiled_matrix_t*" ] graph [ type = "task_graph_t" ] nb_fields [ type = "int" ] time_steps [ type = "int" ] @@ -152,22 +152,22 @@ static int my_startup_task(parsec_execution_stream_t * es, __parsec_stencil_1d_t /* Copy only the valid elements from this_task to new_task one */ new_task->taskpool = this_task->taskpool; new_task->task_class = __parsec_tp->super.super.task_classes_array[stencil_1d_task.task_class_id]; - new_task->chore_id = 0; + new_task->chore_mask = 0; new_task->locals.t.value = this_task->locals.t.value; new_task->locals.x.value = this_task->locals.x.value; new_task->locals.m.value = this_task->locals.m.value; PARSEC_LIST_ITEM_SINGLETON(new_task); new_task->priority = __parsec_tp->super.super.priority; - new_task->data._f_A.data_repo = NULL; + new_task->data._f_A.source_repo = NULL; new_task->data._f_A.data_in = NULL; new_task->data._f_A.data_out = NULL; - new_task->data._f_L.data_repo = NULL; + new_task->data._f_L.source_repo = NULL; new_task->data._f_L.data_in = NULL; new_task->data._f_L.data_out = NULL; - new_task->data._f_B.data_repo = NULL; + new_task->data._f_B.source_repo = NULL; new_task->data._f_B.data_in = NULL; new_task->data._f_B.data_out = NULL; - new_task->data._f_R.data_repo = NULL; + new_task->data._f_R.source_repo = NULL; new_task->data._f_R.data_in = NULL; new_task->data._f_R.data_out = NULL; #if defined(PARSEC_DEBUG_NOISIER) @@ -219,7 +219,7 @@ static int wrap_task(parsec_execution_stream_t * es, } parsec_taskpool_t* -parsec_stencil_1d_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, +parsec_stencil_1d_New(parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory) { void** hook; @@ -233,10 +233,10 @@ parsec_stencil_1d_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fi hook = (void *)&taskpool->super.task_classes_array[0]->incarnations[0].hook; *hook = &wrap_task; - parsec_matrix_add2arena(&(taskpool->arenas_datatypes[PARSEC_stencil_1d_DEFAULT_ARENA]), - parsec_datatype_float_t, matrix_UpperLower, - 1, A->mb, A->nb, A->mb, - PARSEC_ARENA_ALIGNMENT_SSE, -1 ); + parsec_add2arena(&(taskpool->arenas_datatypes[PARSEC_stencil_1d_DEFAULT_ADT_IDX]), + parsec_datatype_float_t, PARSEC_MATRIX_FULL, + 1, A->mb, A->nb, A->mb, + PARSEC_ARENA_ALIGNMENT_SSE, -1 ); return stencil_1d_taskpool; } @@ -247,7 +247,7 @@ parsec_stencil_1d_New(parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fi void parsec_stencil_1d_Destruct(parsec_taskpool_t *taskpool) { parsec_stencil_1d_taskpool_t *stencil_1d_taskpool = (parsec_stencil_1d_taskpool_t *)taskpool; - parsec_matrix_del2arena(&(stencil_1d_taskpool->arenas_datatypes[PARSEC_stencil_1d_DEFAULT_ARENA])); + parsec_del2arena(&(stencil_1d_taskpool->arenas_datatypes[PARSEC_stencil_1d_DEFAULT_ADT_IDX])); parsec_taskpool_free(taskpool); } @@ -257,7 +257,7 @@ void parsec_stencil_1d_Destruct(parsec_taskpool_t *taskpool) * @param [inout] dcY: the data, already distributed and allocated */ int parsec_stencil_1d(parsec_context_t *parsec, - parsec_tiled_matrix_dc_t *A, task_graph_t graph, int nb_fields, + parsec_tiled_matrix_t *A, task_graph_t graph, int nb_fields, int time_steps, int graph_idx, char **extra_local_memory) { parsec_taskpool_t *parsec_stencil_1d = NULL; diff --git a/test_all.sh b/test_all.sh index 897b3efe..2a39930d 100755 --- a/test_all.sh +++ b/test_all.sh @@ -174,12 +174,12 @@ if [[ $USE_PARSEC -eq 1 ]]; then mpirun -np 1 ./parsec/main_dtd -steps $steps -type $t $k -and -steps $steps -type $t $k -c 2 -nodes 1 done done - for k in "${kernels[@]}"; do - mpirun -np 2 ./parsec/main_ptg -p 1 -S 4 -c 2 -steps $steps -type stencil_1d $k -width 8 -field 2 -nodes 2 - mpirun -np 2 ./parsec/main_ptg -p 1 -S 4 -c 2 -steps $steps -type stencil_1d $k -width 8 -and -steps $steps -type stencil_1d $k -width 8 -nodes 2 - mpirun -np 2 ./parsec/main_ptg -p 1 -S 4 -c 2 -steps $steps -type nearest -radix 5 $k -width 8 -field 2 -nodes 2 - mpirun -np 2 ./parsec/main_ptg -p 1 -S 4 -c 2 -steps $steps -type nearest -radix 5 $k -width 8 -and -steps $steps -type nearest -radix 5 $k -width 8 -nodes 2 - done + # for k in "${kernels[@]}"; do + # mpirun -np 2 ./parsec/main_ptg -p 1 -S 4 -c 2 -steps $steps -type stencil_1d $k -width 8 -field 2 -nodes 2 + # mpirun -np 2 ./parsec/main_ptg -p 1 -S 4 -c 2 -steps $steps -type stencil_1d $k -width 8 -and -steps $steps -type stencil_1d $k -width 8 -nodes 2 + # mpirun -np 2 ./parsec/main_ptg -p 1 -S 4 -c 2 -steps $steps -type nearest -radix 5 $k -width 8 -field 2 -nodes 2 + # mpirun -np 2 ./parsec/main_ptg -p 1 -S 4 -c 2 -steps $steps -type nearest -radix 5 $k -width 8 -and -steps $steps -type nearest -radix 5 $k -width 8 -nodes 2 + # done fi if [[ $USE_CHARM -eq 1 ]]; then