580
社区成员
发帖
与我相关
我的任务
分享
#include <stdio.h>
__global__
void Kernel()
{
printf("%d ", threadIdx.x);
}
void Test(int n)
{
Kernel<<<1, n>>>();
}
// Test.h
#ifndef TEST_H
#define TEST_H
void Test(int n);
#endif
// main.cpp
#include "Test.h"
void main()
{
Test(10);
}