tie in group_finalize.
This commit was SVN r779.
Этот коммит содержится в:
родитель
d6c272b65a
Коммит
edf0ebca81
@ -41,8 +41,13 @@ void lam_pointer_array_construct(lam_pointer_array_t *array){
|
||||
*/
|
||||
void lam_pointer_array_destruct(lam_pointer_array_t *array){
|
||||
|
||||
/* return */
|
||||
/* free table */
|
||||
if( NULL != array->addr)
|
||||
free(array->addr);
|
||||
|
||||
lam_mutex_destroy(&array->lock);
|
||||
|
||||
/* return */
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -8,17 +8,18 @@
|
||||
#include "lam/runtime/runtime.h"
|
||||
#include "lam/mem/malloc.h"
|
||||
#include "lam/util/output.h"
|
||||
|
||||
#include "mpi/group/group.h"
|
||||
|
||||
int lam_finalize(void)
|
||||
{
|
||||
/* Shut down malloc debug stuff */
|
||||
/* free group resources */
|
||||
lam_group_finalize();
|
||||
|
||||
lam_malloc_finalize();
|
||||
/* Shut down malloc debug stuff */
|
||||
lam_malloc_finalize();
|
||||
|
||||
/* Shut down the output streams */
|
||||
lam_output_finalize();
|
||||
|
||||
/* Shut down the output streams */
|
||||
|
||||
lam_output_finalize();
|
||||
|
||||
return LAM_SUCCESS;
|
||||
return LAM_SUCCESS;
|
||||
}
|
||||
|
@ -50,4 +50,11 @@ lam_group_t *group_allocate(int group_size);
|
||||
*/
|
||||
int lam_group_init(void);
|
||||
|
||||
/**
|
||||
* Clean up LAM group infrastructure
|
||||
*
|
||||
* @return Error code
|
||||
*/
|
||||
int lam_group_finalize(void);
|
||||
|
||||
#endif /* LAM_GROUP_H */
|
||||
|
@ -89,7 +89,22 @@ int lam_group_init()
|
||||
|
||||
/* initialize lam_group_f_to_c_table */
|
||||
lam_group_f_to_c_table=OBJ_NEW(lam_pointer_array_t);
|
||||
if( (-1) == lam_group_f_to_c_table )
|
||||
return_value=LAM_ERROR;
|
||||
|
||||
/* return */
|
||||
return return_value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Clean up group infrastructure
|
||||
*/
|
||||
int lam_group_finalize(){
|
||||
/* local variables */
|
||||
int return_value=LAM_SUCCESS;
|
||||
|
||||
OBJ_RELEASE(lam_group_f_to_c_table);
|
||||
|
||||
/* return */
|
||||
return return_value;
|
||||
};
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user