![]() |
1.4 (revision 3771)
|
00001 /* 00002 * This file is part of the Score-P software (http://www.score-p.org) 00003 * 00004 * Copyright (c) 2009-2013, 00005 * RWTH Aachen University, Germany 00006 * 00007 * Copyright (c) 2009-2013, 00008 * Gesellschaft fuer numerische Simulation mbH Braunschweig, Germany 00009 * 00010 * Copyright (c) 2009-2014, 00011 * Technische Universitaet Dresden, Germany 00012 * 00013 * Copyright (c) 2009-2013, 00014 * University of Oregon, Eugene, USA 00015 * 00016 * Copyright (c) 2009-2013, 00017 * Forschungszentrum Juelich GmbH, Germany 00018 * 00019 * Copyright (c) 2009-2013, 00020 * German Research School for Simulation Sciences GmbH, Juelich/Aachen, Germany 00021 * 00022 * Copyright (c) 2009-2013, 00023 * Technische Universitaet Muenchen, Germany 00024 * 00025 * This software may be modified and distributed under the terms of 00026 * a BSD-style license. See the COPYING file in the package base 00027 * directory for details. 00028 * 00029 */ 00030 00031 00032 #ifndef OTF2_GENERAL_DEFINITIONS_H 00033 #define OTF2_GENERAL_DEFINITIONS_H 00034 00035 00045 #include <stdint.h> 00046 00047 00048 #include <otf2/OTF2_ErrorCodes.h> 00049 00050 00051 #ifdef __cplusplus 00052 extern "C" { 00053 #endif /* __cplusplus */ 00054 00055 00056 /* ___ OTF2 library version information _____________________________________ */ 00057 00058 00062 #define OTF2_VERSION_MAJOR 1 00063 00064 #define OTF2_VERSION_MINOR 4 00065 00066 #define OTF2_VERSION_BUGFIX 0 00067 00068 #define OTF2_VERSION_SUFFIX "" 00069 00070 #define OTF2_VERSION "1.4" 00071 00074 /* ___ Symbols for undefined values _________________________________________ */ 00075 00076 00080 #define OTF2_UNDEFINED_UINT8 ( ( uint8_t )( ~( ( uint8_t )0u ) ) ) 00081 00082 #define OTF2_UNDEFINED_UINT16 ( ( uint16_t )( ~( ( uint16_t )0u ) ) ) 00083 00084 #define OTF2_UNDEFINED_UINT32 ( ( uint32_t )( ~( ( uint32_t )0u ) ) ) 00085 00086 #define OTF2_UNDEFINED_UINT64 ( ( uint64_t )( ~( ( uint64_t )0u ) ) ) 00087 00091 #define OTF2_UNDEFINED_TYPE OTF2_UNDEFINED_UINT8 00092 00093 00095 typedef uint64_t OTF2_TimeStamp; 00097 #define OTF2_UNDEFINED_TIMESTAMP OTF2_UNDEFINED_UINT64 00098 00099 00101 typedef uint32_t OTF2_StringRef; 00103 #define OTF2_UNDEFINED_STRING ( ( OTF2_StringRef )OTF2_UNDEFINED_UINT32 ) 00104 00105 00107 typedef uint32_t OTF2_AttributeRef; 00109 #define OTF2_UNDEFINED_ATTRIBUTE ( ( OTF2_AttributeRef )OTF2_UNDEFINED_UINT32 ) 00110 00111 00113 typedef uint32_t OTF2_SystemTreeNodeRef; 00115 #define OTF2_UNDEFINED_SYSTEM_TREE_NODE ( ( OTF2_SystemTreeNodeRef )OTF2_UNDEFINED_UINT32 ) 00116 00117 00119 typedef uint32_t OTF2_LocationGroupRef; 00121 #define OTF2_UNDEFINED_LOCATION_GROUP ( ( OTF2_LocationGroupRef )OTF2_UNDEFINED_UINT32 ) 00122 00123 00125 typedef uint64_t OTF2_LocationRef; 00127 #define OTF2_UNDEFINED_LOCATION ( ( OTF2_LocationRef )OTF2_UNDEFINED_UINT64 ) 00128 00129 00131 typedef uint32_t OTF2_RegionRef; 00133 #define OTF2_UNDEFINED_REGION ( ( OTF2_RegionRef )OTF2_UNDEFINED_UINT32 ) 00134 00135 00137 typedef uint32_t OTF2_CallsiteRef; 00139 #define OTF2_UNDEFINED_CALLSITE ( ( OTF2_CallsiteRef )OTF2_UNDEFINED_UINT32 ) 00140 00141 00143 typedef uint32_t OTF2_CallpathRef; 00145 #define OTF2_UNDEFINED_CALLPATH ( ( OTF2_CallpathRef )OTF2_UNDEFINED_UINT32 ) 00146 00147 00149 typedef uint32_t OTF2_GroupRef; 00151 #define OTF2_UNDEFINED_GROUP ( ( OTF2_GroupRef )OTF2_UNDEFINED_UINT32 ) 00152 00153 00155 typedef uint32_t OTF2_MetricMemberRef; 00157 #define OTF2_UNDEFINED_METRIC_MEMBER ( ( OTF2_MetricMemberRef )OTF2_UNDEFINED_UINT32 ) 00158 00159 00161 typedef uint32_t OTF2_MetricRef; 00163 #define OTF2_UNDEFINED_METRIC ( ( OTF2_MetricRef )OTF2_UNDEFINED_UINT32 ) 00164 00165 00167 typedef uint32_t OTF2_CommRef; 00169 #define OTF2_UNDEFINED_COMM ( ( OTF2_CommRef )OTF2_UNDEFINED_UINT32 ) 00170 00171 00173 typedef uint32_t OTF2_ParameterRef; 00175 #define OTF2_UNDEFINED_PARAMETER ( ( OTF2_ParameterRef )OTF2_UNDEFINED_UINT32 ) 00176 00177 00179 typedef uint32_t OTF2_RmaWinRef; 00181 #define OTF2_UNDEFINED_RMA_WIN ( ( OTF2_RmaWinRef )OTF2_UNDEFINED_UINT32 ) 00182 00183 00185 typedef uint32_t OTF2_CartDimensionRef; 00187 #define OTF2_UNDEFINED_CART_DIMENSION ( ( OTF2_CartDimensionRef )OTF2_UNDEFINED_UINT32 ) 00188 00189 00191 typedef uint32_t OTF2_CartTopologyRef; 00193 #define OTF2_UNDEFINED_CART_TOPOLOGY ( ( OTF2_CartTopologyRef )OTF2_UNDEFINED_UINT32 ) 00194 00195 00196 /* ___ Declarations of opaque OTF2 objects __________________________________ */ 00197 00198 00200 typedef struct OTF2_EvtReader_struct OTF2_EvtReader; 00201 00202 00204 typedef struct OTF2_GlobalEvtReader_struct OTF2_GlobalEvtReader; 00205 00206 00208 typedef struct OTF2_DefReader_struct OTF2_DefReader; 00209 00210 00212 typedef struct OTF2_GlobalDefReader_struct OTF2_GlobalDefReader; 00213 00214 00216 typedef struct OTF2_SnapReader_struct OTF2_SnapReader; 00217 00218 00220 typedef struct OTF2_GlobalSnapReader_struct OTF2_GlobalSnapReader; 00221 00222 00224 typedef struct OTF2_MarkerReader_struct OTF2_MarkerReader; 00225 00226 00227 /* ___ Definitions related to the file interaction __________________________ */ 00228 00229 00231 #define OTF2_CHUNK_SIZE_MIN ( uint64_t )( 256 * 1024 ) 00232 00233 00235 #define OTF2_CHUNK_SIZE_MAX ( uint64_t )( 1024 * 1024 * 16 ) 00236 00237 00240 typedef uint8_t OTF2_FileMode; 00241 00242 00244 enum OTF2_FileMode_enum 00245 { 00247 OTF2_FILEMODE_WRITE = 0, 00249 OTF2_FILEMODE_READ = 1, 00251 OTF2_FILEMODE_MODIFY = 2 00252 }; 00253 00254 00257 typedef uint8_t OTF2_Compression; 00258 00259 00261 enum OTF2_Compression_enum 00262 { 00264 OTF2_COMPRESSION_UNDEFINED = 0, 00266 OTF2_COMPRESSION_NONE = 1, 00268 OTF2_COMPRESSION_ZLIB = 2 00269 }; 00270 00271 00299 typedef enum OTF2_CallbackCode_enum 00300 { 00302 OTF2_CALLBACK_SUCCESS = 0, 00303 00310 OTF2_CALLBACK_INTERRUPT = !OTF2_CALLBACK_SUCCESS, 00311 00313 OTF2_CALLBACK_ERROR = !OTF2_CALLBACK_SUCCESS 00314 } OTF2_CallbackCode; 00315 00316 00317 /* ___ Definitions related to the memory buffer ______________________________ */ 00318 00319 00322 typedef uint8_t OTF2_FlushType; 00323 00324 00326 enum OTF2_FlushType_enum 00327 { 00329 OTF2_NO_FLUSH = 0, 00331 OTF2_FLUSH = 1 00332 }; 00333 00334 00336 typedef uint8_t OTF2_FileType; 00337 00343 enum OTF2_FileType_enum 00344 { 00347 OTF2_FILETYPE_ANCHOR = 0, 00350 OTF2_FILETYPE_GLOBAL_DEFS = 1, 00353 OTF2_FILETYPE_LOCAL_DEFS = 2, 00356 OTF2_FILETYPE_EVENTS = 3, 00359 OTF2_FILETYPE_SNAPSHOTS = 4, 00362 OTF2_FILETYPE_THUMBNAIL = 5, 00365 OTF2_FILETYPE_MARKER = 6, 00368 OTF2_FILETYPE_SIONRANKMAP = 7 00369 }; 00370 00371 00373 typedef uint8_t OTF2_FileSubstrate; 00374 00380 enum OTF2_FileSubstrate_enum 00381 { 00384 OTF2_SUBSTRATE_UNDEFINED = 0, 00387 OTF2_SUBSTRATE_POSIX = 1, 00391 OTF2_SUBSTRATE_SION = 2, 00394 OTF2_SUBSTRATE_NONE = 3 00395 }; 00396 00397 00399 typedef uint8_t OTF2_MappingType; 00400 00406 enum OTF2_MappingType_enum 00407 { 00410 OTF2_MAPPING_STRING = 0, 00413 OTF2_MAPPING_ATTRIBUTE = 1, 00416 OTF2_MAPPING_LOCATION = 2, 00419 OTF2_MAPPING_REGION = 3, 00422 OTF2_MAPPING_GROUP = 4, 00425 OTF2_MAPPING_METRIC = 5, 00428 OTF2_MAPPING_COMM = 6, 00431 OTF2_MAPPING_PARAMETER = 7, 00434 OTF2_MAPPING_RMA_WIN = 8, 00435 00438 OTF2_MAPPING_MAX = 9 00439 }; 00440 00441 00443 typedef uint8_t OTF2_Type; 00444 00450 enum OTF2_Type_enum 00451 { 00456 OTF2_TYPE_NONE = 0, 00461 OTF2_TYPE_UINT8 = 1, 00466 OTF2_TYPE_UINT16 = 2, 00471 OTF2_TYPE_UINT32 = 3, 00476 OTF2_TYPE_UINT64 = 4, 00481 OTF2_TYPE_INT8 = 5, 00486 OTF2_TYPE_INT16 = 6, 00491 OTF2_TYPE_INT32 = 7, 00496 OTF2_TYPE_INT64 = 8, 00501 OTF2_TYPE_FLOAT = 9, 00506 OTF2_TYPE_DOUBLE = 10, 00511 OTF2_TYPE_STRING = 11, 00516 OTF2_TYPE_ATTRIBUTE = 12, 00521 OTF2_TYPE_LOCATION = 13, 00526 OTF2_TYPE_REGION = 14, 00531 OTF2_TYPE_GROUP = 15, 00536 OTF2_TYPE_METRIC = 16, 00541 OTF2_TYPE_COMM = 17, 00546 OTF2_TYPE_PARAMETER = 18, 00551 OTF2_TYPE_RMA_WIN = 19 00552 }; 00553 00554 00556 typedef uint8_t OTF2_Paradigm; 00557 00563 enum OTF2_Paradigm_enum 00564 { 00567 OTF2_PARADIGM_UNKNOWN = 0, 00570 OTF2_PARADIGM_USER = 1, 00573 OTF2_PARADIGM_COMPILER = 2, 00576 OTF2_PARADIGM_OPENMP = 3, 00579 OTF2_PARADIGM_MPI = 4, 00582 OTF2_PARADIGM_CUDA = 5, 00585 OTF2_PARADIGM_MEASUREMENT_SYSTEM = 6, 00588 OTF2_PARADIGM_PTHREAD = 7, 00591 OTF2_PARADIGM_HMPP = 8, 00594 OTF2_PARADIGM_OMPSS = 9, 00597 OTF2_PARADIGM_HARDWARE = 10, 00600 OTF2_PARADIGM_GASPI = 11, 00603 OTF2_PARADIGM_UPC = 12, 00606 OTF2_PARADIGM_SHMEM = 13 00607 }; 00608 00609 00611 typedef uint8_t OTF2_ThumbnailType; 00612 00618 enum OTF2_ThumbnailType_enum 00619 { 00622 OTF2_THUMBNAIL_TYPE_REGION = 0, 00625 OTF2_THUMBNAIL_TYPE_METRIC = 1, 00628 OTF2_THUMBNAIL_TYPE_ATTRIBUTES = 2 00629 }; 00630 00631 00632 #ifdef __cplusplus 00633 } 00634 #endif /* __cplusplus */ 00635 00636 00637 #endif /* !OTF2_GENERAL_DEFINITIONS_H */