https://github.com/ivanmurashko closed
https://github.com/llvm/llvm-project/pull/152751
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
ivanmurashko wrote:
@steakhal @NagyDonat Thank you both for the thorough review and valuable
feedback! I've addressed the latest comments with the following commits:
- Test formatting improvement: 6dd767160bef315748488ef3e0598d2847b40c47
- Documentation improvement: 196abdb3e4bd4eced37933dd
@@ -3145,27 +3144,71 @@ static bool isSmartOwningPtrType(QualType QT) {
if (!ND)
return false;
-// Accept both std and custom smart pointer implementations for broader
-// coverage
-return isSmartOwningPtrName(ND->getName());
+// For broader coverage
ivanmurashko wrote:
Thank you very much, @NagyDonat, for the review and useful comments -
especially the code pointers, which I used in
7c6ffa87d87fed8097558a9b79e9fb321903239b. I believe that I have addressed all
comments, and the code is ready for the next review.
Beyond resolving the comme
ivanmurashko wrote:
> Moreover I thought about the approach that you currently emphasize "owning"
> in every name and comment where you speak about smart pointers. As this is
> not a distinguishing feature of these functions (you never interact with
> non-owning smart pointers) and these func
@@ -3068,12 +3124,242 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Helper function to check if a name is a recognized smart pointer name
+static bool isSmartPtrName(StringRef Name) {
+ return Name == "unique_ptr
@@ -1096,6 +1104,54 @@ class StopTrackingCallback final : public SymbolVisitor {
return true;
}
};
+
+/// EscapeTrackedCallback - A SymbolVisitor that marks allocated symbols as
+/// escaped.
+///
+/// This visitor is used to suppress false positive leak reports when smar
@@ -3068,12 +3124,225 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Helper function to check if a name is a recognized smart owning pointer name
+static bool isSmartOwningPtrName(StringRef Name) {
+ return Name =
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/152751
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,232 @@
+// RUN: %clang_analyze_cc1 -verify -analyzer-output=text %s \
+// RUN: -analyzer-checker=core \
+// RUN: -analyzer-checker=cplusplus \
+// RUN: -analyzer-checker=unix \
+// RUN: -analyzer-checker=unix.Malloc
+
+#include "Inputs/system-header-simulator-fo
@@ -3194,7 +3480,6 @@ void MallocChecker::checkEscapeOnReturn(const ReturnStmt
*S,
if (!Sym)
// If we are returning a field of the allocated struct or an array element,
// the callee could still free the memory.
-// TODO: This logic should be a part of generic sy
ivanmurashko wrote:
Thanks for the review, @NagyDonat. I am still working on addressing the
"duplicates the traversal logic" comment and will return to the other comments
right after the commit that addresses this major part of the refactoring.
Overall, I plan to address all comments by the en
@@ -3068,12 +3124,242 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Helper function to check if a name is a recognized smart pointer name
+static bool isSmartPtrName(StringRef Name) {
+ return Name == "unique_ptr
@@ -3068,12 +3124,242 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Helper function to check if a name is a recognized smart pointer name
+static bool isSmartPtrName(StringRef Name) {
+ return Name == "unique_ptr
@@ -3068,12 +3124,242 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Helper function to check if a name is a recognized smart pointer name
+static bool isSmartPtrName(StringRef Name) {
+ return Name == "unique_ptr
@@ -3068,12 +3124,242 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Helper function to check if a name is a recognized smart pointer name
+static bool isSmartPtrName(StringRef Name) {
+ return Name == "unique_ptr
@@ -1096,6 +1104,54 @@ class StopTrackingCallback final : public SymbolVisitor {
return true;
}
};
+
+/// EscapeTrackedCallback - A SymbolVisitor that marks allocated symbols as
+/// escaped.
+///
+/// This visitor is used to suppress false positive leak reports when smar
@@ -3068,12 +3124,240 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Helper function to check if a name is a recognized smart pointer name
+static bool isSmartPtrName(StringRef Name) {
+ return Name == "unique_ptr
ivanmurashko wrote:
Thanks for the feedback! I've already added the commit hashes to my responses
above. I'll avoid force-pushes going forward and use merges to preserve the
commit history.
https://github.com/llvm/llvm-project/pull/152751
___
cfe-co
@@ -3068,12 +3124,240 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Helper function to check if a name is a recognized smart pointer name
+static bool isSmartPtrName(StringRef Name) {
+ return Name == "unique_ptr
@@ -3068,12 +3124,240 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Helper function to check if a name is a recognized smart pointer name
+static bool isSmartPtrName(StringRef Name) {
+ return Name == "unique_ptr
@@ -1096,6 +1104,54 @@ class StopTrackingCallback final : public SymbolVisitor {
return true;
}
};
+
+/// EscapeTrackedCallback - A SymbolVisitor that marks allocated symbols as
+/// escaped.
+///
+/// This visitor is used to suppress false positive leak reports when smar
ivanmurashko wrote:
Hi @steakhal — I believe I have addressed all your comments: I added a test
with multiple memory-owning arguments, fixed the misuse of `addTransition` by
returning early when post-handlers exist, and simplified `checkPostCall` to
about ten lines of code. All tests pass. Whe
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/152751
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,80 @@
+// RUN: %clang_analyze_cc1 -verify -analyzer-output=text %s \
+// RUN: -analyzer-checker=core \
+// RUN: -analyzer-checker=cplusplus \
+// RUN: -analyzer-checker=unix
+// expected-no-diagnostics
+
+#include "Inputs/system-header-simulator-for-malloc.h"
+
+/
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/152751
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/152751
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -3068,12 +3125,235 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Allowlist of owning smart pointers we want to recognize.
+// Start with unique_ptr and shared_ptr. (intentionally exclude weak_ptr)
+static bool
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 01/15] [clang-analyzer] Add regression test for PR60896
---
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 01/15] [clang-analyzer] Add regression test for PR60896
---
@@ -3068,11 +3107,217 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+static QualType canonicalStrip(QualType QT) {
+ return QT.getCanonicalType().getUnqualifiedType();
+}
+
+static bool isInStdNamespace(const DeclCon
@@ -3068,11 +3107,217 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+static QualType canonicalStrip(QualType QT) {
+ return QT.getCanonicalType().getUnqualifiedType();
+}
+
+static bool isInStdNamespace(const DeclCon
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 01/15] [clang-analyzer] Add regression test for PR60896
---
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 01/14] [clang-analyzer] Add regression test for PR60896
---
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 01/13] [clang-analyzer] Add regression test for PR60896
---
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 01/13] [clang-analyzer] Add regression test for PR60896
---
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 01/13] [clang-analyzer] Add regression test for PR60896
---
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 01/12] [clang-analyzer] Add regression test for PR60896
---
ivanmurashko wrote:
> clang-tidy: False positive potential memory leak warning with aggregate
> initialization of unique_ptr members #153300
> > I am sorry, looks like I found another regression:
> > ...
> > With your patch applied `raw` leak is not reported, however current CSA
> > finds it
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 01/12] [clang-analyzer] Add regression test for PR60896
---
@@ -1096,6 +1098,47 @@ class StopTrackingCallback final : public SymbolVisitor {
return true;
}
};
+
+/// EscapeTrackedCallback - A SymbolVisitor that marks allocated symbols as
+/// escaped.
+///
+/// This visitor is used to suppress false positive leak reports when smar
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 01/11] [clang-analyzer] Add regression test for PR60896
---
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/152751
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -3068,11 +3110,195 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Allowlist of owning smart pointers we want to recognize.
+// Start with unique_ptr and shared_ptr. (intentionally exclude weak_ptr)
+static bool
@@ -3068,11 +3110,195 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Allowlist of owning smart pointers we want to recognize.
+// Start with unique_ptr and shared_ptr. (intentionally exclude weak_ptr)
+static bool
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 01/10] [clang-analyzer] Add regression test for PR60896
---
@@ -3068,11 +3110,195 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Allowlist of owning smart pointers we want to recognize.
+// Start with unique_ptr and shared_ptr. (intentionally exclude weak_ptr)
+static bool
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/152751
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,80 @@
+// RUN: %clang_analyze_cc1 -verify -analyzer-output=text %s \
+// RUN: -analyzer-checker=core \
+// RUN: -analyzer-checker=cplusplus \
+// RUN: -analyzer-checker=unix
+// expected-no-diagnostics
+
+#include "Inputs/system-header-simulator-for-malloc.h"
+
+/
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 1/9] [clang-analyzer] Add regression test for PR60896
---
.
@@ -3068,11 +3111,174 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Use isWithinStdNamespace from CheckerHelpers.h instead of custom
+// implementation
+
+// Allowlist of owning smart pointers we want to recognize
@@ -3068,11 +3111,174 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Use isWithinStdNamespace from CheckerHelpers.h instead of custom
+// implementation
+
+// Allowlist of owning smart pointers we want to recognize
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 1/8] [clang-analyzer] Add regression test for PR60896
---
.
@@ -3068,11 +3111,174 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Use isWithinStdNamespace from CheckerHelpers.h instead of custom
+// implementation
+
+// Allowlist of owning smart pointers we want to recognize
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 1/7] [clang-analyzer] Add regression test for PR60896
---
.
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/152751
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1096,6 +1098,47 @@ class StopTrackingCallback final : public SymbolVisitor {
return true;
}
};
+
+/// EscapeTrackedCallback - A SymbolVisitor that marks allocated symbols as
+/// escaped.
+///
+/// This visitor is used to suppress false positive leak reports when smar
@@ -1096,6 +1098,47 @@ class StopTrackingCallback final : public SymbolVisitor {
return true;
}
};
+
+/// EscapeTrackedCallback - A SymbolVisitor that marks allocated symbols as
+/// escaped.
+///
+/// This visitor is used to suppress false positive leak reports when smar
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 1/6] [clang-analyzer] Add regression test for PR60896
---
.
@@ -3107,24 +3111,13 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
-static QualType canonicalStrip(QualType QT) {
- return QT.getCanonicalType().getUnqualifiedType();
-}
-
-static bool isInStdNamespace(const DeclCont
@@ -52,6 +52,7 @@
#include "clang/AST/DeclTemplate.h"
#include "clang/AST/Expr.h"
#include "clang/AST/ExprCXX.h"
+
ivanmurashko wrote:
Applied
https://github.com/llvm/llvm-project/pull/152751
___
cfe-commits mailing
@@ -3068,11 +3111,174 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Use isWithinStdNamespace from CheckerHelpers.h instead of custom
+// implementation
+
+// Allowlist of owning smart pointers we want to recognize
@@ -3068,11 +3111,174 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+// Use isWithinStdNamespace from CheckerHelpers.h instead of custom
+// implementation
+
+// Allowlist of owning smart pointers we want to recognize
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 1/6] [clang-analyzer] Add regression test for PR60896
---
.
@@ -0,0 +1,37 @@
+// RUN: %clang_analyze_cc1 -analyzer-checker=core,cplusplus,unix -verify %s
+// expected-no-diagnostics
+
ivanmurashko wrote:
Done
https://github.com/llvm/llvm-project/pull/152751
___
cfe-commits mail
@@ -0,0 +1,44 @@
+// RUN: %clang_analyze_cc1 -verify -analyzer-output=text %s \
+// RUN: -analyzer-checker=core \
+// RUN: -analyzer-checker=cplusplus \
+// RUN: -analyzer-checker=unix
+// expected-no-diagnostics
+
+#include "Inputs/system-header-simulator-for-malloc.h"
+
+/
@@ -3068,11 +3107,217 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+static QualType canonicalStrip(QualType QT) {
+ return QT.getCanonicalType().getUnqualifiedType();
+}
+
+static bool isInStdNamespace(const DeclCon
@@ -3068,11 +3107,217 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+static QualType canonicalStrip(QualType QT) {
+ return QT.getCanonicalType().getUnqualifiedType();
+}
+
+static bool isInStdNamespace(const DeclCon
@@ -3068,11 +3107,217 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+static QualType canonicalStrip(QualType QT) {
+ return QT.getCanonicalType().getUnqualifiedType();
+}
+
+static bool isInStdNamespace(const DeclCon
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 1/5] [clang-analyzer] Add regression test for PR60896
---
.
@@ -3068,11 +3107,217 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+static QualType canonicalStrip(QualType QT) {
+ return QT.getCanonicalType().getUnqualifiedType();
+}
ivanmurashko wrote:
Replac
@@ -3068,11 +3107,217 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+static QualType canonicalStrip(QualType QT) {
+ return QT.getCanonicalType().getUnqualifiedType();
+}
+
+static bool isInStdNamespace(const DeclCon
@@ -3068,11 +3107,217 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+static QualType canonicalStrip(QualType QT) {
+ return QT.getCanonicalType().getUnqualifiedType();
+}
+
+static bool isInStdNamespace(const DeclCon
@@ -52,6 +52,9 @@
#include "clang/AST/DeclTemplate.h"
#include "clang/AST/Expr.h"
#include "clang/AST/ExprCXX.h"
+#include "clang/AST/TemplateBase.h"
+#include "clang/AST/Type.h"
+
ivanmurashko wrote:
Applied the patch
https://github.com/llvm/llvm-project/pul
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 1/5] [clang-analyzer] Add regression test for PR60896
---
.
@@ -1096,6 +1100,41 @@ class StopTrackingCallback final : public SymbolVisitor {
return true;
}
};
+
+/// EscapeTrackedCallback - A SymbolVisitor that marks allocated symbols as
+/// escaped.
+///
+/// This visitor is used to suppress false positive leak reports when smar
@@ -3068,11 +3107,217 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+static QualType canonicalStrip(QualType QT) {
+ return QT.getCanonicalType().getUnqualifiedType();
+}
+
+static bool isInStdNamespace(const DeclCon
@@ -3068,11 +3107,217 @@ void MallocChecker::checkDeadSymbols(SymbolReaper
&SymReaper,
C.addTransition(state->set(RS), N);
}
+static QualType canonicalStrip(QualType QT) {
+ return QT.getCanonicalType().getUnqualifiedType();
+}
+
+static bool isInStdNamespace(const DeclCon
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 1/5] [clang-analyzer] Add regression test for PR60896
---
.
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/152751
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/152751
>From 7d1c7000c7482f8d1ec1593b77a8f4a9456082ac Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 8 Aug 2025 10:25:26 +0100
Subject: [PATCH 1/4] [clang-analyzer] Add regression test for PR60896
---
.
https://github.com/ivanmurashko created
https://github.com/llvm/llvm-project/pull/152751
## Summary
Fixes [PR60896](https://github.com/llvm/llvm-project/issues/60896) — false
positive leak reports when `std::unique_ptr` or `std::shared_ptr` are members
of a temporary object passed **by value**
https://github.com/ivanmurashko approved this pull request.
@eaeltsin confirmed that the commit fixes an issue introduced earlier by
[#109167](https://github.com/llvm/llvm-project/pull/109167). The fix LGTM
https://github.com/llvm/llvm-project/pull/110131
___
https://github.com/ivanmurashko closed
https://github.com/llvm/llvm-project/pull/91645
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
ivanmurashko wrote:
Friendly ping
@sam-mccall , @jansvoboda11 , could you look at the diff. It fixes a critical
issue for anyone who wants to use Clang modules with file remapping, for
instance at clangd.
https://github.com/llvm/llvm-project/pull/91645
ivanmurashko wrote:
Hi @sam-mccall,
The patch touches some fairly old code that hasn't been modified for a long
time. You are one of the few people who worked on it recently, around two years
ago. I would appreciate any comments and a review of the suggested patch.
https://github.com/llvm/ll
https://github.com/ivanmurashko closed
https://github.com/llvm/llvm-project/pull/91738
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
ivanmurashko wrote:
@dmpolukhin , the test was successfully passed on MS Windows. There is the
corresponding record from the build log
```
_bk;t=1715380522596PASS: Clang :: Modules/implicit-module-no-timestamp.cpp
(12618 of 20053)
```
https://github.com/llvm/llvm-project/pull/91738
_
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/91738
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ivanmurashko created
https://github.com/llvm/llvm-project/pull/91738
There is a followup commit for #90319. The windows test was disabled at that
commit but it should pass on MS Windows and it would be good to have it enabled.
>From 6e5bd93173a8515749115f45c993ddf472437c79 M
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/91645
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/91645
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ivanmurashko edited
https://github.com/llvm/llvm-project/pull/91645
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ivanmurashko created
https://github.com/llvm/llvm-project/pull/91645
The `FileManager` might create a virtual directory that can be used later as a
search path. If the added record is a real directory that is present on a disk,
we might encounter a false cache miss and add t
https://github.com/ivanmurashko closed
https://github.com/llvm/llvm-project/pull/90319
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/90319
>From 71796a80e15b6700fec23fbec70635aae455b188 Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 26 Apr 2024 22:45:26 +0100
Subject: [PATCH] [Modules] Process include files changes with
-fmodules-vali
@@ -0,0 +1,34 @@
+// UNSUPPORTED: system-windows
+// RUN: rm -rf %t
+// RUN: split-file %s %t
+// RUN: cd %t
+//
+// RUN: cp a1.h a.h
+// RUN: %clang -fmodules -fmodules-validate-input-files-content -Xclang
-fno-pch-timestamp -fimplicit-modules -fmodule-map-file=module.modulemap
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/90319
>From 3c36295b5f0f1e011e11d57c5ec4e685cb917cab Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 26 Apr 2024 22:45:26 +0100
Subject: [PATCH] [Modules] Process include files changes with
-fmodules-vali
@@ -0,0 +1,34 @@
+// UNSUPPORTED: system-windows
+// RUN: rm -rf %t
+// RUN: split-file %s %t
+// RUN: cd %t
+//
+// RUN: cp a1.h a.h
+// RUN: %clang -fmodules -fmodules-validate-input-files-content -Xclang
-fno-pch-timestamp -fimplicit-modules -fmodule-map-file=module.modulemap
https://github.com/ivanmurashko updated
https://github.com/llvm/llvm-project/pull/90319
>From 48a019ead18d3e8aeb5d10d0301c2567ef1c5cd7 Mon Sep 17 00:00:00 2001
From: Ivan Murashko
Date: Fri, 26 Apr 2024 22:45:26 +0100
Subject: [PATCH] [Modules] Process include files changes with
-fmodules-vali
1 - 100 of 117 matches
Mail list logo