[clang] [clang-format] Add support for `.cjs` as JavaScript file extension (PR #118188)

2024-12-02 Thread Jim B via cfe-commits
https://github.com/d3x0r updated https://github.com/llvm/llvm-project/pull/118188 >From 8ce527dc2cc7ac285f782648838664491abffc30 Mon Sep 17 00:00:00 2001 From: d3x0r Date: Sat, 30 Nov 2024 02:32:40 -0800 Subject: [PATCH 1/3] Add *.cjs handling for JavaScript Language. --- clang/lib/Format/For

[clang] [clang][bytecode][NFC] Reject invalid FromTypes in emitBuiltinBitcast (PR #118274)

2024-12-02 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/118274 instead of silently accepting them and failing later. >From 989573d4b67760096a40edfae42f853a55f893fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Mon, 2 Dec 2024 10:36:58 +0100 Subject: [

[clang] [clang][bytecode][NFC] Reject invalid FromTypes in emitBuiltinBitcast (PR #118274)

2024-12-02 Thread via cfe-commits
graphite-app[bot] wrote: ## Your org has enabled the Graphite merge queue for merging into main Add the label “FP Bundles” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. You must have a Graphite account and log in to Graphite in order to use the

[clang] [clang][bytecode][NFC] Reject invalid FromTypes in emitBuiltinBitcast (PR #118274)

2024-12-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes instead of silently accepting them and failing later. --- Full diff: https://github.com/llvm/llvm-project/pull/118274.diff 1 Files Affected: - (modified) clang/lib/AST/ByteCode/Compiler.cpp (+2) ```

[clang] [AArch64][Clang] Define __ARM_NEON_SVE_BRIDGE unconditionally (PR #118272)

2024-12-02 Thread via cfe-commits
graphite-app[bot] wrote: ## Your org has enabled the Graphite merge queue for merging into main Add the label “FP Bundles” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. You must have a Graphite account and log in to Graphite in order to use the

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116785)

2024-12-02 Thread Timm Baeder via cfe-commits
@@ -10488,7 +10488,14 @@ static bool AnalyzeBitFieldAssignment(Sema &S, FieldDecl *Bitfield, Expr *Init, // The RHS is not constant. If the RHS has an enum type, make sure the // bitfield is wide enough to hold all the values of the enum without // truncation. -

[clang] [clang][bytecode] Add simple __builtin_memcpy implementation (PR #118278)

2024-12-02 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/118278 Not handling all the special- and error cases yet. Just making sure the bitcast code can be used for this as well. >From 9313b6992afc5e49b0c863b1ad0513b1d75bfc83 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=2

[clang] [clang][bytecode] Add simple __builtin_memcpy implementation (PR #118278)

2024-12-02 Thread via cfe-commits
graphite-app[bot] wrote: ## Your org has enabled the Graphite merge queue for merging into main Add the label “FP Bundles” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. You must have a Graphite account and log in to Graphite in order to use the

[clang] [clang][bytecode] Add simple __builtin_memcpy implementation (PR #118278)

2024-12-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes Not handling all the special- and error cases yet. Just making sure the bitcast code can be used for this as well. --- Full diff: https://github.com/llvm/llvm-project/pull/118278.diff 2 Files Affected: -

[clang] [Clang][AArch64]Refactor typespec handling in SveEmitter.cpp (PR #117717)

2024-12-02 Thread via cfe-commits
@@ -50,20 +50,30 @@ using TypeSpec = std::string; namespace { class SVEType { - bool Float, Signed, Immediate, Void, Constant, Pointer, BFloat, MFloat; - bool DefaultType, IsScalable, Predicate, PredicatePattern, PrefetchOp, - Svcount; + + enum TypeKind { +Void, +

[clang] [clang] Warn [[clang::lifetimebound]] misusages on types (PR #118281)

2024-12-02 Thread Maksim Ivanov via cfe-commits
https://github.com/emaxx-google edited https://github.com/llvm/llvm-project/pull/118281 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Warn [[clang::lifetimebound]] misusages on types (PR #118281)

2024-12-02 Thread Maksim Ivanov via cfe-commits
https://github.com/emaxx-google edited https://github.com/llvm/llvm-project/pull/118281 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 0611fdd - [clang][bytecode] Add simple __builtin_memcpy implementation (#118278)

2024-12-02 Thread via cfe-commits
Author: Timm Baeder Date: 2024-12-02T13:11:22+01:00 New Revision: 0611fdd32046c41647a7719252166033f7bce2f2 URL: https://github.com/llvm/llvm-project/commit/0611fdd32046c41647a7719252166033f7bce2f2 DIFF: https://github.com/llvm/llvm-project/commit/0611fdd32046c41647a7719252166033f7bce2f2.diff L

[clang] [clang] Warn [[clang::lifetimebound]] misusages on types (PR #118281)

2024-12-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Maksim Ivanov (emaxx-google) Changes Emit the "cannot be applied to types" warning instead of silently ignoring the attribute when it's attempted to be used on a type (instead of a function argument or the function definition). Before th

[clang] [clang][bytecode] Add simple __builtin_memcpy implementation (PR #118278)

2024-12-02 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr closed https://github.com/llvm/llvm-project/pull/118278 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Warn [[clang::lifetimebound]] misusages on types (PR #118281)

2024-12-02 Thread Maksim Ivanov via cfe-commits
https://github.com/emaxx-google ready_for_review https://github.com/llvm/llvm-project/pull/118281 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][bytecode] Implement __builtin_reduce_mul (PR #118287)

2024-12-02 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/118287 None >From 4c5d7a068871216dfa57f03412c2e47b4e58f865 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Mon, 2 Dec 2024 13:11:04 +0100 Subject: [PATCH] [clang][bytecode] Implement __builtin_redu

[clang] [clang][bytecode] Implement __builtin_reduce_mul (PR #118287)

2024-12-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/118287.diff 3 Files Affected: - (modified) clang/lib/AST/ByteCode/Integral.h (+3-1) - (modified) clang/lib/AST/ByteCode/InterpBuiltin.cpp (+32-21)

[clang] [clang][bytecode] Implement __builtin_reduce_mul (PR #118287)

2024-12-02 Thread via cfe-commits
graphite-app[bot] wrote: ## Your org has enabled the Graphite merge queue for merging into main Add the label “FP Bundles” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. You must have a Graphite account and log in to Graphite in order to use the

[clang] [clang] Implement __attribute__((format_matches)) (PR #116708)

2024-12-02 Thread via cfe-commits
@@ -292,7 +292,7 @@ class ArgType { }; private: - const Kind K; + Kind K; apple-fcloutier wrote: The `const` field was the only thing that prevented `ArgType` from getting a copy constructor and assignment operators. https://github.com/llvm/llvm-project

[clang] [flang] [clang][driver] Special care for -l flags in config files (PR #117573)

2024-12-02 Thread Paul Osmialowski via cfe-commits
@@ -0,0 +1 @@ +-ffast-math -Wl,--as-needed | -lm -Wl,-Bstatic -lhappy -Wl,-Bdynamic pawosm-arm wrote: mid-air collision. yeah, either '$' or '@' would do :) https://github.com/llvm/llvm-project/pull/117573 ___ cfe-com

[clang] [Darwin][Driver][clang] Prioritise `-isysroot` over `--sysroot` consistently (PR #115993)

2024-12-02 Thread James Y Knight via cfe-commits
jyknight wrote: Hm, I had a thought which might meet the needs here, and not add additional confusion: we could have the Darwin SDKROOT environment variable override both `-isysroot` and `--sysroot`. Would that help the original issue? https://github.com/llvm/llvm-project/pull/115993 _

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik commented: This looks good but I want agreement on the diagnostic message. https://github.com/llvm/llvm-project/pull/118031 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinf

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane commented: Also forgot: this needs a release note. https://github.com/llvm/llvm-project/pull/118031 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

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

[clang] [clang][ARM] disable frame pointers by default for bare metal ARM targets (PR #117140)

2024-12-02 Thread Nick Desaulniers via cfe-commits
https://github.com/nickdesaulniers approved this pull request. https://github.com/llvm/llvm-project/pull/117140 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Warn [[clang::lifetimebound]] misusages on types (PR #118281)

2024-12-02 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/118281 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Amr Hesham via cfe-commits
@@ -10264,6 +10264,10 @@ def warn_depr_array_comparison : Warning< "to compare array addresses, use unary '+' to decay operands to pointers">, InGroup; +def warn_array_comparison : Warning< + "comparison between two arrays compare their addresses and will be deprecated i

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper edited https://github.com/llvm/llvm-project/pull/118031 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper edited https://github.com/llvm/llvm-project/pull/118031 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer][Z3] Restore the original timeout of 15s (PR #118291)

2024-12-02 Thread Kristóf Umann via cfe-commits
https://github.com/Szelethus created https://github.com/llvm/llvm-project/pull/118291 Discussion here: https://discourse.llvm.org/t/analyzer-rfc-taming-z3-query-times/79520/15?u=szelethus The original patch, #97298 introduced new timeouts backed by thorough testing and measurements to keep the

[clang] [flang] [clang][driver] Special care for -l flags in config files (PR #117573)

2024-12-02 Thread Paul Osmialowski via cfe-commits
@@ -0,0 +1 @@ +-ffast-math -Wl,--as-needed | -lm -Wl,-Bstatic -lhappy -Wl,-Bdynamic pawosm-arm wrote: Seems neither '$' nor '@' is the best choice, '$' looks like shell variable expansion, so I'll do `^`, e.g., '^-Wl,-Bstatic`. https://github.com/llvm/llvm-pro

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Amr Hesham via cfe-commits
@@ -10264,6 +10264,11 @@ def warn_depr_array_comparison : Warning< "to compare array addresses, use unary '+' to decay operands to pointers">, InGroup; +def warn_array_comparison : Warning< + "comparison between two arrays; " AmrDeveloper wrote: I think

[clang] [clang][bytecode] Implement __builtin_elementwise_popcount (PR #118307)

2024-12-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/118307.diff 2 Files Affected: - (modified) clang/lib/AST/ByteCode/InterpBuiltin.cpp (+40) - (modified) clang/test/AST/ByteCode/builtin-functions.c

[clang] [Darwin][Driver][clang] Prioritise `-isysroot` over `--sysroot` consistently (PR #115993)

2024-12-02 Thread Steven Wu via cfe-commits
cachemeifyoucan wrote: I think the correct solution for Homebrew is to never use `--sysroot` and switch to `-isysroot` since the former is almost never used on Darwin platforms. https://github.com/llvm/llvm-project/pull/115993 ___ cfe-commits mailing

[clang] [clang][bytecode] Check __builtin_memcpy for null pointers (PR #118313)

2024-12-02 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr updated https://github.com/llvm/llvm-project/pull/118313 >From 577c2b7622d81fba7fe39607e48907d6f47ef9eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Mon, 2 Dec 2024 16:47:50 +0100 Subject: [PATCH] [clang][bytecode] Check __builtin_memcpy for nul

[clang] [clang] Document the return value of __builtin_COLUMN (PR #118360)

2024-12-02 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you, it

[clang] [clang] Document the return value of __builtin_COLUMN (PR #118360)

2024-12-02 Thread via cfe-commits
GeorgeKA wrote: @frederick-vs-ja, were you looking for specific wording for source_location()::current().column(), or does this cover it? https://github.com/llvm/llvm-project/pull/118360 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://

[clang] [llvm] [AArch64] Implement intrinsics for SME FP8 FMOPA (PR #118115)

2024-12-02 Thread via cfe-commits
https://github.com/SpencerAbson updated https://github.com/llvm/llvm-project/pull/118115 >From a92b7a9faba65931918e4c3d6763896f1e1eda6b Mon Sep 17 00:00:00 2001 From: Spencer Abson Date: Mon, 25 Nov 2024 21:47:20 + Subject: [PATCH] [AArch64] Implement intrinsics for SME FP8 FMOPA --- clan

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/118031 >From 9451a1e4f5db18d579b5f7eb206482708c9adc70 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Tue, 26 Nov 2024 22:28:16 +0100 Subject: [PATCH 01/11] Add support for '-Warray-compare' compiler flag ---

[clang] [llvm] [Loads] Check context instruction for context-sensitive derefability (PR #109277)

2024-12-02 Thread Danila Malyutin via cfe-commits
danilaml wrote: @nikic By the way, are there plans to support allocation functions other than alloca in this check? I don't see currently any llvm passes assigning dereferenceable(_or_null) attribute to something like `malloc(42)` , but I don't see why not and in that case this should also be

[clang] [llvm] [HLSL] Implement RWBuffer::operator[] via __builtin_hlsl_resource_getpointer (PR #117017)

2024-12-02 Thread Chris B via cfe-commits
https://github.com/llvm-beanz approved this pull request. https://github.com/llvm/llvm-project/pull/117017 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV][VLS] Support RISCV VLS calling convention (PR #100346)

2024-12-02 Thread Kito Cheng via cfe-commits
@@ -32,3 +36,39 @@ vint32m1_t test_no_vector_cc_attr(vint32m1_t input, int32_t *base, size_t vl) { __riscv_vse32_v_i32m1(base, val, vl); return ret; } + +// CHECK-LLVM: define dso_local void @test_vls_no_cc(i128 noundef %arg.coerce) +// CHECK-LLVM-ABI-VLEN: define dso_loca

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/118031 >From 9451a1e4f5db18d579b5f7eb206482708c9adc70 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Tue, 26 Nov 2024 22:28:16 +0100 Subject: [PATCH 01/10] Add support for '-Warray-compare' compiler flag ---

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/118031 >From 9451a1e4f5db18d579b5f7eb206482708c9adc70 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Tue, 26 Nov 2024 22:28:16 +0100 Subject: [PATCH 1/8] Add support for '-Warray-compare' compiler flag --- cl

[clang] [Clang] ensure mangled names are valid identifiers before being suggested in ifunc/alias attributes notes (PR #118170)

2024-12-02 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk closed https://github.com/llvm/llvm-project/pull/118170 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2024-12-02 Thread Devon Loehr via cfe-commits
https://github.com/DKLoehr updated https://github.com/llvm/llvm-project/pull/117622 >From d944b2fde573a4fb352400ce3425121265b02685 Mon Sep 17 00:00:00 2001 From: Devon Loehr Date: Thu, 21 Nov 2024 19:29:00 + Subject: [PATCH] Warn when unique objects might be duplicated in shared libraries

[clang] [clang] Document the return value of __builtin_COLUMN (PR #118360)

2024-12-02 Thread via cfe-commits
GeorgeKA wrote: I don't have write permission, so requesting review via comment. Please and thanks: @cor3ntin @frederick-vs-ja https://github.com/llvm/llvm-project/pull/118360 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Shafik Yaghmour via cfe-commits
@@ -15,15 +15,15 @@ void test(const char *d) { if (NULL == "/") return; if ("/" != DELIM) // expected-warning {{result of comparison against a string literal is unspecified (use an explicit string comparison function instead)}} -return; +return; // cxx

[clang] [Clang] Permit noescape on non-pointer types (PR #117344)

2024-12-02 Thread Gábor Horváth via cfe-commits
Xazax-hun wrote: > I want to see something that shows that the attribute is actually DOING > something on non-pointer types. I added a test to make sure the attribute is actually applied to the AST. Admittedly, there is not a lot that this can be used for as of now (other than documenting the

[clang] [clang] Document the return value of __builtin_COLUMN (PR #118360)

2024-12-02 Thread via cfe-commits
https://github.com/GeorgeKA created https://github.com/llvm/llvm-project/pull/118360 PR for issue #78657 Updated clang/docs/LanguageExtensions.rst to detail the return value of __builtin_COLUMN for this implementation. -- Fyi, this is my first contribution, so please bear with me. There alr

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Shafik Yaghmour via cfe-commits
@@ -15,15 +15,15 @@ void test(const char *d) { if (NULL == "/") return; if ("/" != DELIM) // expected-warning {{result of comparison against a string literal is unspecified (use an explicit string comparison function instead)}} -return; +return; // cxx

[clang] [flang] [clang][driver] Special care for -l flags in config files (PR #117573)

2024-12-02 Thread Paul Osmialowski via cfe-commits
@@ -0,0 +1 @@ +-ffast-math -Wl,--as-needed | -lm -Wl,-Bstatic -lhappy -Wl,-Bdynamic pawosm-arm wrote: Done. https://github.com/llvm/llvm-project/pull/117573 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https

[clang] b343f3f - [analyzer][NFC] Cleanup BranchNodeBuilder (#117898)

2024-12-02 Thread via cfe-commits
Author: Donát Nagy Date: 2024-12-02T16:38:07+01:00 New Revision: b343f3f3faf5b732cc19c9c51d392389677477ce URL: https://github.com/llvm/llvm-project/commit/b343f3f3faf5b732cc19c9c51d392389677477ce DIFF: https://github.com/llvm/llvm-project/commit/b343f3f3faf5b732cc19c9c51d392389677477ce.diff LO

[libclc] [libcxx] [llvm] [openmp] [polly] [llvm] Move sub-project lead maintainers into their own Maintainers.md files (PR #118309)

2024-12-02 Thread David Spickett via cfe-commits
https://github.com/DavidSpickett created https://github.com/llvm/llvm-project/pull/118309 This adds Maintainers.md files to the sub-projects mentioned here, so that someone going directly to that sub-project will find them more easily. Recently I needed to find a libclc maintainer and I had no

[clang] [clang][bytecode] Implement __builtin_reduce_or (PR #118292)

2024-12-02 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr closed https://github.com/llvm/llvm-project/pull/118292 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libclc] [libcxx] [llvm] [openmp] [polly] [llvm] Move sub-project lead maintainers into their own Maintainers.md files (PR #118309)

2024-12-02 Thread Nikita Popov via cfe-commits
@@ -434,29 +433,17 @@ Others only have a lead maintainer listed here. [Flang maintainers](https://github.com/llvm/llvm-project/blob/main/flang/Maintainers.txt) -[LLD maintainers](https://github.com/llvm/llvm-project/blob/main/lld/CODE_OWNERS.TXT) - -[LLDB maintainers](http

[clang] [compiler-rt] [libcxx] [libcxxabi] [llvm] [libc++] Replace LIBCXX_ENABLE_STATIC_ABI_LIBRARY & friends by a new LIBCXX_CXX_ABI choice (PR #112978)

2024-12-02 Thread Louis Dionne via cfe-commits
https://github.com/ldionne updated https://github.com/llvm/llvm-project/pull/112978 >From fbb6db25d2d52b19486c395d0855e7af4b8812a3 Mon Sep 17 00:00:00 2001 From: Louis Dionne Date: Fri, 13 May 2022 09:26:01 -0400 Subject: [PATCH 1/6] [libc++] Replace LIBCXX_ENABLE_STATIC_ABI_LIBRARY & friends

[clang] [llvm] [SPIR-V] Fixup storage class for global private (PR #116636)

2024-12-02 Thread Steven Perron via cfe-commits
Nathan =?utf-8?q?Gauër?= Message-ID: In-Reply-To: @@ -0,0 +1,17 @@ +; RUN: llc -verify-machineinstrs -O0 -mtriple=spirv64-unknown-unknown %s -o - | FileCheck %s +; RUN: %if spirv-tools %{ llc -O0 -mtriple=spirv64-unknown-unknown %s -o - -filetype=obj | spirv-val %} + +@PrivIn

[clang] [Clang][AArch64]Refactor typespec handling in SveEmitter.cpp (PR #117717)

2024-12-02 Thread Sander de Smalen via cfe-commits
https://github.com/sdesmalen-arm approved this pull request. Thanks, LGTM! https://github.com/llvm/llvm-project/pull/117717 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][bytecode] Implement __builtin_reduce_xor (PR #118299)

2024-12-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/118299.diff 2 Files Affected: - (modified) clang/lib/AST/ByteCode/InterpBuiltin.cpp (+3) - (modified) clang/test/AST/ByteCode/builtin-functions.cp

[clang] [analyzer][NFC] Cleanup BranchNodeBuilder (PR #117898)

2024-12-02 Thread Donát Nagy via cfe-commits
NagyDonat wrote: I tested this commit on several open source projects, and as there were no changes in the results, I'm merging this PR now. https://github.com/llvm/llvm-project/pull/117898 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https

[clang] [llvm] AMDGPU: Allow f16/bf16 for DS_READ_TR16_B64 gfx950 builtins (PR #118297)

2024-12-02 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm edited https://github.com/llvm/llvm-project/pull/118297 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [SPIR-V] Fixup storage class for global private (PR #116636)

2024-12-02 Thread Steven Perron via cfe-commits
Nathan =?utf-8?q?Gau=C3=ABr?= Message-ID: In-Reply-To: https://github.com/s-perron approved this pull request. https://github.com/llvm/llvm-project/pull/116636 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[clang] [analyzer][NFC] Cleanup BranchNodeBuilder (PR #117898)

2024-12-02 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat closed https://github.com/llvm/llvm-project/pull/117898 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 1f2aeef - [OpenACC] Enable copy/create clauses for combined constructs

2024-12-02 Thread via cfe-commits
Author: erichkeane Date: 2024-12-02T11:15:35-08:00 New Revision: 1f2aeef97bf229821b1b254d7ce4e3d1c7f8683f URL: https://github.com/llvm/llvm-project/commit/1f2aeef97bf229821b1b254d7ce4e3d1c7f8683f DIFF: https://github.com/llvm/llvm-project/commit/1f2aeef97bf229821b1b254d7ce4e3d1c7f8683f.diff LO

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread via cfe-commits
https://github.com/cor3ntin commented: should we apply the c++26 changes at the same time? https://github.com/llvm/llvm-project/pull/118031 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

[libclc] [libcxx] [llvm] [openmp] [polly] [llvm] Move sub-project lead maintainers into their own Maintainers.md files (PR #118309)

2024-12-02 Thread Nikita Popov via cfe-commits
nikic wrote: For openmp I'm not really sure, maybe @jdoerfert or @jpeyton52 can advise. https://github.com/llvm/llvm-project/pull/118309 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] AMDGPU: Allow f16/bf16 for DS_READ_TR16_B64 gfx950 builtins (PR #118297)

2024-12-02 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm updated https://github.com/llvm/llvm-project/pull/118297 >From f82bf3450e65ffd366037f6edcc803d7ec053f22 Mon Sep 17 00:00:00 2001 From: Sirish Pande Date: Thu, 18 Jul 2024 14:27:57 -0500 Subject: [PATCH] AMDGPU: Allow f16/bf16 for DS_READ_TR16_B64 gfx950 builtins Co-au

[clang] [clang] Warn [[clang::lifetimebound]] misusages on types (PR #118281)

2024-12-02 Thread Ilya Biryukov via cfe-commits
@@ -9,11 +9,20 @@ namespace usage_invalid { ~A() [[clang::lifetimebound]]; // expected-error {{cannot be applied to a destructor}} static int *static_class_member() [[clang::lifetimebound]]; // expected-error {{static member function has no implicit object parameter}}

[clang-tools-extra] [NFC] Fix uninitialized scalar field in constructor. (PR #118324)

2024-12-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangd Author: Zahira Ammarguellat (zahiraam) Changes Non-static class field is not initialized in constructor. --- Full diff: https://github.com/llvm/llvm-project/pull/118324.diff 2 Files Affected: - (modified) clang-tools-extra/clangd/index/MemInde

[clang-tools-extra] [clang-tidy] fix cppcoreguidelines-narrowing-conversions false positives when narrowing integer to signed integer in C++20 (PR #116591)

2024-12-02 Thread Congcong Cai via cfe-commits
HerrCai0907 wrote: IMO, we should move this check to bugprone and provide 3 level's error. 1. really implement defined behavior -> The above example about float to unsigned 2. standard implement defined behavior but at least gcc and clang in each target has same behavior 3. most strictly check

[clang] [Clang] Add '-Warray-compare' flag for C++ below version 20 (PR #118031)

2024-12-02 Thread Erich Keane via cfe-commits
@@ -10264,6 +10264,10 @@ def warn_depr_array_comparison : Warning< "to compare array addresses, use unary '+' to decay operands to pointers">, InGroup; +def warn_array_comparison : Warning< + "comparison between two arrays compare their addresses and will be deprecated i

[clang-tools-extra] [NFC] Fix uninitialized scalar field in constructor. (PR #118324)

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

[clang] [ASTMatcher] Fix redundant macro expansion checks in getExpansionLocOfMacro (PR #117143)

2024-12-02 Thread via cfe-commits
@@ -36,6 +36,7 @@ #include #include #include +#include mandymimi wrote: very good sugguestion! updated in f3f08877f08c https://github.com/llvm/llvm-project/pull/117143 ___ cfe-commits mailing list cfe-commits@li

[clang] [clang] Warn [[clang::lifetimebound]] misusages on types (PR #118281)

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

[clang] [clang] Warn [[clang::lifetimebound]] misusages on types (PR #118281)

2024-12-02 Thread Haojian Wu via cfe-commits
@@ -8612,7 +8612,11 @@ static void HandleLifetimeBoundAttr(TypeProcessingState &State, CurType = State.getAttributedType( createSimpleAttr(State.getSema().Context, Attr), CurType, CurType); +return; } + State.getSema().Diag(Attr.getLoc(), diag::err_

[clang] [clang] Warn [[clang::lifetimebound]] misusages on types (PR #118281)

2024-12-02 Thread Haojian Wu via cfe-commits
@@ -9,11 +9,20 @@ namespace usage_invalid { ~A() [[clang::lifetimebound]]; // expected-error {{cannot be applied to a destructor}} static int *static_class_member() [[clang::lifetimebound]]; // expected-error {{static member function has no implicit object parameter}}

[clang] [llvm] AMDGPU: Allow f16/bf16 for DS_READ_TR16_B64 gfx950 builtins (PR #118297)

2024-12-02 Thread Shilei Tian via cfe-commits
https://github.com/shiltian approved this pull request. https://github.com/llvm/llvm-project/pull/118297 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] AMDGPU: Allow f16/bf16 for DS_READ_TR16_B64 gfx950 builtins (PR #118297)

2024-12-02 Thread Shilei Tian via cfe-commits
https://github.com/shiltian edited https://github.com/llvm/llvm-project/pull/118297 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Warn [[clang::lifetimebound]] misusages on types (PR #118281)

2024-12-02 Thread Haojian Wu via cfe-commits
https://github.com/hokein commented: Can you add a note in llvm-project/clang/docs/ReleaseNotes.rst? https://github.com/llvm/llvm-project/pull/118281 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinf

[clang] [llvm] [Loads] Check context instruction for context-sensitive derefability (PR #109277)

2024-12-02 Thread Danila Malyutin via cfe-commits
danilaml wrote: @nikic ah, yeah. I remember the issue with dereferenceable w.r.t. free discussion. Guess will have to roll something for allocations that don't have this problem. https://github.com/llvm/llvm-project/pull/109277 ___ cfe-commits mailin

[clang-tools-extra] [clang-tidy] Create a check for signed and unsigned integers comparison (PR #113144)

2024-12-02 Thread Carlos Galvez via cfe-commits
carlosgalvezp wrote: Nit tip: the additional `fixup!` in the commit message for each additional commit is rather distracting, it would be best if each commit were be named after the changes it introduces w.r.t. the previous commit. https://github.com/llvm/llvm-project/pull/113144

[clang] Pack relocations for Android API >= 28 (PR #117624)

2024-12-02 Thread via cfe-commits
@@ -256,6 +256,14 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args) ExtraOpts.push_back("-z"); ExtraOpts.push_back("max-page-size=16384"); } +if (Triple.isAndroidVersionLT(29)) { enh-google wrote: this says

[clang-tools-extra] [clang-tidy][docs] improve documentation on cppcoreguidelines-narrowing-conversions (#111510) (PR #118209)

2024-12-02 Thread via cfe-commits
@@ -27,6 +27,29 @@ This check will flag: - All applications of binary operators with a narrowing conversions. For example: ``int i; i+= 0.1;``. +Note that arithmetic with integer types may perform implicit conversions if the used integer types are smaller than ``int``. --

[clang] [flang] [flang][Driver] Support -print-supported-extensions (PR #117402)

2024-12-02 Thread Andrzej Warzyński via cfe-commits
@@ -0,0 +1,10 @@ +! Test that --print-supported-extensions errors on unsupported architectures. + +! REQUIRES: x86-registered-target + +! RUN: not %flang --target=x86_64-linux-gnu --print-supported-extensions \ +! RUN: 2>&1 | FileCheck %s banach-space wrote: Th

[clang-tools-extra] [clang-tidy][docs] improve documentation on cppcoreguidelines-narrowing-conversions (#111510) (PR #118209)

2024-12-02 Thread via cfe-commits
@@ -27,6 +27,39 @@ This check will flag: - All applications of binary operators with a narrowing conversions. For example: ``int i; i+= 0.1;``. +Arithmetic with smaller integer types than ``int`` trigger implicit conversions, +as explained under `"Integral Promotion" on c

[clang-tools-extra] [clang-tidy][docs] improve documentation on cppcoreguidelines-narrowing-conversions (#111510) (PR #118209)

2024-12-02 Thread via cfe-commits
https://github.com/EugeneZelenko deleted https://github.com/llvm/llvm-project/pull/118209 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] da5f330 - [clang-tidy] Adjust size-empty doc because C++11 size() is constant-time (#117629)

2024-12-02 Thread via cfe-commits
Author: Niels Dekker Date: 2024-12-03T06:45:06+08:00 New Revision: da5f330e84d74aeacdbb801c46282b9eebec6793 URL: https://github.com/llvm/llvm-project/commit/da5f330e84d74aeacdbb801c46282b9eebec6793 DIFF: https://github.com/llvm/llvm-project/commit/da5f330e84d74aeacdbb801c46282b9eebec6793.diff

[clang-tools-extra] [clang-tidy] Adjust size-empty doc because C++11 size() is constant-time (PR #117629)

2024-12-02 Thread via cfe-commits
github-actions[bot] wrote: @N-Dekker Congratulations on having your first Pull Request (PR) merged into the LLVM Project! Your changes will be combined with recent changes from other authors, then tested by our [build bots](https://lab.llvm.org/buildbot/). If there is a problem with a build

[clang-tools-extra] [clang-tidy] Adjust size-empty doc because C++11 size() is constant-time (PR #117629)

2024-12-02 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 closed https://github.com/llvm/llvm-project/pull/117629 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Pack relocations for Android API >= 28 (PR #117624)

2024-12-02 Thread via cfe-commits
@@ -256,6 +256,14 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args) ExtraOpts.push_back("-z"); ExtraOpts.push_back("max-page-size=16384"); } +if (Triple.isAndroidVersionLT(29)) { + // https://github.com/android/ndk/issue

[libclc] [libcxx] [llvm] [openmp] [polly] [llvm] Move sub-project lead maintainers into their own Maintainers.md files (PR #118309)

2024-12-02 Thread David Spickett via cfe-commits
https://github.com/DavidSpickett updated https://github.com/llvm/llvm-project/pull/118309 >From 9d279bcb1174e80e24ddac8755962cb65e20be91 Mon Sep 17 00:00:00 2001 From: David Spickett Date: Mon, 2 Dec 2024 15:22:50 + Subject: [PATCH 1/2] [llvm] Move sub-project lead maintainers into their ow

[clang-tools-extra] [clang-tidy] ignore `[[clang::lifetimebound]]` param in return-const-ref-from-parameter (PR #118315)

2024-12-02 Thread Julian Schmidt via cfe-commits
@@ -38,3 +29,21 @@ Example const S& s = fn(S{1}); s.v; // use after free + + +This issue can be resolved by declaring an overload of the problematic function +where the ``const &`` parameter is instead declared as ``&&``. The developer has +to ensure that the implementati

[clang-tools-extra] [clang-tidy] ignore `[[clang::lifetimebound]]` param in return-const-ref-from-parameter (PR #118315)

2024-12-02 Thread Julian Schmidt via cfe-commits
@@ -38,3 +29,21 @@ Example const S& s = fn(S{1}); s.v; // use after free + + +This issue can be resolved by declaring an overload of the problematic function +where the ``const &`` parameter is instead declared as ``&&``. The developer has +to ensure that the implementati

[clang-tools-extra] [clang-tidy] ignore `[[clang::lifetimebound]]` param in return-const-ref-from-parameter (PR #118315)

2024-12-02 Thread Julian Schmidt via cfe-commits
https://github.com/5chmidti edited https://github.com/llvm/llvm-project/pull/118315 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] ignore `[[clang::lifetimebound]]` param in return-const-ref-from-parameter (PR #118315)

2024-12-02 Thread Julian Schmidt via cfe-commits
@@ -184,7 +184,8 @@ Changes in existing checks ` check to diagnose potential dangling references when returning a ``const &`` parameter by using the conditional operator ``cond ? var1 : var2`` and no longer giving - false positives for functions which contain lambda. +

[clang-tools-extra] [clang-tidy] ignore `[[clang::lifetimebound]]` param in return-const-ref-from-parameter (PR #118315)

2024-12-02 Thread Julian Schmidt via cfe-commits
https://github.com/5chmidti approved this pull request. LGTM, just small nits. https://github.com/llvm/llvm-project/pull/118315 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] ignore `[[clang::lifetimebound]]` param in return-const-ref-from-parameter (PR #118315)

2024-12-02 Thread Julian Schmidt via cfe-commits
@@ -15,14 +16,23 @@ using namespace clang::ast_matchers; namespace clang::tidy::bugprone { +namespace { + +AST_MATCHER(ParmVarDecl, hasLifetimeBoundAttr) { + return Node.getAttr() != nullptr; 5chmidti wrote: nit: `Node.hasAttr()` https://github.com/llvm/ll

[clang] [flang] [flang][Driver] Support -print-supported-extensions (PR #117402)

2024-12-02 Thread Andrzej Warzyński via cfe-commits
@@ -0,0 +1,34 @@ +! REQUIRES: arm-registered-target + +! RUN: %flang --target=arm-linux-gnu --print-supported-extensions 2>&1 \ +! RUN: | FileCheck --strict-whitespace --implicit-check-not=FEAT_ %s + +! CHECK: All available -march extensions for ARM banach-space

<    1   2   3   4   5   6   >