开发者

how to copy 64 bit integer from host to device in cuda?

I need to copy 64 bit integer data from host to device memory.

Both of them are declared as unsigned __int64 and i used cudaMemcpyToSymbol().

By checking with Parallel Nsight, the copied data is shown as a negative integ开发者_开发知识库er.

I guess the most significant bit of the lower 4 bytes is treated as a sign bit which is not supposed to be.

Can anybody give me any direction to come up with this?


Oh, I found the reason.
Though every 64-bit data manipulation works fine, Parallel Nsight does not recognize any 64 bit integer.
It was Nsight problem. It really sucks.
This incomplete debugger made me waste time.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