HOLZSCHUCH Nicolas 8dcc9345f6 Merge branch 'master' of https://github.com/llvm-mirror/clang 5 years ago
..
ABIInfo.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
Address.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
BackendUtil.cpp 8dcc9345f6 Merge branch 'master' of https://github.com/llvm-mirror/clang 5 years ago
CGAtomic.cpp 7fc84cdab9 Codegen - silence static analyzer getAs<> null dereference warnings. NFCI. 5 years ago
CGBlocks.cpp cb0ef14067 CGBlocks - silence static analyzer getAs<> null dereference warnings. NFCI. 5 years ago
CGBlocks.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
CGBuilder.h ce7674d7be Fix parameter name comments using clang-tidy. NFC. 6 years ago
CGBuiltin.cpp 2134663055 CGBuiltin - silence static analyzer getAs<> null dereference warnings. NFCI. 5 years ago
CGCUDANV.cpp 4eef7a8ad0 [Alignment][Clang][NFC] Add CharUnits::getAsAlign 5 years ago
CGCUDARuntime.cpp 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
CGCUDARuntime.h 5e6563143c [HIP] Add the interface deriving the stub name of device kernels. 6 years ago
CGCXX.cpp 7fc84cdab9 Codegen - silence static analyzer getAs<> null dereference warnings. NFCI. 5 years ago
CGCXXABI.cpp 84d475a5ed Silence static analyzer getAs<RecordType> null dereference warnings. NFCI. 5 years ago
CGCXXABI.h 2eb4788e8c Improve code generation for thread_local variables: 6 years ago
CGCall.cpp 8b10d16729 [Alignment] Migrate Attribute::getWith(Stack)Alignment 5 years ago
CGCall.h 6d763e31d2 [opaque pointer types] Make EmitCall pass Function Types to 6 years ago
CGClass.cpp 03bb1778b6 [OpenCL] Preserve addrspace in CGClass (PR43145) 5 years ago
CGCleanup.cpp 4eef7a8ad0 [Alignment][Clang][NFC] Add CharUnits::getAsAlign 5 years ago
CGCleanup.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
CGCoroutine.cpp ce7674d7be Fix parameter name comments using clang-tidy. NFC. 6 years ago
CGDebugInfo.cpp 14947e8df1 PCH debug info: Avoid appending the source directory to an absolute path 5 years ago
CGDebugInfo.h eb045be428 Revert "[CGDebugInfo] Simplify EmitFunctionDecl parameters, NFC" 6 years ago
CGDecl.cpp 1d08493df3 Added support for "#pragma clang section relro=<name>" 5 years ago
CGDeclCXX.cpp 0e6f1764e3 Fix Calling Convention through aliases 5 years ago
CGException.cpp ed5c51707d [WebAssembly] Add -fwasm-exceptions for wasm EH 6 years ago
CGExpr.cpp ea521aa602 [c++20] Add CXXRewrittenBinaryOperator to represent a comparison 5 years ago
CGExprAgg.cpp ea521aa602 [c++20] Add CXXRewrittenBinaryOperator to represent a comparison 5 years ago
CGExprCXX.cpp 827afc80db CFI: wrong type passed to llvm.type.test with multiple inheritance devirtualization. 5 years ago
CGExprComplex.cpp ea521aa602 [c++20] Add CXXRewrittenBinaryOperator to represent a comparison 5 years ago
CGExprConstant.cpp e606cc177e CGExprConstant - silence static analyzer getAs<> null dereference warning. NFCI. 5 years ago
CGExprScalar.cpp ea521aa602 [c++20] Add CXXRewrittenBinaryOperator to represent a comparison 5 years ago
CGGPUBuiltin.cpp 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
CGLoopInfo.cpp 1b1167f58f Recommit "[Clang] Pragma vectorize_width() implies vectorize(enable)" 5 years ago
CGLoopInfo.h e03316caa0 Don't keep stale pointers to LoopInfos. 6 years ago
CGNonTrivialStruct.cpp e63380d34e Do a sweep of symbol internalization. NFC. 6 years ago
CGObjC.cpp 38c1f7c254 Properly handle instantiation-dependent array bounds. 5 years ago
CGObjCGNU.cpp 7fc84cdab9 Codegen - silence static analyzer getAs<> null dereference warnings. NFCI. 5 years ago
CGObjCMac.cpp 4eef7a8ad0 [Alignment][Clang][NFC] Add CharUnits::getAsAlign 5 years ago
CGObjCRuntime.cpp 679ab5f711 [opaque pointer types] Pass function types for runtime function calls. 6 years ago
CGObjCRuntime.h 679ab5f711 [opaque pointer types] Pass function types for runtime function calls. 6 years ago
CGOpenCLRuntime.cpp eae71f8d05 [OpenCL] Simplify LLVM IR generated for OpenCL blocks 6 years ago
CGOpenCLRuntime.h eae71f8d05 [OpenCL] Simplify LLVM IR generated for OpenCL blocks 6 years ago
CGOpenMPRuntime.cpp 653a638f94 [OPENMP50]Add support for master taskloop simd. 5 years ago
CGOpenMPRuntime.h ea4934045a [Clang][OpenMP Offload] Move offload registration code to the wrapper 5 years ago
CGOpenMPRuntimeNVPTX.cpp 653a638f94 [OPENMP50]Add support for master taskloop simd. 5 years ago
CGOpenMPRuntimeNVPTX.h b04fa26eaf [OPENMP50]Support for declare variant directive for NVPTX target. 5 years ago
CGRecordLayout.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
CGRecordLayoutBuilder.cpp 31de5dab92 P0840R2: support for [[no_unique_address]] attribute 6 years ago
CGStmt.cpp 653a638f94 [OPENMP50]Add support for master taskloop simd. 5 years ago
CGStmtOpenMP.cpp 653a638f94 [OPENMP50]Add support for master taskloop simd. 5 years ago
CGVTT.cpp 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
CGVTables.cpp 62e70af15a Reland: Dead Virtual Function Elimination 5 years ago
CGVTables.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
CGValue.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
CMakeLists.txt 8942d642f0 Make CodeGen depend on ASTMatchers 6 years ago
CodeGenABITypes.cpp ce7674d7be Fix parameter name comments using clang-tidy. NFC. 6 years ago
CodeGenAction.cpp 211daf9ad4 Reland "clang-misexpect: Profile Guided Validation of Performance Annotations in LLVM" 6 years ago
CodeGenFunction.cpp bb282f4751 Reland r374450 with Richard Smith's comments and test fixed. 5 years ago
CodeGenFunction.h 653a638f94 [OPENMP50]Add support for master taskloop simd. 5 years ago
CodeGenModule.cpp c78da41cda [AMDGPU] Fix assertion due to initializer list 5 years ago
CodeGenModule.h 62e70af15a Reland: Dead Virtual Function Elimination 5 years ago
CodeGenPGO.cpp 49a6b09101 [Clang] Migrate llvm::make_unique to std::make_unique 6 years ago
CodeGenPGO.h 6aa1f42be9 Fix uninitialized variable warning in CodeGenPGO constructor. NFCI. 5 years ago
CodeGenTBAA.cpp 168f519698 Fix TBAA representation for zero-sized fields and unnamed bit-fields. 6 years ago
CodeGenTBAA.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
CodeGenTypeCache.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
CodeGenTypes.cpp 84d475a5ed Silence static analyzer getAs<RecordType> null dereference warnings. NFCI. 5 years ago
CodeGenTypes.h 3a3e9339ec IRGen: Remove StructorType; thread GlobalDecl through more code. NFCI. 6 years ago
ConstantEmitter.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
ConstantInitBuilder.cpp 4eef7a8ad0 [Alignment][Clang][NFC] Add CharUnits::getAsAlign 5 years ago
CoverageMappingGen.cpp a2a3b137f8 Re-land "Use -fdebug-compilation-dir to form absolute paths in coverage mappings" 5 years ago
CoverageMappingGen.h a2a3b137f8 Re-land "Use -fdebug-compilation-dir to form absolute paths in coverage mappings" 5 years ago
EHScopeStack.h f724ed4411 Replace llvm::integer_sequence and friends with the C++14 standard version 6 years ago
ItaniumCXXABI.cpp 62e70af15a Reland: Dead Virtual Function Elimination 5 years ago
MacroPPCallbacks.cpp 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
MacroPPCallbacks.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
MicrosoftCXXABI.cpp 7fc84cdab9 Codegen - silence static analyzer getAs<> null dereference warnings. NFCI. 5 years ago
ModuleBuilder.cpp 3da9ca444f [Clang] Use -main-file-name for source filename if not set 5 years ago
ObjectFilePCHContainerOperations.cpp 4eef7a8ad0 [Alignment][Clang][NFC] Add CharUnits::getAsAlign 5 years ago
PatternInit.cpp 378f8bc374 CodeGet: Init 32bit pointers with 0xFFFFFFFF 6 years ago
PatternInit.h eae000b425 Variable auto-init: also auto-init alloca 6 years ago
README.txt f1c8380d26 These IRgen improvements have been done. 16 years ago
SanitizerMetadata.cpp 647bdd3207 ARM MTE stack sanitizer. 6 years ago
SanitizerMetadata.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
SwiftCallingConv.cpp 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
TargetInfo.cpp 2aa66afa82 Remove an useless allocation (from by clang-analyzer/scan-build) 5 years ago
TargetInfo.h 5e43603aaa [OpenCL][PR41727] Prevent ICE on global dtors 6 years ago
VarBypassDetector.cpp 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago
VarBypassDetector.h 324f918438 Update the file headers across all of the LLVM projects in the monorepo 6 years ago

