Add the RdcSmiDiagnostic module

Provides a RdcSmiDiagnostic module, which will call rocm_smi_lib.

It will support following diagnostics: Get GPU Topology, Check GPU
parameters and check processes running on the GPUs.

The grpc client and server side diagnostics function is added.

The diag module is added to the rdci.

Change-Id: I10a0cf3c20556a61373ab686f82cae75acaa40dd


[ROCm/rdc commit: 76ccf58008]
This commit is contained in:
Bill(Shuzhou) Liu
2021-06-21 15:35:06 -04:00
parent ac15d50b0c
commit fa9c6ad6f8
22 changed files with 1330 additions and 13 deletions
@@ -145,6 +145,23 @@ int main(int, char **) {
}
}
}
// (5) run one test case
std::cout <<" ============== Run individual diagnostic test ===========\n";
rdc_diag_test_result_t test_result;
result = rdc_test_case_run(rdc_handle, group_id,
RDC_DIAG_COMPUTE_PROCESS, &test_result);
if (result != RDC_ST_OK) {
std::cout << "Error run RDC_DIAG_COMPUTE_PROCESS diagnostic. Return: "
<< rdc_status_string(result);
goto cleanup;
}
std::cout << std::setw(22) << std::left
<< get_test_name(RDC_DIAG_COMPUTE_PROCESS) + ":"
<< rdc_diagnostic_result_string(test_result.status) << "\n";
// Cleanup consists of shutting down RDC.
cleanup:
std::cout << "Cleaning up.\n";