type.h Source File

type.h Source File#

mbltml: type.h Source File
mbltml Test Preview
mbltml — EN
type.h
Go to the documentation of this file.
1// Copyright ⓒ 2019- Mobilint Inc. All rights reserved.
5
6#ifndef MOBILINT_MBLTML_TYPE_H_
7#define MOBILINT_MBLTML_TYPE_H_
8
9#include <stdint.h>
10
17
31
42
54
68
72typedef enum {
73 MBLTML_CLUSTER_0 = 1 << 16,
74 MBLTML_CLUSTER_1 = 2 << 16,
75 MBLTML_CLUSTER_ERROR = 0x7FFF'0000,
77
89
97
104typedef struct {
106 int64_t npu_time;
107 int64_t interval;
109
117typedef struct {
118 int pid = -1;
119 int counts = -1;
120 int64_t npu_memory_usage = 0;
121 int64_t total_interval_us = 0;
122 int64_t total_npu_time_us = 0;
124
126
127#endif // MOBILINT_MBLTML_TYPE_H_
mbltmlDeviceType_t
Identifier of a Mobilint NPU device family.
Definition type.h:25
mbltmlCluster_t
NPU cluster identifier within a device.
Definition type.h:72
mbltmlStatusCode_t
Status code returned by mbltml APIs.
Definition type.h:46
mbltmlCore_t
NPU core identifier within a cluster.
Definition type.h:81
mbltmlHardwareVersion_t
Specific hardware revision of a Mobilint NPU.
Definition type.h:35
mbltmlExtraPmicId_t
Identifier of an extra PMIC rail.
Definition type.h:62
@ MBLTML_DEVICE_REGULUS
Definition type.h:28
@ MBLTML_DEVICE_REGULUS_USB
Definition type.h:29
@ MBLTML_DEVICE_ARIES
Definition type.h:27
@ MBLTML_DEVICE_ERROR
Definition type.h:26
@ MBLTML_CLUSTER_0
Definition type.h:73
@ MBLTML_CLUSTER_1
Definition type.h:74
@ MBLTML_CLUSTER_ERROR
Definition type.h:75
@ MBLTML_INVALID_ARGUMENT
Definition type.h:50
@ MBLTML_DRIVER_NOT_FOUND
Definition type.h:49
@ MBLTML_SUCCESS
Definition type.h:47
@ MBLTML_UNINITIALIZED
Definition type.h:48
@ MBLTML_NOT_SUPPORTED
Definition type.h:51
@ MBLTML_INSUFFICIENT_LENGTH
Definition type.h:52
@ MBLTML_CORE_1
Definition type.h:83
@ MBLTML_CORE_ERROR
Definition type.h:87
@ MBLTML_CORE_2
Definition type.h:84
@ MBLTML_CORE_0
Definition type.h:82
@ MBLTML_CORE_3
Definition type.h:85
@ MBLTML_CORE_GLOBAL
Definition type.h:86
@ MBLTML_HARDWARE_VERSION_ERROR
Definition type.h:40
@ MBLTML_HARDWARE_VERSION_REGULUS
Definition type.h:37
@ MBLTML_HARDWARE_VERSION_ARIES
Definition type.h:36
@ MBLTML_HARDWARE_VERSION_REGULUS2
Definition type.h:39
@ MBLTML_HARDWARE_VERSION_ARIES2
Definition type.h:38
@ MBLTML_EXTRA_PMIC_ID_NPU
Definition type.h:63
@ MBLTML_EXTRA_PMIC_ID_DDR
Definition type.h:64
@ MBLTML_EXTRA_PMIC_ID_PMIC
Definition type.h:65
@ MBLTML_EXTRA_PMIC_ID_GOLDFINGER
Definition type.h:66
Composite identifier of an NPU core (cluster + core).
Definition type.h:93
mbltmlCore_t core
Definition type.h:95
mbltmlCluster_t cluster
Definition type.h:94
Per-core usage record returned by mbltmlGetCoreInfos().
Definition type.h:104
mbltmlCoreId_t core_id
Definition type.h:105
int64_t npu_time
Definition type.h:106
int64_t interval
Definition type.h:107
Per-process usage record returned by mbltmlGetProcessInfos().
Definition type.h:117
int64_t total_npu_time_us
Definition type.h:122
int64_t npu_memory_usage
Definition type.h:120
int64_t total_interval_us
Definition type.h:121