[clang] [clang] Fix crash when declaring invalid lambda member (PR #74110)

2024-02-02 Thread Nikolas Klauser via cfe-commits
philnik777 wrote: ping https://github.com/llvm/llvm-project/pull/74110 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [X86] [iamcu] Fix wrong alignment value for attr (aligned) with -miamcu (PR #80401)

2024-02-02 Thread Phoebe Wang via cfe-commits
https://github.com/phoebewang edited https://github.com/llvm/llvm-project/pull/80401 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [X86] [iamcu] Fix wrong alignment value for attr (aligned) with -miamcu (PR #80401)

2024-02-02 Thread Phoebe Wang via cfe-commits
https://github.com/phoebewang approved this pull request. LGTM with one nit. https://github.com/llvm/llvm-project/pull/80401 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [X86] [iamcu] Fix wrong alignment value for attr (aligned) with -miamcu (PR #80401)

2024-02-02 Thread Phoebe Wang via cfe-commits
@@ -1,4 +1,12 @@ // RUN: %clang_cc1 -triple x86_64-apple-darwin9 -fsyntax-only -verify %s +// RUN: %clang_cc1 -triple i586-intel-elfiamcu -fsyntax-only -verify %s + +#ifdef __iamcu +// expected-no-diagnostics +struct dummy { int x __attribute__((aligned)); }; +int m0[__alignof__

[clang] [flang] [flang]Add support for -moutline-atomics and -mno-outline-atomics (PR #78755)

2024-02-02 Thread Kiran Chandramohan via cfe-commits
https://github.com/kiranchandramohan edited https://github.com/llvm/llvm-project/pull/78755 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [flang]Add support for -moutline-atomics and -mno-outline-atomics (PR #78755)

2024-02-02 Thread Kiran Chandramohan via cfe-commits
@@ -0,0 +1,18 @@ +! RUN: %flang -S -emit-llvm --target=aarch64-none-none -moutline-atomics -o - %s | FileCheck %s --check-prefixes=CHECKON,CHECKALL kiranchandramohan wrote: I think it is better if this is in the integration test directory. https://github.com/ll

[flang] [clang] [flang]Add support for -moutline-atomics and -mno-outline-atomics (PR #78755)

2024-02-02 Thread Kiran Chandramohan via cfe-commits
https://github.com/kiranchandramohan approved this pull request. LG. Please address or reply to comments before submitting. https://github.com/llvm/llvm-project/pull/78755 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/c

[clang] [clang-tools-extra] [clangd] Collect comments from function definitions into the index (PR #67802)

2024-02-02 Thread Christian Kandeler via cfe-commits
https://github.com/ckandeler updated https://github.com/llvm/llvm-project/pull/67802 >From fb3711aa040aa2a986ed7d0c503042adecc6662a Mon Sep 17 00:00:00 2001 From: Christian Kandeler Date: Fri, 29 Sep 2023 15:01:58 +0200 Subject: [PATCH] [clangd] Collect comments from function definitions into t

[clang] [clang-tools-extra] [clangd] Collect comments from function definitions into the index (PR #67802)

2024-02-02 Thread Christian Kandeler via cfe-commits
ckandeler wrote: I have removed the extra Symbol member and extended the Flags enum instead. I benchmarked with Qt as the test project (qtbase, to be exact), which is heavily documented and has all its function documentation in the cpp files, so it should provide an upper bound on the effects o

[clang] [clang][Diagnostics] Highlight code snippets (PR #66514)

2024-02-02 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > This I think qualifies as a serious problem as it introduces a crash which > may occur in _any_ existent codebase. Anyone using the compiler at trunk and > encountering the crash has no way to know how to deal with it. I think it's worth remembering that downstreams carry

[clang] Fix INF/NAN warning. (PR #80290)

2024-02-02 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam ready_for_review https://github.com/llvm/llvm-project/pull/80290 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix INF/NAN warning. (PR #80290)

2024-02-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Zahira Ammarguellat (zahiraam) Changes In https://github.com/llvm/llvm-project/pull/76873 a warning was added when the macros INFINITY and NAN are used in binary expressions when -menable-no-nans or -menable-no-infs are used. If the use

[clang] [clang][dataflow] Add new `join` API and replace existing `merge` implementations. (PR #80361)

2024-02-02 Thread Yitzhak Mandelbaum via cfe-commits
@@ -105,6 +105,27 @@ class Environment { return true; } +/// Modifies `JoinedVal` to approximate both `Val1` and `Val2`. This should +/// obey the properties of a lattice join. +/// +/// `Env1` and `Env2` can be used to query child values and path con

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-02 Thread kadir çetinkaya via cfe-commits
@@ -508,24 +513,46 @@ static bool mayBeValidIdentifier(llvm::StringRef Ident) { !isAsciiIdentifierStart(Ident.front(), AllowDollar)) return false; for (char C : Ident) { +if (AllowColon && C == ':') + continue; if (llvm::isASCII(C) && !isAsciiIdentifie

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-02 Thread kadir çetinkaya via cfe-commits
@@ -538,11 +565,254 @@ std::optional checkName(const NamedDecl &RenameDecl, Conflict->getLocation().printToString(ASTCtx.getSourceManager())}; } } - if (Result) + if (Result) { InvalidNameMetric.record(1, toString(Result->K)); +return makeError(*Re

[clang] 1f4a5d8 - [clang][Interp] Fix broken test case again

2024-02-02 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2024-02-02T14:41:25+01:00 New Revision: 1f4a5d8a5b2ba62f3d9f65bdd4a65d6f5593d4cd URL: https://github.com/llvm/llvm-project/commit/1f4a5d8a5b2ba62f3d9f65bdd4a65d6f5593d4cd DIFF: https://github.com/llvm/llvm-project/commit/1f4a5d8a5b2ba62f3d9f65bdd4a65d6f5593d4cd.diff LO

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-02 Thread kadir çetinkaya via cfe-commits
@@ -681,12 +957,22 @@ renameOutsideFile(const NamedDecl &RenameDecl, llvm::StringRef MainFilePath, ExpBuffer.getError().message()); continue; } +std::string RenameIdentifier = RenameDecl.getNameAsString(); +std::optional Selector = std::nullopt; +

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-02 Thread kadir çetinkaya via cfe-commits
@@ -538,11 +565,254 @@ std::optional checkName(const NamedDecl &RenameDecl, Conflict->getLocation().printToString(ASTCtx.getSourceManager())}; } } - if (Result) + if (Result) { InvalidNameMetric.record(1, toString(Result->K)); +return makeError(*Re

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-02 Thread kadir çetinkaya via cfe-commits
@@ -543,6 +550,45 @@ std::optional checkName(const NamedDecl &RenameDecl, return Result; } +clangd::Range tokenRangeForLoc(ParsedAST &AST, SourceLocation TokLoc, + const SourceManager &SM, + const LangOptions &Lang

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-02 Thread kadir çetinkaya via cfe-commits
@@ -696,7 +982,7 @@ renameOutsideFile(const NamedDecl &RenameDecl, llvm::StringRef MainFilePath, FilePath); } auto RenameEdit = -buildRenameEdit(FilePath, AffectedFileCode, *RenameRanges, NewName); +buildRenameEdit(FilePath, AffectedF

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-02 Thread kadir çetinkaya via cfe-commits
@@ -538,11 +565,254 @@ std::optional checkName(const NamedDecl &RenameDecl, Conflict->getLocation().printToString(ASTCtx.getSourceManager())}; } } - if (Result) + if (Result) { InvalidNameMetric.record(1, toString(Result->K)); +return makeError(*Re

[clang] [clang][dataflow] Add new `join` API and replace existing `merge` implementations. (PR #80361)

2024-02-02 Thread Yitzhak Mandelbaum via cfe-commits
https://github.com/ymand updated https://github.com/llvm/llvm-project/pull/80361 >From 660d1afbda79416beb6f373e6252670f912a5181 Mon Sep 17 00:00:00 2001 From: Yitzhak Mandelbaum Date: Tue, 30 Jan 2024 16:02:21 + Subject: [PATCH 1/2] Add new `join` API and replace existing `merge` implementa

[clang] [clang-tools-extra] [clangd] Add support to rename Objective-C selectors (PR #78872)

2024-02-02 Thread kadir çetinkaya via cfe-commits
kadircet wrote: Hi @ahoppen ! Thanks a lot for the patch, but @DavidGoldman has also been working on this in https://github.com/llvm/llvm-project/pull/76466 and I'd rather follow up on that as we've already put in quite a lot of effort to get it into some decent shape and the functionality pro

[clang] [Clang][AArch64] Warn when calling streaming/non-streaming about vect… (PR #79842)

2024-02-02 Thread Sander de Smalen via cfe-commits
@@ -3717,6 +3717,30 @@ def err_sme_definition_using_za_in_non_sme_target : Error< "function using ZA state requires 'sme'">; def err_sme_definition_using_zt0_in_non_sme2_target : Error< "function using ZT0 state requires 'sme2'">; +def warn_sme_streaming_caller_pass_args_t

[clang] [Clang][AArch64] Warn when calling streaming/non-streaming about vect… (PR #79842)

2024-02-02 Thread Sander de Smalen via cfe-commits
@@ -7513,6 +7516,44 @@ void Sema::checkCall(NamedDecl *FDecl, const FunctionProtoType *Proto, } } +auto *CallerFD = dyn_cast(CurContext); +if (FD && CallerFD && Context.getTargetInfo().hasFeature("sme") && +!FD->getBuiltinID()) { + // If the cal

[clang] [Clang][AArch64] Warn when calling streaming/non-streaming about vect… (PR #79842)

2024-02-02 Thread Sander de Smalen via cfe-commits
@@ -1,5 +1,6 @@ -// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sme -fsyntax-only -verify %s -// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sme -fsyntax-only -verify=expected-cpp -x c++ %s +// RUN: %clang_cc1 -triple aarch64-none-linux-gn

[clang] [Clang][AArch64] Warn when calling streaming/non-streaming about vect… (PR #79842)

2024-02-02 Thread Sander de Smalen via cfe-commits
@@ -7513,6 +7516,44 @@ void Sema::checkCall(NamedDecl *FDecl, const FunctionProtoType *Proto, } } +auto *CallerFD = dyn_cast(CurContext); +if (FD && CallerFD && Context.getTargetInfo().hasFeature("sme") && +!FD->getBuiltinID()) { + // If the cal

[clang] [Clang][C++26] Implement Pack Indexing (P2662R3). (PR #72644)

2024-02-02 Thread Bevin Hansson via cfe-commits
bevin-hansson wrote: Ping. Just wondering if anyone has seen the above. @cor3ntin ? https://github.com/llvm/llvm-project/pull/72644 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libunwind] [llvm] [flang] [libcxxabi] [mlir] [openmp] [lldb] [libc] [clang] [lld] [compiler-rt] [libcxx] [clang-tools-extra] [C23] Implement N3018: The constexpr specifier for object definitions (PR

2024-02-02 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: Ping. https://github.com/llvm/llvm-project/pull/73099 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [coroutine] Suppress unreachable-code warning on coroutine statements. (PR #77454)

2024-02-02 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/77454 >From 43810d2b18e1e31c5f15dc58c847c83b3c34d982 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Tue, 9 Jan 2024 12:29:45 +0100 Subject: [PATCH 1/4] [coroutine] Suppress unreachable-code warning on coroutine statem

[clang] [coroutine] Suppress unreachable-code warning on coroutine statements. (PR #77454)

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

[clang] [coroutine] Suppress unreachable-code warning on coroutine statements. (PR #77454)

2024-02-02 Thread Haojian Wu via cfe-commits
@@ -12,6 +12,13 @@ struct task { std::suspend_always yield_value(int) { return {}; } task get_return_object(); void unhandled_exception(); + +struct Awaiter { + bool await_ready(); + void await_suspend(auto); + int await_resume(); +}; +aut

[llvm] [clang] [PowerPC] AIX TLS allow per function configuration of initial-exec or local-dynamic model (PR #79968)

2024-02-02 Thread Amy Kwan via cfe-commits
https://github.com/amy-kwan commented: Since this patch relies on the local-dynamic patch, I think the local-dynamic changes are already in here, right? Do we know if there is a way yet to make dependent pull requests, just so reviewing this patch may be a bit easier when the local-dynamic cha

[clang] [Clang][C++26] Implement Pack Indexing (P2662R3). (PR #72644)

2024-02-02 Thread via cfe-commits
cor3ntin wrote: @bevin-hansson Thanks for letting me know, I'll look into it https://github.com/llvm/llvm-project/pull/72644 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [coroutine] Suppress unreachable-code warning on coroutine statements. (PR #77454)

2024-02-02 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/77454 >From bcfc755d96379c59f79518ff7764f45e351302b8 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Tue, 9 Jan 2024 12:29:45 +0100 Subject: [PATCH 1/5] [coroutine] Suppress unreachable-code warning on coroutine statem

[clang] [clang][Diagnostics] Highlight code snippets (PR #66514)

2024-02-02 Thread via cfe-commits
bgra8 wrote: @AaronBallman > Do you see this crash with community clang and no downstream changes? Yes I can reproduce it with a vanila `clang` built from a git checkout at this version, but the problem is extremely sensitive to the input headers, their content and defines (`-Dbla`) in the

[clang] [AMDGPU] Diagnose unaligned atomic (PR #80322)

2024-02-02 Thread Yaxun Liu via cfe-commits
https://github.com/yxsamliu updated https://github.com/llvm/llvm-project/pull/80322 >From c2b559f5853a50a54958f2d5f2410a94ca0f722e Mon Sep 17 00:00:00 2001 From: "Yaxun (Sam) Liu" Date: Thu, 1 Feb 2024 13:44:03 -0500 Subject: [PATCH] [AMDGPU] Diagnose unaligned atomic for amdgpu AMDGPU does no

[clang] [libcxx] [Clang][libc++] Implement __is_nothrow_convertible and use it in libc++ (PR #80436)

2024-02-02 Thread Nikolas Klauser via cfe-commits
https://github.com/philnik777 created https://github.com/llvm/llvm-project/pull/80436 GCC 13 has implemented this builtin. >From dc3aafe0e3bd2e20121440efd8efa86263bd6b4b Mon Sep 17 00:00:00 2001 From: Nikolas Klauser Date: Fri, 2 Feb 2024 15:12:15 +0100 Subject: [PATCH] [Clang][libc++] Implem

[clang] [libcxx] [Clang][libc++] Implement __is_nothrow_convertible and use it in libc++ (PR #80436)

2024-02-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Nikolas Klauser (philnik777) Changes GCC 13 has implemented this builtin. --- Full diff: https://github.com/llvm/llvm-project/pull/80436.diff 5 Files Affected: - (modified) clang/docs/LanguageExtensions.rst (+1) - (modified) clang/inc

[clang] [libcxx] [Clang][libc++] Implement __is_nothrow_convertible and use it in libc++ (PR #80436)

2024-02-02 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff a1df10da59e8eb0c1d90df81bf9000d2f7869328 dc3aafe0e3bd2e20121440efd8efa86263bd6b4b --

[llvm] [clang] [RISCV] Add support for RISC-V Pointer Masking (PR #79929)

2024-02-02 Thread Michael Maitland via cfe-commits
michaelmaitland wrote: > Should you also update the riscv32-toolchain-extra.c and > riscv64-toolchain-extra.c? It is not immediately obvious to me what you had in mind for changing those tests. Could you please clarify? https://github.com/llvm/llvm-project/pull/79929 _

[clang] [coroutine] Suppress unreachable-code warning on coroutine statements. (PR #77454)

2024-02-02 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/77454 >From bcfc755d96379c59f79518ff7764f45e351302b8 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Tue, 9 Jan 2024 12:29:45 +0100 Subject: [PATCH 1/6] [coroutine] Suppress unreachable-code warning on coroutine statem

[clang] [clang][Diagnostics] Highlight code snippets (PR #66514)

2024-02-02 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > @AaronBallman > > > Do you see this crash with community clang and no downstream changes? > > Yes I can reproduce it with a vanila `clang` built from a git checkout at > this version, but the problem is extremely sensitive to the input headers, > their content and define

[libunwind] [llvm] [flang] [lldb] [libc] [clang] [lld] [compiler-rt] [libcxx] [clang-tools-extra] [X86] Use RORX over SHR imm (PR #77964)

2024-02-02 Thread Bryce Wilson via cfe-commits
https://github.com/Bryce-MW ready_for_review https://github.com/llvm/llvm-project/pull/77964 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang] [clang-tools-extra] Apply format only if --format is specified (PR #79466)

2024-02-02 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM! Let me know if you need me to land this on your behalf. https://github.com/llvm/llvm-project/pull/79466 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[clang] [clang] Add some CodeGen tests for CWG 1xx issues (PR #80338)

2024-02-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. This looks right to me. https://github.com/llvm/llvm-project/pull/80338 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[flang] [lldb] [libcxx] [libc] [llvm] [clang] [libunwind] [clang-tools-extra] [compiler-rt] [lld] [X86] Use RORX over SHR imm (PR #77964)

2024-02-02 Thread Bryce Wilson via cfe-commits
Bryce-MW wrote: I spent some time trying out something much more complex: starting at the user of flags that has other inputs (ADC, SBB, CMOVcc are the main ones), trace back the non-flags inputs to see if the node producing the flags inputs is along their paths then check the path from there

[clang] [Clang] Fix a crash when dumping a pack indexing type. (PR #80439)

2024-02-02 Thread via cfe-commits
https://github.com/cor3ntin created https://github.com/llvm/llvm-project/pull/80439 Fix a crash caused by incorrect assumptions Reported here https://github.com/llvm/llvm-project/pull/72644#discussion_r1469525524 >From 5999b51171d5ac2abcc10a222d6307399b949008 Mon Sep 17 00:00:00 2001 From: Cor

[clang] [Clang] Fix a crash when dumping a pack indexing type. (PR #80439)

2024-02-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: cor3ntin (cor3ntin) Changes Fix a crash caused by incorrect assumptions Reported here https://github.com/llvm/llvm-project/pull/72644#discussion_r1469525524 --- Full diff: https://github.com/llvm/llvm-project/pull/80439.diff 2 Files Aff

[clang] [Clang][Sema] Correctly look up primary template for variable template specializations (PR #80359)

2024-02-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane commented: Other than release note, this LGTM. https://github.com/llvm/llvm-project/pull/80359 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[flang] [lldb] [libcxx] [libc] [llvm] [clang] [libunwind] [clang-tools-extra] [compiler-rt] [lld] [X86] Use RORX over SHR imm (PR #77964)

2024-02-02 Thread Bryce Wilson via cfe-commits
https://github.com/Bryce-MW updated https://github.com/llvm/llvm-project/pull/77964 >From d4c312b9dbf447d0a53dda0e6cdc482bd908430b Mon Sep 17 00:00:00 2001 From: Bryce Wilson Date: Fri, 12 Jan 2024 16:01:32 -0600 Subject: [PATCH 01/16] [X86] Use RORX over SHR imm --- llvm/lib/Target/X86/X86In

[clang] [Clang][Sema] fix outline member function template with default align crash (PR #80288)

2024-02-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. https://github.com/llvm/llvm-project/pull/80288 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Diagnostics] Highlight code snippets (PR #66514)

2024-02-02 Thread via cfe-commits
eaeltsin wrote: Ok, the problem is in clang/lib/Frontend/TextDiagnostic.cpp:1352: ``` std::unique_ptr[]> SourceStyles = highlightLines(BufStart, Lines.first, Lines.second, PP, LangOpts, DiagOpts->ShowColors, FID, SM); ``` Looks like passing `BufStart` creates a Strin

[clang] [clang][Diagnostics] Highlight code snippets (PR #66514)

2024-02-02 Thread via cfe-commits
bgra8 wrote: Great find @eaeltsin ! Actually it is clear `BuffStart` and `BuffEnd` are derived from `BuffData`. We should just use `BuffData` in that call and all should be fine! https://github.com/llvm/llvm-project/pull/66514 ___ cfe-commits mailing

[libcxx] [clang] [Clang][libc++] Implement __is_nothrow_convertible and use it in libc++ (PR #80436)

2024-02-02 Thread via cfe-commits
https://github.com/cor3ntin edited https://github.com/llvm/llvm-project/pull/80436 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libcxx] [clang] [Clang][libc++] Implement __is_nothrow_convertible and use it in libc++ (PR #80436)

2024-02-02 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. Front end changes looks good. It would be nice to add a release note on the clang side https://github.com/llvm/llvm-project/pull/80436 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https

[libcxx] [clang] [Clang][libc++] Implement __is_nothrow_convertible and use it in libc++ (PR #80436)

2024-02-02 Thread via cfe-commits
@@ -567,6 +567,7 @@ TYPE_TRAIT_1(__is_unsigned, IsUnsigned, KEYCXX) // Embarcadero Binary Type Traits TYPE_TRAIT_2(__is_same, IsSame, KEYCXX) TYPE_TRAIT_2(__is_convertible, IsConvertible, KEYCXX) +TYPE_TRAIT_2(__is_nothrow_convertible, IsNothrowConvertible, KEYCXX)

[clang] [attributes][analyzer] Generalize [[clang::suppress]] to declarations. (PR #80371)

2024-02-02 Thread Erich Keane via cfe-commits
@@ -147,6 +147,20 @@ bool BugSuppression::isSuppressed(const PathDiagnosticLocation &Location, // done as well as perform a lot of work we'll never need. // Gladly, none of our on-by-default checkers currently need it. DeclWithIssue = ACtx.getTranslationUnitDecl();

[clang] [coroutine] Suppress unreachable-code warning on coroutine statements. (PR #77454)

2024-02-02 Thread Utkarsh Saxena via cfe-commits
@@ -12,6 +12,13 @@ struct task { std::suspend_always yield_value(int) { return {}; } task get_return_object(); void unhandled_exception(); + +struct Awaiter { + bool await_ready(); + void await_suspend(auto); + int await_resume(); +}; +aut

[libc] [clang] [flang] [clang-tools-extra] [llvm] [clang][Sema] Populate function template depth at AddTemplateOverloadCandidate (PR #80395)

2024-02-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. I don't see much value in a backport, particularly since this affects back to Clang 12. Else, LGTM. https://github.com/llvm/llvm-project/pull/80395 ___ cfe-commits mailing list cfe-commits@lis

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
https://github.com/alexfh created https://github.com/llvm/llvm-project/pull/80442 Implements the fix proposed by Evgeny Eltsin on https://github.com/llvm/llvm-project/pull/66514#issuecomment-1924039038. No test case provided, since the bug is extremely sensitive to the preprocessor state (heade

[libunwind] Use relative includes to allow source-based dependencies without `-I` (PR #80443)

2024-02-02 Thread Yuriy Chernyshov via cfe-commits
https://github.com/georgthegreat created https://github.com/llvm/llvm-project/pull/80443 We store libunwind code inside monorepo and would like to reduce the overall amount of `-I` flags. >From 3e8bbe318ebbd498a7457afee2192c47650b6dad Mon Sep 17 00:00:00 2001 From: Yuriy Chernyshov Date: Fri,

[libunwind] Use relative includes to allow source-based dependencies without `-I` (PR #80443)

2024-02-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-libunwind Author: Yuriy Chernyshov (georgthegreat) Changes We store libunwind code inside monorepo and would like to reduce the overall amount of `-I` flags. --- Full diff: https://github.com/llvm/llvm-project/pull/80443.diff 2 Files Affected: - (mo

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
https://github.com/alexfh ready_for_review https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (alexfh) Changes Implements the fix proposed by Evgeny Eltsin on https://github.com/llvm/llvm-project/pull/66514#issuecomment-1924039038. No test case provided, since the bug is extremely sensitive to the preprocessor state (headers,

[lldb] [openmp] [mlir] [flang] [clang] [libunwind] [lld] [compiler-rt] [clang-tools-extra] [libcxxabi] [llvm] [libc] [libcxx] [C23] Implement N3018: The constexpr specifier for object definitions (PR

2024-02-02 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon updated https://github.com/llvm/llvm-project/pull/73099 >From 1d70b7726e7d1f11622a6d5c8246b0737e024c8d Mon Sep 17 00:00:00 2001 From: "Podchishchaeva, Mariya" Date: Tue, 19 Sep 2023 08:37:18 -0700 Subject: [PATCH 01/10] [C23] Implement N3018: The constexpr specifier

[clang] [clang][Diagnostics] Highlight code snippets (PR #66514)

2024-02-02 Thread via cfe-commits
alexfh wrote: I've sent the fix proposed above by @eaeltsin with amendment by @bgra8 as https://github.com/llvm/llvm-project/pull/80442. If a different fix is desired, please fix quickly or revert until the fix is available. https://github.com/llvm/llvm-project/pull/66514 _

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane edited https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread Erich Keane via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[libunwind] Use relative includes to allow source-based dependencies without `-I` (PR #80443)

2024-02-02 Thread Louis Dionne via cfe-commits
https://github.com/ldionne requested changes to this pull request. We require that the right paths be setup with `-I` or `-isystem` as a general requirement of libc++, libc++abi and libunwind. This change seems brittle to me, especially if there's no test or no official guarantee being added an

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread Aaron Ballman via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM to get this unblocked, but I would love it if we could add a test case post-commit. https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list cfe-commits@lists.llvm.or

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] a986f5e - Fix clang crash when printing highlighted code in diagnostic (after #66514) (#80442)

2024-02-02 Thread via cfe-commits
Author: alexfh Date: 2024-02-02T16:31:45+01:00 New Revision: a986f5e218ab8a68097fcc1fd3234b8743839ef8 URL: https://github.com/llvm/llvm-project/commit/a986f5e218ab8a68097fcc1fd3234b8743839ef8 DIFF: https://github.com/llvm/llvm-project/commit/a986f5e218ab8a68097fcc1fd3234b8743839ef8.diff LOG: F

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
https://github.com/alexfh closed https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libcxx] [clang] [Clang][libc++] Implement __is_nothrow_convertible and use it in libc++ (PR #80436)

2024-02-02 Thread Nikolas Klauser via cfe-commits
@@ -567,6 +567,7 @@ TYPE_TRAIT_1(__is_unsigned, IsUnsigned, KEYCXX) // Embarcadero Binary Type Traits TYPE_TRAIT_2(__is_same, IsSame, KEYCXX) TYPE_TRAIT_2(__is_convertible, IsConvertible, KEYCXX) +TYPE_TRAIT_2(__is_nothrow_convertible, IsNothrowConvertible, KEYCXX)

[clang] 46b6756 - [AMDGPU] Diagnose unaligned atomic (#80322)

2024-02-02 Thread via cfe-commits
Author: Yaxun (Sam) Liu Date: 2024-02-02T10:41:47-05:00 New Revision: 46b6756255029f442165148115bad99d04057622 URL: https://github.com/llvm/llvm-project/commit/46b6756255029f442165148115bad99d04057622 DIFF: https://github.com/llvm/llvm-project/commit/46b6756255029f442165148115bad99d04057622.dif

[clang] [AMDGPU] Diagnose unaligned atomic (PR #80322)

2024-02-02 Thread Yaxun Liu via cfe-commits
https://github.com/yxsamliu closed https://github.com/llvm/llvm-project/pull/80322 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Add support for RISC-V Pointer Masking (PR #79929)

2024-02-02 Thread Jesse Huang via cfe-commits
jaidTw wrote: > > Should you also update the riscv32-toolchain-extra.c and > > riscv64-toolchain-extra.c? > > It is not immediately obvious to me what you had in mind for changing those > tests. Could you please clarify? I found I messed up the configuration so there were some test errors on

[clang] [llvm] [RISCV] Add support for RISC-V Pointer Masking (PR #79929)

2024-02-02 Thread Jesse Huang via cfe-commits
https://github.com/jaidTw approved this pull request. https://github.com/llvm/llvm-project/pull/79929 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] [llvm] [RISCV] Add support for RISC-V Pointer Masking (PR #79929)

2024-02-02 Thread Craig Topper via cfe-commits
@@ -797,6 +797,40 @@ def FeatureStdExtSvpbmt : SubtargetFeature<"svpbmt", "HasStdExtSvpbmt", "true", "'Svpbmt' (Page-Based Memory Types)">; +// Pointer Masking extensions + +// A supervisor-level extension that provides pointer masking for the next

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
https://github.com/alexfh edited https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
https://github.com/alexfh edited https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Diagnostics] Highlight code snippets (PR #66514)

2024-02-02 Thread via cfe-commits
alexfh wrote: I've added my findings with regard to this issue in https://github.com/llvm/llvm-project/pull/80442#discussion_r1476243065 Hope that helps understanding the problem. https://github.com/llvm/llvm-project/pull/66514 ___ cfe-commits mailin

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[libunwind] Use relative includes to allow source-based dependencies without `-I` (PR #80443)

2024-02-02 Thread Yuriy Chernyshov via cfe-commits
georgthegreat wrote: We have pretty large codebase and we use custom command-graph based build system (consider bazel as a well-known example of such buld system). The system uses module as a basic unit, modules might depend one each other, dependencies might affect dependant modules (but not

[clang] [analyzer] Teach analzer about ms __analyzer_assume(bool) and friends (PR #80456)

2024-02-02 Thread Balazs Benics via cfe-commits
https://github.com/steakhal created https://github.com/llvm/llvm-project/pull/80456 See the MS docs: https://learn.microsoft.com/en-us/windows-hardware/drivers/devtest/using-the--analysis-assume-function-to-suppress-false-defects https://learn.microsoft.com/en-us/cpp/code-quality/how-to-specif

[clang] [analyzer] Teach analzer about ms __analyzer_assume(bool) and friends (PR #80456)

2024-02-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 Author: Balazs Benics (steakhal) Changes See the MS docs: https://learn.microsoft.com/en-us/windows-hardware/drivers/devtest/using-the--analysis-assume-function-to-suppress-false-defects https://learn.microsoft.com/en-us/cpp/cod

[clang] [analyzer] Teach analzer about ms __analyzer_assume(bool) and friends (PR #80456)

2024-02-02 Thread Balazs Benics via cfe-commits
steakhal wrote: Let me know if this is correct @Xazax-hun. You probably have more insights on these APIs than me ;) https://github.com/llvm/llvm-project/pull/80456 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/

[libunwind] Use relative includes to allow source-based dependencies without `-I` (PR #80443)

2024-02-02 Thread Yuriy Chernyshov via cfe-commits
georgthegreat wrote: I understand the _this will definitely break in the future without proper testing_, but libunwind does not experience frequent changes, so this might be a working soluiton even without explicit testing. https://github.com/llvm/llvm-project/pull/80443 __

[clang] [clang][analyzer] Change default value of checker option in unix.StdCLibraryFunctions. (PR #80457)

2024-02-02 Thread Balázs Kéri via cfe-commits
https://github.com/balazske created https://github.com/llvm/llvm-project/pull/80457 Default value of checker option `ModelPOSIX` is changed to `true`. Documentation is updated. From 1f65abda712efce624c01ec99675c8261a8e6cea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bal=C3=A1zs=20K=C3=A9ri?= Dat

[clang] [clang][analyzer] Change default value of checker option in unix.StdCLibraryFunctions. (PR #80457)

2024-02-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 Author: Balázs Kéri (balazske) Changes Default value of checker option `ModelPOSIX` is changed to `true`. Documentation is updated. --- Full diff: https://github.com/llvm/llvm-project/pull/80457.diff 3 Files Affected: - (modi

[clang] [clang-tools-extra] [llvm] [CMake][PGO] Add option for using an external project to generate profile data (PR #78879)

2024-02-02 Thread Tom Stellard via cfe-commits
https://github.com/tstellar updated https://github.com/llvm/llvm-project/pull/78879 >From 0719f49ecc6dd69ae4698c3e84dbf175a1bf2ed3 Mon Sep 17 00:00:00 2001 From: Tom Stellard Date: Sun, 21 Jan 2024 00:25:47 + Subject: [PATCH 1/4] [CMake][PGO] Add libunwind to list of stage1 runtimes This f

[clang] [clang-tools-extra] [llvm] [CMake][PGO] Add option for using an external project to generate profile data (PR #78879)

2024-02-02 Thread Tom Stellard via cfe-commits
@@ -2,7 +2,7 @@ set(CMAKE_BUILD_TYPE RELEASE CACHE STRING "") set(CLANG_ENABLE_BOOTSTRAP ON CACHE BOOL "") set(LLVM_ENABLE_PROJECTS "clang;lld" CACHE STRING "") -set(LLVM_ENABLE_RUNTIMES "compiler-rt;libcxx;libcxxabi" CACHE STRING "") +set(LLVM_ENABLE_RUNTIMES "compiler-rt;lib

[clang] [llvm] [ASAN] For Asan instrumented global, emit two symbols, one with actual size and other with instrumented size. (PR #70166)

2024-02-02 Thread via cfe-commits
skc7 wrote: @hctim @MaskRay @vitalybuka #70166 and #68865 have been pending for review and approvals for few months now. All the feedback has been useful in improving the patch. Made the changes to patches as per feedback. Please review. https://github.com/llvm/llvm-project/pull/70166

[clang] [clang-tools-extra] [llvm] [CMake][PGO] Add option for using an external project to generate profile data (PR #78879)

2024-02-02 Thread Amir Ayupov via cfe-commits
https://github.com/aaupov approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/78879 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

<    1   2   3   4   >