| 33 | namespace { |
| 34 | |
| 35 | TEST(GPUTensorPoolAllocatorTest, SmallAllocationWithAlignment32B) { |
| 36 | PlatformGpuId platform_gpu_id(0); |
| 37 | GPUMemAllocator* sub_allocator = new GPUMemAllocator( |
| 38 | GpuIdUtil::ExecutorForPlatformGpuId(platform_gpu_id).ValueOrDie(), |
| 39 | platform_gpu_id, false /*use_unified_memory*/, {}, {}); |
| 40 | GPUTensorPoolAllocator allocator(sub_allocator, "GPU_0_tensorpool", 1 << 30); |
| 41 | void* p = allocator.AllocateRaw(32, 100); |
| 42 | EXPECT_TRUE(p != nullptr); |
| 43 | allocator.DeallocateRaw(p); |
| 44 | } |
| 45 | |
| 46 | TEST(GPUTensorPoolAllocatorTest, SmallAllocationWithAlignment8B) { |
| 47 | PlatformGpuId platform_gpu_id(0); |
nothing calls this directly
no test coverage detected