0b192d2299
Perform exact matching when the prefix "=" is specified in the NCCL_IB_HCA variable to exclude HCAs mlx5_X[0-9]+ when mlx5_X is specified.
26 lines
705 B
C
26 lines
705 B
C
/*************************************************************************
|
|
* Copyright (c) 2016-2019, NVIDIA CORPORATION. All rights reserved.
|
|
*
|
|
* See LICENSE.txt for license information
|
|
************************************************************************/
|
|
|
|
#ifndef NCCL_UTILS_H_
|
|
#define NCCL_UTILS_H_
|
|
|
|
#include "nccl.h"
|
|
#include <stdint.h>
|
|
|
|
ncclResult_t getHostName(char* hostname, int maxlen, const char delim);
|
|
uint64_t getHostHash();
|
|
uint64_t getPidHash();
|
|
|
|
struct netIf {
|
|
char prefix[64];
|
|
int port;
|
|
};
|
|
|
|
int parseStringList(const char* string, struct netIf* ifList, int maxList);
|
|
bool matchIfList(const char* string, int port, struct netIf* ifList, int listSize, bool matchExact);
|
|
|
|
#endif
|