diff options
Diffstat (limited to 'src/backends/RegistryCommon.hpp')
-rw-r--r-- | src/backends/RegistryCommon.hpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/backends/RegistryCommon.hpp b/src/backends/RegistryCommon.hpp index 27663b6dea..616a63bd53 100644 --- a/src/backends/RegistryCommon.hpp +++ b/src/backends/RegistryCommon.hpp @@ -8,6 +8,8 @@ #include <armnn/Exceptions.hpp> #include <functional> #include <memory> +#include <sstream> +#include <string> #include <unordered_map> namespace armnn @@ -65,6 +67,23 @@ public: return result; } + std::string GetBackendIdsAsString() const + { + static const std::string delimitator = ", "; + + std::stringstream output; + for (auto& backendId : GetBackendIds()) + { + if (output.tellp() != std::streampos(0)) + { + output << delimitator; + } + output << backendId; + } + + return output.str(); + } + RegistryCommon() {} virtual ~RegistryCommon() {} |