|
LMMC
Lamina Mathematic core
|
LMMC 当前线程的初始化与底层栈管理接口. 更多...
函数 | |
| lmmc_status_t | lmmc_init (void) |
| 获取当前线程的 LMMC 生命周期租约. | |
| lmmc_status_t | lmmc_deinit (void) |
| Release one lifecycle lease owned by the current thread. | |
| lmmc_status_t | lmmc_stack_reset (size_t pool_size) |
| Reset the current thread's LMMP temporary-stack capacity. | |
| long long | lmmc_debug_leaks_get_count (void) |
| Get the number of persistent allocations currently owned by LMMC. | |
| lmmc_status_t lmmc_init | ( | void | ) |
获取当前线程的 LMMC 生命周期租约.
调用支持嵌套;首次获取时初始化当前线程的 LMMP 资源. LMMP temporary-stack allocation follows LMMP's fail-fast contract and therefore cannot be translated into LMMC_STATUS_ALLOCATION_FAILED.
LMMC_STATUS_OK on success or LMMC_STATUS_REFERENCE_LIMIT when the current thread's lease count cannot be incremented. 引用了 lmmc_init(), LMMC_STATUS_OK , 以及 LMMC_STATUS_REFERENCE_LIMIT.
被这些函数引用 lmmc_init().
| lmmc_status_t lmmc_deinit | ( | void | ) |
Release one lifecycle lease owned by the current thread.
A final matching call releases only the current thread's LMMP temporary stack state. Persistent LMMC objects use the recoverable heap bridge and may outlive deinitialization; concurrent mutation still requires external synchronization.
LMMC_STATUS_OK on success or LMMC_STATUS_NOT_INITIALIZED when no lease is active. 引用了 lmmc_deinit(), LMMC_STATUS_NOT_INITIALIZED , 以及 LMMC_STATUS_OK.
被这些函数引用 lmmc_deinit().
| lmmc_status_t lmmc_stack_reset | ( | size_t | pool_size | ) |
Reset the current thread's LMMP temporary-stack capacity.
The reset is rejected only while this thread holds nested lifecycle leases. Persistent vectors, matrices, tensors, interpolation objects, and RNG handles do not block a temporary-stack reset.
| pool_size | Requested LMMP temporary-pool size in bytes. |
LMMC_STATUS_OK on success, LMMC_STATUS_NOT_INITIALIZED without an active lease or when the lower-level stack cannot be reinitialized, or LMMC_STATUS_BUSY for a nested lease. 引用了 lmmc_stack_reset(), LMMC_STATUS_BUSY, LMMC_STATUS_NOT_INITIALIZED , 以及 LMMC_STATUS_OK.
被这些函数引用 lmmc_stack_reset().
| long long lmmc_debug_leaks_get_count | ( | void | ) |
Get the number of persistent allocations currently owned by LMMC.
Available only when compiled with LMMC_DEBUG_LEAKS. The process-wide atomic count follows bridge allocations and remains correct when an object is destroyed on a different thread.
在文件 memory_bridge.c 第 111 行定义.
引用了 lmmc_debug_leaks_get_count().
被这些函数引用 lmmc_debug_leaks_get_count().