Remove store allocation methods from memory manager

Move setGPUAddress method to WddmAllocation

Change-Id: I91d877c3791e9eff69276e4258e3ce9c3111ca45
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
Mateusz Jablonski
2018-10-24 14:25:04 +02:00
committed by sys_ocldev
parent f992cff0c3
commit d5c9816428
31 changed files with 319 additions and 324 deletions

View File

@@ -8,6 +8,7 @@
#include "runtime/command_stream/command_stream_receiver.h"
#include "runtime/command_stream/experimental_command_buffer.h"
#include "runtime/command_stream/linear_stream.h"
#include "runtime/memory_manager/internal_allocation_storage.h"
#include "runtime/memory_manager/memory_constants.h"
#include "runtime/memory_manager/memory_manager.h"
#include <cstring>
@@ -66,7 +67,7 @@ void ExperimentalCommandBuffer::getCS(size_t minRequiredSize) {
// Deallocate the old block, if not null
auto oldAllocation = currentStream->getGraphicsAllocation();
if (oldAllocation) {
memoryManager->storeAllocation(std::unique_ptr<GraphicsAllocation>(oldAllocation), REUSABLE_ALLOCATION);
commandStreamReceiver->getInternalAllocationStorage()->storeAllocation(std::unique_ptr<GraphicsAllocation>(oldAllocation), REUSABLE_ALLOCATION);
}
currentStream->replaceBuffer(allocation->getUnderlyingBuffer(), minRequiredSize - CSRequirements::minCommandQueueCommandStreamSize);
currentStream->replaceGraphicsAllocation(allocation);