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