├── .idea
├── llvm-analysis-and-transform-passes.iml
├── misc.xml
├── modules.xml
├── vcs.xml
└── workspace.xml
├── CMakeLists.txt
├── DynCount
├── .DS_Store
├── CMakeCache.txt
├── CMakeFiles
│ ├── .DS_Store
│ ├── 3.6.2
│ │ ├── .DS_Store
│ │ ├── CMakeCCompiler.cmake
│ │ ├── CMakeCXXCompiler.cmake
│ │ ├── CMakeDetermineCompilerABI_C.bin
│ │ ├── CMakeDetermineCompilerABI_CXX.bin
│ │ ├── CMakeSystem.cmake
│ │ ├── CompilerIdC
│ │ │ ├── CMakeCCompilerId.c
│ │ │ └── a.out
│ │ └── CompilerIdCXX
│ │ │ ├── CMakeCXXCompilerId.cpp
│ │ │ └── a.out
│ ├── CMakeOutput.log
│ ├── cmake.check_cache
│ ├── feature_tests.bin
│ ├── feature_tests.c
│ └── feature_tests.cxx
├── CMakeLists.txt
├── DynCount.cpp
└── DynCount.exports
├── HeapTimeTestProgram
├── .DS_Store
├── .idea
│ ├── heaptime.iml
│ ├── misc.xml
│ ├── modules.xml
│ └── workspace.xml
├── CMakeLists.txt
└── main.cpp
├── README.md
├── SmallTestProgram
├── .DS_Store
├── print.c
└── smallProgram.c
├── StaticCount
├── .DS_Store
├── CMakeCache.txt
├── CMakeFiles
│ ├── .DS_Store
│ ├── 3.6.2
│ │ ├── .DS_Store
│ │ ├── CMakeCCompiler.cmake
│ │ ├── CMakeCXXCompiler.cmake
│ │ ├── CMakeDetermineCompilerABI_C.bin
│ │ ├── CMakeDetermineCompilerABI_CXX.bin
│ │ ├── CMakeSystem.cmake
│ │ ├── CompilerIdC
│ │ │ ├── CMakeCCompilerId.c
│ │ │ └── a.out
│ │ └── CompilerIdCXX
│ │ │ ├── CMakeCXXCompilerId.cpp
│ │ │ └── a.out
│ ├── CMakeOutput.log
│ ├── cmake.check_cache
│ ├── feature_tests.bin
│ ├── feature_tests.c
│ └── feature_tests.cxx
├── CMakeLists.txt
├── StaticCount.cpp
└── StaticCount.exports
├── heaptime
├── .DS_Store
├── .idea
│ ├── heaptime.iml
│ ├── misc.xml
│ ├── modules.xml
│ └── workspace.xml
├── CMakeLists.txt
└── main.cpp
├── images
├── milestone1.jpg
├── milestone2.jpg
└── milestone2_2.jpg
└── smalltest
├── .DS_Store
├── instrumentedprogram.bc
├── p.bc
├── print.c
├── smallProgram.c
├── smallprogramandprint.bc
└── sp.bc
/.idea/misc.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/.idea/modules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/.idea/vcs.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.6)
2 | project(llvm_analysis_and_transform_passes)
3 |
4 | set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
5 |
6 | set(SOURCE_FILES
7 | DynCount/CMakeFiles/3.6.2/CompilerIdC/CMakeCCompilerId.c
8 | DynCount/CMakeFiles/3.6.2/CompilerIdCXX/CMakeCXXCompilerId.cpp
9 | DynCount/CMakeFiles/feature_tests.c
10 | DynCount/CMakeFiles/feature_tests.cxx
11 | DynCount/DynCount.cpp
12 | heaptime/main.cpp
13 | HeapTimeTestProgram/main.cpp
14 | smalltest/print.c
15 | smalltest/smallProgram.c
16 | SmallTestProgram/print.c
17 | SmallTestProgram/smallProgram.c
18 | StaticCount/CMakeFiles/3.6.2/CompilerIdC/CMakeCCompilerId.c
19 | StaticCount/CMakeFiles/3.6.2/CompilerIdCXX/CMakeCXXCompilerId.cpp
20 | StaticCount/CMakeFiles/feature_tests.c
21 | StaticCount/CMakeFiles/feature_tests.cxx
22 | StaticCount/StaticCount.cpp)
23 |
24 | add_executable(llvm_analysis_and_transform_passes ${SOURCE_FILES})
--------------------------------------------------------------------------------
/DynCount/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/DynCount/.DS_Store
--------------------------------------------------------------------------------
/DynCount/CMakeCache.txt:
--------------------------------------------------------------------------------
1 | # This is the CMakeCache file.
2 | # For build in directory: /Users/henryboswell/developer/llvm/llvm/lib/Transforms/DynCount
3 | # It was generated by CMake: /Applications/CMake.app/Contents/bin/cmake
4 | # You can edit this file to change values found and used by cmake.
5 | # If you do not want to change any of the values, simply exit the editor.
6 | # If you do want to change a value, simply edit, save, and exit the editor.
7 | # The syntax for the file is as follows:
8 | # KEY:TYPE=VALUE
9 | # KEY is the name of a variable in the cache.
10 | # TYPE is a hint to GUIs for the type of VALUE, DO NOT EDIT TYPE!.
11 | # VALUE is the current value for the KEY.
12 |
13 | ########################
14 | # EXTERNAL cache entries
15 | ########################
16 |
17 | //Path to a program.
18 | CMAKE_AR:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar
19 |
20 | //For backwards compatibility, what version of CMake commands and
21 | // syntax should this version of CMake try to support.
22 | CMAKE_BACKWARDS_COMPATIBILITY:STRING=2.4
23 |
24 | //Choose the type of build, options are: None(CMAKE_CXX_FLAGS or
25 | // CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel.
26 | CMAKE_BUILD_TYPE:STRING=
27 |
28 | //Enable/Disable color output during build.
29 | CMAKE_COLOR_MAKEFILE:BOOL=ON
30 |
31 | //CXX compiler
32 | CMAKE_CXX_COMPILER:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++
33 |
34 | //Flags used by the compiler during all build types.
35 | CMAKE_CXX_FLAGS:STRING=
36 |
37 | //Flags used by the compiler during debug builds.
38 | CMAKE_CXX_FLAGS_DEBUG:STRING=-g
39 |
40 | //Flags used by the compiler during release builds for minimum
41 | // size.
42 | CMAKE_CXX_FLAGS_MINSIZEREL:STRING=-Os -DNDEBUG
43 |
44 | //Flags used by the compiler during release builds.
45 | CMAKE_CXX_FLAGS_RELEASE:STRING=-O3 -DNDEBUG
46 |
47 | //Flags used by the compiler during release builds with debug info.
48 | CMAKE_CXX_FLAGS_RELWITHDEBINFO:STRING=-O2 -g -DNDEBUG
49 |
50 | //C compiler
51 | CMAKE_C_COMPILER:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc
52 |
53 | //Flags used by the compiler during all build types.
54 | CMAKE_C_FLAGS:STRING=
55 |
56 | //Flags used by the compiler during debug builds.
57 | CMAKE_C_FLAGS_DEBUG:STRING=-g
58 |
59 | //Flags used by the compiler during release builds for minimum
60 | // size.
61 | CMAKE_C_FLAGS_MINSIZEREL:STRING=-Os -DNDEBUG
62 |
63 | //Flags used by the compiler during release builds.
64 | CMAKE_C_FLAGS_RELEASE:STRING=-O3 -DNDEBUG
65 |
66 | //Flags used by the compiler during release builds with debug info.
67 | CMAKE_C_FLAGS_RELWITHDEBINFO:STRING=-O2 -g -DNDEBUG
68 |
69 | //Flags used by the linker.
70 | CMAKE_EXE_LINKER_FLAGS:STRING=
71 |
72 | //Flags used by the linker during debug builds.
73 | CMAKE_EXE_LINKER_FLAGS_DEBUG:STRING=
74 |
75 | //Flags used by the linker during release minsize builds.
76 | CMAKE_EXE_LINKER_FLAGS_MINSIZEREL:STRING=
77 |
78 | //Flags used by the linker during release builds.
79 | CMAKE_EXE_LINKER_FLAGS_RELEASE:STRING=
80 |
81 | //Flags used by the linker during Release with Debug Info builds.
82 | CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO:STRING=
83 |
84 | //Enable/Disable output of compile commands during generation.
85 | CMAKE_EXPORT_COMPILE_COMMANDS:BOOL=OFF
86 |
87 | //Path to a program.
88 | CMAKE_INSTALL_NAME_TOOL:FILEPATH=/usr/bin/install_name_tool
89 |
90 | //Install path prefix, prepended onto install directories.
91 | CMAKE_INSTALL_PREFIX:PATH=/usr/local
92 |
93 | //Path to a program.
94 | CMAKE_LINKER:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld
95 |
96 | //Path to a program.
97 | CMAKE_MAKE_PROGRAM:FILEPATH=/usr/bin/make
98 |
99 | //Flags used by the linker during the creation of modules.
100 | CMAKE_MODULE_LINKER_FLAGS:STRING=
101 |
102 | //Flags used by the linker during debug builds.
103 | CMAKE_MODULE_LINKER_FLAGS_DEBUG:STRING=
104 |
105 | //Flags used by the linker during release minsize builds.
106 | CMAKE_MODULE_LINKER_FLAGS_MINSIZEREL:STRING=
107 |
108 | //Flags used by the linker during release builds.
109 | CMAKE_MODULE_LINKER_FLAGS_RELEASE:STRING=
110 |
111 | //Flags used by the linker during Release with Debug Info builds.
112 | CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO:STRING=
113 |
114 | //Path to a program.
115 | CMAKE_NM:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/nm
116 |
117 | //Path to a program.
118 | CMAKE_OBJCOPY:FILEPATH=CMAKE_OBJCOPY-NOTFOUND
119 |
120 | //Path to a program.
121 | CMAKE_OBJDUMP:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/objdump
122 |
123 | //Build architectures for OSX
124 | CMAKE_OSX_ARCHITECTURES:STRING=
125 |
126 | //Minimum OS X version to target for deployment (at runtime); newer
127 | // APIs weak linked. Set to empty string for default value.
128 | CMAKE_OSX_DEPLOYMENT_TARGET:STRING=
129 |
130 | //The product will be built against the headers and libraries located
131 | // inside the indicated SDK.
132 | CMAKE_OSX_SYSROOT:STRING=
133 |
134 | //Value Computed by CMake
135 | CMAKE_PROJECT_NAME:STATIC=Project
136 |
137 | //Path to a program.
138 | CMAKE_RANLIB:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib
139 |
140 | //Flags used by the linker during the creation of dll's.
141 | CMAKE_SHARED_LINKER_FLAGS:STRING=
142 |
143 | //Flags used by the linker during debug builds.
144 | CMAKE_SHARED_LINKER_FLAGS_DEBUG:STRING=
145 |
146 | //Flags used by the linker during release minsize builds.
147 | CMAKE_SHARED_LINKER_FLAGS_MINSIZEREL:STRING=
148 |
149 | //Flags used by the linker during release builds.
150 | CMAKE_SHARED_LINKER_FLAGS_RELEASE:STRING=
151 |
152 | //Flags used by the linker during Release with Debug Info builds.
153 | CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO:STRING=
154 |
155 | //If set, runtime paths are not added when installing shared libraries,
156 | // but are added when building.
157 | CMAKE_SKIP_INSTALL_RPATH:BOOL=NO
158 |
159 | //If set, runtime paths are not added when using shared libraries.
160 | CMAKE_SKIP_RPATH:BOOL=NO
161 |
162 | //Flags used by the linker during the creation of static libraries.
163 | CMAKE_STATIC_LINKER_FLAGS:STRING=
164 |
165 | //Flags used by the linker during debug builds.
166 | CMAKE_STATIC_LINKER_FLAGS_DEBUG:STRING=
167 |
168 | //Flags used by the linker during release minsize builds.
169 | CMAKE_STATIC_LINKER_FLAGS_MINSIZEREL:STRING=
170 |
171 | //Flags used by the linker during release builds.
172 | CMAKE_STATIC_LINKER_FLAGS_RELEASE:STRING=
173 |
174 | //Flags used by the linker during Release with Debug Info builds.
175 | CMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO:STRING=
176 |
177 | //Path to a program.
178 | CMAKE_STRIP:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/strip
179 |
180 | //If this value is on, makefiles will be generated without the
181 | // .SILENT directive, and all commands will be echoed to the console
182 | // during the make. This is useful for debugging only. With Visual
183 | // Studio IDE projects all commands are done without /nologo.
184 | CMAKE_VERBOSE_MAKEFILE:BOOL=FALSE
185 |
186 | //Single output directory for building all executables.
187 | EXECUTABLE_OUTPUT_PATH:PATH=
188 |
189 | //Single output directory for building all libraries.
190 | LIBRARY_OUTPUT_PATH:PATH=
191 |
192 | //Value Computed by CMake
193 | Project_BINARY_DIR:STATIC=/Users/henryboswell/developer/llvm/llvm/lib/Transforms/DynCount
194 |
195 | //Value Computed by CMake
196 | Project_SOURCE_DIR:STATIC=/Users/henryboswell/developer/llvm/llvm/lib/Transforms/DynCount
197 |
198 |
199 | ########################
200 | # INTERNAL cache entries
201 | ########################
202 |
203 | //ADVANCED property for variable: CMAKE_AR
204 | CMAKE_AR-ADVANCED:INTERNAL=1
205 | //This is the directory where this CMakeCache.txt was created
206 | CMAKE_CACHEFILE_DIR:INTERNAL=/Users/henryboswell/developer/llvm/llvm/lib/Transforms/DynCount
207 | //Major version of cmake used to create the current loaded cache
208 | CMAKE_CACHE_MAJOR_VERSION:INTERNAL=3
209 | //Minor version of cmake used to create the current loaded cache
210 | CMAKE_CACHE_MINOR_VERSION:INTERNAL=6
211 | //Patch version of cmake used to create the current loaded cache
212 | CMAKE_CACHE_PATCH_VERSION:INTERNAL=2
213 | //ADVANCED property for variable: CMAKE_COLOR_MAKEFILE
214 | CMAKE_COLOR_MAKEFILE-ADVANCED:INTERNAL=1
215 | //Path to CMake executable.
216 | CMAKE_COMMAND:INTERNAL=/Applications/CMake.app/Contents/bin/cmake
217 | //Path to cpack program executable.
218 | CMAKE_CPACK_COMMAND:INTERNAL=/Applications/CMake.app/Contents/bin/cpack
219 | //Path to ctest program executable.
220 | CMAKE_CTEST_COMMAND:INTERNAL=/Applications/CMake.app/Contents/bin/ctest
221 | //ADVANCED property for variable: CMAKE_CXX_COMPILER
222 | CMAKE_CXX_COMPILER-ADVANCED:INTERNAL=1
223 | //ADVANCED property for variable: CMAKE_CXX_FLAGS
224 | CMAKE_CXX_FLAGS-ADVANCED:INTERNAL=1
225 | //ADVANCED property for variable: CMAKE_CXX_FLAGS_DEBUG
226 | CMAKE_CXX_FLAGS_DEBUG-ADVANCED:INTERNAL=1
227 | //ADVANCED property for variable: CMAKE_CXX_FLAGS_MINSIZEREL
228 | CMAKE_CXX_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
229 | //ADVANCED property for variable: CMAKE_CXX_FLAGS_RELEASE
230 | CMAKE_CXX_FLAGS_RELEASE-ADVANCED:INTERNAL=1
231 | //ADVANCED property for variable: CMAKE_CXX_FLAGS_RELWITHDEBINFO
232 | CMAKE_CXX_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
233 | //ADVANCED property for variable: CMAKE_C_COMPILER
234 | CMAKE_C_COMPILER-ADVANCED:INTERNAL=1
235 | //ADVANCED property for variable: CMAKE_C_FLAGS
236 | CMAKE_C_FLAGS-ADVANCED:INTERNAL=1
237 | //ADVANCED property for variable: CMAKE_C_FLAGS_DEBUG
238 | CMAKE_C_FLAGS_DEBUG-ADVANCED:INTERNAL=1
239 | //ADVANCED property for variable: CMAKE_C_FLAGS_MINSIZEREL
240 | CMAKE_C_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
241 | //ADVANCED property for variable: CMAKE_C_FLAGS_RELEASE
242 | CMAKE_C_FLAGS_RELEASE-ADVANCED:INTERNAL=1
243 | //ADVANCED property for variable: CMAKE_C_FLAGS_RELWITHDEBINFO
244 | CMAKE_C_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
245 | //Path to cache edit program executable.
246 | CMAKE_EDIT_COMMAND:INTERNAL=/Applications/CMake.app/Contents/bin/ccmake
247 | //Executable file format
248 | CMAKE_EXECUTABLE_FORMAT:INTERNAL=Unknown
249 | //ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS
250 | CMAKE_EXE_LINKER_FLAGS-ADVANCED:INTERNAL=1
251 | //ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_DEBUG
252 | CMAKE_EXE_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
253 | //ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_MINSIZEREL
254 | CMAKE_EXE_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
255 | //ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_RELEASE
256 | CMAKE_EXE_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
257 | //ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO
258 | CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
259 | //ADVANCED property for variable: CMAKE_EXPORT_COMPILE_COMMANDS
260 | CMAKE_EXPORT_COMPILE_COMMANDS-ADVANCED:INTERNAL=1
261 | //Name of external makefile project generator.
262 | CMAKE_EXTRA_GENERATOR:INTERNAL=
263 | //Name of generator.
264 | CMAKE_GENERATOR:INTERNAL=Unix Makefiles
265 | //Name of generator platform.
266 | CMAKE_GENERATOR_PLATFORM:INTERNAL=
267 | //Name of generator toolset.
268 | CMAKE_GENERATOR_TOOLSET:INTERNAL=
269 | //Source directory with the top level CMakeLists.txt file for this
270 | // project
271 | CMAKE_HOME_DIRECTORY:INTERNAL=/Users/henryboswell/developer/llvm/llvm/lib/Transforms/DynCount
272 | //ADVANCED property for variable: CMAKE_INSTALL_NAME_TOOL
273 | CMAKE_INSTALL_NAME_TOOL-ADVANCED:INTERNAL=1
274 | //ADVANCED property for variable: CMAKE_LINKER
275 | CMAKE_LINKER-ADVANCED:INTERNAL=1
276 | //ADVANCED property for variable: CMAKE_MAKE_PROGRAM
277 | CMAKE_MAKE_PROGRAM-ADVANCED:INTERNAL=1
278 | //ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS
279 | CMAKE_MODULE_LINKER_FLAGS-ADVANCED:INTERNAL=1
280 | //ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_DEBUG
281 | CMAKE_MODULE_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
282 | //ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_MINSIZEREL
283 | CMAKE_MODULE_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
284 | //ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_RELEASE
285 | CMAKE_MODULE_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
286 | //ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO
287 | CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
288 | //ADVANCED property for variable: CMAKE_NM
289 | CMAKE_NM-ADVANCED:INTERNAL=1
290 | //number of local generators
291 | CMAKE_NUMBER_OF_MAKEFILES:INTERNAL=1
292 | //ADVANCED property for variable: CMAKE_OBJCOPY
293 | CMAKE_OBJCOPY-ADVANCED:INTERNAL=1
294 | //ADVANCED property for variable: CMAKE_OBJDUMP
295 | CMAKE_OBJDUMP-ADVANCED:INTERNAL=1
296 | //ADVANCED property for variable: CMAKE_RANLIB
297 | CMAKE_RANLIB-ADVANCED:INTERNAL=1
298 | //Path to CMake installation.
299 | CMAKE_ROOT:INTERNAL=/Applications/CMake.app/Contents/share/cmake-3.6
300 | //ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS
301 | CMAKE_SHARED_LINKER_FLAGS-ADVANCED:INTERNAL=1
302 | //ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_DEBUG
303 | CMAKE_SHARED_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
304 | //ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_MINSIZEREL
305 | CMAKE_SHARED_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
306 | //ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_RELEASE
307 | CMAKE_SHARED_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
308 | //ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO
309 | CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
310 | //ADVANCED property for variable: CMAKE_SKIP_INSTALL_RPATH
311 | CMAKE_SKIP_INSTALL_RPATH-ADVANCED:INTERNAL=1
312 | //ADVANCED property for variable: CMAKE_SKIP_RPATH
313 | CMAKE_SKIP_RPATH-ADVANCED:INTERNAL=1
314 | //ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS
315 | CMAKE_STATIC_LINKER_FLAGS-ADVANCED:INTERNAL=1
316 | //ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_DEBUG
317 | CMAKE_STATIC_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
318 | //ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_MINSIZEREL
319 | CMAKE_STATIC_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
320 | //ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_RELEASE
321 | CMAKE_STATIC_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
322 | //ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO
323 | CMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
324 | //ADVANCED property for variable: CMAKE_STRIP
325 | CMAKE_STRIP-ADVANCED:INTERNAL=1
326 | //uname command
327 | CMAKE_UNAME:INTERNAL=/usr/bin/uname
328 | //ADVANCED property for variable: CMAKE_VERBOSE_MAKEFILE
329 | CMAKE_VERBOSE_MAKEFILE-ADVANCED:INTERNAL=1
330 |
331 |
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/DynCount/CMakeFiles/.DS_Store
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/3.6.2/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/DynCount/CMakeFiles/3.6.2/.DS_Store
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/3.6.2/CMakeCCompiler.cmake:
--------------------------------------------------------------------------------
1 | set(CMAKE_C_COMPILER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc")
2 | set(CMAKE_C_COMPILER_ARG1 "")
3 | set(CMAKE_C_COMPILER_ID "AppleClang")
4 | set(CMAKE_C_COMPILER_VERSION "8.0.0.8000038")
5 | set(CMAKE_C_COMPILER_WRAPPER "")
6 | set(CMAKE_C_STANDARD_COMPUTED_DEFAULT "11")
7 | set(CMAKE_C_COMPILE_FEATURES "c_function_prototypes;c_restrict;c_variadic_macros;c_static_assert")
8 | set(CMAKE_C90_COMPILE_FEATURES "c_function_prototypes")
9 | set(CMAKE_C99_COMPILE_FEATURES "c_restrict;c_variadic_macros")
10 | set(CMAKE_C11_COMPILE_FEATURES "c_static_assert")
11 |
12 | set(CMAKE_C_PLATFORM_ID "Darwin")
13 | set(CMAKE_C_SIMULATE_ID "")
14 | set(CMAKE_C_SIMULATE_VERSION "")
15 |
16 | set(CMAKE_AR "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar")
17 | set(CMAKE_RANLIB "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib")
18 | set(CMAKE_LINKER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld")
19 | set(CMAKE_COMPILER_IS_GNUCC )
20 | set(CMAKE_C_COMPILER_LOADED 1)
21 | set(CMAKE_C_COMPILER_WORKS TRUE)
22 | set(CMAKE_C_ABI_COMPILED TRUE)
23 | set(CMAKE_COMPILER_IS_MINGW )
24 | set(CMAKE_COMPILER_IS_CYGWIN )
25 | if(CMAKE_COMPILER_IS_CYGWIN)
26 | set(CYGWIN 1)
27 | set(UNIX 1)
28 | endif()
29 |
30 | set(CMAKE_C_COMPILER_ENV_VAR "CC")
31 |
32 | if(CMAKE_COMPILER_IS_MINGW)
33 | set(MINGW 1)
34 | endif()
35 | set(CMAKE_C_COMPILER_ID_RUN 1)
36 | set(CMAKE_C_SOURCE_FILE_EXTENSIONS c;m)
37 | set(CMAKE_C_IGNORE_EXTENSIONS h;H;o;O;obj;OBJ;def;DEF;rc;RC)
38 | set(CMAKE_C_LINKER_PREFERENCE 10)
39 |
40 | # Save compiler ABI information.
41 | set(CMAKE_C_SIZEOF_DATA_PTR "8")
42 | set(CMAKE_C_COMPILER_ABI "")
43 | set(CMAKE_C_LIBRARY_ARCHITECTURE "")
44 |
45 | if(CMAKE_C_SIZEOF_DATA_PTR)
46 | set(CMAKE_SIZEOF_VOID_P "${CMAKE_C_SIZEOF_DATA_PTR}")
47 | endif()
48 |
49 | if(CMAKE_C_COMPILER_ABI)
50 | set(CMAKE_INTERNAL_PLATFORM_ABI "${CMAKE_C_COMPILER_ABI}")
51 | endif()
52 |
53 | if(CMAKE_C_LIBRARY_ARCHITECTURE)
54 | set(CMAKE_LIBRARY_ARCHITECTURE "")
55 | endif()
56 |
57 | set(CMAKE_C_CL_SHOWINCLUDES_PREFIX "")
58 | if(CMAKE_C_CL_SHOWINCLUDES_PREFIX)
59 | set(CMAKE_CL_SHOWINCLUDES_PREFIX "${CMAKE_C_CL_SHOWINCLUDES_PREFIX}")
60 | endif()
61 |
62 |
63 |
64 |
65 | set(CMAKE_C_IMPLICIT_LINK_LIBRARIES "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/8.0.0/lib/darwin/libclang_rt.osx.a")
66 | set(CMAKE_C_IMPLICIT_LINK_DIRECTORIES "/usr/lib;/usr/local/lib")
67 | set(CMAKE_C_IMPLICIT_LINK_FRAMEWORK_DIRECTORIES "/Library/Frameworks;/System/Library/Frameworks")
68 |
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/3.6.2/CMakeCXXCompiler.cmake:
--------------------------------------------------------------------------------
1 | set(CMAKE_CXX_COMPILER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++")
2 | set(CMAKE_CXX_COMPILER_ARG1 "")
3 | set(CMAKE_CXX_COMPILER_ID "AppleClang")
4 | set(CMAKE_CXX_COMPILER_VERSION "8.0.0.8000038")
5 | set(CMAKE_CXX_COMPILER_WRAPPER "")
6 | set(CMAKE_CXX_STANDARD_COMPUTED_DEFAULT "98")
7 | set(CMAKE_CXX_COMPILE_FEATURES "cxx_template_template_parameters;cxx_alias_templates;cxx_alignas;cxx_alignof;cxx_attributes;cxx_auto_type;cxx_constexpr;cxx_decltype;cxx_decltype_incomplete_return_types;cxx_default_function_template_args;cxx_defaulted_functions;cxx_defaulted_move_initializers;cxx_delegating_constructors;cxx_deleted_functions;cxx_enum_forward_declarations;cxx_explicit_conversions;cxx_extended_friend_declarations;cxx_extern_templates;cxx_final;cxx_func_identifier;cxx_generalized_initializers;cxx_inheriting_constructors;cxx_inline_namespaces;cxx_lambdas;cxx_local_type_template_args;cxx_long_long_type;cxx_noexcept;cxx_nonstatic_member_init;cxx_nullptr;cxx_override;cxx_range_for;cxx_raw_string_literals;cxx_reference_qualified_functions;cxx_right_angle_brackets;cxx_rvalue_references;cxx_sizeof_member;cxx_static_assert;cxx_strong_enums;cxx_thread_local;cxx_trailing_return_types;cxx_unicode_literals;cxx_uniform_initialization;cxx_unrestricted_unions;cxx_user_literals;cxx_variadic_macros;cxx_variadic_templates;cxx_aggregate_default_initializers;cxx_attribute_deprecated;cxx_binary_literals;cxx_contextual_conversions;cxx_decltype_auto;cxx_digit_separators;cxx_generic_lambdas;cxx_lambda_init_captures;cxx_relaxed_constexpr;cxx_return_type_deduction;cxx_variable_templates")
8 | set(CMAKE_CXX98_COMPILE_FEATURES "cxx_template_template_parameters")
9 | set(CMAKE_CXX11_COMPILE_FEATURES "cxx_alias_templates;cxx_alignas;cxx_alignof;cxx_attributes;cxx_auto_type;cxx_constexpr;cxx_decltype;cxx_decltype_incomplete_return_types;cxx_default_function_template_args;cxx_defaulted_functions;cxx_defaulted_move_initializers;cxx_delegating_constructors;cxx_deleted_functions;cxx_enum_forward_declarations;cxx_explicit_conversions;cxx_extended_friend_declarations;cxx_extern_templates;cxx_final;cxx_func_identifier;cxx_generalized_initializers;cxx_inheriting_constructors;cxx_inline_namespaces;cxx_lambdas;cxx_local_type_template_args;cxx_long_long_type;cxx_noexcept;cxx_nonstatic_member_init;cxx_nullptr;cxx_override;cxx_range_for;cxx_raw_string_literals;cxx_reference_qualified_functions;cxx_right_angle_brackets;cxx_rvalue_references;cxx_sizeof_member;cxx_static_assert;cxx_strong_enums;cxx_thread_local;cxx_trailing_return_types;cxx_unicode_literals;cxx_uniform_initialization;cxx_unrestricted_unions;cxx_user_literals;cxx_variadic_macros;cxx_variadic_templates")
10 | set(CMAKE_CXX14_COMPILE_FEATURES "cxx_aggregate_default_initializers;cxx_attribute_deprecated;cxx_binary_literals;cxx_contextual_conversions;cxx_decltype_auto;cxx_digit_separators;cxx_generic_lambdas;cxx_lambda_init_captures;cxx_relaxed_constexpr;cxx_return_type_deduction;cxx_variable_templates")
11 |
12 | set(CMAKE_CXX_PLATFORM_ID "Darwin")
13 | set(CMAKE_CXX_SIMULATE_ID "")
14 | set(CMAKE_CXX_SIMULATE_VERSION "")
15 |
16 | set(CMAKE_AR "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar")
17 | set(CMAKE_RANLIB "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib")
18 | set(CMAKE_LINKER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld")
19 | set(CMAKE_COMPILER_IS_GNUCXX )
20 | set(CMAKE_CXX_COMPILER_LOADED 1)
21 | set(CMAKE_CXX_COMPILER_WORKS TRUE)
22 | set(CMAKE_CXX_ABI_COMPILED TRUE)
23 | set(CMAKE_COMPILER_IS_MINGW )
24 | set(CMAKE_COMPILER_IS_CYGWIN )
25 | if(CMAKE_COMPILER_IS_CYGWIN)
26 | set(CYGWIN 1)
27 | set(UNIX 1)
28 | endif()
29 |
30 | set(CMAKE_CXX_COMPILER_ENV_VAR "CXX")
31 |
32 | if(CMAKE_COMPILER_IS_MINGW)
33 | set(MINGW 1)
34 | endif()
35 | set(CMAKE_CXX_COMPILER_ID_RUN 1)
36 | set(CMAKE_CXX_IGNORE_EXTENSIONS inl;h;hpp;HPP;H;o;O;obj;OBJ;def;DEF;rc;RC)
37 | set(CMAKE_CXX_SOURCE_FILE_EXTENSIONS C;M;c++;cc;cpp;cxx;mm;CPP)
38 | set(CMAKE_CXX_LINKER_PREFERENCE 30)
39 | set(CMAKE_CXX_LINKER_PREFERENCE_PROPAGATES 1)
40 |
41 | # Save compiler ABI information.
42 | set(CMAKE_CXX_SIZEOF_DATA_PTR "8")
43 | set(CMAKE_CXX_COMPILER_ABI "")
44 | set(CMAKE_CXX_LIBRARY_ARCHITECTURE "")
45 |
46 | if(CMAKE_CXX_SIZEOF_DATA_PTR)
47 | set(CMAKE_SIZEOF_VOID_P "${CMAKE_CXX_SIZEOF_DATA_PTR}")
48 | endif()
49 |
50 | if(CMAKE_CXX_COMPILER_ABI)
51 | set(CMAKE_INTERNAL_PLATFORM_ABI "${CMAKE_CXX_COMPILER_ABI}")
52 | endif()
53 |
54 | if(CMAKE_CXX_LIBRARY_ARCHITECTURE)
55 | set(CMAKE_LIBRARY_ARCHITECTURE "")
56 | endif()
57 |
58 | set(CMAKE_CXX_CL_SHOWINCLUDES_PREFIX "")
59 | if(CMAKE_CXX_CL_SHOWINCLUDES_PREFIX)
60 | set(CMAKE_CL_SHOWINCLUDES_PREFIX "${CMAKE_CXX_CL_SHOWINCLUDES_PREFIX}")
61 | endif()
62 |
63 |
64 |
65 |
66 | set(CMAKE_CXX_IMPLICIT_LINK_LIBRARIES "c++;/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/8.0.0/lib/darwin/libclang_rt.osx.a")
67 | set(CMAKE_CXX_IMPLICIT_LINK_DIRECTORIES "/usr/lib;/usr/local/lib")
68 | set(CMAKE_CXX_IMPLICIT_LINK_FRAMEWORK_DIRECTORIES "/Library/Frameworks;/System/Library/Frameworks")
69 |
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/3.6.2/CMakeDetermineCompilerABI_C.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/DynCount/CMakeFiles/3.6.2/CMakeDetermineCompilerABI_C.bin
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/3.6.2/CMakeDetermineCompilerABI_CXX.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/DynCount/CMakeFiles/3.6.2/CMakeDetermineCompilerABI_CXX.bin
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/3.6.2/CMakeSystem.cmake:
--------------------------------------------------------------------------------
1 | set(CMAKE_HOST_SYSTEM "Darwin-16.0.0")
2 | set(CMAKE_HOST_SYSTEM_NAME "Darwin")
3 | set(CMAKE_HOST_SYSTEM_VERSION "16.0.0")
4 | set(CMAKE_HOST_SYSTEM_PROCESSOR "x86_64")
5 |
6 |
7 |
8 | set(CMAKE_SYSTEM "Darwin-16.0.0")
9 | set(CMAKE_SYSTEM_NAME "Darwin")
10 | set(CMAKE_SYSTEM_VERSION "16.0.0")
11 | set(CMAKE_SYSTEM_PROCESSOR "x86_64")
12 |
13 | set(CMAKE_CROSSCOMPILING "FALSE")
14 |
15 | set(CMAKE_SYSTEM_LOADED 1)
16 |
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/3.6.2/CompilerIdC/CMakeCCompilerId.c:
--------------------------------------------------------------------------------
1 | #ifdef __cplusplus
2 | # error "A C++ compiler has been selected for C."
3 | #endif
4 |
5 | #if defined(__18CXX)
6 | # define ID_VOID_MAIN
7 | #endif
8 | #if defined(__CLASSIC_C__)
9 | /* cv-qualifiers did not exist in K&R C */
10 | # define const
11 | # define volatile
12 | #endif
13 |
14 |
15 | /* Version number components: V=Version, R=Revision, P=Patch
16 | Version date components: YYYY=Year, MM=Month, DD=Day */
17 |
18 | #if defined(__INTEL_COMPILER) || defined(__ICC)
19 | # define COMPILER_ID "Intel"
20 | # if defined(_MSC_VER)
21 | # define SIMULATE_ID "MSVC"
22 | # endif
23 | /* __INTEL_COMPILER = VRP */
24 | # define COMPILER_VERSION_MAJOR DEC(__INTEL_COMPILER/100)
25 | # define COMPILER_VERSION_MINOR DEC(__INTEL_COMPILER/10 % 10)
26 | # if defined(__INTEL_COMPILER_UPDATE)
27 | # define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER_UPDATE)
28 | # else
29 | # define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER % 10)
30 | # endif
31 | # if defined(__INTEL_COMPILER_BUILD_DATE)
32 | /* __INTEL_COMPILER_BUILD_DATE = YYYYMMDD */
33 | # define COMPILER_VERSION_TWEAK DEC(__INTEL_COMPILER_BUILD_DATE)
34 | # endif
35 | # if defined(_MSC_VER)
36 | /* _MSC_VER = VVRR */
37 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
38 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
39 | # endif
40 |
41 | #elif defined(__PATHCC__)
42 | # define COMPILER_ID "PathScale"
43 | # define COMPILER_VERSION_MAJOR DEC(__PATHCC__)
44 | # define COMPILER_VERSION_MINOR DEC(__PATHCC_MINOR__)
45 | # if defined(__PATHCC_PATCHLEVEL__)
46 | # define COMPILER_VERSION_PATCH DEC(__PATHCC_PATCHLEVEL__)
47 | # endif
48 |
49 | #elif defined(__BORLANDC__) && defined(__CODEGEARC_VERSION__)
50 | # define COMPILER_ID "Embarcadero"
51 | # define COMPILER_VERSION_MAJOR HEX(__CODEGEARC_VERSION__>>24 & 0x00FF)
52 | # define COMPILER_VERSION_MINOR HEX(__CODEGEARC_VERSION__>>16 & 0x00FF)
53 | # define COMPILER_VERSION_PATCH DEC(__CODEGEARC_VERSION__ & 0xFFFF)
54 |
55 | #elif defined(__BORLANDC__)
56 | # define COMPILER_ID "Borland"
57 | /* __BORLANDC__ = 0xVRR */
58 | # define COMPILER_VERSION_MAJOR HEX(__BORLANDC__>>8)
59 | # define COMPILER_VERSION_MINOR HEX(__BORLANDC__ & 0xFF)
60 |
61 | #elif defined(__WATCOMC__) && __WATCOMC__ < 1200
62 | # define COMPILER_ID "Watcom"
63 | /* __WATCOMC__ = VVRR */
64 | # define COMPILER_VERSION_MAJOR DEC(__WATCOMC__ / 100)
65 | # define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
66 | # if (__WATCOMC__ % 10) > 0
67 | # define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
68 | # endif
69 |
70 | #elif defined(__WATCOMC__)
71 | # define COMPILER_ID "OpenWatcom"
72 | /* __WATCOMC__ = VVRP + 1100 */
73 | # define COMPILER_VERSION_MAJOR DEC((__WATCOMC__ - 1100) / 100)
74 | # define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
75 | # if (__WATCOMC__ % 10) > 0
76 | # define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
77 | # endif
78 |
79 | #elif defined(__SUNPRO_C)
80 | # define COMPILER_ID "SunPro"
81 | # if __SUNPRO_C >= 0x5100
82 | /* __SUNPRO_C = 0xVRRP */
83 | # define COMPILER_VERSION_MAJOR HEX(__SUNPRO_C>>12)
84 | # define COMPILER_VERSION_MINOR HEX(__SUNPRO_C>>4 & 0xFF)
85 | # define COMPILER_VERSION_PATCH HEX(__SUNPRO_C & 0xF)
86 | # else
87 | /* __SUNPRO_CC = 0xVRP */
88 | # define COMPILER_VERSION_MAJOR HEX(__SUNPRO_C>>8)
89 | # define COMPILER_VERSION_MINOR HEX(__SUNPRO_C>>4 & 0xF)
90 | # define COMPILER_VERSION_PATCH HEX(__SUNPRO_C & 0xF)
91 | # endif
92 |
93 | #elif defined(__HP_cc)
94 | # define COMPILER_ID "HP"
95 | /* __HP_cc = VVRRPP */
96 | # define COMPILER_VERSION_MAJOR DEC(__HP_cc/10000)
97 | # define COMPILER_VERSION_MINOR DEC(__HP_cc/100 % 100)
98 | # define COMPILER_VERSION_PATCH DEC(__HP_cc % 100)
99 |
100 | #elif defined(__DECC)
101 | # define COMPILER_ID "Compaq"
102 | /* __DECC_VER = VVRRTPPPP */
103 | # define COMPILER_VERSION_MAJOR DEC(__DECC_VER/10000000)
104 | # define COMPILER_VERSION_MINOR DEC(__DECC_VER/100000 % 100)
105 | # define COMPILER_VERSION_PATCH DEC(__DECC_VER % 10000)
106 |
107 | #elif defined(__IBMC__) && defined(__COMPILER_VER__)
108 | # define COMPILER_ID "zOS"
109 | /* __IBMC__ = VRP */
110 | # define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
111 | # define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
112 | # define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
113 |
114 | #elif defined(__IBMC__) && !defined(__COMPILER_VER__) && __IBMC__ >= 800
115 | # define COMPILER_ID "XL"
116 | /* __IBMC__ = VRP */
117 | # define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
118 | # define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
119 | # define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
120 |
121 | #elif defined(__IBMC__) && !defined(__COMPILER_VER__) && __IBMC__ < 800
122 | # define COMPILER_ID "VisualAge"
123 | /* __IBMC__ = VRP */
124 | # define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
125 | # define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
126 | # define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
127 |
128 | #elif defined(__PGI)
129 | # define COMPILER_ID "PGI"
130 | # define COMPILER_VERSION_MAJOR DEC(__PGIC__)
131 | # define COMPILER_VERSION_MINOR DEC(__PGIC_MINOR__)
132 | # if defined(__PGIC_PATCHLEVEL__)
133 | # define COMPILER_VERSION_PATCH DEC(__PGIC_PATCHLEVEL__)
134 | # endif
135 |
136 | #elif defined(_CRAYC)
137 | # define COMPILER_ID "Cray"
138 | # define COMPILER_VERSION_MAJOR DEC(_RELEASE_MAJOR)
139 | # define COMPILER_VERSION_MINOR DEC(_RELEASE_MINOR)
140 |
141 | #elif defined(__TI_COMPILER_VERSION__)
142 | # define COMPILER_ID "TI"
143 | /* __TI_COMPILER_VERSION__ = VVVRRRPPP */
144 | # define COMPILER_VERSION_MAJOR DEC(__TI_COMPILER_VERSION__/1000000)
145 | # define COMPILER_VERSION_MINOR DEC(__TI_COMPILER_VERSION__/1000 % 1000)
146 | # define COMPILER_VERSION_PATCH DEC(__TI_COMPILER_VERSION__ % 1000)
147 |
148 | #elif defined(__FUJITSU) || defined(__FCC_VERSION) || defined(__fcc_version)
149 | # define COMPILER_ID "Fujitsu"
150 |
151 | #elif defined(__TINYC__)
152 | # define COMPILER_ID "TinyCC"
153 |
154 | #elif defined(__BCC__)
155 | # define COMPILER_ID "Bruce"
156 |
157 | #elif defined(__SCO_VERSION__)
158 | # define COMPILER_ID "SCO"
159 |
160 | #elif defined(__clang__) && defined(__apple_build_version__)
161 | # define COMPILER_ID "AppleClang"
162 | # if defined(_MSC_VER)
163 | # define SIMULATE_ID "MSVC"
164 | # endif
165 | # define COMPILER_VERSION_MAJOR DEC(__clang_major__)
166 | # define COMPILER_VERSION_MINOR DEC(__clang_minor__)
167 | # define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
168 | # if defined(_MSC_VER)
169 | /* _MSC_VER = VVRR */
170 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
171 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
172 | # endif
173 | # define COMPILER_VERSION_TWEAK DEC(__apple_build_version__)
174 |
175 | #elif defined(__clang__)
176 | # define COMPILER_ID "Clang"
177 | # if defined(_MSC_VER)
178 | # define SIMULATE_ID "MSVC"
179 | # endif
180 | # define COMPILER_VERSION_MAJOR DEC(__clang_major__)
181 | # define COMPILER_VERSION_MINOR DEC(__clang_minor__)
182 | # define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
183 | # if defined(_MSC_VER)
184 | /* _MSC_VER = VVRR */
185 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
186 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
187 | # endif
188 |
189 | #elif defined(__GNUC__)
190 | # define COMPILER_ID "GNU"
191 | # define COMPILER_VERSION_MAJOR DEC(__GNUC__)
192 | # if defined(__GNUC_MINOR__)
193 | # define COMPILER_VERSION_MINOR DEC(__GNUC_MINOR__)
194 | # endif
195 | # if defined(__GNUC_PATCHLEVEL__)
196 | # define COMPILER_VERSION_PATCH DEC(__GNUC_PATCHLEVEL__)
197 | # endif
198 |
199 | #elif defined(_MSC_VER)
200 | # define COMPILER_ID "MSVC"
201 | /* _MSC_VER = VVRR */
202 | # define COMPILER_VERSION_MAJOR DEC(_MSC_VER / 100)
203 | # define COMPILER_VERSION_MINOR DEC(_MSC_VER % 100)
204 | # if defined(_MSC_FULL_VER)
205 | # if _MSC_VER >= 1400
206 | /* _MSC_FULL_VER = VVRRPPPPP */
207 | # define COMPILER_VERSION_PATCH DEC(_MSC_FULL_VER % 100000)
208 | # else
209 | /* _MSC_FULL_VER = VVRRPPPP */
210 | # define COMPILER_VERSION_PATCH DEC(_MSC_FULL_VER % 10000)
211 | # endif
212 | # endif
213 | # if defined(_MSC_BUILD)
214 | # define COMPILER_VERSION_TWEAK DEC(_MSC_BUILD)
215 | # endif
216 |
217 | #elif defined(__VISUALDSPVERSION__) || defined(__ADSPBLACKFIN__) || defined(__ADSPTS__) || defined(__ADSP21000__)
218 | # define COMPILER_ID "ADSP"
219 | #if defined(__VISUALDSPVERSION__)
220 | /* __VISUALDSPVERSION__ = 0xVVRRPP00 */
221 | # define COMPILER_VERSION_MAJOR HEX(__VISUALDSPVERSION__>>24)
222 | # define COMPILER_VERSION_MINOR HEX(__VISUALDSPVERSION__>>16 & 0xFF)
223 | # define COMPILER_VERSION_PATCH HEX(__VISUALDSPVERSION__>>8 & 0xFF)
224 | #endif
225 |
226 | #elif defined(__IAR_SYSTEMS_ICC__ ) || defined(__IAR_SYSTEMS_ICC)
227 | # define COMPILER_ID "IAR"
228 |
229 | #elif defined(__ARMCC_VERSION)
230 | # define COMPILER_ID "ARMCC"
231 | #if __ARMCC_VERSION >= 1000000
232 | /* __ARMCC_VERSION = VRRPPPP */
233 | # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/1000000)
234 | # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 100)
235 | # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
236 | #else
237 | /* __ARMCC_VERSION = VRPPPP */
238 | # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/100000)
239 | # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 10)
240 | # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
241 | #endif
242 |
243 |
244 | #elif defined(SDCC)
245 | # define COMPILER_ID "SDCC"
246 | /* SDCC = VRP */
247 | # define COMPILER_VERSION_MAJOR DEC(SDCC/100)
248 | # define COMPILER_VERSION_MINOR DEC(SDCC/10 % 10)
249 | # define COMPILER_VERSION_PATCH DEC(SDCC % 10)
250 |
251 | #elif defined(_SGI_COMPILER_VERSION) || defined(_COMPILER_VERSION)
252 | # define COMPILER_ID "MIPSpro"
253 | # if defined(_SGI_COMPILER_VERSION)
254 | /* _SGI_COMPILER_VERSION = VRP */
255 | # define COMPILER_VERSION_MAJOR DEC(_SGI_COMPILER_VERSION/100)
256 | # define COMPILER_VERSION_MINOR DEC(_SGI_COMPILER_VERSION/10 % 10)
257 | # define COMPILER_VERSION_PATCH DEC(_SGI_COMPILER_VERSION % 10)
258 | # else
259 | /* _COMPILER_VERSION = VRP */
260 | # define COMPILER_VERSION_MAJOR DEC(_COMPILER_VERSION/100)
261 | # define COMPILER_VERSION_MINOR DEC(_COMPILER_VERSION/10 % 10)
262 | # define COMPILER_VERSION_PATCH DEC(_COMPILER_VERSION % 10)
263 | # endif
264 |
265 |
266 | /* These compilers are either not known or too old to define an
267 | identification macro. Try to identify the platform and guess that
268 | it is the native compiler. */
269 | #elif defined(__sgi)
270 | # define COMPILER_ID "MIPSpro"
271 |
272 | #elif defined(__hpux) || defined(__hpua)
273 | # define COMPILER_ID "HP"
274 |
275 | #else /* unknown compiler */
276 | # define COMPILER_ID ""
277 | #endif
278 |
279 | /* Construct the string literal in pieces to prevent the source from
280 | getting matched. Store it in a pointer rather than an array
281 | because some compilers will just produce instructions to fill the
282 | array rather than assigning a pointer to a static array. */
283 | char const* info_compiler = "INFO" ":" "compiler[" COMPILER_ID "]";
284 | #ifdef SIMULATE_ID
285 | char const* info_simulate = "INFO" ":" "simulate[" SIMULATE_ID "]";
286 | #endif
287 |
288 | #ifdef __QNXNTO__
289 | char const* qnxnto = "INFO" ":" "qnxnto[]";
290 | #endif
291 |
292 | #if defined(__CRAYXE) || defined(__CRAYXC)
293 | char const *info_cray = "INFO" ":" "compiler_wrapper[CrayPrgEnv]";
294 | #endif
295 |
296 | #define STRINGIFY_HELPER(X) #X
297 | #define STRINGIFY(X) STRINGIFY_HELPER(X)
298 |
299 | /* Identify known platforms by name. */
300 | #if defined(__linux) || defined(__linux__) || defined(linux)
301 | # define PLATFORM_ID "Linux"
302 |
303 | #elif defined(__CYGWIN__)
304 | # define PLATFORM_ID "Cygwin"
305 |
306 | #elif defined(__MINGW32__)
307 | # define PLATFORM_ID "MinGW"
308 |
309 | #elif defined(__APPLE__)
310 | # define PLATFORM_ID "Darwin"
311 |
312 | #elif defined(_WIN32) || defined(__WIN32__) || defined(WIN32)
313 | # define PLATFORM_ID "Windows"
314 |
315 | #elif defined(__FreeBSD__) || defined(__FreeBSD)
316 | # define PLATFORM_ID "FreeBSD"
317 |
318 | #elif defined(__NetBSD__) || defined(__NetBSD)
319 | # define PLATFORM_ID "NetBSD"
320 |
321 | #elif defined(__OpenBSD__) || defined(__OPENBSD)
322 | # define PLATFORM_ID "OpenBSD"
323 |
324 | #elif defined(__sun) || defined(sun)
325 | # define PLATFORM_ID "SunOS"
326 |
327 | #elif defined(_AIX) || defined(__AIX) || defined(__AIX__) || defined(__aix) || defined(__aix__)
328 | # define PLATFORM_ID "AIX"
329 |
330 | #elif defined(__sgi) || defined(__sgi__) || defined(_SGI)
331 | # define PLATFORM_ID "IRIX"
332 |
333 | #elif defined(__hpux) || defined(__hpux__)
334 | # define PLATFORM_ID "HP-UX"
335 |
336 | #elif defined(__HAIKU__)
337 | # define PLATFORM_ID "Haiku"
338 |
339 | #elif defined(__BeOS) || defined(__BEOS__) || defined(_BEOS)
340 | # define PLATFORM_ID "BeOS"
341 |
342 | #elif defined(__QNX__) || defined(__QNXNTO__)
343 | # define PLATFORM_ID "QNX"
344 |
345 | #elif defined(__tru64) || defined(_tru64) || defined(__TRU64__)
346 | # define PLATFORM_ID "Tru64"
347 |
348 | #elif defined(__riscos) || defined(__riscos__)
349 | # define PLATFORM_ID "RISCos"
350 |
351 | #elif defined(__sinix) || defined(__sinix__) || defined(__SINIX__)
352 | # define PLATFORM_ID "SINIX"
353 |
354 | #elif defined(__UNIX_SV__)
355 | # define PLATFORM_ID "UNIX_SV"
356 |
357 | #elif defined(__bsdos__)
358 | # define PLATFORM_ID "BSDOS"
359 |
360 | #elif defined(_MPRAS) || defined(MPRAS)
361 | # define PLATFORM_ID "MP-RAS"
362 |
363 | #elif defined(__osf) || defined(__osf__)
364 | # define PLATFORM_ID "OSF1"
365 |
366 | #elif defined(_SCO_SV) || defined(SCO_SV) || defined(sco_sv)
367 | # define PLATFORM_ID "SCO_SV"
368 |
369 | #elif defined(__ultrix) || defined(__ultrix__) || defined(_ULTRIX)
370 | # define PLATFORM_ID "ULTRIX"
371 |
372 | #elif defined(__XENIX__) || defined(_XENIX) || defined(XENIX)
373 | # define PLATFORM_ID "Xenix"
374 |
375 | #elif defined(__WATCOMC__)
376 | # if defined(__LINUX__)
377 | # define PLATFORM_ID "Linux"
378 |
379 | # elif defined(__DOS__)
380 | # define PLATFORM_ID "DOS"
381 |
382 | # elif defined(__OS2__)
383 | # define PLATFORM_ID "OS2"
384 |
385 | # elif defined(__WINDOWS__)
386 | # define PLATFORM_ID "Windows3x"
387 |
388 | # else /* unknown platform */
389 | # define PLATFORM_ID
390 | # endif
391 |
392 | #else /* unknown platform */
393 | # define PLATFORM_ID
394 |
395 | #endif
396 |
397 | /* For windows compilers MSVC and Intel we can determine
398 | the architecture of the compiler being used. This is because
399 | the compilers do not have flags that can change the architecture,
400 | but rather depend on which compiler is being used
401 | */
402 | #if defined(_WIN32) && defined(_MSC_VER)
403 | # if defined(_M_IA64)
404 | # define ARCHITECTURE_ID "IA64"
405 |
406 | # elif defined(_M_X64) || defined(_M_AMD64)
407 | # define ARCHITECTURE_ID "x64"
408 |
409 | # elif defined(_M_IX86)
410 | # define ARCHITECTURE_ID "X86"
411 |
412 | # elif defined(_M_ARM)
413 | # if _M_ARM == 4
414 | # define ARCHITECTURE_ID "ARMV4I"
415 | # elif _M_ARM == 5
416 | # define ARCHITECTURE_ID "ARMV5I"
417 | # else
418 | # define ARCHITECTURE_ID "ARMV" STRINGIFY(_M_ARM)
419 | # endif
420 |
421 | # elif defined(_M_MIPS)
422 | # define ARCHITECTURE_ID "MIPS"
423 |
424 | # elif defined(_M_SH)
425 | # define ARCHITECTURE_ID "SHx"
426 |
427 | # else /* unknown architecture */
428 | # define ARCHITECTURE_ID ""
429 | # endif
430 |
431 | #elif defined(__WATCOMC__)
432 | # if defined(_M_I86)
433 | # define ARCHITECTURE_ID "I86"
434 |
435 | # elif defined(_M_IX86)
436 | # define ARCHITECTURE_ID "X86"
437 |
438 | # else /* unknown architecture */
439 | # define ARCHITECTURE_ID ""
440 | # endif
441 |
442 | #else
443 | # define ARCHITECTURE_ID
444 | #endif
445 |
446 | /* Convert integer to decimal digit literals. */
447 | #define DEC(n) \
448 | ('0' + (((n) / 10000000)%10)), \
449 | ('0' + (((n) / 1000000)%10)), \
450 | ('0' + (((n) / 100000)%10)), \
451 | ('0' + (((n) / 10000)%10)), \
452 | ('0' + (((n) / 1000)%10)), \
453 | ('0' + (((n) / 100)%10)), \
454 | ('0' + (((n) / 10)%10)), \
455 | ('0' + ((n) % 10))
456 |
457 | /* Convert integer to hex digit literals. */
458 | #define HEX(n) \
459 | ('0' + ((n)>>28 & 0xF)), \
460 | ('0' + ((n)>>24 & 0xF)), \
461 | ('0' + ((n)>>20 & 0xF)), \
462 | ('0' + ((n)>>16 & 0xF)), \
463 | ('0' + ((n)>>12 & 0xF)), \
464 | ('0' + ((n)>>8 & 0xF)), \
465 | ('0' + ((n)>>4 & 0xF)), \
466 | ('0' + ((n) & 0xF))
467 |
468 | /* Construct a string literal encoding the version number components. */
469 | #ifdef COMPILER_VERSION_MAJOR
470 | char const info_version[] = {
471 | 'I', 'N', 'F', 'O', ':',
472 | 'c','o','m','p','i','l','e','r','_','v','e','r','s','i','o','n','[',
473 | COMPILER_VERSION_MAJOR,
474 | # ifdef COMPILER_VERSION_MINOR
475 | '.', COMPILER_VERSION_MINOR,
476 | # ifdef COMPILER_VERSION_PATCH
477 | '.', COMPILER_VERSION_PATCH,
478 | # ifdef COMPILER_VERSION_TWEAK
479 | '.', COMPILER_VERSION_TWEAK,
480 | # endif
481 | # endif
482 | # endif
483 | ']','\0'};
484 | #endif
485 |
486 | /* Construct a string literal encoding the version number components. */
487 | #ifdef SIMULATE_VERSION_MAJOR
488 | char const info_simulate_version[] = {
489 | 'I', 'N', 'F', 'O', ':',
490 | 's','i','m','u','l','a','t','e','_','v','e','r','s','i','o','n','[',
491 | SIMULATE_VERSION_MAJOR,
492 | # ifdef SIMULATE_VERSION_MINOR
493 | '.', SIMULATE_VERSION_MINOR,
494 | # ifdef SIMULATE_VERSION_PATCH
495 | '.', SIMULATE_VERSION_PATCH,
496 | # ifdef SIMULATE_VERSION_TWEAK
497 | '.', SIMULATE_VERSION_TWEAK,
498 | # endif
499 | # endif
500 | # endif
501 | ']','\0'};
502 | #endif
503 |
504 | /* Construct the string literal in pieces to prevent the source from
505 | getting matched. Store it in a pointer rather than an array
506 | because some compilers will just produce instructions to fill the
507 | array rather than assigning a pointer to a static array. */
508 | char const* info_platform = "INFO" ":" "platform[" PLATFORM_ID "]";
509 | char const* info_arch = "INFO" ":" "arch[" ARCHITECTURE_ID "]";
510 |
511 |
512 |
513 |
514 | #if !defined(__STDC__)
515 | # if defined(_MSC_VER) && !defined(__clang__)
516 | # define C_DIALECT "90"
517 | # else
518 | # define C_DIALECT
519 | # endif
520 | #elif __STDC_VERSION__ >= 201000L
521 | # define C_DIALECT "11"
522 | #elif __STDC_VERSION__ >= 199901L
523 | # define C_DIALECT "99"
524 | #else
525 | # define C_DIALECT "90"
526 | #endif
527 | const char* info_language_dialect_default =
528 | "INFO" ":" "dialect_default[" C_DIALECT "]";
529 |
530 | /*--------------------------------------------------------------------------*/
531 |
532 | #ifdef ID_VOID_MAIN
533 | void main() {}
534 | #else
535 | # if defined(__CLASSIC_C__)
536 | int main(argc, argv) int argc; char *argv[];
537 | # else
538 | int main(int argc, char* argv[])
539 | # endif
540 | {
541 | int require = 0;
542 | require += info_compiler[argc];
543 | require += info_platform[argc];
544 | require += info_arch[argc];
545 | #ifdef COMPILER_VERSION_MAJOR
546 | require += info_version[argc];
547 | #endif
548 | #ifdef SIMULATE_ID
549 | require += info_simulate[argc];
550 | #endif
551 | #ifdef SIMULATE_VERSION_MAJOR
552 | require += info_simulate_version[argc];
553 | #endif
554 | #if defined(__CRAYXE) || defined(__CRAYXC)
555 | require += info_cray[argc];
556 | #endif
557 | require += info_language_dialect_default[argc];
558 | (void)argv;
559 | return require;
560 | }
561 | #endif
562 |
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/3.6.2/CompilerIdC/a.out:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/DynCount/CMakeFiles/3.6.2/CompilerIdC/a.out
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/3.6.2/CompilerIdCXX/CMakeCXXCompilerId.cpp:
--------------------------------------------------------------------------------
1 | /* This source file must have a .cpp extension so that all C++ compilers
2 | recognize the extension without flags. Borland does not know .cxx for
3 | example. */
4 | #ifndef __cplusplus
5 | # error "A C compiler has been selected for C++."
6 | #endif
7 |
8 |
9 | /* Version number components: V=Version, R=Revision, P=Patch
10 | Version date components: YYYY=Year, MM=Month, DD=Day */
11 |
12 | #if defined(__COMO__)
13 | # define COMPILER_ID "Comeau"
14 | /* __COMO_VERSION__ = VRR */
15 | # define COMPILER_VERSION_MAJOR DEC(__COMO_VERSION__ / 100)
16 | # define COMPILER_VERSION_MINOR DEC(__COMO_VERSION__ % 100)
17 |
18 | #elif defined(__INTEL_COMPILER) || defined(__ICC)
19 | # define COMPILER_ID "Intel"
20 | # if defined(_MSC_VER)
21 | # define SIMULATE_ID "MSVC"
22 | # endif
23 | /* __INTEL_COMPILER = VRP */
24 | # define COMPILER_VERSION_MAJOR DEC(__INTEL_COMPILER/100)
25 | # define COMPILER_VERSION_MINOR DEC(__INTEL_COMPILER/10 % 10)
26 | # if defined(__INTEL_COMPILER_UPDATE)
27 | # define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER_UPDATE)
28 | # else
29 | # define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER % 10)
30 | # endif
31 | # if defined(__INTEL_COMPILER_BUILD_DATE)
32 | /* __INTEL_COMPILER_BUILD_DATE = YYYYMMDD */
33 | # define COMPILER_VERSION_TWEAK DEC(__INTEL_COMPILER_BUILD_DATE)
34 | # endif
35 | # if defined(_MSC_VER)
36 | /* _MSC_VER = VVRR */
37 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
38 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
39 | # endif
40 |
41 | #elif defined(__PATHCC__)
42 | # define COMPILER_ID "PathScale"
43 | # define COMPILER_VERSION_MAJOR DEC(__PATHCC__)
44 | # define COMPILER_VERSION_MINOR DEC(__PATHCC_MINOR__)
45 | # if defined(__PATHCC_PATCHLEVEL__)
46 | # define COMPILER_VERSION_PATCH DEC(__PATHCC_PATCHLEVEL__)
47 | # endif
48 |
49 | #elif defined(__BORLANDC__) && defined(__CODEGEARC_VERSION__)
50 | # define COMPILER_ID "Embarcadero"
51 | # define COMPILER_VERSION_MAJOR HEX(__CODEGEARC_VERSION__>>24 & 0x00FF)
52 | # define COMPILER_VERSION_MINOR HEX(__CODEGEARC_VERSION__>>16 & 0x00FF)
53 | # define COMPILER_VERSION_PATCH DEC(__CODEGEARC_VERSION__ & 0xFFFF)
54 |
55 | #elif defined(__BORLANDC__)
56 | # define COMPILER_ID "Borland"
57 | /* __BORLANDC__ = 0xVRR */
58 | # define COMPILER_VERSION_MAJOR HEX(__BORLANDC__>>8)
59 | # define COMPILER_VERSION_MINOR HEX(__BORLANDC__ & 0xFF)
60 |
61 | #elif defined(__WATCOMC__) && __WATCOMC__ < 1200
62 | # define COMPILER_ID "Watcom"
63 | /* __WATCOMC__ = VVRR */
64 | # define COMPILER_VERSION_MAJOR DEC(__WATCOMC__ / 100)
65 | # define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
66 | # if (__WATCOMC__ % 10) > 0
67 | # define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
68 | # endif
69 |
70 | #elif defined(__WATCOMC__)
71 | # define COMPILER_ID "OpenWatcom"
72 | /* __WATCOMC__ = VVRP + 1100 */
73 | # define COMPILER_VERSION_MAJOR DEC((__WATCOMC__ - 1100) / 100)
74 | # define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
75 | # if (__WATCOMC__ % 10) > 0
76 | # define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
77 | # endif
78 |
79 | #elif defined(__SUNPRO_CC)
80 | # define COMPILER_ID "SunPro"
81 | # if __SUNPRO_CC >= 0x5100
82 | /* __SUNPRO_CC = 0xVRRP */
83 | # define COMPILER_VERSION_MAJOR HEX(__SUNPRO_CC>>12)
84 | # define COMPILER_VERSION_MINOR HEX(__SUNPRO_CC>>4 & 0xFF)
85 | # define COMPILER_VERSION_PATCH HEX(__SUNPRO_CC & 0xF)
86 | # else
87 | /* __SUNPRO_CC = 0xVRP */
88 | # define COMPILER_VERSION_MAJOR HEX(__SUNPRO_CC>>8)
89 | # define COMPILER_VERSION_MINOR HEX(__SUNPRO_CC>>4 & 0xF)
90 | # define COMPILER_VERSION_PATCH HEX(__SUNPRO_CC & 0xF)
91 | # endif
92 |
93 | #elif defined(__HP_aCC)
94 | # define COMPILER_ID "HP"
95 | /* __HP_aCC = VVRRPP */
96 | # define COMPILER_VERSION_MAJOR DEC(__HP_aCC/10000)
97 | # define COMPILER_VERSION_MINOR DEC(__HP_aCC/100 % 100)
98 | # define COMPILER_VERSION_PATCH DEC(__HP_aCC % 100)
99 |
100 | #elif defined(__DECCXX)
101 | # define COMPILER_ID "Compaq"
102 | /* __DECCXX_VER = VVRRTPPPP */
103 | # define COMPILER_VERSION_MAJOR DEC(__DECCXX_VER/10000000)
104 | # define COMPILER_VERSION_MINOR DEC(__DECCXX_VER/100000 % 100)
105 | # define COMPILER_VERSION_PATCH DEC(__DECCXX_VER % 10000)
106 |
107 | #elif defined(__IBMCPP__) && defined(__COMPILER_VER__)
108 | # define COMPILER_ID "zOS"
109 | /* __IBMCPP__ = VRP */
110 | # define COMPILER_VERSION_MAJOR DEC(__IBMCPP__/100)
111 | # define COMPILER_VERSION_MINOR DEC(__IBMCPP__/10 % 10)
112 | # define COMPILER_VERSION_PATCH DEC(__IBMCPP__ % 10)
113 |
114 | #elif defined(__IBMCPP__) && !defined(__COMPILER_VER__) && __IBMCPP__ >= 800
115 | # define COMPILER_ID "XL"
116 | /* __IBMCPP__ = VRP */
117 | # define COMPILER_VERSION_MAJOR DEC(__IBMCPP__/100)
118 | # define COMPILER_VERSION_MINOR DEC(__IBMCPP__/10 % 10)
119 | # define COMPILER_VERSION_PATCH DEC(__IBMCPP__ % 10)
120 |
121 | #elif defined(__IBMCPP__) && !defined(__COMPILER_VER__) && __IBMCPP__ < 800
122 | # define COMPILER_ID "VisualAge"
123 | /* __IBMCPP__ = VRP */
124 | # define COMPILER_VERSION_MAJOR DEC(__IBMCPP__/100)
125 | # define COMPILER_VERSION_MINOR DEC(__IBMCPP__/10 % 10)
126 | # define COMPILER_VERSION_PATCH DEC(__IBMCPP__ % 10)
127 |
128 | #elif defined(__PGI)
129 | # define COMPILER_ID "PGI"
130 | # define COMPILER_VERSION_MAJOR DEC(__PGIC__)
131 | # define COMPILER_VERSION_MINOR DEC(__PGIC_MINOR__)
132 | # if defined(__PGIC_PATCHLEVEL__)
133 | # define COMPILER_VERSION_PATCH DEC(__PGIC_PATCHLEVEL__)
134 | # endif
135 |
136 | #elif defined(_CRAYC)
137 | # define COMPILER_ID "Cray"
138 | # define COMPILER_VERSION_MAJOR DEC(_RELEASE_MAJOR)
139 | # define COMPILER_VERSION_MINOR DEC(_RELEASE_MINOR)
140 |
141 | #elif defined(__TI_COMPILER_VERSION__)
142 | # define COMPILER_ID "TI"
143 | /* __TI_COMPILER_VERSION__ = VVVRRRPPP */
144 | # define COMPILER_VERSION_MAJOR DEC(__TI_COMPILER_VERSION__/1000000)
145 | # define COMPILER_VERSION_MINOR DEC(__TI_COMPILER_VERSION__/1000 % 1000)
146 | # define COMPILER_VERSION_PATCH DEC(__TI_COMPILER_VERSION__ % 1000)
147 |
148 | #elif defined(__FUJITSU) || defined(__FCC_VERSION) || defined(__fcc_version)
149 | # define COMPILER_ID "Fujitsu"
150 |
151 | #elif defined(__SCO_VERSION__)
152 | # define COMPILER_ID "SCO"
153 |
154 | #elif defined(__clang__) && defined(__apple_build_version__)
155 | # define COMPILER_ID "AppleClang"
156 | # if defined(_MSC_VER)
157 | # define SIMULATE_ID "MSVC"
158 | # endif
159 | # define COMPILER_VERSION_MAJOR DEC(__clang_major__)
160 | # define COMPILER_VERSION_MINOR DEC(__clang_minor__)
161 | # define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
162 | # if defined(_MSC_VER)
163 | /* _MSC_VER = VVRR */
164 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
165 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
166 | # endif
167 | # define COMPILER_VERSION_TWEAK DEC(__apple_build_version__)
168 |
169 | #elif defined(__clang__)
170 | # define COMPILER_ID "Clang"
171 | # if defined(_MSC_VER)
172 | # define SIMULATE_ID "MSVC"
173 | # endif
174 | # define COMPILER_VERSION_MAJOR DEC(__clang_major__)
175 | # define COMPILER_VERSION_MINOR DEC(__clang_minor__)
176 | # define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
177 | # if defined(_MSC_VER)
178 | /* _MSC_VER = VVRR */
179 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
180 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
181 | # endif
182 |
183 | #elif defined(__GNUC__)
184 | # define COMPILER_ID "GNU"
185 | # define COMPILER_VERSION_MAJOR DEC(__GNUC__)
186 | # if defined(__GNUC_MINOR__)
187 | # define COMPILER_VERSION_MINOR DEC(__GNUC_MINOR__)
188 | # endif
189 | # if defined(__GNUC_PATCHLEVEL__)
190 | # define COMPILER_VERSION_PATCH DEC(__GNUC_PATCHLEVEL__)
191 | # endif
192 |
193 | #elif defined(_MSC_VER)
194 | # define COMPILER_ID "MSVC"
195 | /* _MSC_VER = VVRR */
196 | # define COMPILER_VERSION_MAJOR DEC(_MSC_VER / 100)
197 | # define COMPILER_VERSION_MINOR DEC(_MSC_VER % 100)
198 | # if defined(_MSC_FULL_VER)
199 | # if _MSC_VER >= 1400
200 | /* _MSC_FULL_VER = VVRRPPPPP */
201 | # define COMPILER_VERSION_PATCH DEC(_MSC_FULL_VER % 100000)
202 | # else
203 | /* _MSC_FULL_VER = VVRRPPPP */
204 | # define COMPILER_VERSION_PATCH DEC(_MSC_FULL_VER % 10000)
205 | # endif
206 | # endif
207 | # if defined(_MSC_BUILD)
208 | # define COMPILER_VERSION_TWEAK DEC(_MSC_BUILD)
209 | # endif
210 |
211 | #elif defined(__VISUALDSPVERSION__) || defined(__ADSPBLACKFIN__) || defined(__ADSPTS__) || defined(__ADSP21000__)
212 | # define COMPILER_ID "ADSP"
213 | #if defined(__VISUALDSPVERSION__)
214 | /* __VISUALDSPVERSION__ = 0xVVRRPP00 */
215 | # define COMPILER_VERSION_MAJOR HEX(__VISUALDSPVERSION__>>24)
216 | # define COMPILER_VERSION_MINOR HEX(__VISUALDSPVERSION__>>16 & 0xFF)
217 | # define COMPILER_VERSION_PATCH HEX(__VISUALDSPVERSION__>>8 & 0xFF)
218 | #endif
219 |
220 | #elif defined(__IAR_SYSTEMS_ICC__ ) || defined(__IAR_SYSTEMS_ICC)
221 | # define COMPILER_ID "IAR"
222 |
223 | #elif defined(__ARMCC_VERSION)
224 | # define COMPILER_ID "ARMCC"
225 | #if __ARMCC_VERSION >= 1000000
226 | /* __ARMCC_VERSION = VRRPPPP */
227 | # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/1000000)
228 | # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 100)
229 | # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
230 | #else
231 | /* __ARMCC_VERSION = VRPPPP */
232 | # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/100000)
233 | # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 10)
234 | # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
235 | #endif
236 |
237 |
238 | #elif defined(_SGI_COMPILER_VERSION) || defined(_COMPILER_VERSION)
239 | # define COMPILER_ID "MIPSpro"
240 | # if defined(_SGI_COMPILER_VERSION)
241 | /* _SGI_COMPILER_VERSION = VRP */
242 | # define COMPILER_VERSION_MAJOR DEC(_SGI_COMPILER_VERSION/100)
243 | # define COMPILER_VERSION_MINOR DEC(_SGI_COMPILER_VERSION/10 % 10)
244 | # define COMPILER_VERSION_PATCH DEC(_SGI_COMPILER_VERSION % 10)
245 | # else
246 | /* _COMPILER_VERSION = VRP */
247 | # define COMPILER_VERSION_MAJOR DEC(_COMPILER_VERSION/100)
248 | # define COMPILER_VERSION_MINOR DEC(_COMPILER_VERSION/10 % 10)
249 | # define COMPILER_VERSION_PATCH DEC(_COMPILER_VERSION % 10)
250 | # endif
251 |
252 |
253 | /* These compilers are either not known or too old to define an
254 | identification macro. Try to identify the platform and guess that
255 | it is the native compiler. */
256 | #elif defined(__sgi)
257 | # define COMPILER_ID "MIPSpro"
258 |
259 | #elif defined(__hpux) || defined(__hpua)
260 | # define COMPILER_ID "HP"
261 |
262 | #else /* unknown compiler */
263 | # define COMPILER_ID ""
264 | #endif
265 |
266 | /* Construct the string literal in pieces to prevent the source from
267 | getting matched. Store it in a pointer rather than an array
268 | because some compilers will just produce instructions to fill the
269 | array rather than assigning a pointer to a static array. */
270 | char const* info_compiler = "INFO" ":" "compiler[" COMPILER_ID "]";
271 | #ifdef SIMULATE_ID
272 | char const* info_simulate = "INFO" ":" "simulate[" SIMULATE_ID "]";
273 | #endif
274 |
275 | #ifdef __QNXNTO__
276 | char const* qnxnto = "INFO" ":" "qnxnto[]";
277 | #endif
278 |
279 | #if defined(__CRAYXE) || defined(__CRAYXC)
280 | char const *info_cray = "INFO" ":" "compiler_wrapper[CrayPrgEnv]";
281 | #endif
282 |
283 | #define STRINGIFY_HELPER(X) #X
284 | #define STRINGIFY(X) STRINGIFY_HELPER(X)
285 |
286 | /* Identify known platforms by name. */
287 | #if defined(__linux) || defined(__linux__) || defined(linux)
288 | # define PLATFORM_ID "Linux"
289 |
290 | #elif defined(__CYGWIN__)
291 | # define PLATFORM_ID "Cygwin"
292 |
293 | #elif defined(__MINGW32__)
294 | # define PLATFORM_ID "MinGW"
295 |
296 | #elif defined(__APPLE__)
297 | # define PLATFORM_ID "Darwin"
298 |
299 | #elif defined(_WIN32) || defined(__WIN32__) || defined(WIN32)
300 | # define PLATFORM_ID "Windows"
301 |
302 | #elif defined(__FreeBSD__) || defined(__FreeBSD)
303 | # define PLATFORM_ID "FreeBSD"
304 |
305 | #elif defined(__NetBSD__) || defined(__NetBSD)
306 | # define PLATFORM_ID "NetBSD"
307 |
308 | #elif defined(__OpenBSD__) || defined(__OPENBSD)
309 | # define PLATFORM_ID "OpenBSD"
310 |
311 | #elif defined(__sun) || defined(sun)
312 | # define PLATFORM_ID "SunOS"
313 |
314 | #elif defined(_AIX) || defined(__AIX) || defined(__AIX__) || defined(__aix) || defined(__aix__)
315 | # define PLATFORM_ID "AIX"
316 |
317 | #elif defined(__sgi) || defined(__sgi__) || defined(_SGI)
318 | # define PLATFORM_ID "IRIX"
319 |
320 | #elif defined(__hpux) || defined(__hpux__)
321 | # define PLATFORM_ID "HP-UX"
322 |
323 | #elif defined(__HAIKU__)
324 | # define PLATFORM_ID "Haiku"
325 |
326 | #elif defined(__BeOS) || defined(__BEOS__) || defined(_BEOS)
327 | # define PLATFORM_ID "BeOS"
328 |
329 | #elif defined(__QNX__) || defined(__QNXNTO__)
330 | # define PLATFORM_ID "QNX"
331 |
332 | #elif defined(__tru64) || defined(_tru64) || defined(__TRU64__)
333 | # define PLATFORM_ID "Tru64"
334 |
335 | #elif defined(__riscos) || defined(__riscos__)
336 | # define PLATFORM_ID "RISCos"
337 |
338 | #elif defined(__sinix) || defined(__sinix__) || defined(__SINIX__)
339 | # define PLATFORM_ID "SINIX"
340 |
341 | #elif defined(__UNIX_SV__)
342 | # define PLATFORM_ID "UNIX_SV"
343 |
344 | #elif defined(__bsdos__)
345 | # define PLATFORM_ID "BSDOS"
346 |
347 | #elif defined(_MPRAS) || defined(MPRAS)
348 | # define PLATFORM_ID "MP-RAS"
349 |
350 | #elif defined(__osf) || defined(__osf__)
351 | # define PLATFORM_ID "OSF1"
352 |
353 | #elif defined(_SCO_SV) || defined(SCO_SV) || defined(sco_sv)
354 | # define PLATFORM_ID "SCO_SV"
355 |
356 | #elif defined(__ultrix) || defined(__ultrix__) || defined(_ULTRIX)
357 | # define PLATFORM_ID "ULTRIX"
358 |
359 | #elif defined(__XENIX__) || defined(_XENIX) || defined(XENIX)
360 | # define PLATFORM_ID "Xenix"
361 |
362 | #elif defined(__WATCOMC__)
363 | # if defined(__LINUX__)
364 | # define PLATFORM_ID "Linux"
365 |
366 | # elif defined(__DOS__)
367 | # define PLATFORM_ID "DOS"
368 |
369 | # elif defined(__OS2__)
370 | # define PLATFORM_ID "OS2"
371 |
372 | # elif defined(__WINDOWS__)
373 | # define PLATFORM_ID "Windows3x"
374 |
375 | # else /* unknown platform */
376 | # define PLATFORM_ID
377 | # endif
378 |
379 | #else /* unknown platform */
380 | # define PLATFORM_ID
381 |
382 | #endif
383 |
384 | /* For windows compilers MSVC and Intel we can determine
385 | the architecture of the compiler being used. This is because
386 | the compilers do not have flags that can change the architecture,
387 | but rather depend on which compiler is being used
388 | */
389 | #if defined(_WIN32) && defined(_MSC_VER)
390 | # if defined(_M_IA64)
391 | # define ARCHITECTURE_ID "IA64"
392 |
393 | # elif defined(_M_X64) || defined(_M_AMD64)
394 | # define ARCHITECTURE_ID "x64"
395 |
396 | # elif defined(_M_IX86)
397 | # define ARCHITECTURE_ID "X86"
398 |
399 | # elif defined(_M_ARM)
400 | # if _M_ARM == 4
401 | # define ARCHITECTURE_ID "ARMV4I"
402 | # elif _M_ARM == 5
403 | # define ARCHITECTURE_ID "ARMV5I"
404 | # else
405 | # define ARCHITECTURE_ID "ARMV" STRINGIFY(_M_ARM)
406 | # endif
407 |
408 | # elif defined(_M_MIPS)
409 | # define ARCHITECTURE_ID "MIPS"
410 |
411 | # elif defined(_M_SH)
412 | # define ARCHITECTURE_ID "SHx"
413 |
414 | # else /* unknown architecture */
415 | # define ARCHITECTURE_ID ""
416 | # endif
417 |
418 | #elif defined(__WATCOMC__)
419 | # if defined(_M_I86)
420 | # define ARCHITECTURE_ID "I86"
421 |
422 | # elif defined(_M_IX86)
423 | # define ARCHITECTURE_ID "X86"
424 |
425 | # else /* unknown architecture */
426 | # define ARCHITECTURE_ID ""
427 | # endif
428 |
429 | #else
430 | # define ARCHITECTURE_ID
431 | #endif
432 |
433 | /* Convert integer to decimal digit literals. */
434 | #define DEC(n) \
435 | ('0' + (((n) / 10000000)%10)), \
436 | ('0' + (((n) / 1000000)%10)), \
437 | ('0' + (((n) / 100000)%10)), \
438 | ('0' + (((n) / 10000)%10)), \
439 | ('0' + (((n) / 1000)%10)), \
440 | ('0' + (((n) / 100)%10)), \
441 | ('0' + (((n) / 10)%10)), \
442 | ('0' + ((n) % 10))
443 |
444 | /* Convert integer to hex digit literals. */
445 | #define HEX(n) \
446 | ('0' + ((n)>>28 & 0xF)), \
447 | ('0' + ((n)>>24 & 0xF)), \
448 | ('0' + ((n)>>20 & 0xF)), \
449 | ('0' + ((n)>>16 & 0xF)), \
450 | ('0' + ((n)>>12 & 0xF)), \
451 | ('0' + ((n)>>8 & 0xF)), \
452 | ('0' + ((n)>>4 & 0xF)), \
453 | ('0' + ((n) & 0xF))
454 |
455 | /* Construct a string literal encoding the version number components. */
456 | #ifdef COMPILER_VERSION_MAJOR
457 | char const info_version[] = {
458 | 'I', 'N', 'F', 'O', ':',
459 | 'c','o','m','p','i','l','e','r','_','v','e','r','s','i','o','n','[',
460 | COMPILER_VERSION_MAJOR,
461 | # ifdef COMPILER_VERSION_MINOR
462 | '.', COMPILER_VERSION_MINOR,
463 | # ifdef COMPILER_VERSION_PATCH
464 | '.', COMPILER_VERSION_PATCH,
465 | # ifdef COMPILER_VERSION_TWEAK
466 | '.', COMPILER_VERSION_TWEAK,
467 | # endif
468 | # endif
469 | # endif
470 | ']','\0'};
471 | #endif
472 |
473 | /* Construct a string literal encoding the version number components. */
474 | #ifdef SIMULATE_VERSION_MAJOR
475 | char const info_simulate_version[] = {
476 | 'I', 'N', 'F', 'O', ':',
477 | 's','i','m','u','l','a','t','e','_','v','e','r','s','i','o','n','[',
478 | SIMULATE_VERSION_MAJOR,
479 | # ifdef SIMULATE_VERSION_MINOR
480 | '.', SIMULATE_VERSION_MINOR,
481 | # ifdef SIMULATE_VERSION_PATCH
482 | '.', SIMULATE_VERSION_PATCH,
483 | # ifdef SIMULATE_VERSION_TWEAK
484 | '.', SIMULATE_VERSION_TWEAK,
485 | # endif
486 | # endif
487 | # endif
488 | ']','\0'};
489 | #endif
490 |
491 | /* Construct the string literal in pieces to prevent the source from
492 | getting matched. Store it in a pointer rather than an array
493 | because some compilers will just produce instructions to fill the
494 | array rather than assigning a pointer to a static array. */
495 | char const* info_platform = "INFO" ":" "platform[" PLATFORM_ID "]";
496 | char const* info_arch = "INFO" ":" "arch[" ARCHITECTURE_ID "]";
497 |
498 |
499 |
500 |
501 | const char* info_language_dialect_default = "INFO" ":" "dialect_default["
502 | #if __cplusplus >= 201402L
503 | "14"
504 | #elif __cplusplus >= 201103L
505 | "11"
506 | #else
507 | "98"
508 | #endif
509 | "]";
510 |
511 | /*--------------------------------------------------------------------------*/
512 |
513 | int main(int argc, char* argv[])
514 | {
515 | int require = 0;
516 | require += info_compiler[argc];
517 | require += info_platform[argc];
518 | #ifdef COMPILER_VERSION_MAJOR
519 | require += info_version[argc];
520 | #endif
521 | #ifdef SIMULATE_ID
522 | require += info_simulate[argc];
523 | #endif
524 | #ifdef SIMULATE_VERSION_MAJOR
525 | require += info_simulate_version[argc];
526 | #endif
527 | #if defined(__CRAYXE) || defined(__CRAYXC)
528 | require += info_cray[argc];
529 | #endif
530 | require += info_language_dialect_default[argc];
531 | (void)argv;
532 | return require;
533 | }
534 |
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/3.6.2/CompilerIdCXX/a.out:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/DynCount/CMakeFiles/3.6.2/CompilerIdCXX/a.out
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/cmake.check_cache:
--------------------------------------------------------------------------------
1 | # This file is generated by cmake for dependency checking of the CMakeCache.txt file
2 |
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/feature_tests.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/DynCount/CMakeFiles/feature_tests.bin
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/feature_tests.c:
--------------------------------------------------------------------------------
1 |
2 | const char features[] = {"\n"
3 | "C_FEATURE:"
4 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400
5 | "1"
6 | #else
7 | "0"
8 | #endif
9 | "c_function_prototypes\n"
10 | "C_FEATURE:"
11 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
12 | "1"
13 | #else
14 | "0"
15 | #endif
16 | "c_restrict\n"
17 | "C_FEATURE:"
18 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L
19 | "1"
20 | #else
21 | "0"
22 | #endif
23 | "c_static_assert\n"
24 | "C_FEATURE:"
25 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
26 | "1"
27 | #else
28 | "0"
29 | #endif
30 | "c_variadic_macros\n"
31 |
32 | };
33 |
34 | int main(int argc, char** argv) { (void)argv; return features[argc]; }
35 |
--------------------------------------------------------------------------------
/DynCount/CMakeFiles/feature_tests.cxx:
--------------------------------------------------------------------------------
1 |
2 | const char features[] = {"\n"
3 | "CXX_FEATURE:"
4 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_aggregate_nsdmi)
5 | "1"
6 | #else
7 | "0"
8 | #endif
9 | "cxx_aggregate_default_initializers\n"
10 | "CXX_FEATURE:"
11 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_alias_templates)
12 | "1"
13 | #else
14 | "0"
15 | #endif
16 | "cxx_alias_templates\n"
17 | "CXX_FEATURE:"
18 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_alignas)
19 | "1"
20 | #else
21 | "0"
22 | #endif
23 | "cxx_alignas\n"
24 | "CXX_FEATURE:"
25 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_alignas)
26 | "1"
27 | #else
28 | "0"
29 | #endif
30 | "cxx_alignof\n"
31 | "CXX_FEATURE:"
32 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_attributes)
33 | "1"
34 | #else
35 | "0"
36 | #endif
37 | "cxx_attributes\n"
38 | "CXX_FEATURE:"
39 | #if ((__clang_major__ * 100) + __clang_minor__) >= 501 && __cplusplus > 201103L
40 | "1"
41 | #else
42 | "0"
43 | #endif
44 | "cxx_attribute_deprecated\n"
45 | "CXX_FEATURE:"
46 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_auto_type)
47 | "1"
48 | #else
49 | "0"
50 | #endif
51 | "cxx_auto_type\n"
52 | "CXX_FEATURE:"
53 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_binary_literals)
54 | "1"
55 | #else
56 | "0"
57 | #endif
58 | "cxx_binary_literals\n"
59 | "CXX_FEATURE:"
60 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_constexpr)
61 | "1"
62 | #else
63 | "0"
64 | #endif
65 | "cxx_constexpr\n"
66 | "CXX_FEATURE:"
67 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_contextual_conversions)
68 | "1"
69 | #else
70 | "0"
71 | #endif
72 | "cxx_contextual_conversions\n"
73 | "CXX_FEATURE:"
74 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_decltype)
75 | "1"
76 | #else
77 | "0"
78 | #endif
79 | "cxx_decltype\n"
80 | "CXX_FEATURE:"
81 | #if ((__clang_major__ * 100) + __clang_minor__) >= 501 && __cplusplus > 201103L
82 | "1"
83 | #else
84 | "0"
85 | #endif
86 | "cxx_decltype_auto\n"
87 | "CXX_FEATURE:"
88 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_decltype_incomplete_return_types)
89 | "1"
90 | #else
91 | "0"
92 | #endif
93 | "cxx_decltype_incomplete_return_types\n"
94 | "CXX_FEATURE:"
95 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_default_function_template_args)
96 | "1"
97 | #else
98 | "0"
99 | #endif
100 | "cxx_default_function_template_args\n"
101 | "CXX_FEATURE:"
102 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_defaulted_functions)
103 | "1"
104 | #else
105 | "0"
106 | #endif
107 | "cxx_defaulted_functions\n"
108 | "CXX_FEATURE:"
109 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_defaulted_functions)
110 | "1"
111 | #else
112 | "0"
113 | #endif
114 | "cxx_defaulted_move_initializers\n"
115 | "CXX_FEATURE:"
116 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_delegating_constructors)
117 | "1"
118 | #else
119 | "0"
120 | #endif
121 | "cxx_delegating_constructors\n"
122 | "CXX_FEATURE:"
123 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_deleted_functions)
124 | "1"
125 | #else
126 | "0"
127 | #endif
128 | "cxx_deleted_functions\n"
129 | "CXX_FEATURE:"
130 | #if ((__clang_major__ * 100) + __clang_minor__) >= 501 && __cplusplus > 201103L
131 | "1"
132 | #else
133 | "0"
134 | #endif
135 | "cxx_digit_separators\n"
136 | "CXX_FEATURE:"
137 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
138 | "1"
139 | #else
140 | "0"
141 | #endif
142 | "cxx_enum_forward_declarations\n"
143 | "CXX_FEATURE:"
144 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_explicit_conversions)
145 | "1"
146 | #else
147 | "0"
148 | #endif
149 | "cxx_explicit_conversions\n"
150 | "CXX_FEATURE:"
151 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
152 | "1"
153 | #else
154 | "0"
155 | #endif
156 | "cxx_extended_friend_declarations\n"
157 | "CXX_FEATURE:"
158 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
159 | "1"
160 | #else
161 | "0"
162 | #endif
163 | "cxx_extern_templates\n"
164 | "CXX_FEATURE:"
165 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_override_control)
166 | "1"
167 | #else
168 | "0"
169 | #endif
170 | "cxx_final\n"
171 | "CXX_FEATURE:"
172 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
173 | "1"
174 | #else
175 | "0"
176 | #endif
177 | "cxx_func_identifier\n"
178 | "CXX_FEATURE:"
179 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_generalized_initializers)
180 | "1"
181 | #else
182 | "0"
183 | #endif
184 | "cxx_generalized_initializers\n"
185 | "CXX_FEATURE:"
186 | #if ((__clang_major__ * 100) + __clang_minor__) >= 501 && __cplusplus > 201103L
187 | "1"
188 | #else
189 | "0"
190 | #endif
191 | "cxx_generic_lambdas\n"
192 | "CXX_FEATURE:"
193 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_inheriting_constructors)
194 | "1"
195 | #else
196 | "0"
197 | #endif
198 | "cxx_inheriting_constructors\n"
199 | "CXX_FEATURE:"
200 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
201 | "1"
202 | #else
203 | "0"
204 | #endif
205 | "cxx_inline_namespaces\n"
206 | "CXX_FEATURE:"
207 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_lambdas)
208 | "1"
209 | #else
210 | "0"
211 | #endif
212 | "cxx_lambdas\n"
213 | "CXX_FEATURE:"
214 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_init_captures)
215 | "1"
216 | #else
217 | "0"
218 | #endif
219 | "cxx_lambda_init_captures\n"
220 | "CXX_FEATURE:"
221 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_local_type_template_args)
222 | "1"
223 | #else
224 | "0"
225 | #endif
226 | "cxx_local_type_template_args\n"
227 | "CXX_FEATURE:"
228 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
229 | "1"
230 | #else
231 | "0"
232 | #endif
233 | "cxx_long_long_type\n"
234 | "CXX_FEATURE:"
235 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_noexcept)
236 | "1"
237 | #else
238 | "0"
239 | #endif
240 | "cxx_noexcept\n"
241 | "CXX_FEATURE:"
242 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_nonstatic_member_init)
243 | "1"
244 | #else
245 | "0"
246 | #endif
247 | "cxx_nonstatic_member_init\n"
248 | "CXX_FEATURE:"
249 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_nullptr)
250 | "1"
251 | #else
252 | "0"
253 | #endif
254 | "cxx_nullptr\n"
255 | "CXX_FEATURE:"
256 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_override_control)
257 | "1"
258 | #else
259 | "0"
260 | #endif
261 | "cxx_override\n"
262 | "CXX_FEATURE:"
263 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_range_for)
264 | "1"
265 | #else
266 | "0"
267 | #endif
268 | "cxx_range_for\n"
269 | "CXX_FEATURE:"
270 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_raw_string_literals)
271 | "1"
272 | #else
273 | "0"
274 | #endif
275 | "cxx_raw_string_literals\n"
276 | "CXX_FEATURE:"
277 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_reference_qualified_functions)
278 | "1"
279 | #else
280 | "0"
281 | #endif
282 | "cxx_reference_qualified_functions\n"
283 | "CXX_FEATURE:"
284 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_relaxed_constexpr)
285 | "1"
286 | #else
287 | "0"
288 | #endif
289 | "cxx_relaxed_constexpr\n"
290 | "CXX_FEATURE:"
291 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_return_type_deduction)
292 | "1"
293 | #else
294 | "0"
295 | #endif
296 | "cxx_return_type_deduction\n"
297 | "CXX_FEATURE:"
298 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
299 | "1"
300 | #else
301 | "0"
302 | #endif
303 | "cxx_right_angle_brackets\n"
304 | "CXX_FEATURE:"
305 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_rvalue_references)
306 | "1"
307 | #else
308 | "0"
309 | #endif
310 | "cxx_rvalue_references\n"
311 | "CXX_FEATURE:"
312 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
313 | "1"
314 | #else
315 | "0"
316 | #endif
317 | "cxx_sizeof_member\n"
318 | "CXX_FEATURE:"
319 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_static_assert)
320 | "1"
321 | #else
322 | "0"
323 | #endif
324 | "cxx_static_assert\n"
325 | "CXX_FEATURE:"
326 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_strong_enums)
327 | "1"
328 | #else
329 | "0"
330 | #endif
331 | "cxx_strong_enums\n"
332 | "CXX_FEATURE:"
333 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 199711L
334 | "1"
335 | #else
336 | "0"
337 | #endif
338 | "cxx_template_template_parameters\n"
339 | "CXX_FEATURE:"
340 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_thread_local)
341 | "1"
342 | #else
343 | "0"
344 | #endif
345 | "cxx_thread_local\n"
346 | "CXX_FEATURE:"
347 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_trailing_return)
348 | "1"
349 | #else
350 | "0"
351 | #endif
352 | "cxx_trailing_return_types\n"
353 | "CXX_FEATURE:"
354 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_unicode_literals)
355 | "1"
356 | #else
357 | "0"
358 | #endif
359 | "cxx_unicode_literals\n"
360 | "CXX_FEATURE:"
361 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_generalized_initializers)
362 | "1"
363 | #else
364 | "0"
365 | #endif
366 | "cxx_uniform_initialization\n"
367 | "CXX_FEATURE:"
368 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_unrestricted_unions)
369 | "1"
370 | #else
371 | "0"
372 | #endif
373 | "cxx_unrestricted_unions\n"
374 | "CXX_FEATURE:"
375 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_user_literals)
376 | "1"
377 | #else
378 | "0"
379 | #endif
380 | "cxx_user_literals\n"
381 | "CXX_FEATURE:"
382 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_variable_templates)
383 | "1"
384 | #else
385 | "0"
386 | #endif
387 | "cxx_variable_templates\n"
388 | "CXX_FEATURE:"
389 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
390 | "1"
391 | #else
392 | "0"
393 | #endif
394 | "cxx_variadic_macros\n"
395 | "CXX_FEATURE:"
396 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_variadic_templates)
397 | "1"
398 | #else
399 | "0"
400 | #endif
401 | "cxx_variadic_templates\n"
402 |
403 | };
404 |
405 | int main(int argc, char** argv) { (void)argv; return features[argc]; }
406 |
--------------------------------------------------------------------------------
/DynCount/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | # If we don't need RTTI or EH, there's no reason to export anything
2 | # from the hello plugin.
3 | if( NOT LLVM_REQUIRES_RTTI )
4 | if( NOT LLVM_REQUIRES_EH )
5 | set(LLVM_EXPORTED_SYMBOL_FILE ${CMAKE_CURRENT_SOURCE_DIR}/DynCount.exports)
6 | endif()
7 | endif()
8 |
9 | if(WIN32 OR CYGWIN)
10 | set(LLVM_LINK_COMPONENTS Core Support)
11 | endif()
12 |
13 | add_llvm_loadable_module( LLVMDynCount
14 | DynCount.cpp
15 |
16 | DEPENDS
17 | intrinsics_gen
18 | PLUGIN_TOOL
19 | opt
20 | )
21 |
--------------------------------------------------------------------------------
/DynCount/DynCount.cpp:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | #define DEBUG_TYPE "Franklin's Dynamic Count"
6 |
7 | #include "llvm/Pass.h"
8 | #include "llvm/IR/Module.h"
9 | #include "llvm/IR/Function.h"
10 | #include "llvm/IR/BasicBlock.h"
11 | #include "llvm/ADT/Statistic.h"
12 | #include "llvm/IR/InstrTypes.h"
13 | #include "llvm/Transforms/IPO/PassManagerBuilder.h"
14 | #include "llvm/IR/IRBuilder.h"
15 | #include "llvm/Transforms/Utils/BasicBlockUtils.h"
16 | #include "llvm/IR/LegacyPassManager.h"
17 | #include "llvm/Support/raw_ostream.h"
18 |
19 |
20 | using namespace llvm;
21 | namespace {
22 |
23 | struct CountStats : public ModulePass {
24 | static char ID;
25 | CountStats() : ModulePass(ID) {}
26 | bool runOnModule(Module &M);
27 | bool runOnFunction(Function &F, Module &M);
28 | };
29 |
30 | }
31 |
32 | char CountStats::ID = 0;
33 |
34 | static RegisterPass
35 |
36 | X("DynCount", "Count Statistics", false, false);
37 |
38 | bool CountStats::runOnModule(Module &M) {
39 | for(Module::iterator F = M.begin(), E = M.end(); F != E; ++F) {
40 |
41 | runOnFunction(*F, M);
42 | }
43 | return false;
44 | }
45 |
46 |
47 | bool CountStats::runOnFunction(Function &F, Module &M) {
48 |
49 | LLVMContext &Context = F.getContext();
50 |
51 | Constant *BOLog = F.getParent()->getOrInsertFunction("BO", Type::getVoidTy(Context), NULL);
52 |
53 | Constant *allLog = F.getParent()->getOrInsertFunction("ALL", Type::getVoidTy(Context), NULL);
54 |
55 | Constant *branLog = F.getParent()->getOrInsertFunction("BRAN", Type::getVoidTy(Context), NULL);
56 |
57 | Constant *loadLog = F.getParent()->getOrInsertFunction("LOAD", Type::getVoidTy(Context), NULL);
58 |
59 | Constant *storeLog = F.getParent()->getOrInsertFunction("STORE", Type::getVoidTy(Context), NULL);
60 |
61 | Constant *callLog = F.getParent()->getOrInsertFunction("CALL", Type::getVoidTy(Context), NULL);
62 |
63 | Constant *instLog = F.getParent()->getOrInsertFunction("INST", Type::getVoidTy(Context), NULL);
64 |
65 |
66 | for (auto& B : F) {
67 | for (auto& I : B) {
68 |
69 | //errs().write_escaped(I.getOpcodeName()) << '\n';
70 | if (auto* cont = dyn_cast(&I)) {
71 |
72 | IRBuilder<> builder(cont);
73 | builder.SetInsertPoint(&B, ++builder.GetInsertPoint());
74 | builder.CreateCall(allLog);
75 |
76 |
77 |
78 |
79 |
80 | }else if (auto* cont = dyn_cast(&I)) {
81 |
82 | IRBuilder<> builder(cont);
83 | builder.SetInsertPoint(&B, ++builder.GetInsertPoint());
84 | builder.CreateCall(BOLog);
85 |
86 |
87 |
88 |
89 | } else if (auto* cont = dyn_cast(&I)) {
90 |
91 | IRBuilder<> builder(cont);
92 | builder.SetInsertPoint(&B, ++builder.GetInsertPoint());
93 | builder.CreateCall(storeLog);
94 |
95 |
96 | } else if (auto* cont = dyn_cast(&I)) {
97 |
98 | IRBuilder<> builder(cont);
99 | builder.SetInsertPoint(&B, ++builder.GetInsertPoint());
100 | builder.CreateCall(loadLog);
101 |
102 |
103 | } else if (auto* cont = dyn_cast(&I)) {
104 |
105 | IRBuilder<> builder(cont);
106 | builder.SetInsertPoint(&B, --builder.GetInsertPoint());
107 | builder.CreateCall(branLog);
108 |
109 |
110 | }
111 |
112 |
113 |
114 |
115 |
116 |
117 | }
118 | }
119 | return false;
120 | }
121 |
--------------------------------------------------------------------------------
/DynCount/DynCount.exports:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/DynCount/DynCount.exports
--------------------------------------------------------------------------------
/HeapTimeTestProgram/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/HeapTimeTestProgram/.DS_Store
--------------------------------------------------------------------------------
/HeapTimeTestProgram/.idea/misc.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/HeapTimeTestProgram/.idea/modules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/HeapTimeTestProgram/.idea/workspace.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
63 |
64 |
65 |
66 |
67 | true
68 | DEFINITION_ORDER
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 | 1480030595771
117 |
118 |
119 | 1480030595771
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
152 |
153 |
154 |
155 |
156 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 |
166 |
167 |
168 |
169 |
170 |
171 |
172 |
173 |
174 |
175 |
176 |
177 |
178 |
179 |
180 |
181 |
182 |
183 |
184 |
185 |
186 |
--------------------------------------------------------------------------------
/HeapTimeTestProgram/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.6)
2 | project(heaptime)
3 |
4 | set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
5 |
6 | set(SOURCE_FILES main.cpp)
7 | add_executable(heaptime ${SOURCE_FILES})
--------------------------------------------------------------------------------
/HeapTimeTestProgram/main.cpp:
--------------------------------------------------------------------------------
1 | //Assingment 13
2 | //Franklin Boswell
3 | //COMSC 210
4 |
5 | #include
6 | #include
7 | #include
8 | #include
9 | #include
10 |
11 | using namespace std;
12 |
13 |
14 |
15 | void sort ( int x [] , int length);
16 | void buildHeap (int x [], int length);
17 | void buildHeap (int x [], int length);
18 | void reheapifyUpward (int x [], int lastIndex);
19 | void sortHeap (int x [], int length);
20 | void reheapifyDownward (int x [], int lastIndex);
21 | int findBigChildIndex (int parentIndex, int x [ ] , int lastIndex);
22 |
23 | int SIZE = 500000;
24 | int* x = NULL;
25 |
26 | int main(int argc, const char * argv[])
27 | {
28 | ofstream fout;
29 | fout.open("HeapSort.txt", ios::app);
30 |
31 | fout << "DataSize | Time in Sec" << endl;
32 | cout << "DataSize | Time in Sec" << endl;
33 | for(int z = 1; z <=5; z++)
34 | {
35 | SIZE = z*100000;
36 | x = new int[SIZE];
37 |
38 | int i;
39 | //seed srand with different value each time you run
40 | //so that rand will generate different sequence each time you run
41 | srand((unsigned )time(NULL));
42 | for ( i=0;i 1
90 | void buildHeap (int x [], int length)
91 | {
92 | int lastIndex;
93 | for (lastIndex=1; lastIndex 0 )
105 | {
106 | parentIndex = (childIndex-1)/2;
107 | if (x [childIndex] <= x [parentIndex])
108 | break;
109 | else
110 | {
111 | //swap values at childIndex and at parentIndex.
112 | temp = x [childIndex];
113 | x [childIndex] = x [parentIndex];
114 | x [parentIndex] = temp;
115 |
116 |
117 | //Update child to parent
118 | childIndex = parentIndex;
119 | }
120 | }
121 | }
122 |
123 | //Method below changes heapified array into sorted array
124 | //Pre-condition: length > 1
125 | //lastIndex is the index of the last element of the array.
126 | int findBigChildIndex (int parentIndex, int x [ ] , int lastIndex)
127 | {
128 | int lChildIndex = (2 * parentIndex) + 1;
129 | int rChildIndex = (2 * parentIndex) + 2;
130 |
131 | //case both children exist
132 | if (rChildIndex <= lastIndex && lChildIndex <= lastIndex)
133 | {
134 | if(x[rChildIndex] > x[lChildIndex])
135 | {
136 | return rChildIndex;
137 | }
138 | else if(x[rChildIndex] < x[lChildIndex])
139 | {
140 | return lChildIndex;
141 | }
142 | else
143 | {
144 | cout << "they are equal" << endl;
145 | return rChildIndex;
146 | }
147 |
148 | //compare value at rChildIndex and at lChildIndex
149 | //return the index where the value is larger
150 |
151 |
152 |
153 | }
154 | //case only left child exist
155 | else if (lChildIndex <= lastIndex)
156 | {
157 | return lChildIndex;
158 | }
159 | //case both children missing
160 |
161 | return -1;
162 |
163 | }
164 | void reheapifyDownward (int x [], int lastIndex)
165 | {
166 |
167 | int parentIndex = 0;
168 | int temp;
169 |
170 | while (parentIndex < lastIndex)
171 | {
172 | //findBigChildIndex will return a negative value if parent has no children.
173 | int bigChildIndex = findBigChildIndex (parentIndex, x, lastIndex);
174 |
175 | if (bigChildIndex < 0 || x [bigChildIndex] <= x [parentIndex])
176 | break;
177 | else
178 | {
179 | //swap value at parentIndex with value at bigChildIndex
180 | temp = x [parentIndex];
181 | x [parentIndex] = x [bigChildIndex];
182 | x [bigChildIndex] = temp;
183 |
184 |
185 | //update parentIndex
186 | parentIndex = bigChildIndex;
187 | }
188 | }
189 | }
190 |
191 | //The function will return -1 if the parent had no children.
192 |
193 | void sortHeap (int x [], int length)
194 | {
195 | int lastIndex = length - 1;
196 | int temp;
197 | while (lastIndex > 0)
198 | {
199 | //swap the contents of index 0 with contents of lastIndex
200 | temp = x [0];
201 | x [0] = x [lastIndex];
202 | x [lastIndex] = temp;
203 |
204 | //decrement the array size
205 | lastIndex--;
206 |
207 | //call reheapifyDownward. Pass it the array and the last index number of the array.
208 | reheapifyDownward(x, lastIndex);
209 |
210 | }
211 | }
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | #LLVM Analysis And Transform Passes
2 |
3 | This project uses Clang and LLVM to analyze and transform C++ source code.
4 |
5 | ### How It Works
6 |
7 | Clang is a front end to LLVM, it compiles C++ into IR. Intermediate Representation is far simpler then C++, making it easier to analyze and transform.
8 |
9 | LLVM has a variety of libraries that can be used to analyze and transform IR. Instructions for an analysis or a transformation are called a [pass](http://llvm.org/docs/GettingStarted.html#overview).
10 |
11 |
12 |
13 | [Video Demo of The Passes](https://youtu.be/gS9D2PHjrmM)
14 |
15 |
16 |
17 | ### Milestones
18 |
19 | 1. Static Analysis `Done See Below`
20 | * Compile a program down to IR using Clang.
21 | * Get a count of each type of instruction in the IR bitcode.
22 | * Write an explanation and directions about how to use the pass.
23 | 2. Dynamic Analysis Using Transformation `Done See Below`
24 | * Compile a program down to IR using Clang.
25 | * Add instrumentation to the program using a LLVM pass which modifies the IR.
26 | * The added instrumentation will print out each instruction encountered at runtime.
27 | * Write an explanation and directions about how to use the pass.
28 | 3. Travis-Ci
29 | * Write tests to compile and run the passes using Travis-Ci.
30 | * This may require compiling a pass out of source.
31 | 4. Dynamic Analysis Using an External Module
32 | * Get a count of each type of instruction as executed at runtime.
33 | * This pass will add instrumentation to the program IR.
34 | * the instrumentation will call an external function in a module that I will write.
35 | * This external function which will do the actual counting using the information sent to it by the transformed IR.
36 | * Write an explanation and directions about how to use the pass.
37 | 5. Transformation or Optimization Pass
38 | * Convert all doubles in a program into floats.
39 | * I am still learning a lot about LLVM and optimization so I may change this.
40 |
41 |
42 | ## Requirements
43 |
44 | LLVM and Clang are required to compile and apply the passes.
45 | CMake is required to build LLVM and Clang.
46 |
47 | * [LLVM](http://llvm.org/docs/GettingStarted.html#overview)
48 | * [Clang](http://clang.llvm.org/get_started.html)
49 | * [CMake](http://llvm.org/docs/GettingStarted.html#overview)
50 |
51 |
52 |
53 | ## Directions and Explanation for Milestone 1
54 |
55 | CLang is used to compile c++ to bytecode
56 | LLVM is used to implment an analysis pass
57 | The `StaticCount` pass goes through every instruction in the byetecode and prints out what type it is. It also uses LLVM to keep track of certian statistics which it prints out at the end of the analysis.
58 |
59 |
60 | Before following this guide you should have downloaded and built LLVM.
61 |
62 | This project and guide were made using macOS.
63 |
64 | In order to apply a pass to some c code there are a number of steps that must be tacken, they are as follows.
65 |
66 | 1. Clone the project to your computer.
67 | 2. Navigate to `/lib/Transforms`.
68 | 3. Copy the folder `StaticCount` from the cloned repository into the directory listed above.
69 | 4. Inside the `Transforms` directory there should be a number of directorys and only one file `CMakeLists.txt`.
70 | 5. Open `CMakeLists.txt` and add the line `add_subdirectory(StaticCount)`.
71 | 6. In terminal navigate to the root of your `` and run `cmake --build .` this will build all of LLVM including the pass we just added.
72 | 7. Now navigate into the `HeapTimeTestProgram` directory inside the cloned repository.
73 | 8. Run `clang -O0 -emit-llvm -c main.cpp -o bctest.bc` this uses clang to compile our c++ file down to bytecode that llvm can work with.
74 | 9. Run `opt -load /lib/llvmstaticcount.dylib -StaticCount -stats< bctest.bc > /dev/null` The printed statments are a result of the static analysis using llvm.
75 |
76 |
77 | 
78 | Note - This is not the complete output of the pass. It is reduced it so that the commands above are visible.
79 |
80 |
81 | Trouble? Please contact me.
82 |
83 | ## Directions and Explanation for Milestone 2
84 |
85 | CLang is used to compile c++ to bytecode
86 | LLVM is used to implment an analysis pass
87 | The `DynCount` pass goes through every Basic Block in the byetecode and adds a call to a runtime library. The functions in the library are only output statments for this milestone.
88 |
89 | First the pass is compiled just like the first one, next we compile the test program into bytecode. After that the runtime library is compiled into bytecode. These two bytecode files are then linked into a single bytecode file using llvm. After this the pass is applied, unlike in The first pass there will be no output at that point. since this is a dynamic pass we will get the results at runtime. Finally we run the program and get our result, there will be output statments at every occorence of several different Basic Block types.
90 |
91 | Before following this guide you should have downloaded and built LLVM.
92 |
93 | This project and guide were made using macOS.
94 |
95 | In order to apply a pass to C code there are a number of steps that must be tacken, they are as follows.
96 |
97 | 1. Clone the project to your computer.
98 | 2. Navigate to `/lib/Transforms`.
99 | 3. Copy the folder `DynCount` from the cloned repository into the directory listed above.
100 | 4. Inside the `Transforms` directory there should be a number of directorys and only one file `CMakeLists.txt`.
101 | 5. Open `CMakeLists.txt` and add the line `add_subdirectory(DynCount)`.
102 | 6. In terminal navigate to the root of your `` and run `cmake --build .` this will build all of LLVM including the pass we just added.
103 | 7. Now navigate into the `SmallTestProgram` directory inside the cloned repository.
104 | 8. Run `clang -O0 -emit-llvm -c smallProgram.c -o sp.bc` this uses clang to compile our c file down to bytecode that llvm can work with.
105 | 9. Run `clang -O0 -emit-llvm -c print -o p.bc` this uses clang to compile our runtime library down to bytecode that can be linked with the program we compiled above.
106 | 10. Run `llvm-link p.bc sp.bc -S -o smallprogramandprint.bc` this links our program to be analysed and our runtime library.
107 | 11. Run `opt -load /lib/llvmDynCount.dylib -DynCount instrumentedprogram.bc` This applys the pass to the program, modifying the bytecode with calls to the runtime library that we linked to it.
108 | 12. Run `lli instrumentedprogram.bc` This runs the instrumented program so that we can see the result of the pass.
109 |
110 |
111 | 
112 | 
113 | Note - This is not the complete output of the pass. It is reduced it so that the commands above are visible.
114 |
115 | Trouble? Please contact me.
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
--------------------------------------------------------------------------------
/SmallTestProgram/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/SmallTestProgram/.DS_Store
--------------------------------------------------------------------------------
/SmallTestProgram/print.c:
--------------------------------------------------------------------------------
1 | #include
2 | void BO() {
3 | printf("Message from imbedded function: Binary Operator (BB) \n");
4 | }
5 | void ALL() {
6 | printf("Message from imbedded function: Allocation (BB)\n");
7 | }
8 | void BRAN() {
9 | printf("Message from imbedded function: Branch Instruction (BB)\n");
10 | }
11 | void LOAD() {
12 | printf("Message from imbedded function: Load (BB)\n");
13 | }
14 | void STORE() {
15 | printf("Message from imbedded function: Store (BB)\n");
16 | }
17 | void CALL() {
18 | printf("Message from imbedded function: Call Instruction (BB)\n");
19 | }
20 | void INST() {
21 | printf("Message from imbedded function: Instruction (BB)\n");
22 | }
23 |
--------------------------------------------------------------------------------
/SmallTestProgram/smallProgram.c:
--------------------------------------------------------------------------------
1 |
2 |
3 | #include
4 |
5 | void foo();
6 | void bar();
7 |
8 |
9 | #include
10 |
11 | int main()
12 | {
13 |
14 | printf("\nTarget Program: Hello Begin llvm test program\n \n");
15 |
16 | int test = 4;
17 | int test2 = 4;
18 | test = test + test2;
19 | printf("\nTarget Program: Defined some ints and did some addition.\n \n");
20 |
21 | foo();
22 | printf("\nTarget Program: Called a function.\n \n");
23 |
24 | while(test >=1){
25 | test = test - 1;
26 | bar();
27 | }
28 | printf("\nTarget Program: At the end.\n \n");
29 | return 0;
30 | }
31 |
32 |
33 | void foo()
34 | {
35 | int temp = 1;
36 | int temp2 = 2;
37 | temp = temp + temp2;
38 | printf("\nTarget Program: At the end of function is run before the loop.\n \n");
39 | }
40 |
41 |
42 | void bar()
43 | {
44 | int temp = 1;
45 | int temp2 = 2;
46 | temp = temp + temp2;
47 | printf("\nTarget Program: This function is run every iteration of a loop.\n \n");
48 | }
49 |
--------------------------------------------------------------------------------
/StaticCount/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/StaticCount/.DS_Store
--------------------------------------------------------------------------------
/StaticCount/CMakeCache.txt:
--------------------------------------------------------------------------------
1 | # This is the CMakeCache file.
2 | # For build in directory: /Users/henryboswell/developer/llvm/llvm/lib/Transforms/StaticCount
3 | # It was generated by CMake: /Applications/CMake.app/Contents/bin/cmake
4 | # You can edit this file to change values found and used by cmake.
5 | # If you do not want to change any of the values, simply exit the editor.
6 | # If you do want to change a value, simply edit, save, and exit the editor.
7 | # The syntax for the file is as follows:
8 | # KEY:TYPE=VALUE
9 | # KEY is the name of a variable in the cache.
10 | # TYPE is a hint to GUIs for the type of VALUE, DO NOT EDIT TYPE!.
11 | # VALUE is the current value for the KEY.
12 |
13 | ########################
14 | # EXTERNAL cache entries
15 | ########################
16 |
17 | //Path to a program.
18 | CMAKE_AR:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar
19 |
20 | //For backwards compatibility, what version of CMake commands and
21 | // syntax should this version of CMake try to support.
22 | CMAKE_BACKWARDS_COMPATIBILITY:STRING=2.4
23 |
24 | //Choose the type of build, options are: None(CMAKE_CXX_FLAGS or
25 | // CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel.
26 | CMAKE_BUILD_TYPE:STRING=
27 |
28 | //Enable/Disable color output during build.
29 | CMAKE_COLOR_MAKEFILE:BOOL=ON
30 |
31 | //CXX compiler
32 | CMAKE_CXX_COMPILER:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++
33 |
34 | //Flags used by the compiler during all build types.
35 | CMAKE_CXX_FLAGS:STRING=
36 |
37 | //Flags used by the compiler during debug builds.
38 | CMAKE_CXX_FLAGS_DEBUG:STRING=-g
39 |
40 | //Flags used by the compiler during release builds for minimum
41 | // size.
42 | CMAKE_CXX_FLAGS_MINSIZEREL:STRING=-Os -DNDEBUG
43 |
44 | //Flags used by the compiler during release builds.
45 | CMAKE_CXX_FLAGS_RELEASE:STRING=-O3 -DNDEBUG
46 |
47 | //Flags used by the compiler during release builds with debug info.
48 | CMAKE_CXX_FLAGS_RELWITHDEBINFO:STRING=-O2 -g -DNDEBUG
49 |
50 | //C compiler
51 | CMAKE_C_COMPILER:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc
52 |
53 | //Flags used by the compiler during all build types.
54 | CMAKE_C_FLAGS:STRING=
55 |
56 | //Flags used by the compiler during debug builds.
57 | CMAKE_C_FLAGS_DEBUG:STRING=-g
58 |
59 | //Flags used by the compiler during release builds for minimum
60 | // size.
61 | CMAKE_C_FLAGS_MINSIZEREL:STRING=-Os -DNDEBUG
62 |
63 | //Flags used by the compiler during release builds.
64 | CMAKE_C_FLAGS_RELEASE:STRING=-O3 -DNDEBUG
65 |
66 | //Flags used by the compiler during release builds with debug info.
67 | CMAKE_C_FLAGS_RELWITHDEBINFO:STRING=-O2 -g -DNDEBUG
68 |
69 | //Flags used by the linker.
70 | CMAKE_EXE_LINKER_FLAGS:STRING=
71 |
72 | //Flags used by the linker during debug builds.
73 | CMAKE_EXE_LINKER_FLAGS_DEBUG:STRING=
74 |
75 | //Flags used by the linker during release minsize builds.
76 | CMAKE_EXE_LINKER_FLAGS_MINSIZEREL:STRING=
77 |
78 | //Flags used by the linker during release builds.
79 | CMAKE_EXE_LINKER_FLAGS_RELEASE:STRING=
80 |
81 | //Flags used by the linker during Release with Debug Info builds.
82 | CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO:STRING=
83 |
84 | //Enable/Disable output of compile commands during generation.
85 | CMAKE_EXPORT_COMPILE_COMMANDS:BOOL=OFF
86 |
87 | //Path to a program.
88 | CMAKE_INSTALL_NAME_TOOL:FILEPATH=/usr/bin/install_name_tool
89 |
90 | //Install path prefix, prepended onto install directories.
91 | CMAKE_INSTALL_PREFIX:PATH=/usr/local
92 |
93 | //Path to a program.
94 | CMAKE_LINKER:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld
95 |
96 | //Path to a program.
97 | CMAKE_MAKE_PROGRAM:FILEPATH=/usr/bin/make
98 |
99 | //Flags used by the linker during the creation of modules.
100 | CMAKE_MODULE_LINKER_FLAGS:STRING=
101 |
102 | //Flags used by the linker during debug builds.
103 | CMAKE_MODULE_LINKER_FLAGS_DEBUG:STRING=
104 |
105 | //Flags used by the linker during release minsize builds.
106 | CMAKE_MODULE_LINKER_FLAGS_MINSIZEREL:STRING=
107 |
108 | //Flags used by the linker during release builds.
109 | CMAKE_MODULE_LINKER_FLAGS_RELEASE:STRING=
110 |
111 | //Flags used by the linker during Release with Debug Info builds.
112 | CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO:STRING=
113 |
114 | //Path to a program.
115 | CMAKE_NM:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/nm
116 |
117 | //Path to a program.
118 | CMAKE_OBJCOPY:FILEPATH=CMAKE_OBJCOPY-NOTFOUND
119 |
120 | //Path to a program.
121 | CMAKE_OBJDUMP:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/objdump
122 |
123 | //Build architectures for OSX
124 | CMAKE_OSX_ARCHITECTURES:STRING=
125 |
126 | //Minimum OS X version to target for deployment (at runtime); newer
127 | // APIs weak linked. Set to empty string for default value.
128 | CMAKE_OSX_DEPLOYMENT_TARGET:STRING=
129 |
130 | //The product will be built against the headers and libraries located
131 | // inside the indicated SDK.
132 | CMAKE_OSX_SYSROOT:STRING=
133 |
134 | //Value Computed by CMake
135 | CMAKE_PROJECT_NAME:STATIC=Project
136 |
137 | //Path to a program.
138 | CMAKE_RANLIB:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib
139 |
140 | //Flags used by the linker during the creation of dll's.
141 | CMAKE_SHARED_LINKER_FLAGS:STRING=
142 |
143 | //Flags used by the linker during debug builds.
144 | CMAKE_SHARED_LINKER_FLAGS_DEBUG:STRING=
145 |
146 | //Flags used by the linker during release minsize builds.
147 | CMAKE_SHARED_LINKER_FLAGS_MINSIZEREL:STRING=
148 |
149 | //Flags used by the linker during release builds.
150 | CMAKE_SHARED_LINKER_FLAGS_RELEASE:STRING=
151 |
152 | //Flags used by the linker during Release with Debug Info builds.
153 | CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO:STRING=
154 |
155 | //If set, runtime paths are not added when installing shared libraries,
156 | // but are added when building.
157 | CMAKE_SKIP_INSTALL_RPATH:BOOL=NO
158 |
159 | //If set, runtime paths are not added when using shared libraries.
160 | CMAKE_SKIP_RPATH:BOOL=NO
161 |
162 | //Flags used by the linker during the creation of static libraries.
163 | CMAKE_STATIC_LINKER_FLAGS:STRING=
164 |
165 | //Flags used by the linker during debug builds.
166 | CMAKE_STATIC_LINKER_FLAGS_DEBUG:STRING=
167 |
168 | //Flags used by the linker during release minsize builds.
169 | CMAKE_STATIC_LINKER_FLAGS_MINSIZEREL:STRING=
170 |
171 | //Flags used by the linker during release builds.
172 | CMAKE_STATIC_LINKER_FLAGS_RELEASE:STRING=
173 |
174 | //Flags used by the linker during Release with Debug Info builds.
175 | CMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO:STRING=
176 |
177 | //Path to a program.
178 | CMAKE_STRIP:FILEPATH=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/strip
179 |
180 | //If this value is on, makefiles will be generated without the
181 | // .SILENT directive, and all commands will be echoed to the console
182 | // during the make. This is useful for debugging only. With Visual
183 | // Studio IDE projects all commands are done without /nologo.
184 | CMAKE_VERBOSE_MAKEFILE:BOOL=FALSE
185 |
186 | //Single output directory for building all executables.
187 | EXECUTABLE_OUTPUT_PATH:PATH=
188 |
189 | //Single output directory for building all libraries.
190 | LIBRARY_OUTPUT_PATH:PATH=
191 |
192 | //Value Computed by CMake
193 | Project_BINARY_DIR:STATIC=/Users/henryboswell/developer/llvm/llvm/lib/Transforms/StaticCount
194 |
195 | //Value Computed by CMake
196 | Project_SOURCE_DIR:STATIC=/Users/henryboswell/developer/llvm/llvm/lib/Transforms/StaticCount
197 |
198 |
199 | ########################
200 | # INTERNAL cache entries
201 | ########################
202 |
203 | //ADVANCED property for variable: CMAKE_AR
204 | CMAKE_AR-ADVANCED:INTERNAL=1
205 | //This is the directory where this CMakeCache.txt was created
206 | CMAKE_CACHEFILE_DIR:INTERNAL=/Users/henryboswell/developer/llvm/llvm/lib/Transforms/StaticCount
207 | //Major version of cmake used to create the current loaded cache
208 | CMAKE_CACHE_MAJOR_VERSION:INTERNAL=3
209 | //Minor version of cmake used to create the current loaded cache
210 | CMAKE_CACHE_MINOR_VERSION:INTERNAL=6
211 | //Patch version of cmake used to create the current loaded cache
212 | CMAKE_CACHE_PATCH_VERSION:INTERNAL=2
213 | //ADVANCED property for variable: CMAKE_COLOR_MAKEFILE
214 | CMAKE_COLOR_MAKEFILE-ADVANCED:INTERNAL=1
215 | //Path to CMake executable.
216 | CMAKE_COMMAND:INTERNAL=/Applications/CMake.app/Contents/bin/cmake
217 | //Path to cpack program executable.
218 | CMAKE_CPACK_COMMAND:INTERNAL=/Applications/CMake.app/Contents/bin/cpack
219 | //Path to ctest program executable.
220 | CMAKE_CTEST_COMMAND:INTERNAL=/Applications/CMake.app/Contents/bin/ctest
221 | //ADVANCED property for variable: CMAKE_CXX_COMPILER
222 | CMAKE_CXX_COMPILER-ADVANCED:INTERNAL=1
223 | //ADVANCED property for variable: CMAKE_CXX_FLAGS
224 | CMAKE_CXX_FLAGS-ADVANCED:INTERNAL=1
225 | //ADVANCED property for variable: CMAKE_CXX_FLAGS_DEBUG
226 | CMAKE_CXX_FLAGS_DEBUG-ADVANCED:INTERNAL=1
227 | //ADVANCED property for variable: CMAKE_CXX_FLAGS_MINSIZEREL
228 | CMAKE_CXX_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
229 | //ADVANCED property for variable: CMAKE_CXX_FLAGS_RELEASE
230 | CMAKE_CXX_FLAGS_RELEASE-ADVANCED:INTERNAL=1
231 | //ADVANCED property for variable: CMAKE_CXX_FLAGS_RELWITHDEBINFO
232 | CMAKE_CXX_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
233 | //ADVANCED property for variable: CMAKE_C_COMPILER
234 | CMAKE_C_COMPILER-ADVANCED:INTERNAL=1
235 | //ADVANCED property for variable: CMAKE_C_FLAGS
236 | CMAKE_C_FLAGS-ADVANCED:INTERNAL=1
237 | //ADVANCED property for variable: CMAKE_C_FLAGS_DEBUG
238 | CMAKE_C_FLAGS_DEBUG-ADVANCED:INTERNAL=1
239 | //ADVANCED property for variable: CMAKE_C_FLAGS_MINSIZEREL
240 | CMAKE_C_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
241 | //ADVANCED property for variable: CMAKE_C_FLAGS_RELEASE
242 | CMAKE_C_FLAGS_RELEASE-ADVANCED:INTERNAL=1
243 | //ADVANCED property for variable: CMAKE_C_FLAGS_RELWITHDEBINFO
244 | CMAKE_C_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
245 | //Path to cache edit program executable.
246 | CMAKE_EDIT_COMMAND:INTERNAL=/Applications/CMake.app/Contents/bin/ccmake
247 | //Executable file format
248 | CMAKE_EXECUTABLE_FORMAT:INTERNAL=Unknown
249 | //ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS
250 | CMAKE_EXE_LINKER_FLAGS-ADVANCED:INTERNAL=1
251 | //ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_DEBUG
252 | CMAKE_EXE_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
253 | //ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_MINSIZEREL
254 | CMAKE_EXE_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
255 | //ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_RELEASE
256 | CMAKE_EXE_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
257 | //ADVANCED property for variable: CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO
258 | CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
259 | //ADVANCED property for variable: CMAKE_EXPORT_COMPILE_COMMANDS
260 | CMAKE_EXPORT_COMPILE_COMMANDS-ADVANCED:INTERNAL=1
261 | //Name of external makefile project generator.
262 | CMAKE_EXTRA_GENERATOR:INTERNAL=
263 | //Name of generator.
264 | CMAKE_GENERATOR:INTERNAL=Unix Makefiles
265 | //Name of generator platform.
266 | CMAKE_GENERATOR_PLATFORM:INTERNAL=
267 | //Name of generator toolset.
268 | CMAKE_GENERATOR_TOOLSET:INTERNAL=
269 | //Source directory with the top level CMakeLists.txt file for this
270 | // project
271 | CMAKE_HOME_DIRECTORY:INTERNAL=/Users/henryboswell/developer/llvm/llvm/lib/Transforms/StaticCount
272 | //ADVANCED property for variable: CMAKE_INSTALL_NAME_TOOL
273 | CMAKE_INSTALL_NAME_TOOL-ADVANCED:INTERNAL=1
274 | //ADVANCED property for variable: CMAKE_LINKER
275 | CMAKE_LINKER-ADVANCED:INTERNAL=1
276 | //ADVANCED property for variable: CMAKE_MAKE_PROGRAM
277 | CMAKE_MAKE_PROGRAM-ADVANCED:INTERNAL=1
278 | //ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS
279 | CMAKE_MODULE_LINKER_FLAGS-ADVANCED:INTERNAL=1
280 | //ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_DEBUG
281 | CMAKE_MODULE_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
282 | //ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_MINSIZEREL
283 | CMAKE_MODULE_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
284 | //ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_RELEASE
285 | CMAKE_MODULE_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
286 | //ADVANCED property for variable: CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO
287 | CMAKE_MODULE_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
288 | //ADVANCED property for variable: CMAKE_NM
289 | CMAKE_NM-ADVANCED:INTERNAL=1
290 | //number of local generators
291 | CMAKE_NUMBER_OF_MAKEFILES:INTERNAL=1
292 | //ADVANCED property for variable: CMAKE_OBJCOPY
293 | CMAKE_OBJCOPY-ADVANCED:INTERNAL=1
294 | //ADVANCED property for variable: CMAKE_OBJDUMP
295 | CMAKE_OBJDUMP-ADVANCED:INTERNAL=1
296 | //ADVANCED property for variable: CMAKE_RANLIB
297 | CMAKE_RANLIB-ADVANCED:INTERNAL=1
298 | //Path to CMake installation.
299 | CMAKE_ROOT:INTERNAL=/Applications/CMake.app/Contents/share/cmake-3.6
300 | //ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS
301 | CMAKE_SHARED_LINKER_FLAGS-ADVANCED:INTERNAL=1
302 | //ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_DEBUG
303 | CMAKE_SHARED_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
304 | //ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_MINSIZEREL
305 | CMAKE_SHARED_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
306 | //ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_RELEASE
307 | CMAKE_SHARED_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
308 | //ADVANCED property for variable: CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO
309 | CMAKE_SHARED_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
310 | //ADVANCED property for variable: CMAKE_SKIP_INSTALL_RPATH
311 | CMAKE_SKIP_INSTALL_RPATH-ADVANCED:INTERNAL=1
312 | //ADVANCED property for variable: CMAKE_SKIP_RPATH
313 | CMAKE_SKIP_RPATH-ADVANCED:INTERNAL=1
314 | //ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS
315 | CMAKE_STATIC_LINKER_FLAGS-ADVANCED:INTERNAL=1
316 | //ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_DEBUG
317 | CMAKE_STATIC_LINKER_FLAGS_DEBUG-ADVANCED:INTERNAL=1
318 | //ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_MINSIZEREL
319 | CMAKE_STATIC_LINKER_FLAGS_MINSIZEREL-ADVANCED:INTERNAL=1
320 | //ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_RELEASE
321 | CMAKE_STATIC_LINKER_FLAGS_RELEASE-ADVANCED:INTERNAL=1
322 | //ADVANCED property for variable: CMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO
323 | CMAKE_STATIC_LINKER_FLAGS_RELWITHDEBINFO-ADVANCED:INTERNAL=1
324 | //ADVANCED property for variable: CMAKE_STRIP
325 | CMAKE_STRIP-ADVANCED:INTERNAL=1
326 | //uname command
327 | CMAKE_UNAME:INTERNAL=/usr/bin/uname
328 | //ADVANCED property for variable: CMAKE_VERBOSE_MAKEFILE
329 | CMAKE_VERBOSE_MAKEFILE-ADVANCED:INTERNAL=1
330 |
331 |
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/StaticCount/CMakeFiles/.DS_Store
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/3.6.2/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/StaticCount/CMakeFiles/3.6.2/.DS_Store
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/3.6.2/CMakeCCompiler.cmake:
--------------------------------------------------------------------------------
1 | set(CMAKE_C_COMPILER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc")
2 | set(CMAKE_C_COMPILER_ARG1 "")
3 | set(CMAKE_C_COMPILER_ID "AppleClang")
4 | set(CMAKE_C_COMPILER_VERSION "8.0.0.8000038")
5 | set(CMAKE_C_COMPILER_WRAPPER "")
6 | set(CMAKE_C_STANDARD_COMPUTED_DEFAULT "11")
7 | set(CMAKE_C_COMPILE_FEATURES "c_function_prototypes;c_restrict;c_variadic_macros;c_static_assert")
8 | set(CMAKE_C90_COMPILE_FEATURES "c_function_prototypes")
9 | set(CMAKE_C99_COMPILE_FEATURES "c_restrict;c_variadic_macros")
10 | set(CMAKE_C11_COMPILE_FEATURES "c_static_assert")
11 |
12 | set(CMAKE_C_PLATFORM_ID "Darwin")
13 | set(CMAKE_C_SIMULATE_ID "")
14 | set(CMAKE_C_SIMULATE_VERSION "")
15 |
16 | set(CMAKE_AR "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar")
17 | set(CMAKE_RANLIB "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib")
18 | set(CMAKE_LINKER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld")
19 | set(CMAKE_COMPILER_IS_GNUCC )
20 | set(CMAKE_C_COMPILER_LOADED 1)
21 | set(CMAKE_C_COMPILER_WORKS TRUE)
22 | set(CMAKE_C_ABI_COMPILED TRUE)
23 | set(CMAKE_COMPILER_IS_MINGW )
24 | set(CMAKE_COMPILER_IS_CYGWIN )
25 | if(CMAKE_COMPILER_IS_CYGWIN)
26 | set(CYGWIN 1)
27 | set(UNIX 1)
28 | endif()
29 |
30 | set(CMAKE_C_COMPILER_ENV_VAR "CC")
31 |
32 | if(CMAKE_COMPILER_IS_MINGW)
33 | set(MINGW 1)
34 | endif()
35 | set(CMAKE_C_COMPILER_ID_RUN 1)
36 | set(CMAKE_C_SOURCE_FILE_EXTENSIONS c;m)
37 | set(CMAKE_C_IGNORE_EXTENSIONS h;H;o;O;obj;OBJ;def;DEF;rc;RC)
38 | set(CMAKE_C_LINKER_PREFERENCE 10)
39 |
40 | # Save compiler ABI information.
41 | set(CMAKE_C_SIZEOF_DATA_PTR "8")
42 | set(CMAKE_C_COMPILER_ABI "")
43 | set(CMAKE_C_LIBRARY_ARCHITECTURE "")
44 |
45 | if(CMAKE_C_SIZEOF_DATA_PTR)
46 | set(CMAKE_SIZEOF_VOID_P "${CMAKE_C_SIZEOF_DATA_PTR}")
47 | endif()
48 |
49 | if(CMAKE_C_COMPILER_ABI)
50 | set(CMAKE_INTERNAL_PLATFORM_ABI "${CMAKE_C_COMPILER_ABI}")
51 | endif()
52 |
53 | if(CMAKE_C_LIBRARY_ARCHITECTURE)
54 | set(CMAKE_LIBRARY_ARCHITECTURE "")
55 | endif()
56 |
57 | set(CMAKE_C_CL_SHOWINCLUDES_PREFIX "")
58 | if(CMAKE_C_CL_SHOWINCLUDES_PREFIX)
59 | set(CMAKE_CL_SHOWINCLUDES_PREFIX "${CMAKE_C_CL_SHOWINCLUDES_PREFIX}")
60 | endif()
61 |
62 |
63 |
64 |
65 | set(CMAKE_C_IMPLICIT_LINK_LIBRARIES "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/8.0.0/lib/darwin/libclang_rt.osx.a")
66 | set(CMAKE_C_IMPLICIT_LINK_DIRECTORIES "/usr/lib;/usr/local/lib")
67 | set(CMAKE_C_IMPLICIT_LINK_FRAMEWORK_DIRECTORIES "/Library/Frameworks;/System/Library/Frameworks")
68 |
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/3.6.2/CMakeCXXCompiler.cmake:
--------------------------------------------------------------------------------
1 | set(CMAKE_CXX_COMPILER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++")
2 | set(CMAKE_CXX_COMPILER_ARG1 "")
3 | set(CMAKE_CXX_COMPILER_ID "AppleClang")
4 | set(CMAKE_CXX_COMPILER_VERSION "8.0.0.8000038")
5 | set(CMAKE_CXX_COMPILER_WRAPPER "")
6 | set(CMAKE_CXX_STANDARD_COMPUTED_DEFAULT "98")
7 | set(CMAKE_CXX_COMPILE_FEATURES "cxx_template_template_parameters;cxx_alias_templates;cxx_alignas;cxx_alignof;cxx_attributes;cxx_auto_type;cxx_constexpr;cxx_decltype;cxx_decltype_incomplete_return_types;cxx_default_function_template_args;cxx_defaulted_functions;cxx_defaulted_move_initializers;cxx_delegating_constructors;cxx_deleted_functions;cxx_enum_forward_declarations;cxx_explicit_conversions;cxx_extended_friend_declarations;cxx_extern_templates;cxx_final;cxx_func_identifier;cxx_generalized_initializers;cxx_inheriting_constructors;cxx_inline_namespaces;cxx_lambdas;cxx_local_type_template_args;cxx_long_long_type;cxx_noexcept;cxx_nonstatic_member_init;cxx_nullptr;cxx_override;cxx_range_for;cxx_raw_string_literals;cxx_reference_qualified_functions;cxx_right_angle_brackets;cxx_rvalue_references;cxx_sizeof_member;cxx_static_assert;cxx_strong_enums;cxx_thread_local;cxx_trailing_return_types;cxx_unicode_literals;cxx_uniform_initialization;cxx_unrestricted_unions;cxx_user_literals;cxx_variadic_macros;cxx_variadic_templates;cxx_aggregate_default_initializers;cxx_attribute_deprecated;cxx_binary_literals;cxx_contextual_conversions;cxx_decltype_auto;cxx_digit_separators;cxx_generic_lambdas;cxx_lambda_init_captures;cxx_relaxed_constexpr;cxx_return_type_deduction;cxx_variable_templates")
8 | set(CMAKE_CXX98_COMPILE_FEATURES "cxx_template_template_parameters")
9 | set(CMAKE_CXX11_COMPILE_FEATURES "cxx_alias_templates;cxx_alignas;cxx_alignof;cxx_attributes;cxx_auto_type;cxx_constexpr;cxx_decltype;cxx_decltype_incomplete_return_types;cxx_default_function_template_args;cxx_defaulted_functions;cxx_defaulted_move_initializers;cxx_delegating_constructors;cxx_deleted_functions;cxx_enum_forward_declarations;cxx_explicit_conversions;cxx_extended_friend_declarations;cxx_extern_templates;cxx_final;cxx_func_identifier;cxx_generalized_initializers;cxx_inheriting_constructors;cxx_inline_namespaces;cxx_lambdas;cxx_local_type_template_args;cxx_long_long_type;cxx_noexcept;cxx_nonstatic_member_init;cxx_nullptr;cxx_override;cxx_range_for;cxx_raw_string_literals;cxx_reference_qualified_functions;cxx_right_angle_brackets;cxx_rvalue_references;cxx_sizeof_member;cxx_static_assert;cxx_strong_enums;cxx_thread_local;cxx_trailing_return_types;cxx_unicode_literals;cxx_uniform_initialization;cxx_unrestricted_unions;cxx_user_literals;cxx_variadic_macros;cxx_variadic_templates")
10 | set(CMAKE_CXX14_COMPILE_FEATURES "cxx_aggregate_default_initializers;cxx_attribute_deprecated;cxx_binary_literals;cxx_contextual_conversions;cxx_decltype_auto;cxx_digit_separators;cxx_generic_lambdas;cxx_lambda_init_captures;cxx_relaxed_constexpr;cxx_return_type_deduction;cxx_variable_templates")
11 |
12 | set(CMAKE_CXX_PLATFORM_ID "Darwin")
13 | set(CMAKE_CXX_SIMULATE_ID "")
14 | set(CMAKE_CXX_SIMULATE_VERSION "")
15 |
16 | set(CMAKE_AR "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar")
17 | set(CMAKE_RANLIB "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib")
18 | set(CMAKE_LINKER "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld")
19 | set(CMAKE_COMPILER_IS_GNUCXX )
20 | set(CMAKE_CXX_COMPILER_LOADED 1)
21 | set(CMAKE_CXX_COMPILER_WORKS TRUE)
22 | set(CMAKE_CXX_ABI_COMPILED TRUE)
23 | set(CMAKE_COMPILER_IS_MINGW )
24 | set(CMAKE_COMPILER_IS_CYGWIN )
25 | if(CMAKE_COMPILER_IS_CYGWIN)
26 | set(CYGWIN 1)
27 | set(UNIX 1)
28 | endif()
29 |
30 | set(CMAKE_CXX_COMPILER_ENV_VAR "CXX")
31 |
32 | if(CMAKE_COMPILER_IS_MINGW)
33 | set(MINGW 1)
34 | endif()
35 | set(CMAKE_CXX_COMPILER_ID_RUN 1)
36 | set(CMAKE_CXX_IGNORE_EXTENSIONS inl;h;hpp;HPP;H;o;O;obj;OBJ;def;DEF;rc;RC)
37 | set(CMAKE_CXX_SOURCE_FILE_EXTENSIONS C;M;c++;cc;cpp;cxx;mm;CPP)
38 | set(CMAKE_CXX_LINKER_PREFERENCE 30)
39 | set(CMAKE_CXX_LINKER_PREFERENCE_PROPAGATES 1)
40 |
41 | # Save compiler ABI information.
42 | set(CMAKE_CXX_SIZEOF_DATA_PTR "8")
43 | set(CMAKE_CXX_COMPILER_ABI "")
44 | set(CMAKE_CXX_LIBRARY_ARCHITECTURE "")
45 |
46 | if(CMAKE_CXX_SIZEOF_DATA_PTR)
47 | set(CMAKE_SIZEOF_VOID_P "${CMAKE_CXX_SIZEOF_DATA_PTR}")
48 | endif()
49 |
50 | if(CMAKE_CXX_COMPILER_ABI)
51 | set(CMAKE_INTERNAL_PLATFORM_ABI "${CMAKE_CXX_COMPILER_ABI}")
52 | endif()
53 |
54 | if(CMAKE_CXX_LIBRARY_ARCHITECTURE)
55 | set(CMAKE_LIBRARY_ARCHITECTURE "")
56 | endif()
57 |
58 | set(CMAKE_CXX_CL_SHOWINCLUDES_PREFIX "")
59 | if(CMAKE_CXX_CL_SHOWINCLUDES_PREFIX)
60 | set(CMAKE_CL_SHOWINCLUDES_PREFIX "${CMAKE_CXX_CL_SHOWINCLUDES_PREFIX}")
61 | endif()
62 |
63 |
64 |
65 |
66 | set(CMAKE_CXX_IMPLICIT_LINK_LIBRARIES "c++;/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/8.0.0/lib/darwin/libclang_rt.osx.a")
67 | set(CMAKE_CXX_IMPLICIT_LINK_DIRECTORIES "/usr/lib;/usr/local/lib")
68 | set(CMAKE_CXX_IMPLICIT_LINK_FRAMEWORK_DIRECTORIES "/Library/Frameworks;/System/Library/Frameworks")
69 |
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/3.6.2/CMakeDetermineCompilerABI_C.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/StaticCount/CMakeFiles/3.6.2/CMakeDetermineCompilerABI_C.bin
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/3.6.2/CMakeDetermineCompilerABI_CXX.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/StaticCount/CMakeFiles/3.6.2/CMakeDetermineCompilerABI_CXX.bin
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/3.6.2/CMakeSystem.cmake:
--------------------------------------------------------------------------------
1 | set(CMAKE_HOST_SYSTEM "Darwin-16.0.0")
2 | set(CMAKE_HOST_SYSTEM_NAME "Darwin")
3 | set(CMAKE_HOST_SYSTEM_VERSION "16.0.0")
4 | set(CMAKE_HOST_SYSTEM_PROCESSOR "x86_64")
5 |
6 |
7 |
8 | set(CMAKE_SYSTEM "Darwin-16.0.0")
9 | set(CMAKE_SYSTEM_NAME "Darwin")
10 | set(CMAKE_SYSTEM_VERSION "16.0.0")
11 | set(CMAKE_SYSTEM_PROCESSOR "x86_64")
12 |
13 | set(CMAKE_CROSSCOMPILING "FALSE")
14 |
15 | set(CMAKE_SYSTEM_LOADED 1)
16 |
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/3.6.2/CompilerIdC/CMakeCCompilerId.c:
--------------------------------------------------------------------------------
1 | #ifdef __cplusplus
2 | # error "A C++ compiler has been selected for C."
3 | #endif
4 |
5 | #if defined(__18CXX)
6 | # define ID_VOID_MAIN
7 | #endif
8 | #if defined(__CLASSIC_C__)
9 | /* cv-qualifiers did not exist in K&R C */
10 | # define const
11 | # define volatile
12 | #endif
13 |
14 |
15 | /* Version number components: V=Version, R=Revision, P=Patch
16 | Version date components: YYYY=Year, MM=Month, DD=Day */
17 |
18 | #if defined(__INTEL_COMPILER) || defined(__ICC)
19 | # define COMPILER_ID "Intel"
20 | # if defined(_MSC_VER)
21 | # define SIMULATE_ID "MSVC"
22 | # endif
23 | /* __INTEL_COMPILER = VRP */
24 | # define COMPILER_VERSION_MAJOR DEC(__INTEL_COMPILER/100)
25 | # define COMPILER_VERSION_MINOR DEC(__INTEL_COMPILER/10 % 10)
26 | # if defined(__INTEL_COMPILER_UPDATE)
27 | # define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER_UPDATE)
28 | # else
29 | # define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER % 10)
30 | # endif
31 | # if defined(__INTEL_COMPILER_BUILD_DATE)
32 | /* __INTEL_COMPILER_BUILD_DATE = YYYYMMDD */
33 | # define COMPILER_VERSION_TWEAK DEC(__INTEL_COMPILER_BUILD_DATE)
34 | # endif
35 | # if defined(_MSC_VER)
36 | /* _MSC_VER = VVRR */
37 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
38 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
39 | # endif
40 |
41 | #elif defined(__PATHCC__)
42 | # define COMPILER_ID "PathScale"
43 | # define COMPILER_VERSION_MAJOR DEC(__PATHCC__)
44 | # define COMPILER_VERSION_MINOR DEC(__PATHCC_MINOR__)
45 | # if defined(__PATHCC_PATCHLEVEL__)
46 | # define COMPILER_VERSION_PATCH DEC(__PATHCC_PATCHLEVEL__)
47 | # endif
48 |
49 | #elif defined(__BORLANDC__) && defined(__CODEGEARC_VERSION__)
50 | # define COMPILER_ID "Embarcadero"
51 | # define COMPILER_VERSION_MAJOR HEX(__CODEGEARC_VERSION__>>24 & 0x00FF)
52 | # define COMPILER_VERSION_MINOR HEX(__CODEGEARC_VERSION__>>16 & 0x00FF)
53 | # define COMPILER_VERSION_PATCH DEC(__CODEGEARC_VERSION__ & 0xFFFF)
54 |
55 | #elif defined(__BORLANDC__)
56 | # define COMPILER_ID "Borland"
57 | /* __BORLANDC__ = 0xVRR */
58 | # define COMPILER_VERSION_MAJOR HEX(__BORLANDC__>>8)
59 | # define COMPILER_VERSION_MINOR HEX(__BORLANDC__ & 0xFF)
60 |
61 | #elif defined(__WATCOMC__) && __WATCOMC__ < 1200
62 | # define COMPILER_ID "Watcom"
63 | /* __WATCOMC__ = VVRR */
64 | # define COMPILER_VERSION_MAJOR DEC(__WATCOMC__ / 100)
65 | # define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
66 | # if (__WATCOMC__ % 10) > 0
67 | # define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
68 | # endif
69 |
70 | #elif defined(__WATCOMC__)
71 | # define COMPILER_ID "OpenWatcom"
72 | /* __WATCOMC__ = VVRP + 1100 */
73 | # define COMPILER_VERSION_MAJOR DEC((__WATCOMC__ - 1100) / 100)
74 | # define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
75 | # if (__WATCOMC__ % 10) > 0
76 | # define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
77 | # endif
78 |
79 | #elif defined(__SUNPRO_C)
80 | # define COMPILER_ID "SunPro"
81 | # if __SUNPRO_C >= 0x5100
82 | /* __SUNPRO_C = 0xVRRP */
83 | # define COMPILER_VERSION_MAJOR HEX(__SUNPRO_C>>12)
84 | # define COMPILER_VERSION_MINOR HEX(__SUNPRO_C>>4 & 0xFF)
85 | # define COMPILER_VERSION_PATCH HEX(__SUNPRO_C & 0xF)
86 | # else
87 | /* __SUNPRO_CC = 0xVRP */
88 | # define COMPILER_VERSION_MAJOR HEX(__SUNPRO_C>>8)
89 | # define COMPILER_VERSION_MINOR HEX(__SUNPRO_C>>4 & 0xF)
90 | # define COMPILER_VERSION_PATCH HEX(__SUNPRO_C & 0xF)
91 | # endif
92 |
93 | #elif defined(__HP_cc)
94 | # define COMPILER_ID "HP"
95 | /* __HP_cc = VVRRPP */
96 | # define COMPILER_VERSION_MAJOR DEC(__HP_cc/10000)
97 | # define COMPILER_VERSION_MINOR DEC(__HP_cc/100 % 100)
98 | # define COMPILER_VERSION_PATCH DEC(__HP_cc % 100)
99 |
100 | #elif defined(__DECC)
101 | # define COMPILER_ID "Compaq"
102 | /* __DECC_VER = VVRRTPPPP */
103 | # define COMPILER_VERSION_MAJOR DEC(__DECC_VER/10000000)
104 | # define COMPILER_VERSION_MINOR DEC(__DECC_VER/100000 % 100)
105 | # define COMPILER_VERSION_PATCH DEC(__DECC_VER % 10000)
106 |
107 | #elif defined(__IBMC__) && defined(__COMPILER_VER__)
108 | # define COMPILER_ID "zOS"
109 | /* __IBMC__ = VRP */
110 | # define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
111 | # define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
112 | # define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
113 |
114 | #elif defined(__IBMC__) && !defined(__COMPILER_VER__) && __IBMC__ >= 800
115 | # define COMPILER_ID "XL"
116 | /* __IBMC__ = VRP */
117 | # define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
118 | # define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
119 | # define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
120 |
121 | #elif defined(__IBMC__) && !defined(__COMPILER_VER__) && __IBMC__ < 800
122 | # define COMPILER_ID "VisualAge"
123 | /* __IBMC__ = VRP */
124 | # define COMPILER_VERSION_MAJOR DEC(__IBMC__/100)
125 | # define COMPILER_VERSION_MINOR DEC(__IBMC__/10 % 10)
126 | # define COMPILER_VERSION_PATCH DEC(__IBMC__ % 10)
127 |
128 | #elif defined(__PGI)
129 | # define COMPILER_ID "PGI"
130 | # define COMPILER_VERSION_MAJOR DEC(__PGIC__)
131 | # define COMPILER_VERSION_MINOR DEC(__PGIC_MINOR__)
132 | # if defined(__PGIC_PATCHLEVEL__)
133 | # define COMPILER_VERSION_PATCH DEC(__PGIC_PATCHLEVEL__)
134 | # endif
135 |
136 | #elif defined(_CRAYC)
137 | # define COMPILER_ID "Cray"
138 | # define COMPILER_VERSION_MAJOR DEC(_RELEASE_MAJOR)
139 | # define COMPILER_VERSION_MINOR DEC(_RELEASE_MINOR)
140 |
141 | #elif defined(__TI_COMPILER_VERSION__)
142 | # define COMPILER_ID "TI"
143 | /* __TI_COMPILER_VERSION__ = VVVRRRPPP */
144 | # define COMPILER_VERSION_MAJOR DEC(__TI_COMPILER_VERSION__/1000000)
145 | # define COMPILER_VERSION_MINOR DEC(__TI_COMPILER_VERSION__/1000 % 1000)
146 | # define COMPILER_VERSION_PATCH DEC(__TI_COMPILER_VERSION__ % 1000)
147 |
148 | #elif defined(__FUJITSU) || defined(__FCC_VERSION) || defined(__fcc_version)
149 | # define COMPILER_ID "Fujitsu"
150 |
151 | #elif defined(__TINYC__)
152 | # define COMPILER_ID "TinyCC"
153 |
154 | #elif defined(__BCC__)
155 | # define COMPILER_ID "Bruce"
156 |
157 | #elif defined(__SCO_VERSION__)
158 | # define COMPILER_ID "SCO"
159 |
160 | #elif defined(__clang__) && defined(__apple_build_version__)
161 | # define COMPILER_ID "AppleClang"
162 | # if defined(_MSC_VER)
163 | # define SIMULATE_ID "MSVC"
164 | # endif
165 | # define COMPILER_VERSION_MAJOR DEC(__clang_major__)
166 | # define COMPILER_VERSION_MINOR DEC(__clang_minor__)
167 | # define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
168 | # if defined(_MSC_VER)
169 | /* _MSC_VER = VVRR */
170 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
171 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
172 | # endif
173 | # define COMPILER_VERSION_TWEAK DEC(__apple_build_version__)
174 |
175 | #elif defined(__clang__)
176 | # define COMPILER_ID "Clang"
177 | # if defined(_MSC_VER)
178 | # define SIMULATE_ID "MSVC"
179 | # endif
180 | # define COMPILER_VERSION_MAJOR DEC(__clang_major__)
181 | # define COMPILER_VERSION_MINOR DEC(__clang_minor__)
182 | # define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
183 | # if defined(_MSC_VER)
184 | /* _MSC_VER = VVRR */
185 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
186 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
187 | # endif
188 |
189 | #elif defined(__GNUC__)
190 | # define COMPILER_ID "GNU"
191 | # define COMPILER_VERSION_MAJOR DEC(__GNUC__)
192 | # if defined(__GNUC_MINOR__)
193 | # define COMPILER_VERSION_MINOR DEC(__GNUC_MINOR__)
194 | # endif
195 | # if defined(__GNUC_PATCHLEVEL__)
196 | # define COMPILER_VERSION_PATCH DEC(__GNUC_PATCHLEVEL__)
197 | # endif
198 |
199 | #elif defined(_MSC_VER)
200 | # define COMPILER_ID "MSVC"
201 | /* _MSC_VER = VVRR */
202 | # define COMPILER_VERSION_MAJOR DEC(_MSC_VER / 100)
203 | # define COMPILER_VERSION_MINOR DEC(_MSC_VER % 100)
204 | # if defined(_MSC_FULL_VER)
205 | # if _MSC_VER >= 1400
206 | /* _MSC_FULL_VER = VVRRPPPPP */
207 | # define COMPILER_VERSION_PATCH DEC(_MSC_FULL_VER % 100000)
208 | # else
209 | /* _MSC_FULL_VER = VVRRPPPP */
210 | # define COMPILER_VERSION_PATCH DEC(_MSC_FULL_VER % 10000)
211 | # endif
212 | # endif
213 | # if defined(_MSC_BUILD)
214 | # define COMPILER_VERSION_TWEAK DEC(_MSC_BUILD)
215 | # endif
216 |
217 | #elif defined(__VISUALDSPVERSION__) || defined(__ADSPBLACKFIN__) || defined(__ADSPTS__) || defined(__ADSP21000__)
218 | # define COMPILER_ID "ADSP"
219 | #if defined(__VISUALDSPVERSION__)
220 | /* __VISUALDSPVERSION__ = 0xVVRRPP00 */
221 | # define COMPILER_VERSION_MAJOR HEX(__VISUALDSPVERSION__>>24)
222 | # define COMPILER_VERSION_MINOR HEX(__VISUALDSPVERSION__>>16 & 0xFF)
223 | # define COMPILER_VERSION_PATCH HEX(__VISUALDSPVERSION__>>8 & 0xFF)
224 | #endif
225 |
226 | #elif defined(__IAR_SYSTEMS_ICC__ ) || defined(__IAR_SYSTEMS_ICC)
227 | # define COMPILER_ID "IAR"
228 |
229 | #elif defined(__ARMCC_VERSION)
230 | # define COMPILER_ID "ARMCC"
231 | #if __ARMCC_VERSION >= 1000000
232 | /* __ARMCC_VERSION = VRRPPPP */
233 | # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/1000000)
234 | # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 100)
235 | # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
236 | #else
237 | /* __ARMCC_VERSION = VRPPPP */
238 | # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/100000)
239 | # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 10)
240 | # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
241 | #endif
242 |
243 |
244 | #elif defined(SDCC)
245 | # define COMPILER_ID "SDCC"
246 | /* SDCC = VRP */
247 | # define COMPILER_VERSION_MAJOR DEC(SDCC/100)
248 | # define COMPILER_VERSION_MINOR DEC(SDCC/10 % 10)
249 | # define COMPILER_VERSION_PATCH DEC(SDCC % 10)
250 |
251 | #elif defined(_SGI_COMPILER_VERSION) || defined(_COMPILER_VERSION)
252 | # define COMPILER_ID "MIPSpro"
253 | # if defined(_SGI_COMPILER_VERSION)
254 | /* _SGI_COMPILER_VERSION = VRP */
255 | # define COMPILER_VERSION_MAJOR DEC(_SGI_COMPILER_VERSION/100)
256 | # define COMPILER_VERSION_MINOR DEC(_SGI_COMPILER_VERSION/10 % 10)
257 | # define COMPILER_VERSION_PATCH DEC(_SGI_COMPILER_VERSION % 10)
258 | # else
259 | /* _COMPILER_VERSION = VRP */
260 | # define COMPILER_VERSION_MAJOR DEC(_COMPILER_VERSION/100)
261 | # define COMPILER_VERSION_MINOR DEC(_COMPILER_VERSION/10 % 10)
262 | # define COMPILER_VERSION_PATCH DEC(_COMPILER_VERSION % 10)
263 | # endif
264 |
265 |
266 | /* These compilers are either not known or too old to define an
267 | identification macro. Try to identify the platform and guess that
268 | it is the native compiler. */
269 | #elif defined(__sgi)
270 | # define COMPILER_ID "MIPSpro"
271 |
272 | #elif defined(__hpux) || defined(__hpua)
273 | # define COMPILER_ID "HP"
274 |
275 | #else /* unknown compiler */
276 | # define COMPILER_ID ""
277 | #endif
278 |
279 | /* Construct the string literal in pieces to prevent the source from
280 | getting matched. Store it in a pointer rather than an array
281 | because some compilers will just produce instructions to fill the
282 | array rather than assigning a pointer to a static array. */
283 | char const* info_compiler = "INFO" ":" "compiler[" COMPILER_ID "]";
284 | #ifdef SIMULATE_ID
285 | char const* info_simulate = "INFO" ":" "simulate[" SIMULATE_ID "]";
286 | #endif
287 |
288 | #ifdef __QNXNTO__
289 | char const* qnxnto = "INFO" ":" "qnxnto[]";
290 | #endif
291 |
292 | #if defined(__CRAYXE) || defined(__CRAYXC)
293 | char const *info_cray = "INFO" ":" "compiler_wrapper[CrayPrgEnv]";
294 | #endif
295 |
296 | #define STRINGIFY_HELPER(X) #X
297 | #define STRINGIFY(X) STRINGIFY_HELPER(X)
298 |
299 | /* Identify known platforms by name. */
300 | #if defined(__linux) || defined(__linux__) || defined(linux)
301 | # define PLATFORM_ID "Linux"
302 |
303 | #elif defined(__CYGWIN__)
304 | # define PLATFORM_ID "Cygwin"
305 |
306 | #elif defined(__MINGW32__)
307 | # define PLATFORM_ID "MinGW"
308 |
309 | #elif defined(__APPLE__)
310 | # define PLATFORM_ID "Darwin"
311 |
312 | #elif defined(_WIN32) || defined(__WIN32__) || defined(WIN32)
313 | # define PLATFORM_ID "Windows"
314 |
315 | #elif defined(__FreeBSD__) || defined(__FreeBSD)
316 | # define PLATFORM_ID "FreeBSD"
317 |
318 | #elif defined(__NetBSD__) || defined(__NetBSD)
319 | # define PLATFORM_ID "NetBSD"
320 |
321 | #elif defined(__OpenBSD__) || defined(__OPENBSD)
322 | # define PLATFORM_ID "OpenBSD"
323 |
324 | #elif defined(__sun) || defined(sun)
325 | # define PLATFORM_ID "SunOS"
326 |
327 | #elif defined(_AIX) || defined(__AIX) || defined(__AIX__) || defined(__aix) || defined(__aix__)
328 | # define PLATFORM_ID "AIX"
329 |
330 | #elif defined(__sgi) || defined(__sgi__) || defined(_SGI)
331 | # define PLATFORM_ID "IRIX"
332 |
333 | #elif defined(__hpux) || defined(__hpux__)
334 | # define PLATFORM_ID "HP-UX"
335 |
336 | #elif defined(__HAIKU__)
337 | # define PLATFORM_ID "Haiku"
338 |
339 | #elif defined(__BeOS) || defined(__BEOS__) || defined(_BEOS)
340 | # define PLATFORM_ID "BeOS"
341 |
342 | #elif defined(__QNX__) || defined(__QNXNTO__)
343 | # define PLATFORM_ID "QNX"
344 |
345 | #elif defined(__tru64) || defined(_tru64) || defined(__TRU64__)
346 | # define PLATFORM_ID "Tru64"
347 |
348 | #elif defined(__riscos) || defined(__riscos__)
349 | # define PLATFORM_ID "RISCos"
350 |
351 | #elif defined(__sinix) || defined(__sinix__) || defined(__SINIX__)
352 | # define PLATFORM_ID "SINIX"
353 |
354 | #elif defined(__UNIX_SV__)
355 | # define PLATFORM_ID "UNIX_SV"
356 |
357 | #elif defined(__bsdos__)
358 | # define PLATFORM_ID "BSDOS"
359 |
360 | #elif defined(_MPRAS) || defined(MPRAS)
361 | # define PLATFORM_ID "MP-RAS"
362 |
363 | #elif defined(__osf) || defined(__osf__)
364 | # define PLATFORM_ID "OSF1"
365 |
366 | #elif defined(_SCO_SV) || defined(SCO_SV) || defined(sco_sv)
367 | # define PLATFORM_ID "SCO_SV"
368 |
369 | #elif defined(__ultrix) || defined(__ultrix__) || defined(_ULTRIX)
370 | # define PLATFORM_ID "ULTRIX"
371 |
372 | #elif defined(__XENIX__) || defined(_XENIX) || defined(XENIX)
373 | # define PLATFORM_ID "Xenix"
374 |
375 | #elif defined(__WATCOMC__)
376 | # if defined(__LINUX__)
377 | # define PLATFORM_ID "Linux"
378 |
379 | # elif defined(__DOS__)
380 | # define PLATFORM_ID "DOS"
381 |
382 | # elif defined(__OS2__)
383 | # define PLATFORM_ID "OS2"
384 |
385 | # elif defined(__WINDOWS__)
386 | # define PLATFORM_ID "Windows3x"
387 |
388 | # else /* unknown platform */
389 | # define PLATFORM_ID
390 | # endif
391 |
392 | #else /* unknown platform */
393 | # define PLATFORM_ID
394 |
395 | #endif
396 |
397 | /* For windows compilers MSVC and Intel we can determine
398 | the architecture of the compiler being used. This is because
399 | the compilers do not have flags that can change the architecture,
400 | but rather depend on which compiler is being used
401 | */
402 | #if defined(_WIN32) && defined(_MSC_VER)
403 | # if defined(_M_IA64)
404 | # define ARCHITECTURE_ID "IA64"
405 |
406 | # elif defined(_M_X64) || defined(_M_AMD64)
407 | # define ARCHITECTURE_ID "x64"
408 |
409 | # elif defined(_M_IX86)
410 | # define ARCHITECTURE_ID "X86"
411 |
412 | # elif defined(_M_ARM)
413 | # if _M_ARM == 4
414 | # define ARCHITECTURE_ID "ARMV4I"
415 | # elif _M_ARM == 5
416 | # define ARCHITECTURE_ID "ARMV5I"
417 | # else
418 | # define ARCHITECTURE_ID "ARMV" STRINGIFY(_M_ARM)
419 | # endif
420 |
421 | # elif defined(_M_MIPS)
422 | # define ARCHITECTURE_ID "MIPS"
423 |
424 | # elif defined(_M_SH)
425 | # define ARCHITECTURE_ID "SHx"
426 |
427 | # else /* unknown architecture */
428 | # define ARCHITECTURE_ID ""
429 | # endif
430 |
431 | #elif defined(__WATCOMC__)
432 | # if defined(_M_I86)
433 | # define ARCHITECTURE_ID "I86"
434 |
435 | # elif defined(_M_IX86)
436 | # define ARCHITECTURE_ID "X86"
437 |
438 | # else /* unknown architecture */
439 | # define ARCHITECTURE_ID ""
440 | # endif
441 |
442 | #else
443 | # define ARCHITECTURE_ID
444 | #endif
445 |
446 | /* Convert integer to decimal digit literals. */
447 | #define DEC(n) \
448 | ('0' + (((n) / 10000000)%10)), \
449 | ('0' + (((n) / 1000000)%10)), \
450 | ('0' + (((n) / 100000)%10)), \
451 | ('0' + (((n) / 10000)%10)), \
452 | ('0' + (((n) / 1000)%10)), \
453 | ('0' + (((n) / 100)%10)), \
454 | ('0' + (((n) / 10)%10)), \
455 | ('0' + ((n) % 10))
456 |
457 | /* Convert integer to hex digit literals. */
458 | #define HEX(n) \
459 | ('0' + ((n)>>28 & 0xF)), \
460 | ('0' + ((n)>>24 & 0xF)), \
461 | ('0' + ((n)>>20 & 0xF)), \
462 | ('0' + ((n)>>16 & 0xF)), \
463 | ('0' + ((n)>>12 & 0xF)), \
464 | ('0' + ((n)>>8 & 0xF)), \
465 | ('0' + ((n)>>4 & 0xF)), \
466 | ('0' + ((n) & 0xF))
467 |
468 | /* Construct a string literal encoding the version number components. */
469 | #ifdef COMPILER_VERSION_MAJOR
470 | char const info_version[] = {
471 | 'I', 'N', 'F', 'O', ':',
472 | 'c','o','m','p','i','l','e','r','_','v','e','r','s','i','o','n','[',
473 | COMPILER_VERSION_MAJOR,
474 | # ifdef COMPILER_VERSION_MINOR
475 | '.', COMPILER_VERSION_MINOR,
476 | # ifdef COMPILER_VERSION_PATCH
477 | '.', COMPILER_VERSION_PATCH,
478 | # ifdef COMPILER_VERSION_TWEAK
479 | '.', COMPILER_VERSION_TWEAK,
480 | # endif
481 | # endif
482 | # endif
483 | ']','\0'};
484 | #endif
485 |
486 | /* Construct a string literal encoding the version number components. */
487 | #ifdef SIMULATE_VERSION_MAJOR
488 | char const info_simulate_version[] = {
489 | 'I', 'N', 'F', 'O', ':',
490 | 's','i','m','u','l','a','t','e','_','v','e','r','s','i','o','n','[',
491 | SIMULATE_VERSION_MAJOR,
492 | # ifdef SIMULATE_VERSION_MINOR
493 | '.', SIMULATE_VERSION_MINOR,
494 | # ifdef SIMULATE_VERSION_PATCH
495 | '.', SIMULATE_VERSION_PATCH,
496 | # ifdef SIMULATE_VERSION_TWEAK
497 | '.', SIMULATE_VERSION_TWEAK,
498 | # endif
499 | # endif
500 | # endif
501 | ']','\0'};
502 | #endif
503 |
504 | /* Construct the string literal in pieces to prevent the source from
505 | getting matched. Store it in a pointer rather than an array
506 | because some compilers will just produce instructions to fill the
507 | array rather than assigning a pointer to a static array. */
508 | char const* info_platform = "INFO" ":" "platform[" PLATFORM_ID "]";
509 | char const* info_arch = "INFO" ":" "arch[" ARCHITECTURE_ID "]";
510 |
511 |
512 |
513 |
514 | #if !defined(__STDC__)
515 | # if defined(_MSC_VER) && !defined(__clang__)
516 | # define C_DIALECT "90"
517 | # else
518 | # define C_DIALECT
519 | # endif
520 | #elif __STDC_VERSION__ >= 201000L
521 | # define C_DIALECT "11"
522 | #elif __STDC_VERSION__ >= 199901L
523 | # define C_DIALECT "99"
524 | #else
525 | # define C_DIALECT "90"
526 | #endif
527 | const char* info_language_dialect_default =
528 | "INFO" ":" "dialect_default[" C_DIALECT "]";
529 |
530 | /*--------------------------------------------------------------------------*/
531 |
532 | #ifdef ID_VOID_MAIN
533 | void main() {}
534 | #else
535 | # if defined(__CLASSIC_C__)
536 | int main(argc, argv) int argc; char *argv[];
537 | # else
538 | int main(int argc, char* argv[])
539 | # endif
540 | {
541 | int require = 0;
542 | require += info_compiler[argc];
543 | require += info_platform[argc];
544 | require += info_arch[argc];
545 | #ifdef COMPILER_VERSION_MAJOR
546 | require += info_version[argc];
547 | #endif
548 | #ifdef SIMULATE_ID
549 | require += info_simulate[argc];
550 | #endif
551 | #ifdef SIMULATE_VERSION_MAJOR
552 | require += info_simulate_version[argc];
553 | #endif
554 | #if defined(__CRAYXE) || defined(__CRAYXC)
555 | require += info_cray[argc];
556 | #endif
557 | require += info_language_dialect_default[argc];
558 | (void)argv;
559 | return require;
560 | }
561 | #endif
562 |
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/3.6.2/CompilerIdC/a.out:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/StaticCount/CMakeFiles/3.6.2/CompilerIdC/a.out
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/3.6.2/CompilerIdCXX/CMakeCXXCompilerId.cpp:
--------------------------------------------------------------------------------
1 | /* This source file must have a .cpp extension so that all C++ compilers
2 | recognize the extension without flags. Borland does not know .cxx for
3 | example. */
4 | #ifndef __cplusplus
5 | # error "A C compiler has been selected for C++."
6 | #endif
7 |
8 |
9 | /* Version number components: V=Version, R=Revision, P=Patch
10 | Version date components: YYYY=Year, MM=Month, DD=Day */
11 |
12 | #if defined(__COMO__)
13 | # define COMPILER_ID "Comeau"
14 | /* __COMO_VERSION__ = VRR */
15 | # define COMPILER_VERSION_MAJOR DEC(__COMO_VERSION__ / 100)
16 | # define COMPILER_VERSION_MINOR DEC(__COMO_VERSION__ % 100)
17 |
18 | #elif defined(__INTEL_COMPILER) || defined(__ICC)
19 | # define COMPILER_ID "Intel"
20 | # if defined(_MSC_VER)
21 | # define SIMULATE_ID "MSVC"
22 | # endif
23 | /* __INTEL_COMPILER = VRP */
24 | # define COMPILER_VERSION_MAJOR DEC(__INTEL_COMPILER/100)
25 | # define COMPILER_VERSION_MINOR DEC(__INTEL_COMPILER/10 % 10)
26 | # if defined(__INTEL_COMPILER_UPDATE)
27 | # define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER_UPDATE)
28 | # else
29 | # define COMPILER_VERSION_PATCH DEC(__INTEL_COMPILER % 10)
30 | # endif
31 | # if defined(__INTEL_COMPILER_BUILD_DATE)
32 | /* __INTEL_COMPILER_BUILD_DATE = YYYYMMDD */
33 | # define COMPILER_VERSION_TWEAK DEC(__INTEL_COMPILER_BUILD_DATE)
34 | # endif
35 | # if defined(_MSC_VER)
36 | /* _MSC_VER = VVRR */
37 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
38 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
39 | # endif
40 |
41 | #elif defined(__PATHCC__)
42 | # define COMPILER_ID "PathScale"
43 | # define COMPILER_VERSION_MAJOR DEC(__PATHCC__)
44 | # define COMPILER_VERSION_MINOR DEC(__PATHCC_MINOR__)
45 | # if defined(__PATHCC_PATCHLEVEL__)
46 | # define COMPILER_VERSION_PATCH DEC(__PATHCC_PATCHLEVEL__)
47 | # endif
48 |
49 | #elif defined(__BORLANDC__) && defined(__CODEGEARC_VERSION__)
50 | # define COMPILER_ID "Embarcadero"
51 | # define COMPILER_VERSION_MAJOR HEX(__CODEGEARC_VERSION__>>24 & 0x00FF)
52 | # define COMPILER_VERSION_MINOR HEX(__CODEGEARC_VERSION__>>16 & 0x00FF)
53 | # define COMPILER_VERSION_PATCH DEC(__CODEGEARC_VERSION__ & 0xFFFF)
54 |
55 | #elif defined(__BORLANDC__)
56 | # define COMPILER_ID "Borland"
57 | /* __BORLANDC__ = 0xVRR */
58 | # define COMPILER_VERSION_MAJOR HEX(__BORLANDC__>>8)
59 | # define COMPILER_VERSION_MINOR HEX(__BORLANDC__ & 0xFF)
60 |
61 | #elif defined(__WATCOMC__) && __WATCOMC__ < 1200
62 | # define COMPILER_ID "Watcom"
63 | /* __WATCOMC__ = VVRR */
64 | # define COMPILER_VERSION_MAJOR DEC(__WATCOMC__ / 100)
65 | # define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
66 | # if (__WATCOMC__ % 10) > 0
67 | # define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
68 | # endif
69 |
70 | #elif defined(__WATCOMC__)
71 | # define COMPILER_ID "OpenWatcom"
72 | /* __WATCOMC__ = VVRP + 1100 */
73 | # define COMPILER_VERSION_MAJOR DEC((__WATCOMC__ - 1100) / 100)
74 | # define COMPILER_VERSION_MINOR DEC((__WATCOMC__ / 10) % 10)
75 | # if (__WATCOMC__ % 10) > 0
76 | # define COMPILER_VERSION_PATCH DEC(__WATCOMC__ % 10)
77 | # endif
78 |
79 | #elif defined(__SUNPRO_CC)
80 | # define COMPILER_ID "SunPro"
81 | # if __SUNPRO_CC >= 0x5100
82 | /* __SUNPRO_CC = 0xVRRP */
83 | # define COMPILER_VERSION_MAJOR HEX(__SUNPRO_CC>>12)
84 | # define COMPILER_VERSION_MINOR HEX(__SUNPRO_CC>>4 & 0xFF)
85 | # define COMPILER_VERSION_PATCH HEX(__SUNPRO_CC & 0xF)
86 | # else
87 | /* __SUNPRO_CC = 0xVRP */
88 | # define COMPILER_VERSION_MAJOR HEX(__SUNPRO_CC>>8)
89 | # define COMPILER_VERSION_MINOR HEX(__SUNPRO_CC>>4 & 0xF)
90 | # define COMPILER_VERSION_PATCH HEX(__SUNPRO_CC & 0xF)
91 | # endif
92 |
93 | #elif defined(__HP_aCC)
94 | # define COMPILER_ID "HP"
95 | /* __HP_aCC = VVRRPP */
96 | # define COMPILER_VERSION_MAJOR DEC(__HP_aCC/10000)
97 | # define COMPILER_VERSION_MINOR DEC(__HP_aCC/100 % 100)
98 | # define COMPILER_VERSION_PATCH DEC(__HP_aCC % 100)
99 |
100 | #elif defined(__DECCXX)
101 | # define COMPILER_ID "Compaq"
102 | /* __DECCXX_VER = VVRRTPPPP */
103 | # define COMPILER_VERSION_MAJOR DEC(__DECCXX_VER/10000000)
104 | # define COMPILER_VERSION_MINOR DEC(__DECCXX_VER/100000 % 100)
105 | # define COMPILER_VERSION_PATCH DEC(__DECCXX_VER % 10000)
106 |
107 | #elif defined(__IBMCPP__) && defined(__COMPILER_VER__)
108 | # define COMPILER_ID "zOS"
109 | /* __IBMCPP__ = VRP */
110 | # define COMPILER_VERSION_MAJOR DEC(__IBMCPP__/100)
111 | # define COMPILER_VERSION_MINOR DEC(__IBMCPP__/10 % 10)
112 | # define COMPILER_VERSION_PATCH DEC(__IBMCPP__ % 10)
113 |
114 | #elif defined(__IBMCPP__) && !defined(__COMPILER_VER__) && __IBMCPP__ >= 800
115 | # define COMPILER_ID "XL"
116 | /* __IBMCPP__ = VRP */
117 | # define COMPILER_VERSION_MAJOR DEC(__IBMCPP__/100)
118 | # define COMPILER_VERSION_MINOR DEC(__IBMCPP__/10 % 10)
119 | # define COMPILER_VERSION_PATCH DEC(__IBMCPP__ % 10)
120 |
121 | #elif defined(__IBMCPP__) && !defined(__COMPILER_VER__) && __IBMCPP__ < 800
122 | # define COMPILER_ID "VisualAge"
123 | /* __IBMCPP__ = VRP */
124 | # define COMPILER_VERSION_MAJOR DEC(__IBMCPP__/100)
125 | # define COMPILER_VERSION_MINOR DEC(__IBMCPP__/10 % 10)
126 | # define COMPILER_VERSION_PATCH DEC(__IBMCPP__ % 10)
127 |
128 | #elif defined(__PGI)
129 | # define COMPILER_ID "PGI"
130 | # define COMPILER_VERSION_MAJOR DEC(__PGIC__)
131 | # define COMPILER_VERSION_MINOR DEC(__PGIC_MINOR__)
132 | # if defined(__PGIC_PATCHLEVEL__)
133 | # define COMPILER_VERSION_PATCH DEC(__PGIC_PATCHLEVEL__)
134 | # endif
135 |
136 | #elif defined(_CRAYC)
137 | # define COMPILER_ID "Cray"
138 | # define COMPILER_VERSION_MAJOR DEC(_RELEASE_MAJOR)
139 | # define COMPILER_VERSION_MINOR DEC(_RELEASE_MINOR)
140 |
141 | #elif defined(__TI_COMPILER_VERSION__)
142 | # define COMPILER_ID "TI"
143 | /* __TI_COMPILER_VERSION__ = VVVRRRPPP */
144 | # define COMPILER_VERSION_MAJOR DEC(__TI_COMPILER_VERSION__/1000000)
145 | # define COMPILER_VERSION_MINOR DEC(__TI_COMPILER_VERSION__/1000 % 1000)
146 | # define COMPILER_VERSION_PATCH DEC(__TI_COMPILER_VERSION__ % 1000)
147 |
148 | #elif defined(__FUJITSU) || defined(__FCC_VERSION) || defined(__fcc_version)
149 | # define COMPILER_ID "Fujitsu"
150 |
151 | #elif defined(__SCO_VERSION__)
152 | # define COMPILER_ID "SCO"
153 |
154 | #elif defined(__clang__) && defined(__apple_build_version__)
155 | # define COMPILER_ID "AppleClang"
156 | # if defined(_MSC_VER)
157 | # define SIMULATE_ID "MSVC"
158 | # endif
159 | # define COMPILER_VERSION_MAJOR DEC(__clang_major__)
160 | # define COMPILER_VERSION_MINOR DEC(__clang_minor__)
161 | # define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
162 | # if defined(_MSC_VER)
163 | /* _MSC_VER = VVRR */
164 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
165 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
166 | # endif
167 | # define COMPILER_VERSION_TWEAK DEC(__apple_build_version__)
168 |
169 | #elif defined(__clang__)
170 | # define COMPILER_ID "Clang"
171 | # if defined(_MSC_VER)
172 | # define SIMULATE_ID "MSVC"
173 | # endif
174 | # define COMPILER_VERSION_MAJOR DEC(__clang_major__)
175 | # define COMPILER_VERSION_MINOR DEC(__clang_minor__)
176 | # define COMPILER_VERSION_PATCH DEC(__clang_patchlevel__)
177 | # if defined(_MSC_VER)
178 | /* _MSC_VER = VVRR */
179 | # define SIMULATE_VERSION_MAJOR DEC(_MSC_VER / 100)
180 | # define SIMULATE_VERSION_MINOR DEC(_MSC_VER % 100)
181 | # endif
182 |
183 | #elif defined(__GNUC__)
184 | # define COMPILER_ID "GNU"
185 | # define COMPILER_VERSION_MAJOR DEC(__GNUC__)
186 | # if defined(__GNUC_MINOR__)
187 | # define COMPILER_VERSION_MINOR DEC(__GNUC_MINOR__)
188 | # endif
189 | # if defined(__GNUC_PATCHLEVEL__)
190 | # define COMPILER_VERSION_PATCH DEC(__GNUC_PATCHLEVEL__)
191 | # endif
192 |
193 | #elif defined(_MSC_VER)
194 | # define COMPILER_ID "MSVC"
195 | /* _MSC_VER = VVRR */
196 | # define COMPILER_VERSION_MAJOR DEC(_MSC_VER / 100)
197 | # define COMPILER_VERSION_MINOR DEC(_MSC_VER % 100)
198 | # if defined(_MSC_FULL_VER)
199 | # if _MSC_VER >= 1400
200 | /* _MSC_FULL_VER = VVRRPPPPP */
201 | # define COMPILER_VERSION_PATCH DEC(_MSC_FULL_VER % 100000)
202 | # else
203 | /* _MSC_FULL_VER = VVRRPPPP */
204 | # define COMPILER_VERSION_PATCH DEC(_MSC_FULL_VER % 10000)
205 | # endif
206 | # endif
207 | # if defined(_MSC_BUILD)
208 | # define COMPILER_VERSION_TWEAK DEC(_MSC_BUILD)
209 | # endif
210 |
211 | #elif defined(__VISUALDSPVERSION__) || defined(__ADSPBLACKFIN__) || defined(__ADSPTS__) || defined(__ADSP21000__)
212 | # define COMPILER_ID "ADSP"
213 | #if defined(__VISUALDSPVERSION__)
214 | /* __VISUALDSPVERSION__ = 0xVVRRPP00 */
215 | # define COMPILER_VERSION_MAJOR HEX(__VISUALDSPVERSION__>>24)
216 | # define COMPILER_VERSION_MINOR HEX(__VISUALDSPVERSION__>>16 & 0xFF)
217 | # define COMPILER_VERSION_PATCH HEX(__VISUALDSPVERSION__>>8 & 0xFF)
218 | #endif
219 |
220 | #elif defined(__IAR_SYSTEMS_ICC__ ) || defined(__IAR_SYSTEMS_ICC)
221 | # define COMPILER_ID "IAR"
222 |
223 | #elif defined(__ARMCC_VERSION)
224 | # define COMPILER_ID "ARMCC"
225 | #if __ARMCC_VERSION >= 1000000
226 | /* __ARMCC_VERSION = VRRPPPP */
227 | # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/1000000)
228 | # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 100)
229 | # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
230 | #else
231 | /* __ARMCC_VERSION = VRPPPP */
232 | # define COMPILER_VERSION_MAJOR DEC(__ARMCC_VERSION/100000)
233 | # define COMPILER_VERSION_MINOR DEC(__ARMCC_VERSION/10000 % 10)
234 | # define COMPILER_VERSION_PATCH DEC(__ARMCC_VERSION % 10000)
235 | #endif
236 |
237 |
238 | #elif defined(_SGI_COMPILER_VERSION) || defined(_COMPILER_VERSION)
239 | # define COMPILER_ID "MIPSpro"
240 | # if defined(_SGI_COMPILER_VERSION)
241 | /* _SGI_COMPILER_VERSION = VRP */
242 | # define COMPILER_VERSION_MAJOR DEC(_SGI_COMPILER_VERSION/100)
243 | # define COMPILER_VERSION_MINOR DEC(_SGI_COMPILER_VERSION/10 % 10)
244 | # define COMPILER_VERSION_PATCH DEC(_SGI_COMPILER_VERSION % 10)
245 | # else
246 | /* _COMPILER_VERSION = VRP */
247 | # define COMPILER_VERSION_MAJOR DEC(_COMPILER_VERSION/100)
248 | # define COMPILER_VERSION_MINOR DEC(_COMPILER_VERSION/10 % 10)
249 | # define COMPILER_VERSION_PATCH DEC(_COMPILER_VERSION % 10)
250 | # endif
251 |
252 |
253 | /* These compilers are either not known or too old to define an
254 | identification macro. Try to identify the platform and guess that
255 | it is the native compiler. */
256 | #elif defined(__sgi)
257 | # define COMPILER_ID "MIPSpro"
258 |
259 | #elif defined(__hpux) || defined(__hpua)
260 | # define COMPILER_ID "HP"
261 |
262 | #else /* unknown compiler */
263 | # define COMPILER_ID ""
264 | #endif
265 |
266 | /* Construct the string literal in pieces to prevent the source from
267 | getting matched. Store it in a pointer rather than an array
268 | because some compilers will just produce instructions to fill the
269 | array rather than assigning a pointer to a static array. */
270 | char const* info_compiler = "INFO" ":" "compiler[" COMPILER_ID "]";
271 | #ifdef SIMULATE_ID
272 | char const* info_simulate = "INFO" ":" "simulate[" SIMULATE_ID "]";
273 | #endif
274 |
275 | #ifdef __QNXNTO__
276 | char const* qnxnto = "INFO" ":" "qnxnto[]";
277 | #endif
278 |
279 | #if defined(__CRAYXE) || defined(__CRAYXC)
280 | char const *info_cray = "INFO" ":" "compiler_wrapper[CrayPrgEnv]";
281 | #endif
282 |
283 | #define STRINGIFY_HELPER(X) #X
284 | #define STRINGIFY(X) STRINGIFY_HELPER(X)
285 |
286 | /* Identify known platforms by name. */
287 | #if defined(__linux) || defined(__linux__) || defined(linux)
288 | # define PLATFORM_ID "Linux"
289 |
290 | #elif defined(__CYGWIN__)
291 | # define PLATFORM_ID "Cygwin"
292 |
293 | #elif defined(__MINGW32__)
294 | # define PLATFORM_ID "MinGW"
295 |
296 | #elif defined(__APPLE__)
297 | # define PLATFORM_ID "Darwin"
298 |
299 | #elif defined(_WIN32) || defined(__WIN32__) || defined(WIN32)
300 | # define PLATFORM_ID "Windows"
301 |
302 | #elif defined(__FreeBSD__) || defined(__FreeBSD)
303 | # define PLATFORM_ID "FreeBSD"
304 |
305 | #elif defined(__NetBSD__) || defined(__NetBSD)
306 | # define PLATFORM_ID "NetBSD"
307 |
308 | #elif defined(__OpenBSD__) || defined(__OPENBSD)
309 | # define PLATFORM_ID "OpenBSD"
310 |
311 | #elif defined(__sun) || defined(sun)
312 | # define PLATFORM_ID "SunOS"
313 |
314 | #elif defined(_AIX) || defined(__AIX) || defined(__AIX__) || defined(__aix) || defined(__aix__)
315 | # define PLATFORM_ID "AIX"
316 |
317 | #elif defined(__sgi) || defined(__sgi__) || defined(_SGI)
318 | # define PLATFORM_ID "IRIX"
319 |
320 | #elif defined(__hpux) || defined(__hpux__)
321 | # define PLATFORM_ID "HP-UX"
322 |
323 | #elif defined(__HAIKU__)
324 | # define PLATFORM_ID "Haiku"
325 |
326 | #elif defined(__BeOS) || defined(__BEOS__) || defined(_BEOS)
327 | # define PLATFORM_ID "BeOS"
328 |
329 | #elif defined(__QNX__) || defined(__QNXNTO__)
330 | # define PLATFORM_ID "QNX"
331 |
332 | #elif defined(__tru64) || defined(_tru64) || defined(__TRU64__)
333 | # define PLATFORM_ID "Tru64"
334 |
335 | #elif defined(__riscos) || defined(__riscos__)
336 | # define PLATFORM_ID "RISCos"
337 |
338 | #elif defined(__sinix) || defined(__sinix__) || defined(__SINIX__)
339 | # define PLATFORM_ID "SINIX"
340 |
341 | #elif defined(__UNIX_SV__)
342 | # define PLATFORM_ID "UNIX_SV"
343 |
344 | #elif defined(__bsdos__)
345 | # define PLATFORM_ID "BSDOS"
346 |
347 | #elif defined(_MPRAS) || defined(MPRAS)
348 | # define PLATFORM_ID "MP-RAS"
349 |
350 | #elif defined(__osf) || defined(__osf__)
351 | # define PLATFORM_ID "OSF1"
352 |
353 | #elif defined(_SCO_SV) || defined(SCO_SV) || defined(sco_sv)
354 | # define PLATFORM_ID "SCO_SV"
355 |
356 | #elif defined(__ultrix) || defined(__ultrix__) || defined(_ULTRIX)
357 | # define PLATFORM_ID "ULTRIX"
358 |
359 | #elif defined(__XENIX__) || defined(_XENIX) || defined(XENIX)
360 | # define PLATFORM_ID "Xenix"
361 |
362 | #elif defined(__WATCOMC__)
363 | # if defined(__LINUX__)
364 | # define PLATFORM_ID "Linux"
365 |
366 | # elif defined(__DOS__)
367 | # define PLATFORM_ID "DOS"
368 |
369 | # elif defined(__OS2__)
370 | # define PLATFORM_ID "OS2"
371 |
372 | # elif defined(__WINDOWS__)
373 | # define PLATFORM_ID "Windows3x"
374 |
375 | # else /* unknown platform */
376 | # define PLATFORM_ID
377 | # endif
378 |
379 | #else /* unknown platform */
380 | # define PLATFORM_ID
381 |
382 | #endif
383 |
384 | /* For windows compilers MSVC and Intel we can determine
385 | the architecture of the compiler being used. This is because
386 | the compilers do not have flags that can change the architecture,
387 | but rather depend on which compiler is being used
388 | */
389 | #if defined(_WIN32) && defined(_MSC_VER)
390 | # if defined(_M_IA64)
391 | # define ARCHITECTURE_ID "IA64"
392 |
393 | # elif defined(_M_X64) || defined(_M_AMD64)
394 | # define ARCHITECTURE_ID "x64"
395 |
396 | # elif defined(_M_IX86)
397 | # define ARCHITECTURE_ID "X86"
398 |
399 | # elif defined(_M_ARM)
400 | # if _M_ARM == 4
401 | # define ARCHITECTURE_ID "ARMV4I"
402 | # elif _M_ARM == 5
403 | # define ARCHITECTURE_ID "ARMV5I"
404 | # else
405 | # define ARCHITECTURE_ID "ARMV" STRINGIFY(_M_ARM)
406 | # endif
407 |
408 | # elif defined(_M_MIPS)
409 | # define ARCHITECTURE_ID "MIPS"
410 |
411 | # elif defined(_M_SH)
412 | # define ARCHITECTURE_ID "SHx"
413 |
414 | # else /* unknown architecture */
415 | # define ARCHITECTURE_ID ""
416 | # endif
417 |
418 | #elif defined(__WATCOMC__)
419 | # if defined(_M_I86)
420 | # define ARCHITECTURE_ID "I86"
421 |
422 | # elif defined(_M_IX86)
423 | # define ARCHITECTURE_ID "X86"
424 |
425 | # else /* unknown architecture */
426 | # define ARCHITECTURE_ID ""
427 | # endif
428 |
429 | #else
430 | # define ARCHITECTURE_ID
431 | #endif
432 |
433 | /* Convert integer to decimal digit literals. */
434 | #define DEC(n) \
435 | ('0' + (((n) / 10000000)%10)), \
436 | ('0' + (((n) / 1000000)%10)), \
437 | ('0' + (((n) / 100000)%10)), \
438 | ('0' + (((n) / 10000)%10)), \
439 | ('0' + (((n) / 1000)%10)), \
440 | ('0' + (((n) / 100)%10)), \
441 | ('0' + (((n) / 10)%10)), \
442 | ('0' + ((n) % 10))
443 |
444 | /* Convert integer to hex digit literals. */
445 | #define HEX(n) \
446 | ('0' + ((n)>>28 & 0xF)), \
447 | ('0' + ((n)>>24 & 0xF)), \
448 | ('0' + ((n)>>20 & 0xF)), \
449 | ('0' + ((n)>>16 & 0xF)), \
450 | ('0' + ((n)>>12 & 0xF)), \
451 | ('0' + ((n)>>8 & 0xF)), \
452 | ('0' + ((n)>>4 & 0xF)), \
453 | ('0' + ((n) & 0xF))
454 |
455 | /* Construct a string literal encoding the version number components. */
456 | #ifdef COMPILER_VERSION_MAJOR
457 | char const info_version[] = {
458 | 'I', 'N', 'F', 'O', ':',
459 | 'c','o','m','p','i','l','e','r','_','v','e','r','s','i','o','n','[',
460 | COMPILER_VERSION_MAJOR,
461 | # ifdef COMPILER_VERSION_MINOR
462 | '.', COMPILER_VERSION_MINOR,
463 | # ifdef COMPILER_VERSION_PATCH
464 | '.', COMPILER_VERSION_PATCH,
465 | # ifdef COMPILER_VERSION_TWEAK
466 | '.', COMPILER_VERSION_TWEAK,
467 | # endif
468 | # endif
469 | # endif
470 | ']','\0'};
471 | #endif
472 |
473 | /* Construct a string literal encoding the version number components. */
474 | #ifdef SIMULATE_VERSION_MAJOR
475 | char const info_simulate_version[] = {
476 | 'I', 'N', 'F', 'O', ':',
477 | 's','i','m','u','l','a','t','e','_','v','e','r','s','i','o','n','[',
478 | SIMULATE_VERSION_MAJOR,
479 | # ifdef SIMULATE_VERSION_MINOR
480 | '.', SIMULATE_VERSION_MINOR,
481 | # ifdef SIMULATE_VERSION_PATCH
482 | '.', SIMULATE_VERSION_PATCH,
483 | # ifdef SIMULATE_VERSION_TWEAK
484 | '.', SIMULATE_VERSION_TWEAK,
485 | # endif
486 | # endif
487 | # endif
488 | ']','\0'};
489 | #endif
490 |
491 | /* Construct the string literal in pieces to prevent the source from
492 | getting matched. Store it in a pointer rather than an array
493 | because some compilers will just produce instructions to fill the
494 | array rather than assigning a pointer to a static array. */
495 | char const* info_platform = "INFO" ":" "platform[" PLATFORM_ID "]";
496 | char const* info_arch = "INFO" ":" "arch[" ARCHITECTURE_ID "]";
497 |
498 |
499 |
500 |
501 | const char* info_language_dialect_default = "INFO" ":" "dialect_default["
502 | #if __cplusplus >= 201402L
503 | "14"
504 | #elif __cplusplus >= 201103L
505 | "11"
506 | #else
507 | "98"
508 | #endif
509 | "]";
510 |
511 | /*--------------------------------------------------------------------------*/
512 |
513 | int main(int argc, char* argv[])
514 | {
515 | int require = 0;
516 | require += info_compiler[argc];
517 | require += info_platform[argc];
518 | #ifdef COMPILER_VERSION_MAJOR
519 | require += info_version[argc];
520 | #endif
521 | #ifdef SIMULATE_ID
522 | require += info_simulate[argc];
523 | #endif
524 | #ifdef SIMULATE_VERSION_MAJOR
525 | require += info_simulate_version[argc];
526 | #endif
527 | #if defined(__CRAYXE) || defined(__CRAYXC)
528 | require += info_cray[argc];
529 | #endif
530 | require += info_language_dialect_default[argc];
531 | (void)argv;
532 | return require;
533 | }
534 |
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/3.6.2/CompilerIdCXX/a.out:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/StaticCount/CMakeFiles/3.6.2/CompilerIdCXX/a.out
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/cmake.check_cache:
--------------------------------------------------------------------------------
1 | # This file is generated by cmake for dependency checking of the CMakeCache.txt file
2 |
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/feature_tests.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/StaticCount/CMakeFiles/feature_tests.bin
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/feature_tests.c:
--------------------------------------------------------------------------------
1 |
2 | const char features[] = {"\n"
3 | "C_FEATURE:"
4 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400
5 | "1"
6 | #else
7 | "0"
8 | #endif
9 | "c_function_prototypes\n"
10 | "C_FEATURE:"
11 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
12 | "1"
13 | #else
14 | "0"
15 | #endif
16 | "c_restrict\n"
17 | "C_FEATURE:"
18 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L
19 | "1"
20 | #else
21 | "0"
22 | #endif
23 | "c_static_assert\n"
24 | "C_FEATURE:"
25 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
26 | "1"
27 | #else
28 | "0"
29 | #endif
30 | "c_variadic_macros\n"
31 |
32 | };
33 |
34 | int main(int argc, char** argv) { (void)argv; return features[argc]; }
35 |
--------------------------------------------------------------------------------
/StaticCount/CMakeFiles/feature_tests.cxx:
--------------------------------------------------------------------------------
1 |
2 | const char features[] = {"\n"
3 | "CXX_FEATURE:"
4 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_aggregate_nsdmi)
5 | "1"
6 | #else
7 | "0"
8 | #endif
9 | "cxx_aggregate_default_initializers\n"
10 | "CXX_FEATURE:"
11 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_alias_templates)
12 | "1"
13 | #else
14 | "0"
15 | #endif
16 | "cxx_alias_templates\n"
17 | "CXX_FEATURE:"
18 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_alignas)
19 | "1"
20 | #else
21 | "0"
22 | #endif
23 | "cxx_alignas\n"
24 | "CXX_FEATURE:"
25 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_alignas)
26 | "1"
27 | #else
28 | "0"
29 | #endif
30 | "cxx_alignof\n"
31 | "CXX_FEATURE:"
32 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_attributes)
33 | "1"
34 | #else
35 | "0"
36 | #endif
37 | "cxx_attributes\n"
38 | "CXX_FEATURE:"
39 | #if ((__clang_major__ * 100) + __clang_minor__) >= 501 && __cplusplus > 201103L
40 | "1"
41 | #else
42 | "0"
43 | #endif
44 | "cxx_attribute_deprecated\n"
45 | "CXX_FEATURE:"
46 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_auto_type)
47 | "1"
48 | #else
49 | "0"
50 | #endif
51 | "cxx_auto_type\n"
52 | "CXX_FEATURE:"
53 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_binary_literals)
54 | "1"
55 | #else
56 | "0"
57 | #endif
58 | "cxx_binary_literals\n"
59 | "CXX_FEATURE:"
60 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_constexpr)
61 | "1"
62 | #else
63 | "0"
64 | #endif
65 | "cxx_constexpr\n"
66 | "CXX_FEATURE:"
67 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_contextual_conversions)
68 | "1"
69 | #else
70 | "0"
71 | #endif
72 | "cxx_contextual_conversions\n"
73 | "CXX_FEATURE:"
74 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_decltype)
75 | "1"
76 | #else
77 | "0"
78 | #endif
79 | "cxx_decltype\n"
80 | "CXX_FEATURE:"
81 | #if ((__clang_major__ * 100) + __clang_minor__) >= 501 && __cplusplus > 201103L
82 | "1"
83 | #else
84 | "0"
85 | #endif
86 | "cxx_decltype_auto\n"
87 | "CXX_FEATURE:"
88 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_decltype_incomplete_return_types)
89 | "1"
90 | #else
91 | "0"
92 | #endif
93 | "cxx_decltype_incomplete_return_types\n"
94 | "CXX_FEATURE:"
95 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_default_function_template_args)
96 | "1"
97 | #else
98 | "0"
99 | #endif
100 | "cxx_default_function_template_args\n"
101 | "CXX_FEATURE:"
102 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_defaulted_functions)
103 | "1"
104 | #else
105 | "0"
106 | #endif
107 | "cxx_defaulted_functions\n"
108 | "CXX_FEATURE:"
109 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_defaulted_functions)
110 | "1"
111 | #else
112 | "0"
113 | #endif
114 | "cxx_defaulted_move_initializers\n"
115 | "CXX_FEATURE:"
116 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_delegating_constructors)
117 | "1"
118 | #else
119 | "0"
120 | #endif
121 | "cxx_delegating_constructors\n"
122 | "CXX_FEATURE:"
123 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_deleted_functions)
124 | "1"
125 | #else
126 | "0"
127 | #endif
128 | "cxx_deleted_functions\n"
129 | "CXX_FEATURE:"
130 | #if ((__clang_major__ * 100) + __clang_minor__) >= 501 && __cplusplus > 201103L
131 | "1"
132 | #else
133 | "0"
134 | #endif
135 | "cxx_digit_separators\n"
136 | "CXX_FEATURE:"
137 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
138 | "1"
139 | #else
140 | "0"
141 | #endif
142 | "cxx_enum_forward_declarations\n"
143 | "CXX_FEATURE:"
144 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_explicit_conversions)
145 | "1"
146 | #else
147 | "0"
148 | #endif
149 | "cxx_explicit_conversions\n"
150 | "CXX_FEATURE:"
151 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
152 | "1"
153 | #else
154 | "0"
155 | #endif
156 | "cxx_extended_friend_declarations\n"
157 | "CXX_FEATURE:"
158 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
159 | "1"
160 | #else
161 | "0"
162 | #endif
163 | "cxx_extern_templates\n"
164 | "CXX_FEATURE:"
165 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_override_control)
166 | "1"
167 | #else
168 | "0"
169 | #endif
170 | "cxx_final\n"
171 | "CXX_FEATURE:"
172 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
173 | "1"
174 | #else
175 | "0"
176 | #endif
177 | "cxx_func_identifier\n"
178 | "CXX_FEATURE:"
179 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_generalized_initializers)
180 | "1"
181 | #else
182 | "0"
183 | #endif
184 | "cxx_generalized_initializers\n"
185 | "CXX_FEATURE:"
186 | #if ((__clang_major__ * 100) + __clang_minor__) >= 501 && __cplusplus > 201103L
187 | "1"
188 | #else
189 | "0"
190 | #endif
191 | "cxx_generic_lambdas\n"
192 | "CXX_FEATURE:"
193 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_inheriting_constructors)
194 | "1"
195 | #else
196 | "0"
197 | #endif
198 | "cxx_inheriting_constructors\n"
199 | "CXX_FEATURE:"
200 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
201 | "1"
202 | #else
203 | "0"
204 | #endif
205 | "cxx_inline_namespaces\n"
206 | "CXX_FEATURE:"
207 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_lambdas)
208 | "1"
209 | #else
210 | "0"
211 | #endif
212 | "cxx_lambdas\n"
213 | "CXX_FEATURE:"
214 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_init_captures)
215 | "1"
216 | #else
217 | "0"
218 | #endif
219 | "cxx_lambda_init_captures\n"
220 | "CXX_FEATURE:"
221 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_local_type_template_args)
222 | "1"
223 | #else
224 | "0"
225 | #endif
226 | "cxx_local_type_template_args\n"
227 | "CXX_FEATURE:"
228 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
229 | "1"
230 | #else
231 | "0"
232 | #endif
233 | "cxx_long_long_type\n"
234 | "CXX_FEATURE:"
235 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_noexcept)
236 | "1"
237 | #else
238 | "0"
239 | #endif
240 | "cxx_noexcept\n"
241 | "CXX_FEATURE:"
242 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_nonstatic_member_init)
243 | "1"
244 | #else
245 | "0"
246 | #endif
247 | "cxx_nonstatic_member_init\n"
248 | "CXX_FEATURE:"
249 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_nullptr)
250 | "1"
251 | #else
252 | "0"
253 | #endif
254 | "cxx_nullptr\n"
255 | "CXX_FEATURE:"
256 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_override_control)
257 | "1"
258 | #else
259 | "0"
260 | #endif
261 | "cxx_override\n"
262 | "CXX_FEATURE:"
263 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_range_for)
264 | "1"
265 | #else
266 | "0"
267 | #endif
268 | "cxx_range_for\n"
269 | "CXX_FEATURE:"
270 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_raw_string_literals)
271 | "1"
272 | #else
273 | "0"
274 | #endif
275 | "cxx_raw_string_literals\n"
276 | "CXX_FEATURE:"
277 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_reference_qualified_functions)
278 | "1"
279 | #else
280 | "0"
281 | #endif
282 | "cxx_reference_qualified_functions\n"
283 | "CXX_FEATURE:"
284 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_relaxed_constexpr)
285 | "1"
286 | #else
287 | "0"
288 | #endif
289 | "cxx_relaxed_constexpr\n"
290 | "CXX_FEATURE:"
291 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_return_type_deduction)
292 | "1"
293 | #else
294 | "0"
295 | #endif
296 | "cxx_return_type_deduction\n"
297 | "CXX_FEATURE:"
298 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
299 | "1"
300 | #else
301 | "0"
302 | #endif
303 | "cxx_right_angle_brackets\n"
304 | "CXX_FEATURE:"
305 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_rvalue_references)
306 | "1"
307 | #else
308 | "0"
309 | #endif
310 | "cxx_rvalue_references\n"
311 | "CXX_FEATURE:"
312 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
313 | "1"
314 | #else
315 | "0"
316 | #endif
317 | "cxx_sizeof_member\n"
318 | "CXX_FEATURE:"
319 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_static_assert)
320 | "1"
321 | #else
322 | "0"
323 | #endif
324 | "cxx_static_assert\n"
325 | "CXX_FEATURE:"
326 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_strong_enums)
327 | "1"
328 | #else
329 | "0"
330 | #endif
331 | "cxx_strong_enums\n"
332 | "CXX_FEATURE:"
333 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 199711L
334 | "1"
335 | #else
336 | "0"
337 | #endif
338 | "cxx_template_template_parameters\n"
339 | "CXX_FEATURE:"
340 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_thread_local)
341 | "1"
342 | #else
343 | "0"
344 | #endif
345 | "cxx_thread_local\n"
346 | "CXX_FEATURE:"
347 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_trailing_return)
348 | "1"
349 | #else
350 | "0"
351 | #endif
352 | "cxx_trailing_return_types\n"
353 | "CXX_FEATURE:"
354 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_unicode_literals)
355 | "1"
356 | #else
357 | "0"
358 | #endif
359 | "cxx_unicode_literals\n"
360 | "CXX_FEATURE:"
361 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_generalized_initializers)
362 | "1"
363 | #else
364 | "0"
365 | #endif
366 | "cxx_uniform_initialization\n"
367 | "CXX_FEATURE:"
368 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_unrestricted_unions)
369 | "1"
370 | #else
371 | "0"
372 | #endif
373 | "cxx_unrestricted_unions\n"
374 | "CXX_FEATURE:"
375 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_user_literals)
376 | "1"
377 | #else
378 | "0"
379 | #endif
380 | "cxx_user_literals\n"
381 | "CXX_FEATURE:"
382 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_variable_templates)
383 | "1"
384 | #else
385 | "0"
386 | #endif
387 | "cxx_variable_templates\n"
388 | "CXX_FEATURE:"
389 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __cplusplus >= 201103L
390 | "1"
391 | #else
392 | "0"
393 | #endif
394 | "cxx_variadic_macros\n"
395 | "CXX_FEATURE:"
396 | #if ((__clang_major__ * 100) + __clang_minor__) >= 400 && __has_feature(cxx_variadic_templates)
397 | "1"
398 | #else
399 | "0"
400 | #endif
401 | "cxx_variadic_templates\n"
402 |
403 | };
404 |
405 | int main(int argc, char** argv) { (void)argv; return features[argc]; }
406 |
--------------------------------------------------------------------------------
/StaticCount/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | # If we don't need RTTI or EH, there's no reason to export anything
2 | # from the hello plugin.
3 | if( NOT LLVM_REQUIRES_RTTI )
4 | if( NOT LLVM_REQUIRES_EH )
5 | set(LLVM_EXPORTED_SYMBOL_FILE ${CMAKE_CURRENT_SOURCE_DIR}/StaticCount.exports)
6 | endif()
7 | endif()
8 |
9 | if(WIN32 OR CYGWIN)
10 | set(LLVM_LINK_COMPONENTS Core Support)
11 | endif()
12 |
13 | add_llvm_loadable_module( LLVMStaticCount
14 | StaticCount.cpp
15 |
16 | DEPENDS
17 | intrinsics_gen
18 | PLUGIN_TOOL
19 | opt
20 | )
21 |
--------------------------------------------------------------------------------
/StaticCount/StaticCount.cpp:
--------------------------------------------------------------------------------
1 |
2 | #include "llvm/Pass.h"
3 | #include "llvm/IR/Module.h"
4 | #include "llvm/IR/Function.h"
5 | #include "llvm/IR/BasicBlock.h"
6 | #include "llvm/ADT/Statistic.h"
7 | #include "llvm/IR/InstrTypes.h"
8 | #include "llvm/Transforms/IPO/PassManagerBuilder.h"
9 | #include "llvm/IR/IRBuilder.h"
10 | #include "llvm/Transforms/Utils/BasicBlockUtils.h"
11 | #include "llvm/IR/LegacyPassManager.h"
12 | #include "llvm/Support/raw_ostream.h"
13 |
14 | #define DEBUG_TYPE "Franklin's Static Count"
15 |
16 | STATISTIC(TotalFunctions, "Functions");
17 | STATISTIC(TotalInstructions, "Instructions");
18 | STATISTIC(TotalAlloc, "Allocations");
19 | STATISTIC(TotalBinaryOperators, "Binary Operators");
20 |
21 | using namespace llvm;
22 |
23 |
24 | namespace {
25 |
26 | struct CountStats : public ModulePass {
27 | static char ID;
28 | CountStats() : ModulePass(ID) {}
29 | bool runOnModule(Module &M);
30 | bool runOnFunction(Function &F, Module &M);
31 | };
32 |
33 | }
34 |
35 | char CountStats::ID = 0;
36 |
37 |
38 | static RegisterPass
39 | X("StaticCount", "Count Statistics", false, false);
40 |
41 |
42 | bool CountStats::runOnModule(Module &M) {
43 | for(Module::iterator F = M.begin(), E = M.end(); F != E; ++F) {
44 | ++TotalFunctions;
45 | runOnFunction(*F, M);
46 | }
47 | return false;
48 | }
49 |
50 | bool CountStats::runOnFunction(Function &F, Module &M) {
51 |
52 | for (auto& B : F) {
53 | for (auto& I : B) {
54 | if (auto* AllocInst = dyn_cast(&I)) {
55 | ++TotalAlloc;
56 | }
57 | if (auto* op = dyn_cast(&I)) {
58 | ++TotalBinaryOperators;
59 | //errs() << "Instruction: ";
60 | //errs().write_escaped(op->getName()) << '\n';
61 |
62 | //op->dump();
63 | }
64 | errs().write_escaped(I.getOpcodeName()) << '\n';
65 |
66 | }
67 | }
68 | for(Function::iterator BB = F.begin(), E = F.end(); BB != E; ++BB) {
69 |
70 | TotalInstructions += BB->getInstList().size();
71 | }
72 | return false;
73 | }
74 |
--------------------------------------------------------------------------------
/StaticCount/StaticCount.exports:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/StaticCount/StaticCount.exports
--------------------------------------------------------------------------------
/heaptime/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/heaptime/.DS_Store
--------------------------------------------------------------------------------
/heaptime/.idea/misc.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/heaptime/.idea/modules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/heaptime/.idea/workspace.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 | true
68 | DEFINITION_ORDER
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 | 1480030595771
117 |
118 |
119 | 1480030595771
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
152 |
153 |
154 |
155 |
156 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 |
166 |
167 |
168 |
169 |
170 |
171 |
172 |
173 |
174 |
175 |
176 |
177 |
178 |
179 |
180 |
181 |
182 |
183 |
184 |
185 |
186 |
--------------------------------------------------------------------------------
/heaptime/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.6)
2 | project(heaptime)
3 |
4 | set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
5 |
6 | set(SOURCE_FILES main.cpp)
7 | add_executable(heaptime ${SOURCE_FILES})
--------------------------------------------------------------------------------
/heaptime/main.cpp:
--------------------------------------------------------------------------------
1 | //Assingment 13
2 | //Franklin Boswell
3 | //COMSC 210
4 |
5 | #include
6 | #include
7 | #include
8 | #include
9 | #include
10 |
11 | using namespace std;
12 |
13 |
14 |
15 | void sort ( int x [] , int length);
16 | void buildHeap (int x [], int length);
17 | void buildHeap (int x [], int length);
18 | void reheapifyUpward (int x [], int lastIndex);
19 | void sortHeap (int x [], int length);
20 | void reheapifyDownward (int x [], int lastIndex);
21 | int findBigChildIndex (int parentIndex, int x [ ] , int lastIndex);
22 |
23 | int SIZE = 500000;
24 | int* x = NULL;
25 |
26 | int main(int argc, const char * argv[])
27 | {
28 | ofstream fout;
29 | fout.open("HeapSort.txt", ios::app);
30 |
31 | fout << "DataSize | Time in Sec" << endl;
32 | cout << "DataSize | Time in Sec" << endl;
33 | for(int z = 1; z <=5; z++)
34 | {
35 | SIZE = z*100000;
36 | x = new int[SIZE];
37 |
38 | int i;
39 | //seed srand with different value each time you run
40 | //so that rand will generate different sequence each time you run
41 | srand((unsigned )time(NULL));
42 | for ( i=0;i 1
90 | void buildHeap (int x [], int length)
91 | {
92 | int lastIndex;
93 | for (lastIndex=1; lastIndex 0 )
105 | {
106 | parentIndex = (childIndex-1)/2;
107 | if (x [childIndex] <= x [parentIndex])
108 | break;
109 | else
110 | {
111 | //swap values at childIndex and at parentIndex.
112 | temp = x [childIndex];
113 | x [childIndex] = x [parentIndex];
114 | x [parentIndex] = temp;
115 |
116 |
117 | //Update child to parent
118 | childIndex = parentIndex;
119 | }
120 | }
121 | }
122 |
123 | //Method below changes heapified array into sorted array
124 | //Pre-condition: length > 1
125 | //lastIndex is the index of the last element of the array.
126 | int findBigChildIndex (int parentIndex, int x [ ] , int lastIndex)
127 | {
128 | int lChildIndex = (2 * parentIndex) + 1;
129 | int rChildIndex = (2 * parentIndex) + 2;
130 |
131 | //case both children exist
132 | if (rChildIndex <= lastIndex && lChildIndex <= lastIndex)
133 | {
134 | if(x[rChildIndex] > x[lChildIndex])
135 | {
136 | return rChildIndex;
137 | }
138 | else if(x[rChildIndex] < x[lChildIndex])
139 | {
140 | return lChildIndex;
141 | }
142 | else
143 | {
144 | cout << "they are equal" << endl;
145 | return rChildIndex;
146 | }
147 |
148 | //compare value at rChildIndex and at lChildIndex
149 | //return the index where the value is larger
150 |
151 |
152 |
153 | }
154 | //case only left child exist
155 | else if (lChildIndex <= lastIndex)
156 | {
157 | return lChildIndex;
158 | }
159 | //case both children missing
160 |
161 | return -1;
162 |
163 | }
164 | void reheapifyDownward (int x [], int lastIndex)
165 | {
166 |
167 | int parentIndex = 0;
168 | int temp;
169 |
170 | while (parentIndex < lastIndex)
171 | {
172 | //findBigChildIndex will return a negative value if parent has no children.
173 | int bigChildIndex = findBigChildIndex (parentIndex, x, lastIndex);
174 |
175 | if (bigChildIndex < 0 || x [bigChildIndex] <= x [parentIndex])
176 | break;
177 | else
178 | {
179 | //swap value at parentIndex with value at bigChildIndex
180 | temp = x [parentIndex];
181 | x [parentIndex] = x [bigChildIndex];
182 | x [bigChildIndex] = temp;
183 |
184 |
185 | //update parentIndex
186 | parentIndex = bigChildIndex;
187 | }
188 | }
189 | }
190 |
191 | //The function will return -1 if the parent had no children.
192 |
193 | void sortHeap (int x [], int length)
194 | {
195 | int lastIndex = length - 1;
196 | int temp;
197 | while (lastIndex > 0)
198 | {
199 | //swap the contents of index 0 with contents of lastIndex
200 | temp = x [0];
201 | x [0] = x [lastIndex];
202 | x [lastIndex] = temp;
203 |
204 | //decrement the array size
205 | lastIndex--;
206 |
207 | //call reheapifyDownward. Pass it the array and the last index number of the array.
208 | reheapifyDownward(x, lastIndex);
209 |
210 | }
211 | }
--------------------------------------------------------------------------------
/images/milestone1.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/images/milestone1.jpg
--------------------------------------------------------------------------------
/images/milestone2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/images/milestone2.jpg
--------------------------------------------------------------------------------
/images/milestone2_2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/images/milestone2_2.jpg
--------------------------------------------------------------------------------
/smalltest/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/smalltest/.DS_Store
--------------------------------------------------------------------------------
/smalltest/instrumentedprogram.bc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/smalltest/instrumentedprogram.bc
--------------------------------------------------------------------------------
/smalltest/p.bc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/smalltest/p.bc
--------------------------------------------------------------------------------
/smalltest/print.c:
--------------------------------------------------------------------------------
1 | #include
2 | void BO() {
3 | printf("Message from imbedded function: Binary Operator (BB) \n");
4 | }
5 | void ALL() {
6 | printf("Message from imbedded function: Allocation (BB)\n");
7 | }
8 | void BRAN() {
9 | printf("Message from imbedded function: Branch Instruction (BB)\n");
10 | }
11 | void LOAD() {
12 | printf("Message from imbedded function: Load (BB)\n");
13 | }
14 | void STORE() {
15 | printf("Message from imbedded function: Store (BB)\n");
16 | }
17 | void CALL() {
18 | printf("Message from imbedded function: Call Instruction (BB)\n");
19 | }
20 | void INST() {
21 | printf("Message from imbedded function: Instruction (BB)\n");
22 | }
23 |
--------------------------------------------------------------------------------
/smalltest/smallProgram.c:
--------------------------------------------------------------------------------
1 |
2 |
3 | #include
4 |
5 | void foo();
6 | void bar();
7 |
8 |
9 | #include
10 |
11 | int main()
12 | {
13 |
14 | printf("\nTarget Program: Hello Begin llvm test program\n \n");
15 |
16 | int test = 4;
17 | int test2 = 4;
18 | test = test + test2;
19 | printf("\nTarget Program: Defined some ints and did some addition.\n \n");
20 |
21 | foo();
22 | printf("\nTarget Program: Called a function.\n \n");
23 |
24 | while(test >=1){
25 | test = test - 1;
26 | bar();
27 | }
28 | printf("\nTarget Program: At the end.\n \n");
29 | return 0;
30 | }
31 |
32 |
33 | void foo()
34 | {
35 | int temp = 1;
36 | int temp2 = 2;
37 | temp = temp + temp2;
38 | printf("\nTarget Program: At the end of function is run before the loop.\n \n");
39 | }
40 |
41 |
42 | void bar()
43 | {
44 | int temp = 1;
45 | int temp2 = 2;
46 | temp = temp + temp2;
47 | printf("\nTarget Program: This function is run every iteration of a loop.\n \n");
48 | }
49 |
--------------------------------------------------------------------------------
/smalltest/smallprogramandprint.bc:
--------------------------------------------------------------------------------
1 | ; ModuleID = 'llvm-link'
2 | source_filename = "llvm-link"
3 | target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128"
4 | target triple = "x86_64-apple-macosx10.12.0"
5 |
6 | @.str = private unnamed_addr constant [59 x i8] c"Message from imbedded function: Binary Operator (BB) \0A\00", align 1
7 | @.str.1 = private unnamed_addr constant [58 x i8] c"Message from imbedded function: Allocation (BB)\0A\00", align 1
8 | @.str.2 = private unnamed_addr constant [58 x i8] c"Message from imbedded function: Branch Instruction (BB)\0A\00", align 1
9 | @.str.3 = private unnamed_addr constant [58 x i8] c"Message from imbedded function: Load (BB)\0A\00", align 1
10 | @.str.4 = private unnamed_addr constant [58 x i8] c"Message from imbedded function: Store (BB)\0A\00", align 1
11 | @.str.5 = private unnamed_addr constant [58 x i8] c"Message from imbedded function: Call Instruction (BB)\0A\00", align 1
12 | @.str.6 = private unnamed_addr constant [58 x i8] c"Message from imbedded function: Instruction (BB)\0A\00", align 1
13 | @.str.7 = private unnamed_addr constant [50 x i8] c"\0ATarget Program: Hello Begin llvm test program\0A \0A\00", align 1
14 | @.str.1.8 = private unnamed_addr constant [61 x i8] c"\0ATarget Program: Defined some ints and did some addition.\0A \0A\00", align 1
15 | @.str.2.9 = private unnamed_addr constant [39 x i8] c"\0ATarget Program: Called a function.\0A \0A\00", align 1
16 | @.str.3.10 = private unnamed_addr constant [32 x i8] c"\0ATarget Program: At the end.\0A \0A\00", align 1
17 | @.str.5.11 = private unnamed_addr constant [68 x i8] c"\0ATarget Program: This function is run every iteration of a loop.\0A \0A\00", align 1
18 | @.str.4.12 = private unnamed_addr constant [67 x i8] c"\0ATarget Program: At the end of function is run before the loop.\0A \0A\00", align 1
19 |
20 | ; Function Attrs: nounwind ssp uwtable
21 | define void @BO() #0 {
22 | entry:
23 | %call = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([59 x i8], [59 x i8]* @.str, i32 0, i32 0))
24 | ret void
25 | }
26 |
27 | declare i32 @printf(i8*, ...) #1
28 |
29 | ; Function Attrs: nounwind ssp uwtable
30 | define void @ALL() #0 {
31 | entry:
32 | %call = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([58 x i8], [58 x i8]* @.str.1, i32 0, i32 0))
33 | ret void
34 | }
35 |
36 | ; Function Attrs: nounwind ssp uwtable
37 | define void @BRAN() #0 {
38 | entry:
39 | %call = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([58 x i8], [58 x i8]* @.str.2, i32 0, i32 0))
40 | ret void
41 | }
42 |
43 | ; Function Attrs: nounwind ssp uwtable
44 | define void @LOAD() #0 {
45 | entry:
46 | %call = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([58 x i8], [58 x i8]* @.str.3, i32 0, i32 0))
47 | ret void
48 | }
49 |
50 | ; Function Attrs: nounwind ssp uwtable
51 | define void @STORE() #0 {
52 | entry:
53 | %call = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([58 x i8], [58 x i8]* @.str.4, i32 0, i32 0))
54 | ret void
55 | }
56 |
57 | ; Function Attrs: nounwind ssp uwtable
58 | define void @CALL() #0 {
59 | entry:
60 | %call = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([58 x i8], [58 x i8]* @.str.5, i32 0, i32 0))
61 | ret void
62 | }
63 |
64 | ; Function Attrs: nounwind ssp uwtable
65 | define void @INST() #0 {
66 | entry:
67 | %call = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([58 x i8], [58 x i8]* @.str.6, i32 0, i32 0))
68 | ret void
69 | }
70 |
71 | ; Function Attrs: nounwind ssp uwtable
72 | define i32 @main() #0 {
73 | entry:
74 | %retval = alloca i32, align 4
75 | %test = alloca i32, align 4
76 | %test2 = alloca i32, align 4
77 | store i32 0, i32* %retval, align 4
78 | %call = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.7, i32 0, i32 0))
79 | store i32 4, i32* %test, align 4
80 | store i32 4, i32* %test2, align 4
81 | %0 = load i32, i32* %test, align 4
82 | %1 = load i32, i32* %test2, align 4
83 | %add = add nsw i32 %0, %1
84 | store i32 %add, i32* %test, align 4
85 | %call1 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([61 x i8], [61 x i8]* @.str.1.8, i32 0, i32 0))
86 | call void @foo()
87 | %call2 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.2.9, i32 0, i32 0))
88 | br label %while.cond
89 |
90 | while.cond: ; preds = %while.body, %entry
91 | %2 = load i32, i32* %test, align 4
92 | %cmp = icmp sge i32 %2, 1
93 | br i1 %cmp, label %while.body, label %while.end
94 |
95 | while.body: ; preds = %while.cond
96 | %3 = load i32, i32* %test, align 4
97 | %sub = sub nsw i32 %3, 1
98 | store i32 %sub, i32* %test, align 4
99 | call void @bar()
100 | br label %while.cond
101 |
102 | while.end: ; preds = %while.cond
103 | %call3 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.3.10, i32 0, i32 0))
104 | ret i32 0
105 | }
106 |
107 | ; Function Attrs: nounwind ssp uwtable
108 | define void @foo() #0 {
109 | entry:
110 | %temp = alloca i32, align 4
111 | %temp2 = alloca i32, align 4
112 | store i32 1, i32* %temp, align 4
113 | store i32 2, i32* %temp2, align 4
114 | %0 = load i32, i32* %temp, align 4
115 | %1 = load i32, i32* %temp2, align 4
116 | %add = add nsw i32 %0, %1
117 | store i32 %add, i32* %temp, align 4
118 | %call = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([67 x i8], [67 x i8]* @.str.4.12, i32 0, i32 0))
119 | ret void
120 | }
121 |
122 | ; Function Attrs: nounwind ssp uwtable
123 | define void @bar() #0 {
124 | entry:
125 | %temp = alloca i32, align 4
126 | %temp2 = alloca i32, align 4
127 | store i32 1, i32* %temp, align 4
128 | store i32 2, i32* %temp2, align 4
129 | %0 = load i32, i32* %temp, align 4
130 | %1 = load i32, i32* %temp2, align 4
131 | %add = add nsw i32 %0, %1
132 | store i32 %add, i32* %temp, align 4
133 | %call = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([68 x i8], [68 x i8]* @.str.5.11, i32 0, i32 0))
134 | ret void
135 | }
136 |
137 | attributes #0 = { nounwind ssp uwtable "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "no-frame-pointer-elim-non-leaf" "no-infs-fp-math"="false" "no-jump-tables"="false" "no-nans-fp-math"="false" "no-signed-zeros-fp-math"="false" "no-trapping-math"="false" "stack-protector-buffer-size"="8" "target-cpu"="core2" "target-features"="+cx16,+fxsr,+mmx,+sse,+sse2,+sse3,+ssse3,+x87" "unsafe-fp-math"="false" "use-soft-float"="false" }
138 | attributes #1 = { "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "no-frame-pointer-elim-non-leaf" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "no-signed-zeros-fp-math"="false" "no-trapping-math"="false" "stack-protector-buffer-size"="8" "target-cpu"="core2" "target-features"="+cx16,+fxsr,+mmx,+sse,+sse2,+sse3,+ssse3,+x87" "unsafe-fp-math"="false" "use-soft-float"="false" }
139 |
140 | !llvm.ident = !{!0, !0}
141 | !llvm.module.flags = !{!1}
142 |
143 | !0 = !{!"clang version 4.0.0 (trunk 283174) (llvm/trunk 283173)"}
144 | !1 = !{i32 1, !"PIC Level", i32 2}
145 |
--------------------------------------------------------------------------------
/smalltest/sp.bc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/fhboswell/llvm-analysis-and-transform-passes/e4cde5e8b259142cf0dd23adaeb9dc6fb8c006bb/smalltest/sp.bc
--------------------------------------------------------------------------------