README.txt

IRgen optimization opportunities.

//===---------------------------------------------------------------------===//

The common pattern of
--
short x; // or char, etc
(x == 10)
--
generates an zext/sext of x which can easily be avoided.

//===---------------------------------------------------------------------===//

Bitfields accesses can be shifted to simplify masking and sign
extension. For example, if the bitfield width is 8 and it is
appropriately aligned then is is a lot shorter to just load the char
directly.

//===---------------------------------------------------------------------===//

It may be worth avoiding creation of alloca's for formal arguments
for the common situation where the argument is never written to or has
its address taken. The idea would be to begin generating code by using
the argument directly and if its address is taken or it is stored to
then generate the alloca and patch up the existing code.

In theory, the same optimization could be a win for block local
variables as long as the declaration dominates all statements in the
block.

NOTE: The main case we care about this for is for -O0 -g compile time
performance, and in that scenario we will need to emit the alloca
anyway currently to emit proper debug info. So this is blocked by
being able to emit debug information which refers to an LLVM
temporary, not an alloca.

//===---------------------------------------------------------------------===//

We should try and avoid generating basic blocks which only contain
jumps. At -O0, this penalizes us all the way from IRgen (malloc &
instruction overhead), all the way down through code generation and
assembly time.

On 176.gcc:expr.ll, it looks like over 12% of basic blocks are just
direct branches!

//===---------------------------------------------------------------------===//