CUdeviceptr Problem

I just include “generated_cuda_meta.h” in my AutoProfiler.cc code,and this fault happen to me:

[ERROR] fail to compile baidu/adu-lab/inference-engine/infer/CUPTI_Profiling/xxx_adu-lab_inference-engine_inference-engine_so_AutoProfiler.cc.o ip:10.144.206.23
 err:In file included from xxx/adu-lab/inference-engine/infer/CUPTI_Profiling/AutoProfiler.h:33,
                 from baidu/adu-lab/inference-engine/infer/CUPTI_Profiling/AutoProfiler.cc:1:
bc_out/xxx/adu-3rd/cuda/output/include/generated_cuda_meta.h:2370:5: error: 'CUdeviceptr_v1' does not name a type; did you mean 'CUdeviceptr_v2'?
 2370 |     CUdeviceptr_v1 *dptr;
      |     ^~~~~~~~~~~~~~
      |     CUdeviceptr_v2
bc_out/xxx/adu-3rd/cuda/output/include/generated_cuda_meta.h:2382:5: error: 'CUdeviceptr_v1' does not name a type; did you mean 'CUdeviceptr_v2'?
 2382 |     CUdeviceptr_v1 *dptr;
      |     ^~~~~~~~~~~~~~
      |     CUdeviceptr_v2

Whats the problem here?And the header inclusion part in my AutoProfiler.h is as below:

#include <iostream>

using ::std::cerr;

using ::std::cout;

using ::std::endl;

using ::std::left;

#include <iomanip>

using ::std::setw;

#include <string>

using ::std::string;

using ::std::to_string;

#include <vector>

using ::std::vector;

#include <unordered_map>

using ::std::unordered_map;

#include <mutex>

using ::std::mutex;

#include <unordered_set>

using ::std::unordered_set;

#include <map>

using ::std::map;

#include <stdlib.h>

#include <cuda.h>

#include <cuda_runtime_api.h>

#include <cuda_runtime.h>

// CUPTI headers

#include <cupti_activity.h>

#include <cupti_callbacks.h>

#include <cupti_profiler_target.h>

#include <cupti_driver_cbid.h>

#include <cupti_runtime_cbid.h>

#include "generated_cuda_runtime_api_meta.h"

#include "generated_cuda_meta.h"

#include <cupti_target.h>

#include "infer/CUPTI_Profiling/CUpti_Header/CUpti_tool.h"

//#include "helper_cupti_activity.h"

// NVPW headers

#include <nvperf_host.h>

#include <nvperf_cuda_host.h>

#include <nvperf_target.h> // CUDA 相关的 NVPW 接口

#include "infer/CUPTI_Profiling/CUpti_Header/Eval.h"

using ::NV::Metric::Eval::PrintMetricValues;

// NVTX headers

#include "nvtx3/nvToolsExt.h"

#include "nvtx3/nvToolsExtCuda.h"

#include "nvtx3/nvToolsExtCudaRt.h"

#include "generated_nvtx_meta.h"

#include "infer/CUPTI_Profiling/CUpti_Header/Metric.h"

using ::NV::Metric::Config::GetConfigImage;

using ::NV::Metric::Config::GetCounterDataPrefixImage;

#include "infer/CUPTI_Profiling/CUpti_Header/Utils.h"

using ::NV::Metric::Utils::GetNVPWResultString;

#include "infer/CUPTI_Profiling/CUpti_Header/Parser.h"

really looking forward to any possible answer or solution

Hi, @fwd20001101

Is it possible to provide us a mini-repro for investigation ?

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.