Hash :
6c160cad
Author :
Date :
2025-08-04T12:32:36
CL/Vulkan: cl_khr_external_memory extension (pt.1)
- Make this extension visible if Vulkan implementation support
features supportsExternalMemoryFd and/or
supportsExternalMemoryDmaBuf
- Implemented APIs clEnqueueAcquireExternalMemObjectsKHR and
clEnqueueReleaseExternalMemObjectsKHR
- Updated clCreateBufferWithProperties to handle external memory
file descriptor.
Bug: angleproject:378017028
Change-Id: Idff08808bc0227b5f98b84c2086b68541665146d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6785087
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Austin Annestrand <a.annestrand@samsung.com>
//
// Copyright 2021 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
// dispatch.h: Declares a function to fetch the ANGLE OpenCL dispatch table.
#ifndef LIBOPENCL_DISPATCH_H_
#define LIBOPENCL_DISPATCH_H_
#include "export.h"
#ifndef CL_API_ENTRY
# define CL_API_ENTRY ANGLE_EXPORT
#endif
#include "angle_cl.h"
namespace cl
{
struct IcdDispatch : public _cl_icd_dispatch
{
clIcdGetPlatformIDsKHR_fn clIcdGetPlatformIDsKHR;
// TODO: below extensions will be refactored to not to expose them publicly later
// http://anglebug.com/378017028
clEnqueueAcquireExternalMemObjectsKHR_fn clEnqueueAcquireExternalMemObjectsKHR;
clEnqueueReleaseExternalMemObjectsKHR_fn clEnqueueReleaseExternalMemObjectsKHR;
};
const IcdDispatch &GetDispatch();
} // namespace cl
#endif // LIBOPENCL_DISPATCH_H_