[clang-tools-extra] [clangd] Guard against trivial FunctionProtoTypeLoc when creating inlay hints (PR #143087)

2025-06-06 Thread Haojian Wu via cfe-commits
@@ -368,6 +368,14 @@ static FunctionProtoTypeLoc getPrototypeLoc(Expr *Fn) { } if (auto F = Target.getAs()) { +// In some edge cases the AST can contain a "trivial" FunctionProtoTypeLoc +// which has null parameters. Avoid these as they don't contain useful +//

[clang-tools-extra] [clangd] Guard against trivial FunctionProtoTypeLoc when creating inlay hints (PR #143087)

2025-06-06 Thread Haojian Wu via cfe-commits
@@ -368,6 +368,14 @@ static FunctionProtoTypeLoc getPrototypeLoc(Expr *Fn) { } if (auto F = Target.getAs()) { +// In some edge cases the AST can contain a "trivial" FunctionProtoTypeLoc hokein wrote: nit: We have a duplicated one in ` SemaCodeComplete

[clang] [clang] NFC: Add alias for std::pair used in SourceLocation (PR #145711)

2025-06-26 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/145711 >From 2bd778b5b5c5ffc0a36cf0e0e71034fe16c48ad0 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Wed, 25 Jun 2025 16:12:40 +0200 Subject: [PATCH 1/2] [clang] Create alias for the common `std::pair` type used in Sou

[clang] [clang][AST] Reduce some AST node size. (PR #142585)

2025-06-03 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/142585 >From 4b1cdc30ddb476d7e30519e5fe5ab6c298b59809 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Sat, 10 May 2025 07:44:51 +0200 Subject: [PATCH 1/4] [AST] Restructure the CXXForRanageStmt class to reduce the size

[clang] [clang][AST] Reduce some AST node size. (PR #142585)

2025-06-03 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/142585 >From 1a233dbb9d58cf488551caf29d441f2c6a5b68b5 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Tue, 3 Jun 2025 08:42:37 +0200 Subject: [PATCH 1/2] [clang][modules] Remove the workaround for the lambda issue. Th

[clang] [clang][AST] Reduce some AST node size. (PR #142585)

2025-06-03 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/142585 >From 1a233dbb9d58cf488551caf29d441f2c6a5b68b5 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Tue, 3 Jun 2025 08:42:37 +0200 Subject: [PATCH 1/3] [clang][modules] Remove the workaround for the lambda issue. Th

[clang] [clang][AST] Reduce some AST node size. (PR #142585)

2025-06-03 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/142585 >From b6b83987f117ed037fb4de4fc5be7740bab295e1 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Tue, 3 Jun 2025 08:42:37 +0200 Subject: [PATCH] [clang][AST] Reduce AST node size --- clang/include/clang/AST/Expr.

[clang] [clang][AST] Reduce some AST node size. (PR #142585)

2025-06-03 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/142585 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Reduce LateInstantiatedAttrVec vector default size. (PR #142840)

2025-06-04 Thread Haojian Wu via cfe-commits
https://github.com/hokein created https://github.com/llvm/llvm-project/pull/142840 This increases clang's template instantiation depths. I can see 7% increase (1510 -> 1612 on my local machine) for the `clang/test/SemaTemplate/instantiation-depth-default.cpp` case. No performance regressions

[clang-tools-extra] [clangd] Log the paths of loaded config files without --log=verbose (PR #142063)

2025-05-30 Thread Haojian Wu via cfe-commits
https://github.com/hokein approved this pull request. https://github.com/llvm/llvm-project/pull/142063 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] SourceManager: Cache offsets for LastFileIDLookup to speed up getFileID (PR #146782)

2025-07-03 Thread Haojian Wu via cfe-commits
@@ -832,13 +835,11 @@ FileID SourceManager::getFileIDLocal(SourceLocation::UIntTy SLocOffset) const { unsigned LessIndex = 0; // upper bound of the search range. unsigned GreaterIndex = LocalSLocEntryTable.size(); - if (LastFileIDLookup.ID >= 0) { -// Use the LastFi

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-07-03 Thread Haojian Wu via cfe-commits
@@ -1304,6 +1304,13 @@ checkExprLifetimeImpl(Sema &SemaRef, const InitializedEntity *InitEntity, if (LK == LK_FullExpression) return; + if (LK == LK_Extended && SemaRef.getLangOpts().CPlusPlus23) { hokein wrote: Is the `LK == LK_Extended` check necess

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-07-03 Thread Haojian Wu via cfe-commits
https://github.com/hokein commented: There are some test failures in the presubmit checks, you probably need to update these tests. https://github.com/llvm/llvm-project/pull/145164 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.

[clang] [clang] SourceManager: Cache offsets for LastFileIDLookup to speed up getFileID (PR #146782)

2025-07-03 Thread Haojian Wu via cfe-commits
@@ -1901,9 +1903,8 @@ class SourceManager : public RefCountedBase { FileID getFileID(SourceLocation::UIntTy SLocOffset) const { // If our one-entry cache covers this offset, just return it. -if (isOffsetInFileID(LastFileIDLookup, SLocOffset)) +if (SLocOffset >=

[clang] [clang] SourceManager: Cache offsets for LastFileIDLookup to speed up getFileID (PR #146782)

2025-07-03 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/146782 >From 50c6fcb2a1167b65255d2edce9ef34789b85a7a5 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Wed, 2 Jul 2025 16:22:48 +0200 Subject: [PATCH 1/3] Cache the Offset for LastFileIDLookup. --- clang/include/clang/

[clang] [Serialization] Fix source location data loss during decoding. (PR #145529)

2025-06-25 Thread Haojian Wu via cfe-commits
hokein wrote: > The design is, the higher 32 bits are used for module file index and the > lower bits are used for offsets. Could you give a concrete example why the > current implementation is problematic? I don’t have a concrete failure case, but I noticed this while working on 64-bit sourc

[clang] [Sema] Avoid deep recursion in AnalyzeImplicitConversions (PR #145734)

2025-06-25 Thread Haojian Wu via cfe-commits
https://github.com/hokein approved this pull request. https://github.com/llvm/llvm-project/pull/145734 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Serialization] Remove delta encoding optimization (PR #145670)

2025-06-25 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/145670 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] SourceManager: Cache offsets for LastFileIDLookup to speed up getFileID (PR #146782)

2025-07-03 Thread Haojian Wu via cfe-commits
@@ -832,13 +835,11 @@ FileID SourceManager::getFileIDLocal(SourceLocation::UIntTy SLocOffset) const { unsigned LessIndex = 0; // upper bound of the search range. unsigned GreaterIndex = LocalSLocEntryTable.size(); - if (LastFileIDLookup.ID >= 0) { -// Use the LastFi

[clang] [clang] SourceManager: Cache offsets for LastFileIDLookup to speed up getFileID (PR #146782)

2025-07-03 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/146782 >From 50c6fcb2a1167b65255d2edce9ef34789b85a7a5 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Wed, 2 Jul 2025 16:22:48 +0200 Subject: [PATCH 1/2] Cache the Offset for LastFileIDLookup. --- clang/include/clang/

[clang] [clang] SourceManager: Cache offsets for LastFileIDLookup to speed up getFileID (PR #146782)

2025-07-03 Thread Haojian Wu via cfe-commits
@@ -1901,9 +1903,8 @@ class SourceManager : public RefCountedBase { FileID getFileID(SourceLocation::UIntTy SLocOffset) const { // If our one-entry cache covers this offset, just return it. -if (isOffsetInFileID(LastFileIDLookup, SLocOffset)) +if (SLocOffset >=

[clang] [clang] SourceManager: Cache offsets for LastFileIDLookup to speed up getFileID (PR #146782)

2025-07-03 Thread Haojian Wu via cfe-commits
@@ -849,7 +850,12 @@ FileID SourceManager::getFileIDLocal(SourceLocation::UIntTy SLocOffset) const { FileID Res = FileID::get(int(GreaterIndex)); // Remember it. We have good locality across FileID lookups. LastFileIDLookup = Res; - NumLinearScans += Nu

[clang] [clang] SourceManager: Cache offsets for LastFileIDLookup to speed up getFileID (PR #146782)

2025-07-03 Thread Haojian Wu via cfe-commits
@@ -1901,9 +1903,8 @@ class SourceManager : public RefCountedBase { FileID getFileID(SourceLocation::UIntTy SLocOffset) const { // If our one-entry cache covers this offset, just return it. -if (isOffsetInFileID(LastFileIDLookup, SLocOffset)) +if (SLocOffset >=

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-07-04 Thread Haojian Wu via cfe-commits
hokein wrote: > Yes, indeed. For example, in `AST/ast-dump-for-range-lifetime.cpp` we move > from: `-MaterializeTemporaryExpr {{.*}} 'C':'P2718R0::C' xvalue extended by > Var {{.*}} '__range1' 'C &&'` to: `-MaterializeTemporaryExpr {{.*}} > 'C':'P2718R0::C' xvalue`. At a first look it seems l

[clang] [clang] Speedup getFileIDLocal with a separate offset table. (PR #146604)

2025-07-04 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/146604 >From 7b06dabcc8fafee1e9ff3261264c36a44cb7b0a3 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Tue, 1 Jul 2025 22:04:51 +0200 Subject: [PATCH] [SourceManager] Speedup getFileIDLocal with a separate Offset Table.

[clang] [clang] Improve getFileIDLocal binary search. (PR #146510)

2025-07-01 Thread Haojian Wu via cfe-commits
@@ -855,35 +857,24 @@ FileID SourceManager::getFileIDLocal(SourceLocation::UIntTy SLocOffset) const { break; } - NumProbes = 0; - while (true) { -unsigned MiddleIndex = (GreaterIndex-LessIndex)/2+LessIndex; -SourceLocation::UIntTy MidOffset = -getLoc

[clang] [clang] Improve getFileIDLocal binary search. (PR #146510)

2025-07-01 Thread Haojian Wu via cfe-commits
@@ -855,35 +857,24 @@ FileID SourceManager::getFileIDLocal(SourceLocation::UIntTy SLocOffset) const { break; } - NumProbes = 0; - while (true) { -unsigned MiddleIndex = (GreaterIndex-LessIndex)/2+LessIndex; -SourceLocation::UIntTy MidOffset = -getLoc

[clang] ac76e4d - [Serialization] Use SourceLocation::UIntTy for the offset type, NFC

2025-07-01 Thread Haojian Wu via cfe-commits
Author: Haojian Wu Date: 2025-07-01T22:33:23+02:00 New Revision: ac76e4d8a9aedc23123571b3801684babb78424f URL: https://github.com/llvm/llvm-project/commit/ac76e4d8a9aedc23123571b3801684babb78424f DIFF: https://github.com/llvm/llvm-project/commit/ac76e4d8a9aedc23123571b3801684babb78424f.diff LO

[clang] [clang] Improve getFileIDLocal binary search. (PR #146510)

2025-07-01 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/146510 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Improve getFileIDLocal binary search. (PR #146510)

2025-07-01 Thread Haojian Wu via cfe-commits
@@ -855,35 +857,24 @@ FileID SourceManager::getFileIDLocal(SourceLocation::UIntTy SLocOffset) const { break; } - NumProbes = 0; - while (true) { -unsigned MiddleIndex = (GreaterIndex-LessIndex)/2+LessIndex; -SourceLocation::UIntTy MidOffset = -getLoc

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-06-30 Thread Haojian Wu via cfe-commits
@@ -1341,6 +1341,14 @@ checkExprLifetimeImpl(Sema &SemaRef, const InitializedEntity *InitEntity, } if (IsGslPtrValueFromGslTempOwner && DiagLoc.isValid()) { + +if (SemaRef.getLangOpts().CPlusPlus23) { hokein wrote: the analysis is done he

[clang] [clang-tools-extra] WIP: Extend SourceLocation to 64 bits. (PR #146314)

2025-06-30 Thread Haojian Wu via cfe-commits
@@ -682,6 +682,11 @@ class DeclarationNameTable { DeclarationName getCXXLiteralOperatorName(const IdentifierInfo *II); }; +struct CXXOperatorSourceInfo { + SourceLocation::UIntTy BeginOpNameLoc; hokein wrote: Interesting -- this patch was rebased recently

[clang] [clang-tools-extra] WIP: Extend SourceLocation to 64 bits. (PR #146314)

2025-06-30 Thread Haojian Wu via cfe-commits
@@ -698,8 +703,7 @@ class DeclarationNameLoc { // The location (if any) of the operator keyword is stored elsewhere. struct CXXOpName { -SourceLocation::UIntTy BeginOpNameLoc; -SourceLocation::UIntTy EndOpNameLoc; +CXXOperatorSourceInfo* OInfo;

[clang] [clang] Don't use raw source location in DeclarationName, NFC (PR #146412)

2025-06-30 Thread Haojian Wu via cfe-commits
https://github.com/hokein created https://github.com/llvm/llvm-project/pull/146412 Converting back and forth for the source location raw encoding is unnecessary. >From 21619dbe7f13c73c8657fac0410fe87ab8baeea4 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Mon, 30 Jun 2025 17:06:01 +0200 Subj

[clang] [clang-tools-extra] WIP: Extend SourceLocation to 64 bits. (PR #146314)

2025-06-30 Thread Haojian Wu via cfe-commits
hokein wrote: > Sorry for being dumb... how are we getting away with only storing 40 bits? > Does that not just artificially limit our source-location size for > statements? And, frankly, then our entire space? I guess 8 2x-increases in > source-location size are nice, but I was sort of hoping

[clang] [clang-tools-extra] WIP: Extend SourceLocation to 64 bits. (PR #146314)

2025-06-30 Thread Haojian Wu via cfe-commits
hokein wrote: > I did a light pass of the 1st 1/4 of this or so. The smuggling back and forth > to raw-encoding seems strange? WHy are we doing that here? In this patch, to keep AST node size as small as possible, we're using 40 bits of `StmtBits` to store the SourceLocation, we need this back

[clang] [clang-tools-extra] WIP: Extend SourceLocation to 64 bits. (PR #146314)

2025-06-30 Thread Haojian Wu via cfe-commits
@@ -742,8 +742,12 @@ class CXXBoolLiteralExpr : public Expr { SourceLocation getBeginLoc() const { return getLocation(); } SourceLocation getEndLoc() const { return getLocation(); } - SourceLocation getLocation() const { return CXXBoolLiteralExprBits.Loc; } - void setLoc

[clang] [clang] NFC: Add alias for std::pair used in SourceLocation (PR #145711)

2025-06-26 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/145711 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] NFC: Add alias for std::pair used in SourceLocation (PR #145711)

2025-06-26 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/145711 >From 2bd778b5b5c5ffc0a36cf0e0e71034fe16c48ad0 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Wed, 25 Jun 2025 16:12:40 +0200 Subject: [PATCH 1/2] [clang] Create alias for the common `std::pair` type used in Sou

[clang] 0588e81 - [Serialization] Use the SourceLocation::UIntTy instead of the raw type

2025-07-02 Thread Haojian Wu via cfe-commits
Author: Haojian Wu Date: 2025-07-02T09:11:55+02:00 New Revision: 0588e8188c647460b641b09467fe6b13a8d510d5 URL: https://github.com/llvm/llvm-project/commit/0588e8188c647460b641b09467fe6b13a8d510d5 DIFF: https://github.com/llvm/llvm-project/commit/0588e8188c647460b641b09467fe6b13a8d510d5.diff LO

[clang] [clang] Don't use raw source location in DeclarationName, NFC (PR #146412)

2025-07-01 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/146412 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] 2ee884a - [clang-doc] Remove the unused clangd header.

2025-07-01 Thread Haojian Wu via cfe-commits
Author: Haojian Wu Date: 2025-07-01T12:07:35+02:00 New Revision: 2ee884a9db293d8906056414753b64918517be4a URL: https://github.com/llvm/llvm-project/commit/2ee884a9db293d8906056414753b64918517be4a DIFF: https://github.com/llvm/llvm-project/commit/2ee884a9db293d8906056414753b64918517be4a.diff LO

[clang] WIP: Extend SourceLocation to 64 bits. (PR #146314)

2025-06-30 Thread Haojian Wu via cfe-commits
https://github.com/hokein edited https://github.com/llvm/llvm-project/pull/146314 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] WIP: Extend SourceLocation to 64 bits. (PR #146314)

2025-06-30 Thread Haojian Wu via cfe-commits
hokein wrote: Although this is still a draft, it should be ready for an initial round of review. Any feedback or suggestions would be greatly appreciated. @AaronBallman @cor3ntin @erichkeane @ilya-biryukov https://github.com/llvm/llvm-project/pull/146314 _

[clang] [clang] Improve getFileIDLocal binary search. (PR #146510)

2025-07-01 Thread Haojian Wu via cfe-commits
https://github.com/hokein created https://github.com/llvm/llvm-project/pull/146510 Avoid reading the `LocalSLocEntryTable` twice per loop iteration. NFC. https://llvm-compile-time-tracker.com/compare.php?from=0b6ddb02efdcbdac9426e8d857499ea0580303cd&to=1aa335ccfb07ba96177b89b1933aa6b980fa14f6&s

[clang] [clang] Reduce the small vector size for DeclTypeInfo. (PR #148788)

2025-07-14 Thread Haojian Wu via cfe-commits
https://github.com/hokein created https://github.com/llvm/llvm-project/pull/148788 The `Declarator` class is large (4584 bytes) and used as a stack-local variable during parsing. This patch reduces the default size of its `DeclTypeInfo` member, reducing the overall size down to 3880 bytes. Th

[clang] [clang] Remove source range from CXXOperatorCallExpr (PR #147028)

2025-07-04 Thread Haojian Wu via cfe-commits
https://github.com/hokein created https://github.com/llvm/llvm-project/pull/147028 This patch stops storing a source range in `CXXOperatorCallExpr` and keeps only the begin location. This change allows us to retain the optimization #141058 when switching to 64-bit source locations. Performan

[clang] [clang-tools-extra] [clang] Extend SourceLocation to 64 bits. (PR #147292)

2025-07-07 Thread Haojian Wu via cfe-commits
@@ -43,17 +46,24 @@ namespace clang { // Macro locations have the top bit set, we rotate by one so it is the low bit. class SourceLocationEncoding { using UIntTy = SourceLocation::UIntTy; - constexpr static unsigned UIntBits = CHAR_BIT * sizeof(UIntTy); static UIntTy en

[clang] [clang] Remove source range from CXXOperatorCallExpr (PR #147028)

2025-07-04 Thread Haojian Wu via cfe-commits
@@ -158,9 +158,9 @@ class CXXOperatorCallExpr final : public CallExpr { : getOperatorLoc(); } - SourceLocation getBeginLoc() const { return Range.getBegin(); } - SourceLocation getEndLoc() const { return Range.getEnd(); } - SourceRange getSourceRange() cons

[clang] [clang] Speedup getFileIDLocal with a separate offset table. (PR #146604)

2025-07-07 Thread Haojian Wu via cfe-commits
hokein wrote: I'm landing this PR now, happy to address any post comments. https://github.com/llvm/llvm-project/pull/146604 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Speedup getFileIDLocal with a separate offset table. (PR #146604)

2025-07-07 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/146604 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Remove source range from CXXOperatorCallExpr (PR #147028)

2025-07-07 Thread Haojian Wu via cfe-commits
hokein wrote: Thank. https://github.com/llvm/llvm-project/pull/147028 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Remove source range from CXXOperatorCallExpr (PR #147028)

2025-07-07 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/147028 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] SourceManager: Cache offsets for LastFileIDLookup to speed up getFileID (PR #146782)

2025-07-04 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/146782 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 7c2182a - NFC, use structured binding to simplify the code in SourceManager.cpp.

2025-07-07 Thread Haojian Wu via cfe-commits
Author: Haojian Wu Date: 2025-07-07T16:43:46+02:00 New Revision: 7c2182a132c709316f7795197978a610a9dfdeae URL: https://github.com/llvm/llvm-project/commit/7c2182a132c709316f7795197978a610a9dfdeae DIFF: https://github.com/llvm/llvm-project/commit/7c2182a132c709316f7795197978a610a9dfdeae.diff LO

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-07-07 Thread Haojian Wu via cfe-commits
https://github.com/hokein approved this pull request. This change looks good to me. https://github.com/llvm/llvm-project/pull/145164 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Fix lifetime extension for temporaries in range-based for loops in C++23 (PR #145164)

2025-07-07 Thread Haojian Wu via cfe-commits
hokein wrote: > I have debug the issue, seems we cannot move the __range variable check to > the start of checkExprLifetimeImpl, we may missing extending lifetime of > temporaries. Ah, that makes sense -- I missed the fact that this part of the code is also responsible for extending the objec

[clang] 7fea83e - [clang] NFC, use LocalLocOffsetTable in getFIleIDLocal.

2025-07-07 Thread Haojian Wu via cfe-commits
Author: Haojian Wu Date: 2025-07-07T09:57:41+02:00 New Revision: 7fea83e3143e1a88a096a37ecd13668e2da94b93 URL: https://github.com/llvm/llvm-project/commit/7fea83e3143e1a88a096a37ecd13668e2da94b93 DIFF: https://github.com/llvm/llvm-project/commit/7fea83e3143e1a88a096a37ecd13668e2da94b93.diff LO

[clang] b7c4ac2 - NFC, use structured binding to simplify the code.

2025-07-07 Thread Haojian Wu via cfe-commits
Author: Haojian Wu Date: 2025-07-07T17:07:37+02:00 New Revision: b7c4ac2db4cdd99203b836bd94b3392fd7536de5 URL: https://github.com/llvm/llvm-project/commit/b7c4ac2db4cdd99203b836bd94b3392fd7536de5 DIFF: https://github.com/llvm/llvm-project/commit/b7c4ac2db4cdd99203b836bd94b3392fd7536de5.diff LO

[clang] [clang-tools-extra] [clang] Extend SourceLocation to 64 bits. (PR #147292)

2025-07-07 Thread Haojian Wu via cfe-commits
hokein wrote: > Why is this a new review? What changed from the last one I looked at? Ah, right -- this patch is actually derived from the previous one, and it is simpler. That older patch became a bit outdated since some of its changes were split out and already landed in main. I found it eas

[clang] [clang-tools-extra] WIP: Extend SourceLocation to 64 bits. (PR #146314)

2025-07-08 Thread Haojian Wu via cfe-commits
https://github.com/hokein closed https://github.com/llvm/llvm-project/pull/146314 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] WIP: Extend SourceLocation to 64 bits. (PR #146314)

2025-07-08 Thread Haojian Wu via cfe-commits
hokein wrote: Closing it in favor of #147292 https://github.com/llvm/llvm-project/pull/146314 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [lldb] [clang] Extend SourceLocation to 64 bits. (PR #147292)

2025-07-08 Thread Haojian Wu via cfe-commits
hokein wrote: > Ah, not a problem, the new one is fine. I was just very thrown/wondering why > I was reviewing something so similar again. Sorry for not being clearer about that. I’ll go ahead and close the previous review. The new one should already incorporate your review comments from the

[clang] [clang] Implement P2582R1: CTAD from inherited constructors (PR #98788)

2025-07-10 Thread Haojian Wu via cfe-commits
hokein wrote: We seem to have lost track of this. This patch has been around for a while, and it needs a rebase before it can be merged. >From what I can tell, part 1 splitting out deduction guide source tracking has >already landed, and the missing piece for alias templates (#103016) is done

[clang] a709621 - [Lex] Use SourceLocation::UIntTy for the MacroDefStart, NFC

2025-07-10 Thread Haojian Wu via cfe-commits
Author: Haojian Wu Date: 2025-07-10T10:46:27+02:00 New Revision: a709621cd545b061782b03136286227867b452a6 URL: https://github.com/llvm/llvm-project/commit/a709621cd545b061782b03136286227867b452a6 DIFF: https://github.com/llvm/llvm-project/commit/a709621cd545b061782b03136286227867b452a6.diff LO

<    27   28   29   30   31   32