allocate unified memory in my program. aftering running, it throws CUDA Error:out of memory,but still has free memory
问题 Before asking this, I have read this question , which is similar to mine. Here I will provide my program in detail. #define N 70000 #define M 1000 class ObjBox {public: int oid; float x; float y; float ts}; class Bucket {public: int bid; int nxt; ObjBox *arr_obj; int nO;} int main() { Bucket *arr_bkt; cudaMallocManaged(&arr_bkt, N * sizeof(Bucket)); for (int i = 0; i < N; i++) { arr_bkt[i].bid = i; arr_bkt[i].nxt = -1; arr_bkt[i].nO = 0; cudaError_t r = cudaMallocManaged(&(arr_bkt[i].arr_obj)