[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-05-15 Thread Adrian Prantl via cfe-commits
@@ -6178,10 +6178,16 @@ The current supported opcode vocabulary is limited: the last entry from the second last entry and appends the result to the expression stack. - ``DW_OP_plus_uconst, 93`` adds ``93`` to the working expression. -- ``DW_OP_LLVM_fragment, 16, 8``

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-05-14 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl edited https://github.com/llvm/llvm-project/pull/85665 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-05-14 Thread Adrian Prantl via cfe-commits
@@ -6178,10 +6178,16 @@ The current supported opcode vocabulary is limited: the last entry from the second last entry and appends the result to the expression stack. - ``DW_OP_plus_uconst, 93`` adds ``93`` to the working expression. -- ``DW_OP_LLVM_fragment, 16, 8``

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-05-09 Thread Adrian Prantl via cfe-commits
@@ -6178,10 +6178,16 @@ The current supported opcode vocabulary is limited: the last entry from the second last entry and appends the result to the expression stack. - ``DW_OP_plus_uconst, 93`` adds ``93`` to the working expression. -- ``DW_OP_LLVM_fragment, 16, 8``

[clang] [clang-tools-extra] Reapply "[Clang] Unify interface for accessing template arguments as written for class/variable template specializations (#81642)" (PR #91393)

2024-05-08 Thread Adrian Prantl via cfe-commits
adrian-prantl wrote: Interesting. I though that the check-lldb target would clean the module cache before each run? https://github.com/llvm/llvm-project/blob/fcfc15b7052a311b7a045e2c6bd26fb5d0b7122c/lldb/test/CMakeLists.txt#L56

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-05-08 Thread Adrian Prantl via cfe-commits
@@ -6178,10 +6178,16 @@ The current supported opcode vocabulary is limited: the last entry from the second last entry and appends the result to the expression stack. - ``DW_OP_plus_uconst, 93`` adds ``93`` to the working expression. -- ``DW_OP_LLVM_fragment, 16, 8``

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-05-08 Thread Adrian Prantl via cfe-commits
@@ -6178,10 +6178,16 @@ The current supported opcode vocabulary is limited: the last entry from the second last entry and appends the result to the expression stack. - ``DW_OP_plus_uconst, 93`` adds ``93`` to the working expression. -- ``DW_OP_LLVM_fragment, 16, 8``

[clang] [clang-tools-extra] Reapply "[Clang] Unify interface for accessing template arguments as written for class/variable template specializations (#81642)" (PR #91393)

2024-05-07 Thread Adrian Prantl via cfe-commits
adrian-prantl wrote: How did you address the LLDB test failures? https://github.com/llvm/llvm-project/pull/91393 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 2e4abfa - Revert "[Sema] Fix warnings"

2024-05-07 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2024-05-07T13:03:14-07:00 New Revision: 2e4abfae57f81e2bb23fc654d6edbaeae51ae10a URL: https://github.com/llvm/llvm-project/commit/2e4abfae57f81e2bb23fc654d6edbaeae51ae10a DIFF: https://github.com/llvm/llvm-project/commit/2e4abfae57f81e2bb23fc654d6edbaeae51ae10a.diff

[clang] [clang-tools-extra] [Clang] Unify interface for accessing template arguments as written for class/variable template specializations (PR #81642)

2024-05-07 Thread Adrian Prantl via cfe-commits
adrian-prantl wrote: This broke several tests in the LLDB testsuite, I'm going to have to revert this. https://green.lab.llvm.org/job/llvm.org/view/LLDB/job/as-lldb-cmake/3480/ https://github.com/llvm/llvm-project/pull/81642 ___ cfe-commits mailing

[clang] [clang][PGO] Apply artificial DebugLoc to llvm.instrprof.increment instructions (PR #90717)

2024-05-02 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/90717 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-05-02 Thread Adrian Prantl via cfe-commits
@@ -172,6 +172,27 @@ static bool checkArgCount(Sema , CallExpr *Call, unsigned DesiredArgCount) { << /*is non object*/ 0 << Call->getArg(1)->getSourceRange(); } +static bool checkBuiltinVerboseTrap(CallExpr *Call, Sema ) { + bool HasError = false; + + for (int I =

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-05-02 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/79230 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-05-02 Thread Adrian Prantl via cfe-commits
@@ -29,7 +29,9 @@ #include "llvm/IR/DebugInfo.h" #include "llvm/IR/ValueHandle.h" #include "llvm/Support/Allocator.h" +#include adrian-prantl wrote: This seems to not belong to this commit? https://github.com/llvm/llvm-project/pull/79230

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-05-02 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl edited https://github.com/llvm/llvm-project/pull/79230 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-04-29 Thread Adrian Prantl via cfe-commits
@@ -27,6 +27,9 @@ namespace llvm { } } +// Prefix for __builtin_verbose_trap. +#define CLANG_VERBOSE_TRAP_PREFIX "__llvm_verbose_trap" adrian-prantl wrote: Does this have to be a macro or could it be a C++ constant?

[clang] [DebugInfo] Add flag to only emit referenced member functions (PR #87018)

2024-04-01 Thread Adrian Prantl via cfe-commits
adrian-prantl wrote: Seems to be a reasonable tuning option to have available. I probably wouldn't want this to be on by default, but I can see the appeal. https://github.com/llvm/llvm-project/pull/87018 ___ cfe-commits mailing list

[clang] 380f0fb - [CodeGen/DWARF] Introduce DWARF tag for SwiftTail and emit it in CodeGen.

2024-03-28 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2024-03-28T14:54:51-07:00 New Revision: 380f0fb682041aca3d682d9f1be9d3021f4b2daa URL: https://github.com/llvm/llvm-project/commit/380f0fb682041aca3d682d9f1be9d3021f4b2daa DIFF: https://github.com/llvm/llvm-project/commit/380f0fb682041aca3d682d9f1be9d3021f4b2daa.diff

[clang] [clang-tools-extra] [compiler-rt] [flang] [lld] [lldb] [llvm] [mlir] [openmp] [pstl] Finally formalise our defacto line-ending policy (PR #86318)

2024-03-22 Thread Adrian Prantl via cfe-commits
adrian-prantl wrote: While I'm sure this commit will manage to break _something_ unexpectedly, I think this is reasonable to do! Thanks for taking this on. https://github.com/llvm/llvm-project/pull/86318 ___ cfe-commits mailing list

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-03-19 Thread Adrian Prantl via cfe-commits
@@ -8,8 +8,8 @@ struct S0 { // CHECK-LABEL: define dso_local void @_Z3fS0v // CHECK:alloca %struct.S0, align 4 // CHECK-NEXT:[[TMP0:%.*]] = alloca %struct.S0, align 4 -// CHECK: call void @llvm.dbg.declare(metadata ptr [[TMP0]], metadata

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-03-19 Thread Adrian Prantl via cfe-commits
@@ -8,8 +8,8 @@ struct S0 { // CHECK-LABEL: define dso_local void @_Z3fS0v // CHECK:alloca %struct.S0, align 4 // CHECK-NEXT:[[TMP0:%.*]] = alloca %struct.S0, align 4 -// CHECK: call void @llvm.dbg.declare(metadata ptr [[TMP0]], metadata

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-03-19 Thread Adrian Prantl via cfe-commits
@@ -8,8 +8,8 @@ struct S0 { // CHECK-LABEL: define dso_local void @_Z3fS0v // CHECK:alloca %struct.S0, align 4 // CHECK-NEXT:[[TMP0:%.*]] = alloca %struct.S0, align 4 -// CHECK: call void @llvm.dbg.declare(metadata ptr [[TMP0]], metadata

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-03-19 Thread Adrian Prantl via cfe-commits
@@ -8,8 +8,8 @@ struct S0 { // CHECK-LABEL: define dso_local void @_Z3fS0v // CHECK:alloca %struct.S0, align 4 // CHECK-NEXT:[[TMP0:%.*]] = alloca %struct.S0, align 4 -// CHECK: call void @llvm.dbg.declare(metadata ptr [[TMP0]], metadata

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-03-19 Thread Adrian Prantl via cfe-commits
@@ -8,8 +8,8 @@ struct S0 { // CHECK-LABEL: define dso_local void @_Z3fS0v // CHECK:alloca %struct.S0, align 4 // CHECK-NEXT:[[TMP0:%.*]] = alloca %struct.S0, align 4 -// CHECK: call void @llvm.dbg.declare(metadata ptr [[TMP0]], metadata

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-03-18 Thread Adrian Prantl via cfe-commits
@@ -8,8 +8,8 @@ struct S0 { // CHECK-LABEL: define dso_local void @_Z3fS0v // CHECK:alloca %struct.S0, align 4 // CHECK-NEXT:[[TMP0:%.*]] = alloca %struct.S0, align 4 -// CHECK: call void @llvm.dbg.declare(metadata ptr [[TMP0]], metadata

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-03-18 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl edited https://github.com/llvm/llvm-project/pull/85665 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [DebugInfo] Use DW_op_bit_piece for structured bindings of bitfields (PR #85665)

2024-03-18 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl requested changes to this pull request. https://github.com/llvm/llvm-project/pull/85665 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Move CCC_OVERRIDE_OPTIONS implementation to Driver (PR #85425)

2024-03-15 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/85425 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][CodeCompletion] Allow debuggers to code-complete reserved identifiers (PR #84891)

2024-03-12 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/84891 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-03-01 Thread Adrian Prantl via cfe-commits
@@ -0,0 +1,20 @@ +// RUN: mkdir -p %t/src +// RUN: cp %s %t/src/debug-info-debug-prefix-map.c + +// RUN: mkdir -p %t/out +// RUN: cd %t/out +// RUN: %clang_cc1 -debug-info-kind=limited -triple %itanium_abi_triple \ +// RUN: -fdebug-prefix-map="%t/=./"

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-27 Thread Adrian Prantl via cfe-commits
@@ -628,9 +628,8 @@ void CGDebugInfo::CreateCompileUnit() { // file was specified with an absolute path. if (CSKind) CSInfo.emplace(*CSKind, Checksum); - llvm::DIFile *CUFile = DBuilder.createFile( - remapDIPath(MainFileName), remapDIPath(getCurrentDirname()),

[clang] [Clang][DebugInfo] Use CGDebugInfo::createFile in CGDebugInfo::CreateCompileUnit (#83174) (PR #83175)

2024-02-27 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl commented: Can you add a test for this? https://github.com/llvm/llvm-project/pull/83175 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 66d462d - Add missing textual header to module map

2024-02-08 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2024-02-08T08:56:25-08:00 New Revision: 66d462d0a1ba1e510fff479baff8f21ecb924b1f URL: https://github.com/llvm/llvm-project/commit/66d462d0a1ba1e510fff479baff8f21ecb924b1f DIFF: https://github.com/llvm/llvm-project/commit/66d462d0a1ba1e510fff479baff8f21ecb924b1f.diff

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-02-01 Thread Adrian Prantl via cfe-commits
@@ -3416,6 +3437,27 @@ llvm::DIMacroFile *CGDebugInfo::CreateTempMacroFile(llvm::DIMacroFile *Parent, return DBuilder.createTempMacroFile(Parent, Line, FName); } +llvm::DILocation *CGDebugInfo::CreateTrapFailureMessageFor( +llvm::DebugLoc TrapLocation, StringRef

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-02-01 Thread Adrian Prantl via cfe-commits
@@ -3416,6 +3437,27 @@ llvm::DIMacroFile *CGDebugInfo::CreateTempMacroFile(llvm::DIMacroFile *Parent, return DBuilder.createTempMacroFile(Parent, Line, FName); } +llvm::DILocation *CGDebugInfo::CreateTrapFailureMessageFor( +llvm::DebugLoc TrapLocation, StringRef

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-02-01 Thread Adrian Prantl via cfe-commits
@@ -346,6 +348,15 @@ class CGDebugInfo { const FieldDecl *BitFieldDecl, const llvm::DIDerivedType *BitFieldDI, llvm::ArrayRef PreviousFieldsDI, const RecordDecl *RD); + // A cache that maps artificial inlined function names used for + // __builtin_verbose_trap

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-02-01 Thread Adrian Prantl via cfe-commits
@@ -346,6 +348,15 @@ class CGDebugInfo { const FieldDecl *BitFieldDecl, const llvm::DIDerivedType *BitFieldDI, llvm::ArrayRef PreviousFieldsDI, const RecordDecl *RD); + // A cache that maps artificial inlined function names used for + // __builtin_verbose_trap

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-02-01 Thread Adrian Prantl via cfe-commits
@@ -602,6 +613,19 @@ class CGDebugInfo { return CoroutineParameterMappings; } + // Create a debug location from `TrapLocation` that adds an artificial inline + // frame where the frame name is + // + // * `: ` if `` is not empty. + // * `` if `` is empty. Note ``

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-02-01 Thread Adrian Prantl via cfe-commits
@@ -3424,6 +3443,26 @@ llvm::DIMacroFile *CGDebugInfo::CreateTempMacroFile(llvm::DIMacroFile *Parent, return DBuilder.createTempMacroFile(Parent, Line, FName); } +llvm::DILocation * +CGDebugInfo::CreateTrapFailureMessageFor(llvm::DebugLoc TrapLocation, +

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-01-24 Thread Adrian Prantl via cfe-commits
adrian-prantl wrote: > neat idea (I imagine some debuggers will trip over the space in the inlined > name, but seems pretty good) For spaces specifically there's a multi-decade precedent: Objective-C methods have names like `DW_AT_name ("-[NSObject init:]")`

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-01-24 Thread Adrian Prantl via cfe-commits
adrian-prantl wrote: For context, we've been using this same trick in the Swift standard library for a long time now, to get a good trade-off between space-efficient code generation and usability for inlineable functions such as the arithmetic `+` operator, which traps on overflow.

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-01-24 Thread Adrian Prantl via cfe-commits
@@ -3416,6 +3437,27 @@ llvm::DIMacroFile *CGDebugInfo::CreateTempMacroFile(llvm::DIMacroFile *Parent, return DBuilder.createTempMacroFile(Parent, Line, FName); } +llvm::DILocation *CGDebugInfo::CreateTrapFailureMessageFor( +llvm::DebugLoc TrapLocation, StringRef

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-01-24 Thread Adrian Prantl via cfe-commits
@@ -1628,6 +1628,27 @@ llvm::DIType *CGDebugInfo::createFieldType( offsetInBits, flags, debugType, Annotations); } +llvm::DISubprogram * +CGDebugInfo::getFakeFuncSubprogram(const std::string ) { adrian-prantl wrote: Maybe

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-01-24 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl commented: A cosmetic suggestion I have would be to replace all instances of `Fake` with `inlinedTrap` to make the purpose clearer. https://github.com/llvm/llvm-project/pull/79230 ___ cfe-commits mailing list

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-01-24 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl edited https://github.com/llvm/llvm-project/pull/79230 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [clang-tools-extra] [lldb] [lldb][test] Add tests for target.max-string-summary-length setting (PR #77920)

2024-01-12 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/77920 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

2024-01-05 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. Test would be nice, but generally this looks like a reasonable modification. https://github.com/llvm/llvm-project/pull/77079 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [llvm] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2023-12-15 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl commented: I think this LGTM, but it would be good if someone else also took a look. https://github.com/llvm/llvm-project/pull/75385 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [llvm] [CloneFunction][DebugInfo] Avoid cloning DILocalVariables of inlined functions (PR #75385)

2023-12-15 Thread Adrian Prantl via cfe-commits
@@ -238,6 +238,13 @@ void llvm::CloneFunctionInto(Function *NewFunc, const Function *OldFunc, } } +// Avoid cloning local variables of subprograms that won't be cloned. adrian-prantl wrote: Can you add a sentence explaining why some

[clang] [clang-tools-extra] [lldb] [llvm] [lldb][test] Apply @expectedFailureAll/@skipIf early for debug_info tests (PR #73067)

2023-12-05 Thread Adrian Prantl via cfe-commits
adrian-prantl wrote: SGTM, maybe wait one more day for @JDevlieghere to chime in. https://github.com/llvm/llvm-project/pull/73067 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang-tools-extra] [lldb] [clang] [lldb][test] Apply @expectedFailureAll/@skipIf early for debug_info tests (PR #73067)

2023-12-05 Thread Adrian Prantl via cfe-commits
adrian-prantl wrote: Is this a performance optimization or a function al change? https://github.com/llvm/llvm-project/pull/73067 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][modules] Reset codegen options. (PR #74006)

2023-12-01 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/74006 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [BoundsSafety] Initial documentation for -fbounds-safety (PR #70749)

2023-11-30 Thread Adrian Prantl via cfe-commits
@@ -0,0 +1,255 @@ + +Implementation plans for ``-fbounds-safety`` + + +.. contents:: + :local: + +External bounds annotations +=== + +The bounds annotations are C

[clang] [BoundsSafety] Initial documentation for -fbounds-safety (PR #70749)

2023-11-30 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. Debug info part looks good! https://github.com/llvm/llvm-project/pull/70749 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [BoundsSafety] Initial documentation for -fbounds-safety (PR #70749)

2023-11-30 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl edited https://github.com/llvm/llvm-project/pull/70749 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][DebugInfo] Improve heuristic to determine whether to evaluate a static variable's initializer (PR #72974)

2023-11-29 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/72974 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Remove unused argument. NFC. (PR #73594)

2023-11-28 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. I can't even remember what this was supposed to do. https://github.com/llvm/llvm-project/pull/73594 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[lldb] [flang] [clang] [clang-tools-extra] [llvm] [mlir] [compiler-rt] [CodeGen][DebugInfo] Add missing debug info for jump table BB (PR #71021)

2023-11-15 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/71021 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang] [llvm][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72234)

2023-11-14 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. LGTM, then https://github.com/llvm/llvm-project/pull/72234 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang] [llvm][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72234)

2023-11-14 Thread Adrian Prantl via cfe-commits
@@ -1681,7 +1681,8 @@ CGDebugInfo::CreateRecordStaticField(const VarDecl *Var, llvm::DIType *RecordTy, llvm::DINode::DIFlags Flags = getAccessFlag(Var->getAccess(), RD); auto Align = getDeclAlignIfRequired(Var, CGM.getContext()); llvm::DIDerivedType *GV =

[llvm] [clang] [llvm][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72234)

2023-11-14 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl requested changes to this pull request. I think this is missing a test in clang/test/CodeGenCXX that verifies Clang generates the expected LLVM IR. https://github.com/llvm/llvm-project/pull/72234 ___ cfe-commits

[llvm] [clang] [llvm][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72234)

2023-11-14 Thread Adrian Prantl via cfe-commits
@@ -1315,17 +1315,15 @@ LLVMDIBuilderCreateUnspecifiedType(LLVMDIBuilderRef Builder, const char *Name, return wrap(unwrap(Builder)->createUnspecifiedType({Name, NameLen})); } -LLVMMetadataRef -LLVMDIBuilderCreateStaticMemberType( +LLVMMetadataRef

[clang] [llvm] [llvm][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72234)

2023-11-14 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl edited https://github.com/llvm/llvm-project/pull/72234 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [llvm][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72234)

2023-11-14 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/72234 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[lldb] [clang] Reland "[clang][DebugInfo] Emit global variable definitions for static data members with constant initializers" (PR #71780)

2023-11-10 Thread Adrian Prantl via cfe-commits
@@ -5800,6 +5827,18 @@ void CGDebugInfo::setDwoId(uint64_t Signature) { } void CGDebugInfo::finalize() { + for (auto const *VD : StaticDataMemberDefinitionsToEmit) { +assert(VD->isStaticDataMember()); + +if (DeclCache.contains(VD)) + continue; + +if

[clang] [lldb] Reland "[clang][DebugInfo] Emit global variable definitions for static data members with constant initializers" (PR #71780)

2023-11-10 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. Minor comments inside. https://github.com/llvm/llvm-project/pull/71780 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] Reland "[clang][DebugInfo] Emit global variable definitions for static data members with constant initializers" (PR #71780)

2023-11-10 Thread Adrian Prantl via cfe-commits
@@ -5596,6 +5587,42 @@ void CGDebugInfo::EmitGlobalVariable(const ValueDecl *VD, const APValue ) { TemplateParameters, Align)); } +void CGDebugInfo::EmitGlobalVariable(const VarDecl *VD) { + assert(VD->hasInit()); + assert(CGM.getCodeGenOpts().hasReducedDebugInfo());

[clang] [lldb] Reland "[clang][DebugInfo] Emit global variable definitions for static data members with constant initializers" (PR #71780)

2023-11-10 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl edited https://github.com/llvm/llvm-project/pull/71780 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 1adb898 - Mark headers as textual and unbreak the modules build

2023-10-31 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2023-10-31T09:10:50-07:00 New Revision: 1adb898e2db980fc402b8eac7ebc762c75d05826 URL: https://github.com/llvm/llvm-project/commit/1adb898e2db980fc402b8eac7ebc762c75d05826 DIFF: https://github.com/llvm/llvm-project/commit/1adb898e2db980fc402b8eac7ebc762c75d05826.diff

[clang] [Clang][DebugInfo] Clang generates an extra spurious unnamed 'dbg.declare' (PR #69681)

2023-10-23 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. Aside from other open comments the spirit of the change LGTM. https://github.com/llvm/llvm-project/pull/69681 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang-tidy]Add new check bugprone-casting-through-void (PR #69465)

2023-10-18 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl updated https://github.com/llvm/llvm-project/pull/69465 >From 627f68e57b2526fb72285ef4831fc3c02a6ee6d0 Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Wed, 18 Oct 2023 08:47:02 +0800 Subject: [PATCH 1/6] [clang-tidy]Add new check bugprone-casting-through-void

[clang] [clang] set DebugCompilationDir in PCHContainer (PR #67744)

2023-09-29 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/67744 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Revert "[Parse] Split incremental-extensions" (PR #66281)

2023-09-13 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/66281 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Propagate the DWARF version from the main compiler invocation to PCHC… (PR #66032)

2023-09-12 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl closed https://github.com/llvm/llvm-project/pull/66032 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Propagate the DWARF version from the main compiler invocation to PCHC… (PR #66032)

2023-09-11 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl review_requested https://github.com/llvm/llvm-project/pull/66032 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Propagate the DWARF version from the main compiler invocation to PCHC… (PR #66032)

2023-09-11 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl review_requested https://github.com/llvm/llvm-project/pull/66032 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Propagate the DWARF version from the main compiler invocation to PCHC… (PR #66032)

2023-09-11 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl review_requested https://github.com/llvm/llvm-project/pull/66032 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Propagate the DWARF version from the main compiler invocation to PCHC… (PR #66032)

2023-09-11 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl review_requested https://github.com/llvm/llvm-project/pull/66032 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Propagate the DWARF version from the main compiler invocation to PCHC… (PR #66032)

2023-09-11 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl created https://github.com/llvm/llvm-project/pull/66032: …ontainerGenerator Currently it remains uninitialized and thus always uses the LLVM default of 4. >From 6bdd0f5468ae1bf04912a9559c685b335fbe94c9 Mon Sep 17 00:00:00 2001 From: Adrian Prantl Date: Mon,

[clang] d6e1909 - Mark header as textual

2023-05-30 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2023-05-30T09:21:39-07:00 New Revision: d6e1909526fea196e20566d7d66c1b6ca04fa9e5 URL: https://github.com/llvm/llvm-project/commit/d6e1909526fea196e20566d7d66c1b6ca04fa9e5 DIFF: https://github.com/llvm/llvm-project/commit/d6e1909526fea196e20566d7d66c1b6ca04fa9e5.diff

[clang] 45905b5 - Add missing include

2023-05-02 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2023-05-02T08:37:40-07:00 New Revision: 45905b53f0eddb7b07a35a9a493a5ebd508bedda URL: https://github.com/llvm/llvm-project/commit/45905b53f0eddb7b07a35a9a493a5ebd508bedda DIFF: https://github.com/llvm/llvm-project/commit/45905b53f0eddb7b07a35a9a493a5ebd508bedda.diff

[clang] 4cbf4bb - Remove textual headers from module map

2023-02-07 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2023-02-07T13:24:47-08:00 New Revision: 4cbf4bb4dd17b813179467396c692180681cb003 URL: https://github.com/llvm/llvm-project/commit/4cbf4bb4dd17b813179467396c692180681cb003 DIFF: https://github.com/llvm/llvm-project/commit/4cbf4bb4dd17b813179467396c692180681cb003.diff

[clang] d1f313e - Mark BuiltinHeaders.def as textual

2023-01-23 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2023-01-23T10:14:33-08:00 New Revision: d1f313e73a1b33d662dbab54be76720b9c875645 URL: https://github.com/llvm/llvm-project/commit/d1f313e73a1b33d662dbab54be76720b9c875645 DIFF: https://github.com/llvm/llvm-project/commit/d1f313e73a1b33d662dbab54be76720b9c875645.diff

[clang] 2cf550a - Add missing textual header to module map

2022-12-20 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2022-12-20T10:05:55-08:00 New Revision: 2cf550a80a0177f8a1aa9ae45c40b0d17ef7f11d URL: https://github.com/llvm/llvm-project/commit/2cf550a80a0177f8a1aa9ae45c40b0d17ef7f11d DIFF: https://github.com/llvm/llvm-project/commit/2cf550a80a0177f8a1aa9ae45c40b0d17ef7f11d.diff

[clang-tools-extra] d951ca5 - Revert "[Driver] Enable to use C++20 standalne by -fcxx-modules"

2022-06-01 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2022-06-01T12:11:57-07:00 New Revision: d951ca5439bb8726cfe1ceb2d12e220f29fe5125 URL: https://github.com/llvm/llvm-project/commit/d951ca5439bb8726cfe1ceb2d12e220f29fe5125 DIFF: https://github.com/llvm/llvm-project/commit/d951ca5439bb8726cfe1ceb2d12e220f29fe5125.diff

[clang] c84b9bb - Revert "[NFC] Use %clang instead of %clang++ in tests"

2022-06-01 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2022-06-01T12:11:56-07:00 New Revision: c84b9bbac1ecaafb34daa7618b035f063ef1094e URL: https://github.com/llvm/llvm-project/commit/c84b9bbac1ecaafb34daa7618b035f063ef1094e DIFF: https://github.com/llvm/llvm-project/commit/c84b9bbac1ecaafb34daa7618b035f063ef1094e.diff

[clang] 128ffb3 - Revert "[Driver][Modules] Remove dependence on linking support from clang/test/Driver/modules.cpp"

2022-06-01 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2022-06-01T12:11:56-07:00 New Revision: 128ffb332bca2c3efae82665b2b557f9b481b83f URL: https://github.com/llvm/llvm-project/commit/128ffb332bca2c3efae82665b2b557f9b481b83f DIFF: https://github.com/llvm/llvm-project/commit/128ffb332bca2c3efae82665b2b557f9b481b83f.diff

[clang] bc7aeea - Revert "Don't append the working directory to absolute paths"

2022-02-25 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2022-02-25T17:00:10-08:00 New Revision: bc7aeea8542d48111f8cc923451b7c53347c75b5 URL: https://github.com/llvm/llvm-project/commit/bc7aeea8542d48111f8cc923451b7c53347c75b5 DIFF: https://github.com/llvm/llvm-project/commit/bc7aeea8542d48111f8cc923451b7c53347c75b5.diff

[clang] 2cd9a86 - Don't append the working directory to absolute paths

2022-02-25 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2022-02-25T13:03:59-08:00 New Revision: 2cd9a86da54f8be4eb2aff3e766b125cbdeb023f URL: https://github.com/llvm/llvm-project/commit/2cd9a86da54f8be4eb2aff3e766b125cbdeb023f DIFF: https://github.com/llvm/llvm-project/commit/2cd9a86da54f8be4eb2aff3e766b125cbdeb023f.diff

[clang] 0604d86 - Darwin: introduce a global override for debug prefix map entries.

2022-02-16 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2022-02-16T08:36:26-08:00 New Revision: 0604d86c07ab8a28b95df689aff4ddd26347f35f URL: https://github.com/llvm/llvm-project/commit/0604d86c07ab8a28b95df689aff4ddd26347f35f DIFF: https://github.com/llvm/llvm-project/commit/0604d86c07ab8a28b95df689aff4ddd26347f35f.diff

[clang] baac665 - Revert "[lld/coff] Make lld-link work in a non-MSVC shell, add /winsysroot:"

2022-02-11 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2022-02-11T13:07:23-08:00 New Revision: baac665adf324672802dcc7037a25468e9569c95 URL: https://github.com/llvm/llvm-project/commit/baac665adf324672802dcc7037a25468e9569c95 DIFF: https://github.com/llvm/llvm-project/commit/baac665adf324672802dcc7037a25468e9569c95.diff

[clang] eb200e5 - Emit the C++ dialect in -gmodules .pcm files.

2022-01-10 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2022-01-10T16:13:40-08:00 New Revision: eb200e584ece7ca8c1f8cac59ca5418956ccf1e4 URL: https://github.com/llvm/llvm-project/commit/eb200e584ece7ca8c1f8cac59ca5418956ccf1e4 DIFF: https://github.com/llvm/llvm-project/commit/eb200e584ece7ca8c1f8cac59ca5418956ccf1e4.diff

[clang] 915d1c0 - Add missing textual header to module map

2021-12-13 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2021-12-13T09:21:21-08:00 New Revision: 915d1c0b74b5e9462a9ae7cd684a70d1422c7f5a URL: https://github.com/llvm/llvm-project/commit/915d1c0b74b5e9462a9ae7cd684a70d1422c7f5a DIFF: https://github.com/llvm/llvm-project/commit/915d1c0b74b5e9462a9ae7cd684a70d1422c7f5a.diff

[clang] c03c58c - Add missing textual header to module map

2021-12-13 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2021-12-13T09:19:22-08:00 New Revision: c03c58c97ab8ac41c84b5269a40c0b35455e URL: https://github.com/llvm/llvm-project/commit/c03c58c97ab8ac41c84b5269a40c0b35455e DIFF: https://github.com/llvm/llvm-project/commit/c03c58c97ab8ac41c84b5269a40c0b35455e.diff

[clang] 843390c - Apply proper source location to fallthrough switch cases.

2021-09-17 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2021-09-17T14:45:04-07:00 New Revision: 843390c58ae660fa356c534fdc8b19756f8d175c URL: https://github.com/llvm/llvm-project/commit/843390c58ae660fa356c534fdc8b19756f8d175c DIFF: https://github.com/llvm/llvm-project/commit/843390c58ae660fa356c534fdc8b19756f8d175c.diff

[clang] 6c3a107 - Mark Basic/TargetCXXABI.def as textual in the module map.

2021-05-04 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2021-05-04T12:52:52-07:00 New Revision: 6c3a10760da3707186d5204bd9283e99344fa90f URL: https://github.com/llvm/llvm-project/commit/6c3a10760da3707186d5204bd9283e99344fa90f DIFF: https://github.com/llvm/llvm-project/commit/6c3a10760da3707186d5204bd9283e99344fa90f.diff

[clang] 0ff9116 - Register TargetCXXABI.def as a textual header

2020-10-14 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2020-10-14T14:20:39-07:00 New Revision: 0ff9116b36781d6fa61c25841edd53dc8f366bec URL: https://github.com/llvm/llvm-project/commit/0ff9116b36781d6fa61c25841edd53dc8f366bec DIFF: https://github.com/llvm/llvm-project/commit/0ff9116b36781d6fa61c25841edd53dc8f366bec.diff

[clang] 272742a - Perform an extra consistency check when searching ModuleManager's

2020-09-02 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2020-09-02T14:16:26-07:00 New Revision: 272742a92d2443893eb98a7b3460e243e34278f9 URL: https://github.com/llvm/llvm-project/commit/272742a92d2443893eb98a7b3460e243e34278f9 DIFF: https://github.com/llvm/llvm-project/commit/272742a92d2443893eb98a7b3460e243e34278f9.diff

[clang] 3b12e12 - Revert "[clang] Add missing .def files to Clang's modulemap"

2020-09-02 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2020-09-02T14:15:32-07:00 New Revision: 3b12e12d4b9efbdd28113da6db0f74b660257c83 URL: https://github.com/llvm/llvm-project/commit/3b12e12d4b9efbdd28113da6db0f74b660257c83 DIFF: https://github.com/llvm/llvm-project/commit/3b12e12d4b9efbdd28113da6db0f74b660257c83.diff

[clang] b907ad5 - [NFC] Clean up doc comment and implementation for Module::isSubModuleOf.

2020-07-21 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2020-07-21T16:23:36-07:00 New Revision: b907ad539a900279443dc8ef8816b6b5a76b1ea1 URL: https://github.com/llvm/llvm-project/commit/b907ad539a900279443dc8ef8816b6b5a76b1ea1 DIFF: https://github.com/llvm/llvm-project/commit/b907ad539a900279443dc8ef8816b6b5a76b1ea1.diff

  1   2   3   4   5   >