mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-08 14:02:58 +08:00
This change introduces creating and releasing buffers from memory handle. Currently Windows NT Handles are supported. Change-Id: I61b89d97946ce61617ad98922b7e9731d4a754a9 Signed-off-by: Maciej Dziuban <maciej.dziuban@intel.com> Related-To: NEO-3771
28 lines
689 B
C++
28 lines
689 B
C++
/*
|
|
* Copyright (C) 2019 Intel Corporation
|
|
*
|
|
* SPDX-License-Identifier: MIT
|
|
*
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include "runtime/sharings/unified/unified_sharing.h"
|
|
|
|
namespace NEO {
|
|
class Buffer;
|
|
class Context;
|
|
|
|
class UnifiedBuffer : public UnifiedSharing {
|
|
using UnifiedSharing::UnifiedSharing;
|
|
|
|
public:
|
|
static Buffer *createSharedUnifiedBuffer(Context *context, cl_mem_flags flags, UnifiedSharingMemoryDescription description, cl_int *errcodeRet);
|
|
void synchronizeObject(UpdateData &updateData) override;
|
|
|
|
protected:
|
|
void releaseResource(MemObj *memObject) override;
|
|
static GraphicsAllocation *createGraphicsAllocation(Context *context, void *handle);
|
|
};
|
|
} // namespace NEO
|