mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-05 09:09:04 +08:00
Cleanup includes 49
Cleaned up files: opencl/source/command_queue/command_queue_hw.h opencl/source/gtpin/gtpin_defs.h opencl/source/mem_obj/mem_obj_helper.h opencl/source/memory_manager/mem_obj_surface.h opencl/source/sharings/unified/unified_sharing.h opencl/test/unit_test/api/cl_enqueue_migrate_mem_objects_tests.inl opencl/test/unit_test/aub_tests/fixtures/unified_memory_fixture.h opencl/test/unit_test/command_queue/command_queue_fixture.h Related-To: NEO-5548 Signed-off-by: Warchulski, Jaroslaw <jaroslaw.warchulski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
64f735481d
commit
d1b2311207
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -8,28 +8,18 @@
|
||||
#pragma once
|
||||
#include "shared/source/memory_manager/surface.h"
|
||||
|
||||
#include "opencl/source/mem_obj/mem_obj.h"
|
||||
|
||||
namespace NEO {
|
||||
|
||||
class MemObj;
|
||||
|
||||
class MemObjSurface : public Surface {
|
||||
public:
|
||||
MemObjSurface(MemObj *memObj) : Surface(memObj->getMultiGraphicsAllocation().isCoherent()), memObj(memObj) {
|
||||
memObj->incRefInternal();
|
||||
}
|
||||
~MemObjSurface() override {
|
||||
memObj->decRefInternal();
|
||||
memObj = nullptr;
|
||||
};
|
||||
MemObjSurface(MemObj *memObj);
|
||||
~MemObjSurface() override;
|
||||
|
||||
void makeResident(CommandStreamReceiver &csr) override {
|
||||
DEBUG_BREAK_IF(!memObj);
|
||||
csr.makeResident(*memObj->getGraphicsAllocation(csr.getRootDeviceIndex()));
|
||||
}
|
||||
void makeResident(CommandStreamReceiver &csr) override;
|
||||
|
||||
Surface *duplicate() override {
|
||||
return new MemObjSurface(this->memObj);
|
||||
};
|
||||
Surface *duplicate() override;
|
||||
|
||||
protected:
|
||||
class MemObj *memObj;
|
||||
|
||||
Reference in New Issue
Block a user