CreateAndRegisterAllocator property
Pointer<NativeFunction<OrtStatusPtr Function(Pointer<OrtEnv> env, Pointer<OrtMemoryInfo> mem_info, Pointer<OrtArenaCfg> arena_cfg)> >
CreateAndRegisterAllocator
getter/setter pair
\brief Create an allocator and register it with the ::OrtEnv
Enables sharing the allocator between multiple sessions that use the same env instance. Lifetime of the created allocator will be valid for the duration of the environment. Returns an error if an allocator with the same ::OrtMemoryInfo is already registered.
See https://onnxruntime.ai/docs/get-started/with-c.html for details.
\paramin env ::OrtEnv instance
\paramin mem_info
\paramin arena_cfg Pass nullptr for defaults
\snippet{doc} snippets.dox OrtStatus Return Value
Implementation
external ffi.Pointer<
ffi.NativeFunction<
OrtStatusPtr Function(
ffi.Pointer<OrtEnv> env,
ffi.Pointer<OrtMemoryInfo> mem_info,
ffi.Pointer<OrtArenaCfg> arena_cfg,
)
>
>
CreateAndRegisterAllocator;