Searched refs:alloc_mem_size (Results 1 – 2 of 2) sorted by relevance
59 auto alloc_mem_size = ASCEND_DYNAMIC_MEM_ALLOC_UNIT_SIZE; in CalMemBlockAllocSize() local66 while (alloc_mem_size < size) { in CalMemBlockAllocSize()67 alloc_mem_size = alloc_mem_size * kDouble; in CalMemBlockAllocSize()70 alloc_mem_size = ASCEND_DYNAMIC_MEM_ALLOC_UNIT_SIZE_FOR_GRAPH; in CalMemBlockAllocSize()71 while (alloc_mem_size < size) { in CalMemBlockAllocSize()72 alloc_mem_size = alloc_mem_size + ASCEND_DYNAMIC_MEM_ALLOC_UNIT_SIZE_FOR_GRAPH; in CalMemBlockAllocSize()75 alloc_mem_size = std::min(alloc_mem_size, device_free_mem_size); in CalMemBlockAllocSize()76 return alloc_mem_size; in CalMemBlockAllocSize()
111 size_t alloc_mem_size = CalMemBlockAllocSize(size); in AddMemBlockAndMemBuf() local112 if (alloc_mem_size == 0) { in AddMemBlockAndMemBuf()117 auto real_alloc_size = AllocDeviceMem(alloc_mem_size, &device_addr); in AddMemBlockAndMemBuf()154 auto alloc_mem_size = mem_alloc_unit_size(); in CalMemBlockAllocSize() local157 while (alloc_mem_size < size) { in CalMemBlockAllocSize()158 alloc_mem_size = alloc_mem_size * kDouble; in CalMemBlockAllocSize()160 alloc_mem_size = std::min(alloc_mem_size, device_free_mem_size); in CalMemBlockAllocSize()161 return alloc_mem_size; in CalMemBlockAllocSize()