Debian Codegraph @

shared/source/gmm_helper/client_context/gmm_handle_allocator.h

raw
1 /*
2 * Copyright (C) 2021-2022 Intel Corporation
3 *
4 * SPDX-License-Identifier: MIT
5 *
6 */
7
8 #pragma once
9
10 #include "shared/source/gmm_helper/gmm_lib.h"
11
12 #include <cstddef>
13
14 namespace NEO {
15
16 class GmmHandleAllocator {
17 public:
18 virtual ~GmmHandleAllocator() = default;
19
20 virtual void *createHandle(const GMM_RESOURCE_INFO *gmmResourceInfo) {
21 return nullptr;
22 }
23 virtual void destroyHandle(void *handle) {
24 }
25 virtual bool openHandle(void *handle, GMM_RESOURCE_INFO *dstResInfo, size_t handleSize) {
26 return true;
27 }
28 virtual size_t getHandleSize() {
29 return 0;
30 }
31 };
32
33 } // namespace NEO