我有一张2GB内存的GTX570显卡,但是当我尝试在一个cudamalloc调用中分配超过804MB的内存时,就会出现问题。有人知道这是为什么吗?这是我的第一次调用,所以我怀疑这不是碎片化造成的问题。
没问题:
没问题:
Memory avaliable: Free: 2336116736, Total: 2684026880
requesting 804913152 bytes
no error
Memory avaliable: Free: 1531199488, Total: 2684026880
requesting 804913152 bytes
no error
Memory avaliable: Free: 726286336, Total: 2684026880
问题:
Memory avaliable: Free: 2327601152, Total: 2684026880
requesting 805306368 bytes
out of memory
Memory avaliable: Free: 2327597056, Total: 2684026880
requesting 805306368 bytes
out of memory
Memory avaliable: Free: 2327597056, Total: 2684026880