Error in Linking

Hello,

I have written a code that needs to compare CPU and GPU performance. For that purpose I was using GPU timers (Can I use Events and other functions from cutil_inline.h in .cpp files? They worked all right in the Debug mode). However, when I try to compile in the Release mode, I get the following error

error LNK2001: unresolved external symbol _cudaEventCreate@4

Do I have to time using the CPU timers? Is there no other way I could overcome this problem?

Hi,

I think you have a different configuration in Release and Debug mode.

You have to go properties > linking options > input
and make sure you have all libraries in this input (like in your debug mode options)

Hope that will help you

Hi mainak,

Does your code work, i want to test GPU performance also, but i am new to cuda and i am not a developper, could you post it please?

thx!