[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-02-03 Thread Ilya Biryukov via cfe-commits
ilya-biryukov wrote: FYI: this PR was taking too long to pick changes after rebase, so the discussions continued in #125492. https://github.com/llvm/llvm-project/pull/124554 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.or

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-02-03 Thread Ivana Ivanovska via cfe-commits
https://github.com/ivanaivanovska closed https://github.com/llvm/llvm-project/pull/124554 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-31 Thread Ilya Biryukov via cfe-commits
@@ -1986,112 +2362,117 @@ class DerefSimplePtrArithFixableGadget : public FixableGadget { } }; -/// Scan the function and return a list of gadgets found with provided kits. -static void findGadgets(const Stmt *S, ASTContext &Ctx, -const UnsafeBufferU

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-31 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov commented: This generally looks good, just one more minor comment from me. Could we put this out of the draft state and send to upstream owners of the check to start a discussion about landing it? https://github.com/llvm/llvm-project/pull/124554

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-31 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov edited https://github.com/llvm/llvm-project/pull/124554 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-31 Thread Ivana Ivanovska via cfe-commits
https://github.com/ivanaivanovska edited https://github.com/llvm/llvm-project/pull/124554 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-31 Thread Ivana Ivanovska via cfe-commits
@@ -68,32 +70,60 @@ static std::string getDREAncestorString(const DeclRefExpr *DRE, if (StParents.size() > 1) return "unavailable due to multiple parents"; -if (StParents.size() == 0) +if (StParents.empty()) break; St = StParents.begin()->get();

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-31 Thread Ivana Ivanovska via cfe-commits
@@ -68,32 +70,60 @@ static std::string getDREAncestorString(const DeclRefExpr *DRE, if (StParents.size() > 1) return "unavailable due to multiple parents"; -if (StParents.size() == 0) +if (StParents.empty()) break; St = StParents.begin()->get();

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-30 Thread Ivana Ivanovska via cfe-commits
https://github.com/ivanaivanovska updated https://github.com/llvm/llvm-project/pull/124554 504 Gateway Time-out The server didn't respond in time. ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-30 Thread Ilya Biryukov via cfe-commits
@@ -68,32 +70,60 @@ static std::string getDREAncestorString(const DeclRefExpr *DRE, if (StParents.size() > 1) return "unavailable due to multiple parents"; -if (StParents.size() == 0) +if (StParents.empty()) break; St = StParents.begin()->get();

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-30 Thread Ilya Biryukov via cfe-commits
@@ -68,32 +70,60 @@ static std::string getDREAncestorString(const DeclRefExpr *DRE, if (StParents.size() > 1) return "unavailable due to multiple parents"; -if (StParents.size() == 0) +if (StParents.empty()) break; St = StParents.begin()->get();

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-30 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov commented: I only have a few suggestions left, overall this LG. Could you also add a description for the PR that explains the motivation and approach taken for the rewrite? Benchmark numbers would also be needed there. Thanks! https://github.com/llvm/llvm-pro

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-30 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov edited https://github.com/llvm/llvm-project/pull/124554 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-29 Thread via cfe-commits
https://github.com/ivanaivanovska edited https://github.com/llvm/llvm-project/pull/124554 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits