commit | 47144a0dc1f987981da14c18af9dbf962a6eb9c7 | [log] [tgz] |
---|---|---|
author | Vladislav Dzhidzhoev <vdzhidzhoev@accesssoftek.com> | Wed May 14 19:41:56 2025 +0200 |
committer | GitHub <noreply@github.com> | Wed May 14 19:41:56 2025 +0200 |
tree | 28554a87b91236dda67a2f39ae815c588126f716 | |
parent | 80fa6214821582511c687d00a484929530df1661 [diff] |
[CloneFunction][DebugInfo] Ensure DILocalVariables of inlined functions are not cloned (NFC) (#138590) This change was separated from https://github.com/llvm/llvm-project/pull/119001. When cloning functions, use IdentityMDPredicate to ensure that if DISubprogram is not cloned, then its DILocalVariables are not cloned either. This is currently expected to be an NFC, as DILocalVariables only reference their subprograms (via DILocalScopes) and types, and inlined DISubprograms and DITypes are not cloned. Thus, DILocalVariables are mapped to self in ValueMapper (in mapTopLevelUniquedNode). However, it will be needed for the original PR https://github.com/llvm/llvm-project/pull/119001, where a DILocalVariable may refer to a local type of a DISubprogram that is being cloned. In that case, ValueMapper will clone DILocalVariable even if it belongs to an inlined DISubprogram that is not cloned, which should be avoided. I'm making this change into a separate PR to make the original PR a bit smaller, and because this has more to do with variables than with types.
Welcome to the LLVM project!
This repository contains the source code for LLVM, a toolkit for the construction of highly optimized compilers, optimizers, and run-time environments.
The LLVM project has multiple components. The core of the project is itself called “LLVM”. This contains all of the tools, libraries, and header files needed to process intermediate representations and convert them into object files. Tools include an assembler, disassembler, bitcode analyzer, and bitcode optimizer.
C-like languages use the Clang frontend. This component compiles C, C++, Objective-C, and Objective-C++ code into LLVM bitcode -- and from there into object files, using LLVM.
Other components include: the libc++ C++ standard library, the LLD linker, and more.
Consult the Getting Started with LLVM page for information on building and running LLVM.
For information on how to contribute to the LLVM project, please take a look at the Contributing to LLVM guide.
Join the LLVM Discourse forums, Discord chat, LLVM Office Hours or Regular sync-ups.
The LLVM project has adopted a code of conduct for participants to all modes of communication within the project.