文字列操作は出来ないんですか?
#include <stdio.h>
int main (int argc, const char * argv[]) {
char string[] ="Hello,World";
char stringat[13];
copy (string,stringat);
printf("%s¥n",stringat);
return 0;
}
__global__ void
copy (char *buff,char *buffat){
int i = 0;
while(buff[i]){
buffat[i] = buff[i];
i++;
}
buffat[i] = '¥0';
}
良く分からないですけれど、こんな感じで。