ArmNN
 22.08
Utils.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/TypesUtils.hpp>
8 
9 #include <iostream>
10 
11 namespace armnn
12 {
13 
14 enum class LogSeverity
15 {
16  Trace,
17  Debug,
18  Info,
19  Warning,
20  Error,
21  Fatal
22 };
23 
24 /// Configures the logging behaviour of the ARMNN library.
25 /// printToStandardOutput: Set to true if log messages should be printed to the standard output.
26 /// printToDebugOutput: Set to true if log messages be printed to a platform-specific debug output
27 /// (where supported).
28 /// severity: All log messages that are at this severity level or higher will be printed, others will be ignored.
29 void ConfigureLogging(bool printToStandardOutput, bool printToDebugOutput, LogSeverity severity);
30 
31 
32 #if defined(__clang__) &&((__clang_major__>=3)||(__clang_major__==3 && __clang_minor__ >= 5))
33 # define ARMNN_FALLTHROUGH [[clang::fallthrough]]
34 #elif defined(__GNUC__) && (__GNUC__ >= 7)
35 # define ARMNN_FALLTHROUGH __attribute__((fallthrough))
36 #else
37 # define ARMNN_FALLTHROUGH ((void)0)
38 #endif
39 
40 bool NeonDetected();
41 
42 const std::string GetVersion();
43 
44 } // namespace armnn
void ConfigureLogging(bool printToStandardOutput, bool printToDebugOutput, LogSeverity severity)
Configures the logging behaviour of the ARMNN library.
Definition: Utils.cpp:18
Copyright (c) 2021 ARM Limited and Contributors.
const std::string GetVersion()
Definition: Utils.cpp:77
bool NeonDetected()
Definition: Utils.cpp:37
LogSeverity
Definition: Utils.hpp:14