Click here to Skip to main content
15,868,016 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi, how can i get rid of this error :IntelliSense: expected an expression ??
it's bothering me alot :(
C++
#include "cuda.h"
#include "cuda_runtime.h"
#include "device_launch_parameters.h"

#include <stdio.h>

__global__ void helloworldcuda_Kernel()
{
    printf("Hello world cuda");
    }

void helloworldcuda()
{
helloworldcuda_Kernel<<<1, 1>>>();
}
int main()
{
    helloworldcuda();
}
Posted
Updated 24-Apr-15 22:13pm
v3
Comments
Richard MacCutchan 25-Apr-15 4:13am    
Where?
Member 11640624 25-Apr-15 4:34am    
in line 14 helloworldcuda_Kernel<<<1, 1>>>(); here is red line ???
Richard MacCutchan 25-Apr-15 4:56am    
I don't recognise that syntax, what does it mean?
Member 11640624 25-Apr-15 7:08am    
i myself don't know ... it's cuda c program
Richard MacCutchan 25-Apr-15 8:08am    
Then go and talk to the people who wrote it.

1 solution

This syntax looks strange and the compilers says it isnt valid. You should check the CUDA documents to write working code.

I found some solution with google. There is also a link for a tutorial. You should study it.
 
Share this answer
 
Comments
Member 11640624 26-Apr-15 3:09am    
thanks but it wasn't helpful :(
Richard MacCutchan 26-Apr-15 9:25am    
Are you sure you read the solution suggestion? It quite clearly states that this syntax will not be recognised by a C++ compiler, so you need to use the proper CUDA processor to deal with it.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900