Intel® oneAPI Base Toolkit
Support for the core tools and libraries within the base toolkit that are used to build and deploy high-performance data-centric applications.
419 Discussions

Problem to run DNN /// @example getting_started.cpp


I try to install OneDNN on my computer (Visual studio 2022) -
The Intel c++ compiler extension --> well installed
ONE API toolkit --> is also well installed.

1 - I built the project with Cmake.

On my CMAKE build, the .dln getting started.cpp file is working fine (I can compile without worries)

2 - So now, I want to generate the library to use it on my project --> installation and it works fine (C:\Program Files (x86)\oneDNN --> see screenshot)

3 - I create a new project on Visual Studio.
I put as additional include directories:
C:\Program Files (x86)\oneDNN\bin
C:\Program Files (x86)\oneDNN\include
C:\Program Files (x86)\oneDNN\lib

First problem!
#include "examples\example_utils.hpp" is still not recognized so for that I add this path
#include "C:\Program Files (x86)\Intel\oneAPI\dnl\latest\iompples\example_utils.hpp" --> PATH of an api installation


Now I can compile but the compilation fails with "linker command failed". (the log file is in copy)

Can you tell me what I did wrong?

Thank you very much

0 Kudos
8 Replies



Thanks for reaching out to us.

We are working on your issue internally. We will get back to you soon.


Thanks & Regards,



0 Kudos

Can you please provide a sample of your project that demonstrates the issue you reported?

0 Kudos

Yes of course, please find the project file attached below ; Test
This morning i redbuild the project with cmake. from official INTEL repo

And i reinstalled with installers inside (to be sure to have the same version, w_BaseKit_p_2022.2.0.252, w_dpcpp-cpp-compiler_p_2022.1.0.138, VisualStudioSetup)


It seems version of oneAPI change therefore the path of exemple are now : C:\Program Files (x86)\Intel\oneAPI\dnnl\2022.1.0\cpu_iomp\examples




Waiting your solution as reply

0 Kudos



For VS on Windows, you should link/use the cpu_vcomp folder instead of cpu_iomp.

Moreover, you could also refer to the CMakefile and template.vcproj.user for your new projects.



The good first step might be put your samples into cpu_vcomp/examples folder, and then compile it with other existed examples.

once it is compiled successfully, you could try to create your own project refer to the CMakefile and template.vcproj.user.

you could also refer to below cmakefile how we compile a new sample with VS on command line.


Wish it help.





0 Kudos


For VS on Windows, you should link/use the cpu_vcomp folder instead of cpu_iomp. --> changed and it doesn't work  ---> could also be better to give more explanation


Moreover, you could also refer to the CMakefile and template.vcproj.user for your new projects. 

---> sorry i'm not  Cmake engineer i just want to use your INTEL library ...


It's frustrating ! believe that you do not want us to use your libraries.
Nothing is simple, the explanations are not clear!
Intel if you are not able to be user friendly I would use cuda or the more user friendly AMD environments.

Your tutorials are not clear, your "get started" is for Intel employees.

I really want to use your libraries, I took the time to explain my problem and on the INTEL side the explanations are not...

We paid $699 last week for Priority Support...

I m losing time and money thank you intel


Is there someone can really help me to use DNN ? SInce two week i try to use this "DNN" ... Two weeks and still no good explanation






0 Kudos


If CMakefile confuses you, the easiest way as I mentioned is to copy your codes into 

C:\Program Files (x86)\Intel\oneAPI\dnnl\latest\cpu_vcomp\examples folder, and then recompile with your successful VS project in step 1.

You should be able to develop your codes without worrying those cmake or VS details.


If you are priority support customer, please go for priority support web portal.

Issues from Priority Support are treated with higher priority than Forum questions.




0 Kudos

Dear Louie,


I'm really estonished on your answer for two reasons :


First, i did what you ask to do from me as copy your codes into cpu_vcomp\examples folder --> it does not work !!!

(complete screen shot attached --> Test DNN.cpp file is the latest one)




I also added path in order to be able to start compilation (without it's not working)



As result fail in compilation (Log is in copy please check !!)


Secondly, as i told you we paid $699 last week for Priority Support because the answers of the forum are random. We said to ourselves, ok we will pay, we will save time --> serious mistake.


Because i open 4 cases (same cases !!!) in my priority support and it only post it in this forum !!

Please see the screen shot !!!


A priority support web portal story


First we click on priority support on the web portal dedicated on  :


Secondly will be redirected in our "only service center", as you can see i open 4 cases and one is closed just becasue i tries the "chat" and explain i need help (no solution)



The Request 05486219 is this post !!!! --> Problem to run DNN /// @example getting_started.cpp --> same title !!!!

My other cases could be find inside this "helpful" forum




Priority Support  is $699 joke !

It just repost inside this forum and give up without any help !! 

I need to know where is my Priority Support ????


So now, after all this effort i have no real solution, no priority support and lost $699 !!

Thank you INTEL !! 


I understand better now why nobody uses your libraries. You don't respect your customers.


Issues from Priority Support are treated with higher priority than Forum questions. --> i like this joke, really very funy ! 


More seriously, we expect a detailed and tested solution from you, be a pro. Cause we're really wasting time.


0 Kudos



I am not sure why it doesn't work for you. The Cmakefile will compile all the source c and cpp files there for you.

Remember to do all reproduces again, because you need to generate a new Cmakecache.txt for your new files list.

If not, it definitely won't compile your new C or Cpp file.


This issue duplicates 05485460.

As we mentioned in 0585460, you could also use below method to compile your codes with a new CMakefile project.


please follow below session for building a sample with Windows Visual Studio.

You should be able to see the results like attached onednn_windows.PNG, and it is validated with Visual Studio 2019.





For your own codes, you could follow below steps to compile it based upon above steps.

  1. change below line. replace $ENV{DNNLROOT}/examples to either your source code folder and source file.
  2. repeat every steps in


Let us know whether it works for you or not.

0 Kudos