Migrating to SYCL
One-stop forum for getting assistance migrating your existing code to SYCL
Announcements
FPGA community forums and blogs have moved to the Altera Community. Existing Intel Community members can sign in with their current credentials.
48 Discussions

DPC++ compatibility tool error, oneAPI samples, Devcloud

Eltablawy__Alaa
3,596 Views

Hello,

 

I'm trying to run one of the oneAPI samples for Cuda code migration on the devcloud.

The code I'm running is https://github.com/oneapi-src/oneAPI-samples/tree/master/Tools/Migration/folder-options-dpct

 

When I run the command in the README.md, I get the following:

Case1:

dpct --in-root=foo --out-root=result/foo foo/main.cu foo/bar/util.cu --extra-arg="-Ifoo/bar/"

dpct exited with code: -5 (Error: Path for CUDA header files is invalid or not available. Use --cuda-include-path to specify the correct path to the header files)

 

When I add the path to include/cude, I get the following:


Case2:

dpct --cuda-include-path=<path to cuda>/include --in-root=foo --out-root=result/foo foo/main.cu foo/bar/util.cu --extra-arg="-Ifoo/bar/"


Processing: /home/u52/workstation/CudaToDPC++/oneAPI-samples/Tools/Migration/folder-options-dpct/foo/main.cu
Skipping /home/u52/workstation/CudaToDPC++/oneAPI-samples/Tools/Migration/folder-options-dpct/foo/main.cu. Compile command not found.
Processing: /home/u52/workstation/CudaToDPC++/oneAPI-samples/Tools/Migration/folder-options-dpct/foo/bar/util.cu
Skipping /home/u52/workstation/CudaToDPC++/oneAPI-samples/Tools/Migration/folder-options-dpct/foo/bar/util.cu. Compile command not found.
dpct exited with code: 1 (Migration not necessary; no CUDA code detected)

 

is the DPC++ compatibility tool supported on Devcloud? and is there any documentation for using the tool on the Devcloud?

 

0 Kudos
8 Replies
RahulV_intel
Moderator
3,560 Views

Hi,


I have tried the steps (given in the tutorial) in my environment. The migration and compilation/run were successful in my case.


Could you please specify your CUDA toolkit?


DPCT requirements:

https://software.intel.com/content/www/us/en/develop/articles/intel-dpc-compatibility-tool-system-requirements.html


Thanks,

Rahul



0 Kudos
Eltablawy__Alaa
3,544 Views

Thanks, Rahul for your answer, I used the toolkit include from 10.2. 

Which toolkit you used in your env. ?

 

Regards,

Alaa

0 Kudos
RahulV_intel
Moderator
3,516 Views

Hi,

 

Apologies for the late response. I have the same CUDA toolkit version.

 

As a possible workaround, could you try changing your CUDA application to a different directory and give it a try? (CUDA toolkit installation directory and CUDA application directory should be different). Let me know if it helps.

 

Also, try to migrate a simple CUDA vector add code and let me know how it goes.

dpct --cuda-include-path=<path to cuda>/include vecadd.cu

 

Thanks,

Rahul

0 Kudos
RahulV_intel
Moderator
3,463 Views

Hi,


Could you please confirm if your issue is solved? Let us know if you face any issues.


Thanks,

Rahul


0 Kudos
Eltablawy__Alaa
3,445 Views

Thanks Rahul, yes, I have the issue resolved. The solution to my issue us as follow:

1- as you suggested, changing the CUDA application directory helped in resolving the following issue:

Processing: /home/.../oneAPI-samples/Tools/Migration/vector-add-dpct/src/vector_add.cu
Skipping /home/.../oneAPI-samples/Tools/Migration/vector-add-dpct/src/vector_add.cu. Compile command not found.
dpct exited with code: 1 (Migration not necessary; no CUDA code detected)

 

2- Changing the CUDA application path not to be the same as CUDA lib, helped with that issue:

dpct exited with code: -5 (Error: Path for CUDA header files is invalid or not available. Use --cuda-include-path to specify the correct path to the header files)

So I used the following command to migrate: dpct --cuda-include-path=../include --in-root=. src/vector_add.cu --out-root=output/

Also, without specifying the --in-root option, it produced the same output.

 

Thanks for your help! 

0 Kudos
RahulV_intel
Moderator
3,416 Views

Hi,


Since your issue is resolved, could you let me know if I can close this thread from my end?


Thanks,

Rahul


0 Kudos
Eltablawy__Alaa
3,411 Views

Sure, it's resolved, and you can close the issue.

 

Thanks!

Alaa

0 Kudos
RahulV_intel
Moderator
3,375 Views

Hi,


Thanks for the confirmation. Intel will no longer monitor this thread. Further discussions on this thread will be considered community only.


Regards,

Rahul


0 Kudos
Reply