From 6940dd720ebb6b3d1df8ca203ab696daefe58189 Mon Sep 17 00:00:00 2001 From: Jim Flynn Date: Fri, 20 Mar 2020 12:25:56 +0000 Subject: renamed Documentation folder 20.02 and added .nojekyll file Signed-off-by: Jim Flynn --- 20.02/_device_spec_8hpp_source.xhtml | 125 +++++++++++++++++++++++++++++++++++ 1 file changed, 125 insertions(+) create mode 100644 20.02/_device_spec_8hpp_source.xhtml (limited to '20.02/_device_spec_8hpp_source.xhtml') diff --git a/20.02/_device_spec_8hpp_source.xhtml b/20.02/_device_spec_8hpp_source.xhtml new file mode 100644 index 0000000000..2753144591 --- /dev/null +++ b/20.02/_device_spec_8hpp_source.xhtml @@ -0,0 +1,125 @@ + + + + + + + + + + + + + +ArmNN: src/armnn/DeviceSpec.hpp Source File + + + + + + + + + + + + + + + + +
+
+ + + + ArmNN + + + +
+
+  20.02 +
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+ +
+ +
+
+
DeviceSpec.hpp
+
+
+Go to the documentation of this file.
1 //
2 // Copyright © 2017 Arm Ltd. All rights reserved.
3 // SPDX-License-Identifier: MIT
4 //
5 #pragma once
6 
7 #include <armnn/Types.hpp>
8 #include <set>
9 #include <vector>
10 
11 namespace armnn
12 {
13 
14 class DeviceSpec : public IDeviceSpec
15 {
16 public:
18  {}
19 
20  DeviceSpec(const BackendIdSet& supportedBackends)
21  : m_SupportedBackends{supportedBackends} {}
22 
23  virtual ~DeviceSpec() {}
24 
25  virtual const BackendIdSet& GetSupportedBackends() const override
26  {
27  return m_SupportedBackends;
28  }
29 
30  void AddSupportedBackends(const BackendIdSet& backendIds, bool isDynamic = false)
31  {
32  m_SupportedBackends.insert(backendIds.begin(), backendIds.end());
33  if (isDynamic)
34  {
35  m_DynamicBackends.insert(backendIds.begin(), backendIds.end());
36  }
37  }
38 
40  {
41  for (const auto& id : m_DynamicBackends)
42  {
43  m_SupportedBackends.erase(id);
44  }
45  m_DynamicBackends.clear();
46  }
47 
49  {
50  return m_DynamicBackends;
51  }
52 
53 private:
54  BackendIdSet m_SupportedBackends;
55  BackendIdSet m_DynamicBackends;
56 };
57 
58 } // namespace armnn
void AddSupportedBackends(const BackendIdSet &backendIds, bool isDynamic=false)
Definition: DeviceSpec.hpp:30
+
std::unordered_set< BackendId > BackendIdSet
Definition: BackendId.hpp:191
+ +
Copyright (c) 2020 ARM Limited.
+ +
Device specific knowledge to be passed to the optimizer.
Definition: Types.hpp:161
+
virtual ~DeviceSpec()
Definition: DeviceSpec.hpp:23
+
DeviceSpec(const BackendIdSet &supportedBackends)
Definition: DeviceSpec.hpp:20
+
virtual const BackendIdSet & GetSupportedBackends() const override
Definition: DeviceSpec.hpp:25
+
const BackendIdSet & GetDynamicBackends() const
Definition: DeviceSpec.hpp:48
+ +
void ClearDynamicBackends()
Definition: DeviceSpec.hpp:39
+
+
+ + + + -- cgit v1.2.1