Intel(R) Threading Building Blocks Doxygen Documentation  version 4.2.3
runtime_loader.h
Go to the documentation of this file.
1 /*
2  Copyright (c) 2005-2019 Intel Corporation
3 
4  Licensed under the Apache License, Version 2.0 (the "License");
5  you may not use this file except in compliance with the License.
6  You may obtain a copy of the License at
7 
8  http://www.apache.org/licenses/LICENSE-2.0
9 
10  Unless required by applicable law or agreed to in writing, software
11  distributed under the License is distributed on an "AS IS" BASIS,
12  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  See the License for the specific language governing permissions and
14  limitations under the License.
15 */
16 
18 
19 #if !defined(__TBB_show_deprecation_message_runtime_loader_H) && defined(__TBB_show_deprecated_header_message)
20 #define __TBB_show_deprecation_message_runtime_loader_H
21 #pragma message("TBB Warning: tbb/runtime_loader.h is deprecated. For details, please see Deprecated Features appendix in the TBB reference manual.")
22 #endif
23 
24 #if defined(__TBB_show_deprecated_header_message)
25 #undef __TBB_show_deprecated_header_message
26 #endif
27 
28 #ifndef __TBB_runtime_loader_H
29 #define __TBB_runtime_loader_H
30 
31 #define __TBB_runtime_loader_H_include_area
33 
34 #if ! TBB_PREVIEW_RUNTIME_LOADER
35  #error Set TBB_PREVIEW_RUNTIME_LOADER to include runtime_loader.h
36 #endif
37 
38 #include "tbb_stddef.h"
39 #include <climits>
40 
41 #if _MSC_VER
42  #if ! __TBB_NO_IMPLICIT_LINKAGE
43  #ifdef _DEBUG
44  #pragma comment( linker, "/nodefaultlib:tbb_debug.lib" )
45  #pragma comment( linker, "/defaultlib:tbbproxy_debug.lib" )
46  #else
47  #pragma comment( linker, "/nodefaultlib:tbb.lib" )
48  #pragma comment( linker, "/defaultlib:tbbproxy.lib" )
49  #endif
50  #endif
51 #endif
52 
53 namespace tbb {
54 
55 namespace interface6 {
56 
58 
96 
97  public:
98 
100  enum error_mode {
103  em_abort
104  }; // error_mode
105 
107  enum error_code {
113  ec_no_lib
114  }; // error_code
115 
117  runtime_loader( error_mode mode = em_abort );
118 
120 
126  char const * path[],
127  int min_ver = TBB_INTERFACE_VERSION,
128  int max_ver = INT_MAX,
129  error_mode mode = em_abort
130  );
131 
133  ~runtime_loader();
134 
136 
160  error_code
161  load(
162  char const * path[],
163  int min_ver = TBB_INTERFACE_VERSION,
164  int max_ver = INT_MAX
165 
166  );
167 
168 
170 
173  error_code status();
174 
175  private:
176 
179  bool my_loaded;
180 
181 }; // class runtime_loader
182 
183 } // namespace interface6
184 
186 
187 } // namespace tbb
188 
190 #undef __TBB_runtime_loader_H_include_area
191 
192 #endif /* __TBB_runtime_loader_H */
193 
_deprecated_header_message_guard.h
tbb::interface6::runtime_loader::ec_bad_ver
TBB found but version is not suitable.
Definition: runtime_loader.h:112
tbb::interface6::runtime_loader::em_throw
Throw an exception of tbb::runtime_loader::error_code type.
Definition: runtime_loader.h:102
tbb::interface6::runtime_loader::ec_ok
No errors.
Definition: runtime_loader.h:108
tbb::interface6::runtime_loader::error_code
error_code
Error codes.
Definition: runtime_loader.h:107
tbb
The graph class.
Definition: serial/tbb/parallel_for.h:46
TBB_INTERFACE_VERSION
#define TBB_INTERFACE_VERSION
Definition: tbb_stddef.h:25
tbb::interface6::runtime_loader::ec_bad_call
Invalid function call (e. g. load() called when TBB is already loaded).
Definition: runtime_loader.h:109
tbb::interface6::runtime_loader::my_mode
const error_mode my_mode
Definition: runtime_loader.h:177
tbb::interface6::runtime_loader::ec_bad_arg
Invalid argument passed.
Definition: runtime_loader.h:110
mode
void const char const char int ITT_FORMAT __itt_group_sync x void const char ITT_FORMAT __itt_group_sync s void ITT_FORMAT __itt_group_sync p void ITT_FORMAT p void ITT_FORMAT p no args __itt_suppress_mode_t mode
Definition: ittnotify_static.h:94
_warning_suppress_disable_notice.h
tbb::load
struct __TBB_DEPRECATED_VERBOSE_MSG("tbb::atomic is deprecated, use std::atomic") atomic< T * > struct __TBB_DEPRECATED_VERBOSE_MSG("tbb::atomic is deprecated, use std::atomic") atomic< void * > T load(const atomic< T > &a)
Specialization for atomic<T*> with arithmetic and operator->.
Definition: atomic.h:546
tbb::interface6::runtime_loader
Load TBB at runtime.
Definition: runtime_loader.h:95
__TBB_DEPRECATED_VERBOSE
#define __TBB_DEPRECATED_VERBOSE
Definition: tbb_config.h:648
tbb::interface6::runtime_loader::ec_bad_lib
Invalid library found (e. g. TBB_runtime_version symbol not found).
Definition: runtime_loader.h:111
tbb::interface6::runtime_loader::error_mode
error_mode
Error mode constants.
Definition: runtime_loader.h:100
tbb::interface6::runtime_loader::em_status
Save status of operation and continue.
Definition: runtime_loader.h:101
tbb::interface6::runtime_loader::my_status
error_code my_status
Definition: runtime_loader.h:178
tbb_stddef.h
_warning_suppress_enable_notice.h
tbb::interface6::runtime_loader::my_loaded
bool my_loaded
Definition: runtime_loader.h:179
tbb::internal::no_copy
Base class for types that should not be copied or assigned.
Definition: tbb_stddef.h:330

Copyright © 2005-2019 Intel Corporation. All Rights Reserved.

Intel, Pentium, Intel Xeon, Itanium, Intel XScale and VTune are registered trademarks or trademarks of Intel Corporation or its subsidiaries in the United States and other countries.

* Other names and brands may be claimed as the property of others.