56 строки
1.8 KiB
C
56 строки
1.8 KiB
C
|
/*
|
||
|
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
|
||
|
* University Research and Technology
|
||
|
* Corporation. All rights reserved.
|
||
|
* Copyright (c) 2004-2006 The University of Tennessee and The University
|
||
|
* of Tennessee Research Foundation. All rights
|
||
|
* reserved.
|
||
|
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
||
|
* University of Stuttgart. All rights reserved.
|
||
|
* Copyright (c) 2004-2005 The Regents of the University of California.
|
||
|
* All rights reserved.
|
||
|
* $COPYRIGHT$
|
||
|
*
|
||
|
* Additional copyrights may follow
|
||
|
*
|
||
|
* $HEADER$
|
||
|
*/
|
||
|
|
||
|
|
||
|
#include "opal_config.h"
|
||
|
|
||
|
#ifdef HAVE_SYS_TYPES_H
|
||
|
#include <sys/types.h>
|
||
|
#endif
|
||
|
#ifdef HAVE_UNISTD_H
|
||
|
#include <unistd.h>
|
||
|
#endif
|
||
|
|
||
|
#include "opal/constants.h"
|
||
|
#include "opal/util/show_help.h"
|
||
|
#include "opal/mca/maffinity/maffinity.h"
|
||
|
#include "opal/mca/maffinity/base/base.h"
|
||
|
|
||
|
|
||
|
int opal_maffinity_base_report_bind_failure(const char *file,
|
||
|
int line,
|
||
|
const char *msg, int rc)
|
||
|
{
|
||
|
static int already_reported = 0;
|
||
|
|
||
|
if (!already_reported) {
|
||
|
char hostname[64];
|
||
|
gethostname(hostname, sizeof(hostname));
|
||
|
|
||
|
opal_show_help("help-opal-maffinity-base.txt", "mbind failure", true,
|
||
|
hostname, getpid(), file, line, msg,
|
||
|
(OPAL_MAFFINITY_BASE_BFA_WARN == opal_maffinity_base_bfa) ?
|
||
|
"Warning -- your job will continue, but possibly with degraded performance" :
|
||
|
"ERROR -- your job may abort or behave erraticly");
|
||
|
already_reported = 1;
|
||
|
return rc;
|
||
|
}
|
||
|
|
||
|
return OPAL_SUCCESS;
|
||
|
}
|