Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Iker Martín Álvarez
Proteo
Commits
2ca85de0
Commit
2ca85de0
authored
Jun 04, 2024
by
iker_martin
Browse files
WIP. Renaming of all files related to malleability to start with MAM. No relevant changes
parent
43dc1240
Changes
33
Hide whitespace changes
Inline
Side-by-side
Codes/IOcodes/read_ini.c
View file @
2ca85de0
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
#include <string.h>
#include <string.h>
#include "read_ini.h"
#include "read_ini.h"
#include "ini.h"
#include "ini.h"
#include "../malleability/
malleabilityStates
.h"
#include "../malleability/
MAM
.h"
ext_functions_t
*
user_functions
;
ext_functions_t
*
user_functions
;
...
...
Codes/Main/Main.c
View file @
2ca85de0
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
#include "Main_datatypes.h"
#include "Main_datatypes.h"
#include "configuration.h"
#include "configuration.h"
#include "../IOcodes/results.h"
#include "../IOcodes/results.h"
#include "../malleability/CommDist.h"
#include "../malleability/
distribution_methods/Distributed_
CommDist.h"
#include "../malleability/MAM.h"
#include "../malleability/MAM.h"
#define DR_MAX_SIZE 1000000000
#define DR_MAX_SIZE 1000000000
...
...
Codes/malleability/MAM.h
View file @
2ca85de0
#ifndef MAM_H
#ifndef MAM_H
#define MAM_H
#define MAM_H
#include "
malleabilityState
s.h"
#include "
MAM_Constant
s.h"
#include "
malleability
Manager.h"
#include "
MAM_
Manager.h"
#include "MAM_Configuration.h"
#include "MAM_Configuration.h"
#endif
#endif
Codes/malleability/MAM_Configuration.c
View file @
2ca85de0
#include "MAM_Configuration.h"
#include "MAM_Configuration.h"
#include "MAM_Init_Configuration.h"
#include "MAM_Init_Configuration.h"
#include "
malleability
DataStructures.h"
#include "
MAM_
DataStructures.h"
#include <limits.h>
#include <limits.h>
typedef
struct
{
typedef
struct
{
...
...
Codes/malleability/MAM_Configuration.h
View file @
2ca85de0
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
#define MAM_CONFIGURATION_H
#define MAM_CONFIGURATION_H
#include <mpi.h>
#include <mpi.h>
#include "
malleabilityState
s.h"
#include "
MAM_Constant
s.h"
#define MAM_STRAT_CLEAR_VALUE 0
#define MAM_STRAT_CLEAR_VALUE 0
...
...
Codes/malleability/
malleabilityState
s.h
→
Codes/malleability/
MAM_Constant
s.h
View file @
2ca85de0
#ifndef MALLEABILITY_STATES_H
#ifndef MAM_CONSTANTS_H
#define MALLEABILITY_STATES_H
#define MAM_CONSTANTS_H
#include <stdio.h>
#include <stdlib.h>
//States
//States
#define MALL_DENIED -1
#define MALL_DENIED -1
#define MAM_OK 0
#define MAM_OK 0
enum
mall_inner_states
{
MALL_UNRESERVED
,
MALL_NOT_STARTED
,
MALL_RMS_COMPLETED
,
MALL_SPAWN_PENDING
,
MALL_SPAWN_SINGLE_PENDING
,
MALL_SPAWN_SINGLE_COMPLETED
,
MALL_SPAWN_ADAPT_POSTPONE
,
MALL_SPAWN_COMPLETED
,
MALL_DIST_PENDING
,
MALL_DIST_COMPLETED
,
MALL_SPAWN_ADAPT_PENDING
,
MALL_USER_START
,
MALL_USER_PENDING
,
MALL_USER_COMPLETED
,
MALL_SPAWN_ADAPTED
,
MALL_COMPLETED
};
enum
mam_states
{
MAM_UNRESERVED
,
MAM_NOT_STARTED
,
MAM_PENDING
,
MAM_USER_PENDING
,
MAM_COMPLETED
};
enum
mam_states
{
MAM_UNRESERVED
,
MAM_NOT_STARTED
,
MAM_PENDING
,
MAM_USER_PENDING
,
MAM_COMPLETED
};
enum
mam_proc_states
{
MAM_PROC_CONTINUE
,
MAM_PROC_NEW_RANK
,
MAM_PROC_ZOMBIE
};
enum
mam_proc_states
{
MAM_PROC_CONTINUE
,
MAM_PROC_NEW_RANK
,
MAM_PROC_ZOMBIE
};
enum
mall_spawn_methods
{
MALL_SPAWN_BASELINE
,
MALL_SPAWN_MERGE
,
MAM_METHODS_SPAWN_LEN
};
enum
mall_spawn_methods
{
MALL_SPAWN_BASELINE
,
MALL_SPAWN_MERGE
,
MAM_METHODS_SPAWN_LEN
};
enum
mam_spawn_strategies
{
MAM_STRAT_SPAWN_CLEAR
,
MAM_STRAT_SPAWN_PTHREAD
,
MAM_STRAT_SPAWN_SINGLE
,
MAM_STRAT_SPAWN_INTERCOMM
,
MAM_STRAT_SPAWN_MULTIPLE
,
MAM_STRATS_SPAWN_LEN
};
enum
mam_spawn_strategies
{
MAM_STRAT_SPAWN_CLEAR
,
MAM_STRAT_SPAWN_PTHREAD
,
MAM_STRAT_SPAWN_SINGLE
,
MAM_STRAT_SPAWN_INTERCOMM
,
MAM_STRAT_SPAWN_MULTIPLE
,
MAM_STRATS_SPAWN_LEN
};
...
...
Codes/malleability/
malleability
DataStructures.c
→
Codes/malleability/
MAM_
DataStructures.c
View file @
2ca85de0
#include "
malleability
DataStructures.h"
#include "
MAM_
DataStructures.h"
malleability_config_t
*
mall_conf
=
NULL
;
malleability_config_t
*
mall_conf
=
NULL
;
malleability_t
*
mall
=
NULL
;
malleability_t
*
mall
=
NULL
;
...
...
Codes/malleability/
malleability
DataStructures.h
→
Codes/malleability/
MAM_
DataStructures.h
View file @
2ca85de0
#ifndef MA
LLEABILITY
_DATA_STRUCTURES_H
#ifndef MA
M
_DATA_STRUCTURES_H
#define MA
LLEABILITY
_DATA_STRUCTURES_H
#define MA
M
_DATA_STRUCTURES_H
/*
/*
* Shows available data structures for inner ussage.
* Shows available data structures for inner ussage.
...
@@ -8,10 +8,15 @@
...
@@ -8,10 +8,15 @@
#include <stdio.h>
#include <stdio.h>
#include <mpi.h>
#include <mpi.h>
#include <pthread.h>
#include <pthread.h>
#include "
malleabilityState
s.h"
#include "
MAM_Constant
s.h"
#define DEBUG_FUNC(debug_string, rank, numP) printf("MaM [P%d/%d]: %s -- %s:%s:%d\n", rank, numP, debug_string, __FILE__, __func__, __LINE__)
#define DEBUG_FUNC(debug_string, rank, numP) printf("MaM [P%d/%d]: %s -- %s:%s:%d\n", rank, numP, debug_string, __FILE__, __func__, __LINE__)
/* --- MAM REAL STATES --- */
enum
mam_inner_states
{
MALL_UNRESERVED
,
MALL_NOT_STARTED
,
MALL_RMS_COMPLETED
,
MALL_SPAWN_PENDING
,
MALL_SPAWN_SINGLE_PENDING
,
MALL_SPAWN_SINGLE_COMPLETED
,
MALL_SPAWN_ADAPT_POSTPONE
,
MALL_SPAWN_COMPLETED
,
MALL_DIST_PENDING
,
MALL_DIST_COMPLETED
,
MALL_SPAWN_ADAPT_PENDING
,
MALL_USER_START
,
MALL_USER_PENDING
,
MALL_USER_COMPLETED
,
MALL_SPAWN_ADAPTED
,
MALL_COMPLETED
};
/* --- TIME CAPTURE STRUCTURE --- */
/* --- TIME CAPTURE STRUCTURE --- */
typedef
struct
{
typedef
struct
{
// Spawn, Sync and Async time
// Spawn, Sync and Async time
...
...
Codes/malleability/MAM_Init_Configuration.h
View file @
2ca85de0
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
#define MAM_INIT_CONFIGURATION_H
#define MAM_INIT_CONFIGURATION_H
#include <mpi.h>
#include <mpi.h>
#include "
malleabilityState
s.h"
#include "
MAM_Constant
s.h"
void
MAM_Init_configuration
();
void
MAM_Init_configuration
();
void
MAM_Set_initial_configuration
();
void
MAM_Set_initial_configuration
();
...
...
Codes/malleability/
malleability
Manager.c
→
Codes/malleability/
MAM_
Manager.c
View file @
2ca85de0
#include <pthread.h>
#include <pthread.h>
#include <string.h>
#include <string.h>
//#include "malleabilityManager.h"
#include "MAM.h"
#include "MAM.h"
#include "
malleabilityState
s.h"
#include "
MAM_Constant
s.h"
#include "
malleability
DataStructures.h"
#include "
MAM_
DataStructures.h"
#include "
malleability
Types.h"
#include "
MAM_
Types.h"
#include "
malleability
Zombies.h"
#include "
MAM_
Zombies.h"
#include "
malleability
Times.h"
#include "
MAM_
Times.h"
#include "
malleability
RMS.h"
#include "
MAM_
RMS.h"
#include "MAM_Init_Configuration.h"
#include "MAM_Init_Configuration.h"
#include "spawn_methods/GenericSpawn.h"
#include "spawn_methods/GenericSpawn.h"
#include "CommDist.h"
#include "
distribution_methods/Distributed_
CommDist.h"
#define MALLEABILITY_USE_SYNCHRONOUS 0
#define MALLEABILITY_USE_SYNCHRONOUS 0
#define MALLEABILITY_USE_ASYNCHRONOUS 1
#define MALLEABILITY_USE_ASYNCHRONOUS 1
...
...
Codes/malleability/
malleability
Manager.h
→
Codes/malleability/
MAM_
Manager.h
View file @
2ca85de0
#ifndef MA
LLEABILITY
_MANAGER_H
#ifndef MA
M
_MANAGER_H
#define MA
LLEABILITY
_MANAGER_H
#define MA
M
_MANAGER_H
#include <stdio.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdlib.h>
...
@@ -7,7 +7,6 @@
...
@@ -7,7 +7,6 @@
#include <fcntl.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <sys/stat.h>
#include <mpi.h>
#include <mpi.h>
#include "malleabilityStates.h"
typedef
struct
{
typedef
struct
{
int
numS
,
numT
;
int
numS
,
numT
;
...
...
Codes/malleability/
malleability
RMS.c
→
Codes/malleability/
MAM_
RMS.c
View file @
2ca85de0
...
@@ -5,8 +5,8 @@
...
@@ -5,8 +5,8 @@
#include <unistd.h>
#include <unistd.h>
#include <sched.h>
#include <sched.h>
#include <mpi.h>
#include <mpi.h>
#include "
malleability
RMS.h"
#include "
MAM_
RMS.h"
#include "
malleability
DataStructures.h"
#include "
MAM_
DataStructures.h"
#if USE_MAL_SLURM
#if USE_MAL_SLURM
...
...
Codes/malleability/
malleability
RMS.h
→
Codes/malleability/
MAM_
RMS.h
View file @
2ca85de0
#ifndef MA
LLEABILITY
_RMS_H
#ifndef MA
M
_RMS_H
#define MA
LLEABILITY
_RMS_H
#define MA
M
_RMS_H
void
MAM_check_hosts
();
void
MAM_check_hosts
();
int
MAM_Is_internode_group
();
int
MAM_Is_internode_group
();
...
...
Codes/malleability/
malleability
Times.c
→
Codes/malleability/
MAM_
Times.c
View file @
2ca85de0
#include "
malleability
Times.h"
#include "
MAM_
Times.h"
#include "
malleability
DataStructures.h"
#include "
MAM_
DataStructures.h"
void
def_malleability_times
(
MPI_Datatype
*
new_type
);
void
def_malleability_times
(
MPI_Datatype
*
new_type
);
...
...
Codes/malleability/
malleability
Times.h
→
Codes/malleability/
MAM_
Times.h
View file @
2ca85de0
#ifndef MA
LLEABILITY
_TIMES_H
#ifndef MA
M
_TIMES_H
#define MA
LLEABILITY
_TIMES_H
#define MA
M
_TIMES_H
#include <mpi.h>
#include <mpi.h>
...
...
Codes/malleability/
malleability
Types.c
→
Codes/malleability/
MAM_
Types.c
View file @
2ca85de0
#include "
malleability
Types.h"
#include "
MAM_
Types.h"
#include "
malleability
DataStructures.h"
#include "
MAM_
DataStructures.h"
#include "MAM_Configuration.h"
#include "MAM_Configuration.h"
...
...
Codes/malleability/
malleability
Types.h
→
Codes/malleability/
MAM_
Types.h
View file @
2ca85de0
#ifndef MA
LLEABILITY
_TYPES_H
#ifndef MA
M
_TYPES_H
#define MA
LLEABILITY
_TYPES_H
#define MA
M
_TYPES_H
#include <stdio.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdlib.h>
#include <mpi.h>
#include <mpi.h>
#include <fcntl.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <sys/stat.h>
#include "
malleabilityState
s.h"
#include "
MAM_Constant
s.h"
#define MALLEABILITY_INIT_DATA_QTY 100
#define MALLEABILITY_INIT_DATA_QTY 100
...
...
Codes/malleability/
malleability
Zombies.c
→
Codes/malleability/
MAM_
Zombies.c
View file @
2ca85de0
...
@@ -5,7 +5,8 @@
...
@@ -5,7 +5,8 @@
#include <unistd.h>
#include <unistd.h>
#include <mpi.h>
#include <mpi.h>
#include <signal.h>
#include <signal.h>
#include "malleabilityZombies.h"
#include "MAM_Zombies.h"
#include "MAM_DataStructures.h"
#define PIDS_QTY 320
#define PIDS_QTY 320
//TODO Add option to allow the usage of signal USR2 or not.
//TODO Add option to allow the usage of signal USR2 or not.
...
...
Codes/malleability/MAM_Zombies.h
0 → 100644
View file @
2ca85de0
#ifndef MAM_ZOMBIES_H
#define MAM_ZOMBIES_H
void
MAM_Zombies_service_init
();
int
MAM_Zombies_service_free
();
void
MAM_Zombies_update
();
#endif
Codes/malleability/CommDist.c
→
Codes/malleability/
distribution_methods/Distributed_
CommDist.c
View file @
2ca85de0
...
@@ -2,10 +2,11 @@
...
@@ -2,10 +2,11 @@
#include <stdlib.h>
#include <stdlib.h>
#include <mpi.h>
#include <mpi.h>
#include <string.h>
#include <string.h>
#include "distribution_methods/block_distribution.h"
#include "block_distribution.h"
#include "CommDist.h"
#include "Distributed_CommDist.h"
#include "MAM_Configuration.h"
#include "../MAM_Constants.h"
#include "malleabilityDataStructures.h"
#include "../MAM_Configuration.h"
#include "../MAM_DataStructures.h"
void
prepare_redistribution
(
int
qty
,
MPI_Datatype
datatype
,
int
numP
,
int
numO
,
int
is_children_group
,
void
**
recv
,
struct
Counts
*
s_counts
,
struct
Counts
*
r_counts
);
void
prepare_redistribution
(
int
qty
,
MPI_Datatype
datatype
,
int
numP
,
int
numO
,
int
is_children_group
,
void
**
recv
,
struct
Counts
*
s_counts
,
struct
Counts
*
r_counts
);
void
check_requests
(
struct
Counts
s_counts
,
struct
Counts
r_counts
,
MPI_Request
**
requests
,
size_t
*
request_qty
);
void
check_requests
(
struct
Counts
s_counts
,
struct
Counts
r_counts
,
MPI_Request
**
requests
,
size_t
*
request_qty
);
...
...
Prev
1
2
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment