Исходный код СУБД RuDB — свободной СУБД с открытым исходным кодом на базе PostgreSQL
rudb
3 days ago bd039d1e92813358c5c5a1e346b49074baf513f2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
 
#pragma once
 
#include "core/session/onnxruntime_c_api.h"
 
namespace OrtInteropAPI {
 
// implementation that returns the API struct
ORT_API(const OrtInteropApi*, GetInteropApi);
 
ORT_API_STATUS_IMPL(CreateExternalResourceImporterForDevice, _In_ const OrtEpDevice* ep_device,
                    _Outptr_result_maybenull_ OrtExternalResourceImporter** out_importer);
 
ORT_API(void, ReleaseExternalResourceImporter, _Frees_ptr_opt_ OrtExternalResourceImporter* importer);
 
ORT_API_STATUS_IMPL(CanImportMemory, _In_ const OrtExternalResourceImporter* importer,
                    _In_ OrtExternalMemoryHandleType handle_type,
                    _Out_ bool* out_supported);
 
ORT_API_STATUS_IMPL(ImportMemory, _In_ OrtExternalResourceImporter* importer,
                    _In_ const OrtExternalMemoryDescriptor* desc,
                    _Outptr_ OrtExternalMemoryHandle** out_handle);
 
ORT_API(void, ReleaseExternalMemoryHandle, _Frees_ptr_opt_ OrtExternalMemoryHandle* handle);
 
ORT_API_STATUS_IMPL(CreateTensorFromMemory, _In_ OrtExternalResourceImporter* importer,
                    _In_ const OrtExternalMemoryHandle* mem_handle,
                    _In_ const OrtExternalTensorDescriptor* tensor_desc,
                    _Outptr_ OrtValue** out_tensor);
 
ORT_API_STATUS_IMPL(CanImportSemaphore, _In_ const OrtExternalResourceImporter* importer,
                    _In_ OrtExternalSemaphoreType type,
                    _Out_ bool* out_supported);
 
ORT_API_STATUS_IMPL(ImportSemaphore, _In_ OrtExternalResourceImporter* importer,
                    _In_ const OrtExternalSemaphoreDescriptor* desc,
                    _Outptr_ OrtExternalSemaphoreHandle** out_handle);
 
ORT_API(void, ReleaseExternalSemaphoreHandle, _Frees_ptr_opt_ OrtExternalSemaphoreHandle* handle);
 
ORT_API_STATUS_IMPL(WaitSemaphore, _In_ OrtExternalResourceImporter* importer,
                    _In_ OrtExternalSemaphoreHandle* semaphore_handle,
                    _In_ OrtSyncStream* stream,
                    _In_ uint64_t value);
 
ORT_API_STATUS_IMPL(SignalSemaphore, _In_ OrtExternalResourceImporter* importer,
                    _In_ OrtExternalSemaphoreHandle* semaphore_handle,
                    _In_ OrtSyncStream* stream,
                    _In_ uint64_t value);
 
ORT_API_STATUS_IMPL(InitGraphicsInteropForEpDevice, _In_ const OrtEpDevice* ep_device,
                    _In_ const OrtGraphicsInteropConfig* config);
ORT_API_STATUS_IMPL(DeinitGraphicsInteropForEpDevice, _In_ const OrtEpDevice* ep_device);
 
}  // namespace OrtInteropAPI