ArmNN  NotReleased
RefDynamicBackend.hpp File Reference
#include <cstdint>

Go to the source code of this file.

Functions

const char * GetBackendId ()
 
void GetVersion (uint32_t *outMajor, uint32_t *outMinor)
 
void * BackendFactory ()
 

Function Documentation

◆ BackendFactory()

void* BackendFactory ( )

Definition at line 128 of file TestDynamicBackend.cpp.

129 {
130 #if defined(INVALID_TEST_DYNAMIC_BACKEND_6)
131 
132  // Return an invalid backend instance
133  return nullptr;
134 
135 #else
136 
137  // Return a non-null backend instance
138  return new TestDynamicBackend();
139 
140 #endif
141 }

◆ GetBackendId()

const char* GetBackendId ( )

Definition at line 80 of file TestDynamicBackend.cpp.

81 {
82 #if defined(INVALID_TEST_DYNAMIC_BACKEND_5) || \
83  defined(INVALID_TEST_DYNAMIC_BACKEND_8)
84 
85  // Return an invalid backend id
86  return nullptr;
87 
88 #else
89 
90  // Return a valid backend id
91  return TestDynamicBackendId();
92 
93 #endif
94 }
constexpr const char * TestDynamicBackendId()

◆ GetVersion()

void GetVersion ( uint32_t *  outMajor,
uint32_t *  outMinor 
)

Definition at line 96 of file TestDynamicBackend.cpp.

97 {
98  if (!outMajor || !outMinor)
99  {
100  return;
101  }
102 
103 #if defined(INVALID_TEST_DYNAMIC_BACKEND_7) || \
104  defined(INVALID_TEST_DYNAMIC_BACKEND_8)
105 
106  *outMajor = 0;
107  *outMinor = 7;
108 
109 #else
110 
112 
113  *outMajor = apiVersion.m_Major;
114 
115 #if defined(INVALID_TEST_DYNAMIC_BACKEND_9)
116 
117  *outMinor = apiVersion.m_Minor + 1;
118 
119 #else
120 
121  *outMinor = apiVersion.m_Minor;
122 
123 #endif
124 
125 #endif
126 }
static constexpr BackendVersion GetApiVersion()
Returns the version of the Backend API.