1
1

Remove initialized but unused variables.

This commit was SVN r26959.
Этот коммит содержится в:
George Bosilca 2012-08-07 12:05:25 +00:00
родитель 2f442799f8
Коммит 2303cd0bdb
8 изменённых файлов: 24 добавлений и 33 удалений

Просмотреть файл

@ -278,7 +278,7 @@ void opal_graph_add_vertex(opal_graph_t *graph, opal_graph_vertex_t *vertex)
*/
int opal_graph_add_edge(opal_graph_t *graph, opal_graph_edge_t *edge)
{
opal_adjacency_list_t *aj_list, *start_aj_list= NULL, *end_aj_list;
opal_adjacency_list_t *aj_list, *start_aj_list= NULL;
opal_list_item_t *item;
bool start_found = false, end_found = false;
@ -296,7 +296,6 @@ int opal_graph_add_edge(opal_graph_t *graph, opal_graph_edge_t *edge)
}
if (aj_list->vertex == edge->end) {
end_found = true;
end_aj_list = aj_list;
}
}
/**

Просмотреть файл

@ -445,7 +445,7 @@ static opal_tree_item_t *find_in_descendants(opal_tree_item_t* item, void *key)
*/
opal_tree_item_t *opal_tree_find_with(opal_tree_item_t *item, void *key)
{
opal_tree_item_t *root, *curr_item = item, *result = NULL;
opal_tree_item_t *curr_item = item, *result = NULL;
if (!opal_tree_is_empty(item->opal_tree_container)) {
/* check my descendant for a match */
@ -459,7 +459,6 @@ opal_tree_item_t *opal_tree_find_with(opal_tree_item_t *item, void *key)
}
/* check my ancestors (uncles) for match */
root = opal_tree_get_root(item->opal_tree_container);
curr_item = item;
while (!result && curr_item && curr_item->opal_tree_num_ancestors > 0){
curr_item = opal_tree_get_next_sibling(item->opal_tree_parent);

Просмотреть файл

@ -101,7 +101,6 @@ int32_t opal_datatype_copy_content_same_ddt( const opal_datatype_t* datatype, in
char* destination_base, char* source_base )
{
OPAL_PTRDIFF_TYPE extent;
size_t iov_len_local;
int32_t (*fct)( const opal_datatype_t*, int32_t, char*, char*);
#if OPAL_CUDA_SUPPORT
@ -116,7 +115,6 @@ int32_t opal_datatype_copy_content_same_ddt( const opal_datatype_t* datatype, in
*/
if( 0 == count ) return 1;
iov_len_local = count * datatype->size;
/**
* see discussion in coll_basic_reduce.c for the computation of extent when
* count != 1. Short version of the story:

Просмотреть файл

@ -389,10 +389,6 @@ static int open_components(const char *type_name, int output_id,
ret = component->mca_register_component_params();
if (MCA_SUCCESS == ret) {
registered = true;
opal_output_verbose(10, output_id,
"mca: base: components_open: "
"component %s register function successful",
component->mca_component_name);
} else if (OPAL_ERR_NOT_AVAILABLE != ret) {
/* If the component returns OPAL_ERR_NOT_AVAILABLE,
it's a cue to "silently ignore me" -- it's not a
@ -411,11 +407,12 @@ static int open_components(const char *type_name, int output_id,
component->mca_type_name,
component->mca_component_name);
}
opal_output_verbose(10, output_id,
"mca: base: components_open: "
"component %s register function failed",
component->mca_component_name);
}
opal_output_verbose(10, output_id,
"mca: base: components_open: "
"component %s register function %s",
component->mca_component_name,
(true == registered ? "successful": "failed"));
}
if (NULL == component->mca_open_component) {

Просмотреть файл

@ -178,7 +178,6 @@ int mca_base_param_init(void)
int mca_base_param_recache_files(bool rel_path_search)
{
int id;
char *files, *new_files = NULL, *new_agg_files = NULL;
char * new_agg_path = NULL, *agg_default_path = NULL;
@ -206,28 +205,28 @@ int mca_base_param_recache_files(bool rel_path_search)
/* Initialize a parameter that says where MCA param files can
be found */
id = mca_base_param_reg_string_name("mca", "param_files",
"Path for MCA configuration files containing default parameter values",
false, false, files, &new_files);
mca_base_param_reg_string_name("mca", "param_files",
"Path for MCA configuration files containing default parameter values",
false, false, files, &new_files);
/* Aggregate MCA parameter files
* A prefix search path to look up aggregate MCA parameter file
* requests that do not specify an absolute path
*/
id = mca_base_param_reg_string_name("mca", "base_param_file_prefix",
"Aggregate MCA parameter file sets",
false, false, NULL, &new_agg_files);
mca_base_param_reg_string_name("mca", "base_param_file_prefix",
"Aggregate MCA parameter file sets",
false, false, NULL, &new_agg_files);
asprintf(&agg_default_path,
"%s"OPAL_PATH_SEP"amca-param-sets%c%s",
opal_install_dirs.pkgdatadir, OPAL_ENV_SEP, cwd);
id = mca_base_param_reg_string_name("mca", "base_param_file_path",
"Aggregate MCA parameter Search path",
false, false, agg_default_path, &new_agg_path);
mca_base_param_reg_string_name("mca", "base_param_file_path",
"Aggregate MCA parameter Search path",
false, false, agg_default_path, &new_agg_path);
id = mca_base_param_reg_string_name("mca", "base_param_file_path_force",
"Forced Aggregate MCA parameter Search path",
false, false, NULL, &force_agg_path);
mca_base_param_reg_string_name("mca", "base_param_file_path_force",
"Forced Aggregate MCA parameter Search path",
false, false, NULL, &force_agg_path);
if( NULL != force_agg_path ) {
char *tmp_str = NULL;

Просмотреть файл

@ -744,7 +744,7 @@ hwloc_obj_t opal_hwloc_base_get_obj_by_type(hwloc_topology_t topo,
unsigned int instance,
opal_hwloc_resource_type_t rtype)
{
unsigned int num_objs, idx;
unsigned int idx;
hwloc_obj_t obj;
/* bozo check */
@ -761,7 +761,6 @@ hwloc_obj_t opal_hwloc_base_get_obj_by_type(hwloc_topology_t topo,
}
/* for everything else, we have to do some work */
num_objs = 0;
idx = 0;
obj = hwloc_get_root_obj(topo);
return df_search(topo, obj, target, cache_level, instance, rtype, &idx, NULL);

Просмотреть файл

@ -375,7 +375,7 @@ int opal_cr_init(void )
}
#else
/* Silence a compiler warning */
t = 0;
(void)t;
#endif
mca_base_param_reg_string_name("opal_cr", "tmp_dir",
@ -928,7 +928,7 @@ int opal_cr_refresh_environ(int prev_pid) {
"opal_cr: init: C/R Debugging Enabled [%s] (refresh)\n",
(MPIR_debug_with_checkpoint ? "True": "False"));
#else
val = 0; /* Silence Compiler warning */
(void)val; /* Silence Compiler warning */
#endif
if( NULL != file_name ){

Просмотреть файл

@ -40,7 +40,7 @@
*/
static int guess_strlen(const char *fmt, va_list ap)
{
char *sarg, carg;
char *sarg;
double darg;
float farg;
size_t i;
@ -58,7 +58,7 @@ static int guess_strlen(const char *fmt, va_list ap)
++i;
switch (fmt[i]) {
case 'c':
carg = va_arg(ap, int);
(void)va_arg(ap, int);
len += 1; /* let's suppose it's a printable char */
break;
case 's':