{"action":"created","issue":{"url":"https://api.github.com/repos/eliben/llvm-clang-samples/issues/23","labels_url":"https://api.github.com/repos/eliben/llvm-clang-samples/issues/23/labels{/name}","comments_url":"https://api.github.com/repos/eliben/llvm-clang-samples/issues/23/comments","events_url":"https://api.github.com/repos/eliben/llvm-clang-samples/issues/23/events","html_url":"https://github.com/eliben/llvm-clang-samples/issues/23","id":112550755,"number":23,"title":"Time needed to compile a sample?","user":{"login":"Lekensteyn","id":164530,"avatar_url":"https://avatars.githubusercontent.com/u/164530?v=3","gravatar_id":"","url":"https://api.github.com/users/Lekensteyn","html_url":"https://github.com/Lekensteyn","followers_url":"https://api.github.com/users/Lekensteyn/followers","following_url":"https://api.github.com/users/Lekensteyn/following{/other_user}","gists_url":"https://api.github.com/users/Lekensteyn/gists{/gist_id}","starred_url":"https://api.github.com/users/Lekensteyn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Lekensteyn/subscriptions","organizations_url":"https://api.github.com/users/Lekensteyn/orgs","repos_url":"https://api.github.com/users/Lekensteyn/repos","events_url":"https://api.github.com/users/Lekensteyn/events{/privacy}","received_events_url":"https://api.github.com/users/Lekensteyn/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-10-21T09:47:14Z","updated_at":"2015-10-22T23:54:51Z","closed_at":null,"body":"For some reason `make build/matchers_replacements` takes quite some time to compile. This was observed with clang 3.7.0-4 binaries from Arch Linux x86_64. On my i5-560M laptop, it takes 20.5 seconds. On an i7-3770 it takes 10 seconds.\r\n\r\nAre these numbers expected? What can I do to improve this process?\r\n\r\nEdit: maybe it takes so long because `llvm-config --cxxflags` (built using cmake and gcc) injects -`O3` in the flags...?\r\nEdit2: nope, removal of `-O[23]` does not make a difference.\r\n\r\n```\r\n$ /usr/bin/llvm-config --cxxflags\r\n-I/usr/include -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong --param=ssp-buffer-size=4  -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wnon-virtual-dtor -Wno-comment -std=c++11 -ffunction-sections -fdata-sections -O3 -DNDEBUG  -fno-exceptions  -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS\r\n\r\n$ llvm-config --ldflags --libs --system-libs\r\n-L/usr/lib \r\n-lLLVMLTO -lLLVMObjCARCOpts -lLLVMLinker -lLLVMBitWriter -lLLVMIRReader -lLLVMXCoreDisassembler -lLLVMXCoreCodeGen -lLLVMXCoreDesc -lLLVMXCoreInfo -lLLVMXCoreAsmPrinter -lLLVMSystemZDisassembler -lLLVMSystemZCodeGen -lLLVMSystemZAsmParser -lLLVMSystemZDesc -lLLVMSystemZInfo -lLLVMSystemZAsmPrinter -lLLVMSparcDisassembler -lLLVMSparcCodeGen -lLLVMSparcAsmParser -lLLVMSparcDesc -lLLVMSparcInfo -lLLVMSparcAsmPrinter -lLLVMPowerPCDisassembler -lLLVMPowerPCCodeGen -lLLVMPowerPCAsmParser -lLLVMPowerPCDesc -lLLVMPowerPCInfo -lLLVMPowerPCAsmPrinter -lLLVMNVPTXCodeGen -lLLVMNVPTXDesc -lLLVMNVPTXInfo -lLLVMNVPTXAsmPrinter -lLLVMMSP430CodeGen -lLLVMMSP430Desc -lLLVMMSP430Info -lLLVMMSP430AsmPrinter -lLLVMMipsDisassembler -lLLVMMipsCodeGen -lLLVMMipsAsmParser -lLLVMMipsDesc -lLLVMMipsInfo -lLLVMMipsAsmPrinter -lLLVMHexagonDisassembler -lLLVMHexagonCodeGen -lLLVMHexagonDesc -lLLVMHexagonInfo -lLLVMCppBackendCodeGen -lLLVMCppBackendInfo -lLLVMBPFCodeGen -lLLVMBPFDesc -lLLVMBPFInfo -lLLVMBPFAsmPrinter -lLLVMARMDisassembler -lLLVMARMCodeGen -lLLVMARMAsmParser -lLLVMARMDesc -lLLVMARMInfo -lLLVMARMAsmPrinter -lLLVMAMDGPUCodeGen -lLLVMAMDGPUAsmParser -lLLVMAMDGPUUtils -lLLVMAMDGPUDesc -lLLVMAMDGPUInfo -lLLVMAMDGPUAsmPrinter -lLLVMAArch64Disassembler -lLLVMAArch64CodeGen -lLLVMAArch64AsmParser -lLLVMAArch64Desc -lLLVMAArch64Info -lLLVMAArch64AsmPrinter -lLLVMAArch64Utils -lLLVMMIRParser -lLLVMAsmParser -lLLVMLibDriver -lLLVMOption -lLLVMDebugInfoPDB -lLLVMTableGen -lLLVMOrcJIT -lLLVMLineEditor -lLLVMX86Disassembler -lLLVMX86AsmParser -lLLVMX86CodeGen -lLLVMSelectionDAG -lLLVMAsmPrinter -lLLVMX86Desc -lLLVMMCDisassembler -lLLVMX86Info -lLLVMX86AsmPrinter -lLLVMX86Utils -lLLVMMCJIT -lLLVMDebugInfoDWARF -lLLVMPasses -lLLVMipo -lLLVMVectorize -lLLVMInterpreter -lLLVMExecutionEngine -lLLVMRuntimeDyld -lLLVMCodeGen -lLLVMTarget -lLLVMScalarOpts -lLLVMProfileData -lLLVMObject -lLLVMMCParser -lLLVMBitReader -lLLVMInstCombine -lLLVMInstrumentation -lLLVMTransformUtils -lLLVMipa -lLLVMMC -lLLVMAnalysis -lLLVMCore -lLLVMSupport\r\n-lrt -ldl -lcurses -lpthread -lz -lm\r\n$ time make matchers_replacements\r\n-----------------------------------------------\r\nUsing LLVM_SRC_PATH = $HOME/llvm/llvm_svn_rw\r\nUsing LLVM_BUILD_PATH = $HOME/llvm/build/svn-make-debug\r\nUsing LLVM_BIN_PATH = /usr/bin\r\n-----------------------------------------------\r\nclang++ -fno-rtti -O0 -g -ftime-report `/usr/bin/llvm-config --cxxflags` -I$HOME/llvm/llvm_svn_rw/tools/clang/include -I$HOME/llvm/build/svn-make-debug/tools/clang/include src_clang/matchers_replacements.cpp \\\r\n\t-Wl,--start-group -lclangAST -lclangAnalysis -lclangBasic -lclangDriver -lclangEdit -lclangFrontend -lclangFrontendTool -lclangLex -lclangParse -lclangSema -lclangEdit -lclangASTMatchers -lclangRewrite -lclangRewriteFrontend -lclangStaticAnalyzerFrontend -lclangStaticAnalyzerCheckers -lclangStaticAnalyzerCore -lclangSerialization -lclangToolingCore -lclangTooling -Wl,--end-group `/usr/bin/llvm-config --ldflags --libs --system-libs` -o build/matchers_replacements\r\nwarning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]\r\n===-------------------------------------------------------------------------===\r\n                         Miscellaneous Ungrouped Timers\r\n===-------------------------------------------------------------------------===\r\n\r\n   ---User Time---   --System Time--   --User+System--   ---Wall Time---  --- Name ---\r\n   1.8480 ( 59.0%)   1.2320 ( 87.3%)   3.0800 ( 67.8%)   3.0810 ( 66.9%)  Code Generation Time\r\n   1.2840 ( 41.0%)   0.1800 ( 12.7%)   1.4640 ( 32.2%)   1.5244 ( 33.1%)  LLVM IR Generation Time\r\n   3.1320 (100.0%)   1.4120 (100.0%)   4.5440 (100.0%)   4.6054 (100.0%)  Total\r\n\r\n1 warning generated.\r\n===-------------------------------------------------------------------------===\r\n                              Register Allocation\r\n===-------------------------------------------------------------------------===\r\n  Total Execution Time: 0.0000 seconds (0.0007 wall clock)\r\n\r\n   ---Wall Time---  --- Name ---\r\n   0.0003 ( 40.7%)  Evict\r\n   0.0002 ( 29.5%)  Global Splitting\r\n   0.0001 ( 16.7%)  Seed Live Regs\r\n   0.0001 ( 12.3%)  Spiller\r\n   0.0000 (  0.8%)  Local Splitting\r\n   0.0007 (100.0%)  Total\r\n\r\n===-------------------------------------------------------------------------===\r\n                      Instruction Selection and Scheduling\r\n===-------------------------------------------------------------------------===\r\n  Total Execution Time: 0.0080 seconds (0.0181 wall clock)\r\n\r\n   ---User Time---   --System Time--   --User+System--   ---Wall Time---  --- Name ---\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0033 ( 18.2%)  Instruction Selection\r\n   0.0040 (100.0%)   0.0000 (  0.0%)   0.0040 ( 50.0%)   0.0029 ( 15.9%)  DAG Combining 1\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0027 ( 14.9%)  Instruction Scheduling\r\n   0.0000 (  0.0%)   0.0040 (100.0%)   0.0040 ( 50.0%)   0.0020 ( 11.0%)  Instruction Creation\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0017 (  9.4%)  DAG Combining 2\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0016 (  8.9%)  DAG Legalization\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0014 (  7.9%)  Type Legalization\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0012 (  6.7%)  DAG Combining after legalize types\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0007 (  3.7%)  Instruction Scheduling Cleanup\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0006 (  3.5%)  Vector Legalization\r\n   0.0040 (100.0%)   0.0040 (100.0%)   0.0080 (100.0%)   0.0181 (100.0%)  Total\r\n\r\n===-------------------------------------------------------------------------===\r\n                                 DWARF Emission\r\n===-------------------------------------------------------------------------===\r\n  Total Execution Time: 0.2720 seconds (0.2729 wall clock)\r\n\r\n   ---User Time---   --System Time--   --User+System--   ---Wall Time---  --- Name ---\r\n   0.1600 ( 71.4%)   0.0120 ( 25.0%)   0.1720 ( 63.2%)   0.1696 ( 62.1%)  Debug Info Emission\r\n   0.0640 ( 28.6%)   0.0320 ( 66.7%)   0.0960 ( 35.3%)   0.0955 ( 35.0%)  DWARF Debug Writer\r\n   0.0000 (  0.0%)   0.0040 (  8.3%)   0.0040 (  1.5%)   0.0078 (  2.9%)  DWARF Exception Writer\r\n   0.2240 (100.0%)   0.0480 (100.0%)   0.2720 (100.0%)   0.2729 (100.0%)  Total\r\n\r\n===-------------------------------------------------------------------------===\r\n                      ... Pass execution timing report ...\r\n===-------------------------------------------------------------------------===\r\n  Total Execution Time: 1.9640 seconds (1.9512 wall clock)\r\n\r\n   ---User Time---   --System Time--   --User+System--   ---Wall Time---  --- Name ---\r\n   0.1160 ( 10.0%)   0.0640 (  8.0%)   0.1800 (  9.2%)   0.1963 ( 10.1%)  Function Integration/Inlining\r\n   0.0480 (  4.1%)   0.0760 (  9.5%)   0.1240 (  6.3%)   0.1269 (  6.5%)  SROA\r\n   0.0320 (  2.8%)   0.0520 (  6.5%)   0.0840 (  4.3%)   0.0880 (  4.5%)  Early CSE\r\n   0.0640 (  5.5%)   0.0400 (  5.0%)   0.1040 (  5.3%)   0.0870 (  4.5%)  Combine redundant instructions\r\n   0.0240 (  2.1%)   0.0360 (  4.5%)   0.0600 (  3.1%)   0.0651 (  3.3%)  Global Value Numbering\r\n   0.0400 (  3.4%)   0.0360 (  4.5%)   0.0760 (  3.9%)   0.0601 (  3.1%)  Simplify the CFG\r\n   0.0320 (  2.8%)   0.0160 (  2.0%)   0.0480 (  2.4%)   0.0572 (  2.9%)  Combine redundant instructions\r\n   0.0280 (  2.4%)   0.0080 (  1.0%)   0.0360 (  1.8%)   0.0548 (  2.8%)  Combine redundant instructions\r\n   0.0240 (  2.1%)   0.0160 (  2.0%)   0.0400 (  2.0%)   0.0542 (  2.8%)  Combine redundant instructions\r\n   0.0240 (  2.1%)   0.0200 (  2.5%)   0.0440 (  2.2%)   0.0534 (  2.7%)  Combine redundant instructions\r\n   0.0480 (  4.1%)   0.0000 (  0.0%)   0.0480 (  2.4%)   0.0496 (  2.5%)  Global Variable Optimizer\r\n   0.0320 (  2.8%)   0.0120 (  1.5%)   0.0440 (  2.2%)   0.0399 (  2.0%)  Deduce function attributes\r\n   0.0160 (  1.4%)   0.0080 (  1.0%)   0.0240 (  1.2%)   0.0397 (  2.0%)  Early CSE\r\n   0.0200 (  1.7%)   0.0120 (  1.5%)   0.0320 (  1.6%)   0.0373 (  1.9%)  X86 Assembly / Object Emitter\r\n   0.0160 (  1.4%)   0.0280 (  3.5%)   0.0440 (  2.2%)   0.0349 (  1.8%)  Remove unused exception handling info\r\n   0.0200 (  1.7%)   0.0080 (  1.0%)   0.0280 (  1.4%)   0.0344 (  1.8%)  Dominator Tree Construction\r\n   0.0120 (  1.0%)   0.0160 (  2.0%)   0.0280 (  1.4%)   0.0335 (  1.7%)  Add DWARF path discriminators\r\n   0.0240 (  2.1%)   0.0120 (  1.5%)   0.0360 (  1.8%)   0.0313 (  1.6%)  X86 DAG->DAG Instruction Selection\r\n   0.0280 (  2.4%)   0.0000 (  0.0%)   0.0280 (  1.4%)   0.0298 (  1.5%)  Interprocedural Sparse Conditional Constant Propagation\r\n   0.0040 (  0.3%)   0.0080 (  1.0%)   0.0120 (  0.6%)   0.0263 (  1.3%)  Lower 'expect' Intrinsics\r\n   0.0120 (  1.0%)   0.0040 (  0.5%)   0.0160 (  0.8%)   0.0260 (  1.3%)  Induction Variable Simplification\r\n   0.0120 (  1.0%)   0.0000 (  0.0%)   0.0120 (  0.6%)   0.0240 (  1.2%)  Dead Store Elimination\r\n   0.0120 (  1.0%)   0.0120 (  1.5%)   0.0240 (  1.2%)   0.0232 (  1.2%)  Combine redundant instructions\r\n   0.0160 (  1.4%)   0.0080 (  1.0%)   0.0240 (  1.2%)   0.0232 (  1.2%)  Combine redundant instructions\r\n   0.0120 (  1.0%)   0.0120 (  1.5%)   0.0240 (  1.2%)   0.0210 (  1.1%)  Simplify the CFG\r\n   0.0160 (  1.4%)   0.0080 (  1.0%)   0.0240 (  1.2%)   0.0200 (  1.0%)  Combine redundant instructions\r\n   0.0080 (  0.7%)   0.0120 (  1.5%)   0.0200 (  1.0%)   0.0195 (  1.0%)  Tail Call Elimination\r\n   0.0120 (  1.0%)   0.0080 (  1.0%)   0.0200 (  1.0%)   0.0194 (  1.0%)  Simplify the CFG\r\n   0.0160 (  1.4%)   0.0080 (  1.0%)   0.0240 (  1.2%)   0.0179 (  0.9%)  SROA\r\n   0.0160 (  1.4%)   0.0200 (  2.5%)   0.0360 (  1.8%)   0.0177 (  0.9%)  Simplify the CFG\r\n   0.0200 (  1.7%)   0.0120 (  1.5%)   0.0320 (  1.6%)   0.0177 (  0.9%)  Reassociate expressions\r\n   0.0040 (  0.3%)   0.0160 (  2.0%)   0.0200 (  1.0%)   0.0176 (  0.9%)  Jump Threading\r\n   0.0160 (  1.4%)   0.0000 (  0.0%)   0.0160 (  0.8%)   0.0170 (  0.9%)  Jump Threading\r\n   0.0200 (  1.7%)   0.0040 (  0.5%)   0.0240 (  1.2%)   0.0165 (  0.8%)  Sparse Conditional Constant Propagation\r\n   0.0280 (  2.4%)   0.0200 (  2.5%)   0.0480 (  2.4%)   0.0161 (  0.8%)  Value Propagation\r\n   0.0240 (  2.1%)   0.0040 (  0.5%)   0.0280 (  1.4%)   0.0159 (  0.8%)  Value Propagation\r\n   0.0240 (  2.1%)   0.0080 (  1.0%)   0.0320 (  1.6%)   0.0158 (  0.8%)  Simplify the CFG\r\n   0.0120 (  1.0%)   0.0080 (  1.0%)   0.0200 (  1.0%)   0.0149 (  0.8%)  Bit-Tracking Dead Code Elimination\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0146 (  0.8%)  MemCpy Optimization\r\n   0.0160 (  1.4%)   0.0120 (  1.5%)   0.0280 (  1.4%)   0.0135 (  0.7%)  Natural Loop Information\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0130 (  0.7%)  Aggressive Dead Code Elimination\r\n   0.0040 (  0.3%)   0.0080 (  1.0%)   0.0120 (  0.6%)   0.0122 (  0.6%)  Dominator Tree Construction\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0121 (  0.6%)  Natural Loop Information\r\n   0.0040 (  0.3%)   0.0040 (  0.5%)   0.0080 (  0.4%)   0.0119 (  0.6%)  Dominator Tree Construction\r\n   0.0080 (  0.7%)   0.0080 (  1.0%)   0.0160 (  0.8%)   0.0117 (  0.6%)  Dominator Tree Construction\r\n   0.0080 (  0.7%)   0.0080 (  1.0%)   0.0160 (  0.8%)   0.0115 (  0.6%)  Dominator Tree Construction\r\n   0.0120 (  1.0%)   0.0040 (  0.5%)   0.0160 (  0.8%)   0.0113 (  0.6%)  Dominator Tree Construction\r\n   0.0240 (  2.1%)   0.0120 (  1.5%)   0.0360 (  1.8%)   0.0113 (  0.6%)  Dominator Tree Construction\r\n   0.0040 (  0.3%)   0.0040 (  0.5%)   0.0080 (  0.4%)   0.0112 (  0.6%)  Dominator Tree Construction\r\n   0.0080 (  0.7%)   0.0080 (  1.0%)   0.0160 (  0.8%)   0.0104 (  0.5%)  Dominator Tree Construction\r\n   0.0040 (  0.3%)   0.0040 (  0.5%)   0.0080 (  0.4%)   0.0094 (  0.5%)  Lazy Value Information Analysis\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0093 (  0.5%)  Canonicalize natural loops\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0093 (  0.5%)  Canonicalize natural loops\r\n   0.0000 (  0.0%)   0.0120 (  1.5%)   0.0120 (  0.6%)   0.0092 (  0.5%)  Lazy Value Information Analysis\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0088 (  0.5%)  Scalar Evolution Analysis\r\n   0.0040 (  0.3%)   0.0080 (  1.0%)   0.0120 (  0.6%)   0.0088 (  0.4%)  MergedLoadStoreMotion\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0087 (  0.4%)  Loop-Closed SSA Form Pass\r\n   0.0000 (  0.0%)   0.0080 (  1.0%)   0.0080 (  0.4%)   0.0087 (  0.4%)  Memory Dependence Analysis\r\n   0.0000 (  0.0%)   0.0120 (  1.5%)   0.0120 (  0.6%)   0.0085 (  0.4%)  Inline Cost Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0084 (  0.4%)  Memory Dependence Analysis\r\n   0.0040 (  0.3%)   0.0040 (  0.5%)   0.0080 (  0.4%)   0.0084 (  0.4%)  Loop-Closed SSA Form Pass\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0084 (  0.4%)  Loop-Closed SSA Form Pass\r\n   0.0040 (  0.3%)   0.0080 (  1.0%)   0.0120 (  0.6%)   0.0083 (  0.4%)  Canonicalize natural loops\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0083 (  0.4%)  Promote 'by reference' arguments to scalars\r\n   0.0040 (  0.3%)   0.0040 (  0.5%)   0.0080 (  0.4%)   0.0081 (  0.4%)  Memory Dependence Analysis\r\n   0.0080 (  0.7%)   0.0000 (  0.0%)   0.0080 (  0.4%)   0.0068 (  0.3%)  SLP Vectorizer\r\n   0.0080 (  0.7%)   0.0000 (  0.0%)   0.0080 (  0.4%)   0.0068 (  0.3%)  Dead Global Elimination\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0065 (  0.3%)  Loop Invariant Code Motion\r\n   0.0080 (  0.7%)   0.0040 (  0.5%)   0.0120 (  0.6%)   0.0058 (  0.3%)  Loop Invariant Code Motion\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0057 (  0.3%)  Simplify the CFG\r\n   0.0040 (  0.3%)   0.0040 (  0.5%)   0.0080 (  0.4%)   0.0055 (  0.3%)  Loop Vectorization\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0038 (  0.2%)  Unroll loops\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0036 (  0.2%)  Dominator Tree Construction\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0034 (  0.2%)  Block Frequency Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0031 (  0.2%)  Loop Invariant Code Motion\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0030 (  0.2%)  Branch Probability Analysis\r\n   0.0000 (  0.0%)   0.0040 (  0.5%)   0.0040 (  0.2%)   0.0029 (  0.2%)  Float to int\r\n   0.0040 (  0.3%)   0.0040 (  0.5%)   0.0080 (  0.4%)   0.0028 (  0.1%)  Natural Loop Information\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0027 (  0.1%)  Natural Loop Information\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0026 (  0.1%)  CallGraph Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0026 (  0.1%)  Unroll loops\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0025 (  0.1%)  Dominator Tree Construction\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0025 (  0.1%)  Loop-Closed SSA Form Pass\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0024 (  0.1%)  Rotate Loops\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0023 (  0.1%)  Unswitch loops\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0021 (  0.1%)  Greedy Register Allocator\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0019 (  0.1%)  Machine Instruction Scheduler\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0019 (  0.1%)  Canonicalize natural loops\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0018 (  0.1%)  Canonicalize natural loops\r\n   0.0040 (  0.3%)   0.0040 (  0.5%)   0.0080 (  0.4%)   0.0018 (  0.1%)  Loop Strength Reduction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0016 (  0.1%)  Canonicalize natural loops\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0016 (  0.1%)  Loop-Closed SSA Form Pass\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0016 (  0.1%)  Dead Argument Elimination\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0016 (  0.1%)  CodeGen Prepare\r\n   0.0000 (  0.0%)   0.0040 (  0.5%)   0.0040 (  0.2%)   0.0016 (  0.1%)  Loop-Closed SSA Form Pass\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0015 (  0.1%)  Scalar Evolution Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0015 (  0.1%)  Scalar Evolution Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0015 (  0.1%)  Scalar Evolution Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0015 (  0.1%)  Scalar Evolution Analysis\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0015 (  0.1%)  Loop Access Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0014 (  0.1%)  Alignment from assumptions\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0011 (  0.1%)  Debug Variable Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0011 (  0.1%)  Live Variable Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0009 (  0.0%)  Recognize loop idioms\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0009 (  0.0%)  Delete dead loops\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0008 (  0.0%)  Induction Variable Users\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0007 (  0.0%)  Basic Alias Analysis (stateless AA impl)\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0007 (  0.0%)  Target Transform Information\r\n   0.0000 (  0.0%)   0.0040 (  0.5%)   0.0040 (  0.2%)   0.0007 (  0.0%)  Simple Register Coalescing\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0007 (  0.0%)  Machine Common Subexpression Elimination\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0007 (  0.0%)  Prologue/Epilogue Insertion & Frame Finalization\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0006 (  0.0%)  Live Interval Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0006 (  0.0%)  Virtual Register Rewriter\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0006 (  0.0%)  Merge Duplicate Global Constants\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0005 (  0.0%)  X86 FP Stackifier\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0005 (  0.0%)  Control Flow Optimizer\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0004 (  0.0%)  Rotate Loops\r\n   0.0000 (  0.0%)   0.0040 (  0.5%)   0.0040 (  0.2%)   0.0004 (  0.0%)  Merge disjoint stack slots\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0004 (  0.0%)  Two-Address instruction pass\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0004 (  0.0%)  Machine Copy Propagation Pass\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0004 (  0.0%)  Insert stack protectors\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0004 (  0.0%)  Machine Loop Invariant Code Motion\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0004 (  0.0%)  Constant Hoisting\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0004 (  0.0%)  Dominator Tree Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0004 (  0.0%)  Machine code sinking\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0004 (  0.0%)  Machine Block Frequency Analysis\r\n   0.0000 (  0.0%)   0.0040 (  0.5%)   0.0040 (  0.2%)   0.0003 (  0.0%)  Machine Block Frequency Analysis\r\n   0.0000 (  0.0%)   0.0040 (  0.5%)   0.0040 (  0.2%)   0.0003 (  0.0%)  Machine Function Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Execution dependency fix\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Machine Block Frequency Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Dominator Tree Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Dominator Tree Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Branch Probability Basic Block Placement\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Expand Atomic calls in terms of either load-linked & store-conditional or cmpxchg\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  MachineDominator Tree Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Peephole Optimizations\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Branch Probability Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Remove dead machine instructions\r\n   0.0040 (  0.3%)   0.0000 (  0.0%)   0.0040 (  0.2%)   0.0003 (  0.0%)  Eliminate PHI nodes for register allocation\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Machine Block Frequency Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  MachineDominator Tree Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  MachinePostDominator Tree Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Natural Loop Information\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  MachineDominator Tree Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Dominator Tree Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Natural Loop Information\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  Partially inline calls to library functions\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0003 (  0.0%)  MachineDominator Tree Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Machine Natural Loop Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  MachineDominator Tree Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Remove dead machine instructions\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Machine Natural Loop Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Machine Natural Loop Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Dominator Tree Construction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Slot index numbering\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Slot index numbering\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Exception handling preparation\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Machine Loop Invariant Code Motion\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Remove unreachable machine basic blocks\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Post-RA pseudo instruction expansion pass\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Tail Duplication\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Stack Slot Coloring\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Remove unreachable blocks from the CFG\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Machine InstCombiner\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Canonicalize natural loops\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Tail Duplication\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Live Register Matrix\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  X86 pseudo instruction expansion pass\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Post RA top-down list latency scheduler\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Optimize machine instruction PHIs\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Spill Code Placement Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0002 (  0.0%)  Safe Stack instrumentation pass\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Expand ISel Pseudo-instructions\r\n   0.0000 (  0.0%)   0.0040 (  0.5%)   0.0040 (  0.2%)   0.0001 (  0.0%)  Bundle Machine CFG Edges\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Process Implicit Definitions\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Machine Trace Metrics\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Live Stack Slot Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Bundle Machine CFG Edges\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Scalar Evolution Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Analyze Machine Code For Garbage Collection\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Virtual Register Map\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Early If-Conversion\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Shadow Stack GC Lowering\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  StackMap Liveness Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  ObjC ARC contraction\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  X86 Atom pad short functions\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Local Dynamic TLS Access Clean-up\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  X86 LEA Fixup\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Local Stack Slot Allocation\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  X86 PIC Global Base Reg Initialization\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Lower Garbage Collection Instructions\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  X86 Optimize Call Frame\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  X86 vzeroupper inserter\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Assumption Cache Tracker\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Assumption Cache Tracker\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0001 (  0.0%)  Strip Unused Function Prototypes\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  Eliminate Available Externally Globals\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  A No-Op Barrier Pass\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  Rewrite Symbols\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  Target Pass Configuration\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  No Alias Analysis (always returns 'may' alias)\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  Machine Module Information\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  Target Transform Information\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  Target Library Information\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  Target Library Information\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  Machine Branch Probability Analysis\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  Basic Alias Analysis (stateless AA impl)\r\n   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)   0.0000 (  0.0%)  Create Garbage Collector Module Metadata\r\n   1.1600 (100.0%)   0.8040 (100.0%)   1.9640 (100.0%)   1.9512 (100.0%)  Total\r\n\r\n===-------------------------------------------------------------------------===\r\n                          Clang front-end time report\r\n===-------------------------------------------------------------------------===\r\n  Total Execution Time: 8.8640 seconds (8.8675 wall clock)\r\n\r\n   ---User Time---   --System Time--   --User+System--   ---Wall Time---  --- Name ---\r\n   7.0760 (100.0%)   1.7880 (100.0%)   8.8640 (100.0%)   8.8675 (100.0%)  Clang front-end timer\r\n   7.0760 (100.0%)   1.7880 (100.0%)   8.8640 (100.0%)   8.8675 (100.0%)  Total\r\n\r\n\r\nreal\t0m10.152s\r\nuser\t0m7.892s\r\nsys\t0m2.220s\r\n```"},"comment":{"url":"https://api.github.com/repos/eliben/llvm-clang-samples/issues/comments/150390405","html_url":"https://github.com/eliben/llvm-clang-samples/issues/23#issuecomment-150390405","issue_url":"https://api.github.com/repos/eliben/llvm-clang-samples/issues/23","id":150390405,"user":{"login":"eliben","id":1130906,"avatar_url":"https://avatars.githubusercontent.com/u/1130906?v=3","gravatar_id":"","url":"https://api.github.com/users/eliben","html_url":"https://github.com/eliben","followers_url":"https://api.github.com/users/eliben/followers","following_url":"https://api.github.com/users/eliben/following{/other_user}","gists_url":"https://api.github.com/users/eliben/gists{/gist_id}","starred_url":"https://api.github.com/users/eliben/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eliben/subscriptions","organizations_url":"https://api.github.com/users/eliben/orgs","repos_url":"https://api.github.com/users/eliben/repos","events_url":"https://api.github.com/users/eliben/events{/privacy}","received_events_url":"https://api.github.com/users/eliben/received_events","type":"User","site_admin":false},"created_at":"2015-10-22T23:54:51Z","updated_at":"2015-10-22T23:54:51Z","body":"This is with LLVM 3.7, downloaded (for Ubuntu) from the LLVM releases website. \r\n\r\nFWIW 8 seconds for an optimizing build resulting in a 27MB executable doesn't sound excessively long to me. There are dozens multi-MB objects involved in the linking - so it takes time."}}