From 3f55ab0f89c3a2e716aa5f8d0389a62ee3254cd8 Mon Sep 17 00:00:00 2001 From: Huihuang Zheng Date: Fri, 14 Jun 2019 19:05:49 +0800 Subject: [PATCH] Modify format of GPU allocation failure log. (#18034) As title test=develop --- paddle/fluid/memory/allocation/legacy_allocator.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/paddle/fluid/memory/allocation/legacy_allocator.cc b/paddle/fluid/memory/allocation/legacy_allocator.cc index 9b6f7d42114..4adc0aabf4f 100644 --- a/paddle/fluid/memory/allocation/legacy_allocator.cc +++ b/paddle/fluid/memory/allocation/legacy_allocator.cc @@ -200,12 +200,12 @@ void *Alloc(const platform::CUDAPlace &place, platform::GpuMemoryUsage(&avail, &total); LOG(FATAL) << "Cannot allocate " << string::HumanReadableSize(size) << " in GPU " << place.device << ", available " - << string::HumanReadableSize(avail) << "total " << total - << "GpuMinChunkSize " + << string::HumanReadableSize(avail) << ", total " + << string::HumanReadableSize(total) << ", GpuMinChunkSize " << string::HumanReadableSize(buddy_allocator->GetMinChunkSize()) - << "GpuMaxChunkSize " + << ", GpuMaxChunkSize " << string::HumanReadableSize(buddy_allocator->GetMaxChunkSize()) - << "GPU memory used: " + << ", GPU memory used: " << string::HumanReadableSize(Used(place)); } else { if (FLAGS_benchmark) { -- GitLab