Error codes¶
This page summarizes QNN API error codes.
-
QNN_SUCCESS 0
Global value indicating success.
-
enum QnnCommon_Error_t
An enum which defines error codes commonly used across API components.
Values:
-
enumerator QNN_COMMON_MIN_ERROR = 1000
-
enumerator QNN_COMMON_ERROR_NOT_SUPPORTED = 1000 + 0
API or feature is not supported by implementation.
-
enumerator QNN_COMMON_ERROR_MEM_ALLOC = 1000 + 2
Memory allocation related error.
-
enumerator QNN_COMMON_ERROR_SYSTEM = 1000 + 3
System level error, such as related to platform / OS services.
-
enumerator QNN_COMMON_ERROR_INVALID_ARGUMENT = 1000 + 4
Invalid function argument.
-
enumerator QNN_COMMON_ERROR_OPERATION_NOT_PERMITTED = 1000 + 5
Illegal operation or sequence of operations.
-
enumerator QNN_COMMON_ERROR_PLATFORM_NOT_SUPPORTED = 1000 + 6
Attempt to use QNN API on an unsupported platform.
-
enumerator QNN_COMMON_ERROR_SYSTEM_COMMUNICATION = 1000 + 7
Communication errors with platform / OS service (service is recoverable)
-
enumerator QNN_COMMON_ERROR_INCOMPATIBLE_BINARIES = 1000 + 8
Loaded libraries are of incompatible versions.
-
enumerator QNN_COMMON_ERROR_LOADING_BINARIES = 1000 + 9
Attempt to reload library already loaded in this process.
-
enumerator QNN_COMMON_ERROR_RESOURCE_UNAVAILABLE = 1000 + 10
Resource allocation related error.
-
enumerator QNN_COMMON_ERROR_SYSTEM_COMMUNICATION_FATAL = 1000 + 11
Communication errors with platform / OS service (service is non-recoverable)
-
enumerator QNN_COMMON_ERROR_GENERAL = 1000 + 100
General error, which has not been identified as any other error type.
-
enumerator QNN_COMMON_MAX_ERROR = 1999
-
enumerator QNN_COMMON_ERROR_UNDEFINED = 0x7FFFFFFF
-
enumerator QNN_COMMON_MIN_ERROR = 1000
-
enum QnnProperty_Error_t
QNN Property API result / error codes.
Values:
-
enumerator QNN_PROPERTY_MIN_ERROR = 2000
-
enumerator QNN_PROPERTY_NO_ERROR = 0
-
enumerator QNN_PROPERTY_SUPPORTED = 0
Property in question is supported.
-
enumerator QNN_PROPERTY_NOT_SUPPORTED = QNN_COMMON_ERROR_NOT_SUPPORTED
Property in question not supported.
-
enumerator QNN_PROPERTY_ERROR_UNKNOWN_KEY = 2000 + 0
Backend did not recognize the property key.
-
enumerator QNN_PROPERTY_MAX_ERROR = 2999
-
enumerator QNN_PROPERTY_ERROR_UNDEFINED = 0x7FFFFFFF
-
enumerator QNN_PROPERTY_MIN_ERROR = 2000
-
enum QnnOpPackage_Error_t
QNN OpPackage API result / error codes.
Values:
-
enumerator QNN_OP_PACKAGE_MIN_ERROR = 3000
-
enumerator QNN_OP_PACKAGE_NO_ERROR = 0
-
enumerator QNN_OP_PACKAGE_ERROR_UNSUPPORTED_FEATURE = QNN_COMMON_ERROR_NOT_SUPPORTED
There is optional API component that is not supported yet. See QnnProperty.
-
enumerator QNN_OP_PACKAGE_ERROR_LIBRARY_ALREADY_INITIALIZED = 3000 + 0
Op package library was already initialized.
-
enumerator QNN_OP_PACKAGE_ERROR_LIBRARY_NOT_INITIALIZED = 3000 + 1
Attempt to call a function in an uninitialized op package library.
-
enumerator QNN_OP_PACKAGE_ERROR_INVALID_HANDLE = 3000 + 2
An invalid op package handle was provided.
-
enumerator QNN_OP_PACKAGE_ERROR_INVALID_INFRASTRUCTURE = 3000 + 100
Invalid infrastructure object used in initializing op package.
-
enumerator QNN_OP_PACKAGE_ERROR_INVALID_INFO = 3000 + 101
Invalid op package info object used in initializing op package.
-
enumerator QNN_OP_PACKAGE_ERROR_VALIDATION_FAILURE = 3000 + 110
Op configuration failed validation.
-
enumerator QNN_OP_PACKAGE_ERROR_INVALID_ARGUMENT = 3000 + 200
Invalid function argument.
-
enumerator QNN_OP_PACKAGE_ERROR_GENERAL = QNN_COMMON_ERROR_GENERAL
Indicates an error has occurred due to a condition unforeseen by QNN, and possibly meaningful only in the context of the particular op package. Unless otherwise noted, any op package function may return this error.
-
enumerator QNN_OP_PACKAGE_MAX_ERROR = 3999
-
enumerator QNN_OP_PACKAGE_ERROR_UNDEFINED = 0x7FFFFFFF
-
enumerator QNN_OP_PACKAGE_MIN_ERROR = 3000
-
enum QnnBackend_Error_t
QNN Backend API result / error codes.
Values:
-
enumerator QNN_BACKEND_MIN_ERROR = 4000
-
enumerator QNN_BACKEND_NO_ERROR = 0
Qnn Backend success.
-
enumerator QNN_BACKEND_ERROR_MEM_ALLOC = QNN_COMMON_ERROR_MEM_ALLOC
General error relating to memory allocation in Backend API.
-
enumerator QNN_BACKEND_ERROR_UNSUPPORTED_PLATFORM = QNN_COMMON_ERROR_PLATFORM_NOT_SUPPORTED
Backend attempted to be created on an unsupported platform.
-
enumerator QNN_BACKEND_ERROR_CANNOT_INITIALIZE = 4000 + 0
Backend failed to initialize.
-
enumerator QNN_BACKEND_ERROR_TERMINATE_FAILED = 4000 + 2
Failed to free allocated resources during termination.
-
enumerator QNN_BACKEND_ERROR_NOT_SUPPORTED = 4000 + 3
Backend does not support requested functionality.
-
enumerator QNN_BACKEND_ERROR_INVALID_ARGUMENT = 4000 + 4
Invalid function argument.
-
enumerator QNN_BACKEND_ERROR_OP_PACKAGE_NOT_FOUND = 4000 + 5
Could not find specified op package.
-
enumerator QNN_BACKEND_ERROR_OP_PACKAGE_IF_PROVIDER_NOT_FOUND = 4000 + 6
Could not load interface provider from op package library.
-
enumerator QNN_BACKEND_ERROR_OP_PACKAGE_REGISTRATION_FAILED = 4000 + 7
Failed to register op package.
-
enumerator QNN_BACKEND_ERROR_OP_PACKAGE_UNSUPPORTED_VERSION = 4000 + 8
Backend does not support the op config’s interface version.
-
enumerator QNN_BACKEND_ERROR_OP_PACKAGE_DUPLICATE = 4000 + 9
An Op with the same package name and op name was already registered.
-
enumerator QNN_BACKEND_ERROR_INCONSISTENT_CONFIG = 4000 + 10
Inconsistent backend configuration.
-
enumerator QNN_BACKEND_ERROR_INVALID_HANDLE = 4000 + 11
Invalid backend handle.
-
enumerator QNN_BACKEND_ERROR_INVALID_CONFIG = 4000 + 12
Invalid config.
-
enumerator QNN_BACKEND_MAX_ERROR = 4999
-
enumerator QNN_BACKEND_ERROR_UNDEFINED = 0x7FFFFFFF
-
enumerator QNN_BACKEND_MIN_ERROR = 4000
-
enum QnnContext_Error_t
QNN Context API result / error codes.
Values:
-
enumerator QNN_CONTEXT_MIN_ERROR = 5000
-
enumerator QNN_CONTEXT_NO_ERROR = 0
Qnn context success.
-
enumerator QNN_CONTEXT_ERROR_UNSUPPORTED_FEATURE = QNN_COMMON_ERROR_NOT_SUPPORTED
There is optional API component that is not supported yet. See QnnProperty.
-
enumerator QNN_CONTEXT_ERROR_MEM_ALLOC = QNN_COMMON_ERROR_MEM_ALLOC
Context-specific memory allocation/deallocation failure.
-
enumerator QNN_CONTEXT_ERROR_INVALID_ARGUMENT = 5000 + 0
An argument to QNN context API is deemed invalid by a backend.
-
enumerator QNN_CONTEXT_ERROR_CTX_DOES_NOT_EXIST = 5000 + 1
A QNN context has not yet been created in the backend.
-
enumerator QNN_CONTEXT_ERROR_INVALID_HANDLE = 5000 + 2
Invalid/NULL QNN context handle.
-
enumerator QNN_CONTEXT_ERROR_NOT_FINALIZED = 5000 + 3
Attempting an operation when graphs in a context haven’t been finalized.
-
enumerator QNN_CONTEXT_ERROR_BINARY_VERSION = 5000 + 4
Attempt to access context binary with an incompatible version.
-
enumerator QNN_CONTEXT_ERROR_CREATE_FROM_BINARY = 5000 + 5
Failure to create context from binary.
-
enumerator QNN_CONTEXT_ERROR_GET_BINARY_SIZE_FAILED = 5000 + 6
Failure to get size of a QNN serialized context.
-
enumerator QNN_CONTEXT_ERROR_GET_BINARY_FAILED = 5000 + 7
Failure to generate a QNN serialized context.
-
enumerator QNN_CONTEXT_ERROR_BINARY_CONFIGURATION = 5000 + 8
Invalid context binary configuration.
-
enumerator QNN_CONTEXT_ERROR_SET_PROFILE = 5000 + 9
Failure to set profile.
-
enumerator QNN_CONTEXT_ERROR_INVALID_CONFIG = 5000 + 10
Invalid config.
-
enumerator QNN_CONTEXT_ERROR_BINARY_SUBOPTIMAL = 5000 + 11
Attempt to create a context from suboptimal binary.
-
enumerator QNN_CONTEXT_ERROR_ABORTED = 5000 + 12
Call aborted early due to a QnnSignal_trigger call issued to the observed signal object.
-
enumerator QNN_CONTEXT_ERROR_TIMED_OUT = 5000 + 13
Call aborted early due to a QnnSignal timeout.
-
enumerator QNN_CONTEXT_ERROR_INCREMENT_INVALID_BUFFER = 5000 + 14
Incremental Binary Buffer was not allocated by backend.
-
enumerator QNN_CONTEXT_MAX_ERROR = 5999
-
enumerator QNN_CONTEXT_ERROR_UNDEFINED = 0x7FFFFFFF
-
enumerator QNN_CONTEXT_MIN_ERROR = 5000
-
enum QnnGraph_Error_t
QNN Graph API result / error codes.
Values:
-
enumerator QNN_GRAPH_MIN_ERROR = 6000
-
enumerator QNN_GRAPH_NO_ERROR = 0
Qnn Graph success.
-
enumerator QNN_GRAPH_ERROR_UNSUPPORTED_FEATURE = QNN_COMMON_ERROR_NOT_SUPPORTED
There is optional API component that is not supported yet. See QnnProperty.
-
enumerator QNN_GRAPH_ERROR_MEM_ALLOC = QNN_COMMON_ERROR_MEM_ALLOC
General error relating to memory allocation in processing graph API.
-
enumerator QNN_GRAPH_ERROR_GENERAL = QNN_COMMON_ERROR_GENERAL
General type of graph error, which has not been identified as any other error type. Any Graph API can return this error code.
-
enumerator QNN_GRAPH_ERROR_INVALID_ARGUMENT = 6000 + 0
An argument to QNN API is deemed invalid by a backend.
-
enumerator QNN_GRAPH_ERROR_INVALID_HANDLE = 6000 + 1
Invalid graph handle.
-
enumerator QNN_GRAPH_ERROR_GRAPH_DOES_NOT_EXIST = 6000 + 2
No graph with specified info is registered in the backend.
-
enumerator QNN_GRAPH_ERROR_INVALID_NAME = 6000 + 3
Invalid or duplicate graph name.
-
enumerator QNN_GRAPH_ERROR_INVALID_TENSOR = 6000 + 4
Invalid or NULL QNN tensor.
-
enumerator QNN_GRAPH_ERROR_INVALID_OP_CONFIG = 6000 + 5
Some elements in the op config data are invalid.
-
enumerator QNN_GRAPH_ERROR_SET_PROFILE = 6000 + 6
Failure to set profile.
-
enumerator QNN_GRAPH_ERROR_UNCONNECTED_NODE = 6000 + 7
Node added before its dependent node(s)
-
enumerator QNN_GRAPH_ERROR_CREATE_FAILED = 6000 + 20
Failure in creating graph with specified configuration.
-
enumerator QNN_GRAPH_ERROR_OPTIMIZATION_FAILED = 6000 + 21
Graph couldn’t be optimized with specified list of ops or config.
-
enumerator QNN_GRAPH_ERROR_FINALIZE_FAILED = 6000 + 22
Graph finalize failed.
-
enumerator QNN_GRAPH_ERROR_GRAPH_NOT_FINALIZED = 6000 + 23
Attempt to execute graph before finalizing it.
-
enumerator QNN_GRAPH_ERROR_GRAPH_FINALIZED = 6000 + 24
Attempt to modify graph after finalizing it.
-
enumerator QNN_GRAPH_ERROR_EXECUTION_ASYNC_FIFO_FULL = 6000 + 25
FIFO queue cannot register any more async execution requests.
-
enumerator QNN_GRAPH_ERROR_SIGNAL_IN_USE = 6000 + 30
A control signal object was provided to a call, but that signal object is already in-use by another call.
-
enumerator QNN_GRAPH_ERROR_ABORTED = 6000 + 31
Call aborted early due to a QnnSignal_trigger call issued to the observed signal object.
-
enumerator QNN_GRAPH_ERROR_PROFILE_IN_USE = 6000 + 32
Attempt to bind to a graph a profile handle that is already in-use by another graph.
-
enumerator QNN_GRAPH_ERROR_TIMED_OUT = 6000 + 33
Call aborted early due to a QnnSignal timeout.
-
enumerator QNN_GRAPH_ERROR_SUBGRAPH = 6000 + 34
Operation not permitted on a subgraph.
-
enumerator QNN_GRAPH_ERROR_DISABLED = 6000 + 35
Graph is not enabled.
-
enumerator QNN_GRAPH_ERROR_DYNAMIC_TENSOR_SHAPE = 6000 + 36
Dynamic tensor shape error.
-
enumerator QNN_GRAPH_ERROR_TENSOR_SPARSITY = 6000 + 37
Tensor sparsity error.
-
enumerator QNN_GRAPH_ERROR_EARLY_TERMINATION = 6000 + 38
Early termination error.
-
enumerator QNN_GRAPH_ERROR_INVALID_CONTEXT = 6000 + 39
Invalid context error.
-
enumerator QNN_GRAPH_MAX_ERROR = 6999
-
enumerator QNN_GRAPH_ERROR_UNDEFINED = 0x7FFFFFFF
-
enumerator QNN_GRAPH_MIN_ERROR = 6000
-
enum QnnTensor_Error_t
QNN Tensor API result / error codes.
Values:
-
enumerator QNN_TENSOR_MIN_ERROR = 7000
-
enumerator QNN_TENSOR_NO_ERROR = 0
Success.
-
enumerator QNN_TENSOR_ERROR_INVALID_HANDLE = 7000 + 1
Invalid context/graph handle in creating tensor.
-
enumerator QNN_TENSOR_ERROR_DOES_NOT_EXIST = 7000 + 2
Tensor with specified credentials not registered with a context/graph.
-
enumerator QNN_TENSOR_ERROR_ALREADY_EXISTS = 7000 + 3
(deprecated) Tensor has already been registered with backend.
-
enumerator QNN_TENSOR_ERROR_INVALID_TENSOR_PARAM = 7000 + 4
Invalid tensor param.
-
enumerator QNN_TENSOR_ERROR_UNSUPPORTED_TENSOR_PARAM = 7000 + 5
This tensor param is currently unsupported.
-
enumerator QNN_TENSOR_ERROR_NAME_HASH_COLLISION = 7000 + 6
(deprecated) A hash collision has occurred with a previously registered tensor’s name.
-
enumerator QNN_TENSOR_ERROR_INCOMPATIBLE_TENSOR_UPDATE = 7000 + 7
Tensor provided for update is invalid.
-
enumerator QNN_TENSOR_ERROR_UNSUPPORTED_FEATURE = QNN_COMMON_ERROR_NOT_SUPPORTED
There is optional API component that is not supported yet. See QnnProperty.
-
enumerator QNN_TENSOR_MAX_ERROR = 7999
-
enumerator QNN_TENSOR_ERROR_UNDEFINED = 0x7FFFFFFF
-
enumerator QNN_TENSOR_MIN_ERROR = 7000
-
enum QnnMem_Error_t
QNN Mem(ory) API result / error codes.
Values:
-
enumerator QNN_MEM_MIN_ERROR = 8000
-
enumerator QNN_MEM_NO_ERROR = 0
Qnn Memory success.
-
enumerator QNN_MEM_ERROR_NOT_SUPPORTED = QNN_COMMON_ERROR_NOT_SUPPORTED
Backend does not support requested functionality.
-
enumerator QNN_MEM_ERROR_INVALID_ARGUMENT = 8000 + 0
Invalid function argument.
-
enumerator QNN_MEM_ERROR_INVALID_HANDLE = 8000 + 1
Invalid memory handle.
-
enumerator QNN_MEM_ERROR_ALREADY_REGISTERED = 8000 + 2
Provided memory has already been registered.
-
enumerator QNN_MEM_ERROR_MAPPING = 8000 + 3
Error in memory mapping.
-
enumerator QNN_MEM_ERROR_INVALID_SHAPE = 8000 + 4
Invalid memory shape based on a backend’s memory restrictions (e.g. alignment incompatibility)
-
enumerator QNN_MEM_ERROR_UNSUPPORTED_MEMTYPE = 8000 + 5
Backend does not support requested memory type.
-
enumerator QNN_MEM_MAX_ERROR = 8999
-
enumerator QNN_MEM_ERROR_UNDEFINED = 0x7FFFFFFF
-
enumerator QNN_MEM_MIN_ERROR = 8000
-
enum QnnSignal_Error_t
QNN Signal API result / error codes.
Values:
-
enumerator QNN_SIGNAL_MIN_ERROR = 9000
-
enumerator QNN_SIGNAL_NO_ERROR = 0
-
enumerator QNN_SIGNAL_ERROR_UNSUPPORTED = QNN_COMMON_ERROR_NOT_SUPPORTED
Backend does not support the requested functionality.
-
enumerator QNN_SIGNAL_ERROR_SIGNAL_IN_USE = 9000 + 0
Attempt to reconfigure, free, or supply to a second QNN function call a signal object that is already in use.
-
enumerator QNN_SIGNAL_ERROR_SIGNAL_IDLE = 9000 + 1
Signal object is idle and not being used by an outstanding function call.
-
enumerator QNN_SIGNAL_ERROR_INVALID_ARGUMENT = 9000 + 2
Invalid configuration error.
-
enumerator QNN_SIGNAL_ERROR_INVALID_HANDLE = 9000 + 3
NULL or unrecognized signal handle error.
-
enumerator QNN_SIGNAL_ERROR_TIMEOUT = 9000 + 4
Timeout error.
-
enumerator QNN_SIGNAL_ERROR_INCOMPATIBLE_SIGNAL_TYPE = 9000 + 5
API supplied with incompatible signal type.
-
enumerator QNN_SIGNAL_ERROR_MEM_ALLOC = QNN_COMMON_ERROR_MEM_ALLOC
-
enumerator QNN_SIGNAL_MAX_ERROR = 9999
-
enumerator QNN_SIGNAL_ERROR_UNDEFINED = 0x7FFFFFFF
-
enumerator QNN_SIGNAL_MIN_ERROR = 9000
-
enum QnnLog_Error_t
QNN Log API result / error codes.
Values:
-
enumerator QNN_LOG_MIN_ERROR = 11000
-
enumerator QNN_LOG_NO_ERROR = 0
Qnn Log success.
-
enumerator QNN_LOG_ERROR_MEM_ALLOC = QNN_COMMON_ERROR_MEM_ALLOC
General error relating to memory allocation in Log API.
-
enumerator QNN_LOG_ERROR_INITIALIZATION = 11000 + 2
Unable to initialize logging.
-
enumerator QNN_LOG_ERROR_INVALID_ARGUMENT = 11000 + 3
Invalid argument passed.
-
enumerator QNN_LOG_ERROR_INVALID_HANDLE = 11000 + 4
Invalid log handle passed.
-
enumerator QNN_LOG_MAX_ERROR = 11999
-
enumerator QNN_LOG_ERROR_UNDEFINED = 0x7FFFFFFF
-
enumerator QNN_LOG_MIN_ERROR = 11000
-
enum QnnProfile_Error_t
QNN Profile API result / error codes.
Values:
-
enumerator QNN_PROFILE_MIN_ERROR = 12000
-
enumerator QNN_PROFILE_NO_ERROR = 0
Qnn Profile success.
-
enumerator QNN_PROFILE_ERROR_UNSUPPORTED = QNN_COMMON_ERROR_NOT_SUPPORTED
Backend does not support requested functionality.
-
enumerator QNN_PROFILE_ERROR_INVALID_ARGUMENT = QNN_COMMON_ERROR_INVALID_ARGUMENT
Invalid function argument.
-
enumerator QNN_PROFILE_ERROR_MEM_ALLOC = QNN_COMMON_ERROR_MEM_ALLOC
General error relating to memory allocation in Profile API.
-
enumerator QNN_PROFILE_ERROR_INVALID_HANDLE = 12000 + 0
Invalid/NULL QNN profile handle.
-
enumerator QNN_PROFILE_ERROR_HANDLE_IN_USE = 12000 + 1
Attempt to free or reconfigure a profile handle that is in-use.
-
enumerator QNN_PROFILE_ERROR_INCOMPATIBLE_EVENT = 12000 + 2
Event is incompatible with API.
-
enumerator QNN_PROFILE_MAX_ERROR = 12999
-
enumerator QNN_PROFILE_ERROR_UNDEFINED = 0x7FFFFFFF
-
enumerator QNN_PROFILE_MIN_ERROR = 12000
-
enum QnnSystemContext_Error_t
QNN System Context API result / error codes.
Values:
-
enumerator QNN_SYSTEM_CONTEXT_MINERROR = 30000
-
enumerator QNN_SYSTEM_CONTEXT_NO_ERROR = QNN_SYSTEM_COMMON_NO_ERROR
Qnn System Context success.
-
enumerator QNN_SYSTEM_CONTEXT_ERROR_UNSUPPORTED_FEATURE = QNN_SYSTEM_COMMON_ERROR_UNSUPPORTED_FEATURE
There is optional API component that is not supported yet.
-
enumerator QNN_SYSTEM_CONTEXT_ERROR_INVALID_HANDLE = QNN_SYSTEM_COMMON_ERROR_INVALID_HANDLE
QNN System Context invalid handle.
-
enumerator QNN_SYSTEM_CONTEXT_ERROR_INVALID_ARGUMENT = QNN_SYSTEM_COMMON_ERROR_INVALID_ARGUMENT
One or more arguments to a System Context API is/are NULL/invalid.
-
enumerator QNN_SYSTEM_CONTEXT_ERROR_OPERATION_FAILED = QNN_SYSTEM_CONTEXT_MINERROR + 2
Generic Failure in achieving the objective of a System Context API.
-
enumerator QNN_SYSTEM_CONTEXT_ERROR_MALFORMED_BINARY = QNN_SYSTEM_CONTEXT_MINERROR + 10
Malformed context binary.
-
enumerator QNN_SYSTEM_CONTEXT_MAXERROR = 49999
-
enumerator QNN_SYSTEM_CONTEXT_MINERROR = 30000
-
enum QnnInterface_Error_t
QNN Interface API result / error codes.
Values:
-
enumerator QNN_INTERFACE_MIN_ERROR = 60000
-
enumerator QNN_INTERFACE_NO_ERROR = 0
-
enumerator QNN_INTERFACE_ERROR_NOT_SUPPORTED = QNN_COMMON_ERROR_NOT_SUPPORTED
-
enumerator QNN_INTERFACE_ERROR_INVALID_PARAMETER = QNN_COMMON_ERROR_INVALID_ARGUMENT
-
enumerator QNN_INTERFACE_MAX_ERROR = 60999
-
enumerator QNN_INTERFACE_MIN_ERROR = 60000