[libcxx] [libcxxabi] [libunwind] [runtimes] Always define cxx_shared, cxx_static & other targets (PR #80007)

2024-10-09 Thread Petr Hosek via cfe-commits
petrhosek wrote: I tested this locally in a clean build but I'm seeing the following build error: ``` CMake Error: Running '/usr/local/google/home/phosek/fuchsia/prebuilt/third_party/ninja/linux-x64/ninja' '-C' '/usr/local/google/home/phosek/llvm/llvm-project/build/fuchsia/runtimes/runti

[clang] [clang][x86] Missing `AVX512VP2INTERSECT` flag (PR #111435)

2024-10-09 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 d2457e6d8f62a12b3b74791cfd3f5808168c8a71 694113e6d475df6b271c4174d02d5cd03b9aabf2 --e

[compiler-rt] [libunwind] [AArch64] Fix nofp regressions in compiler-rt and libunwind (PR #111235)

2024-10-09 Thread Oliver Stannard via cfe-commits
@@ -1,5 +1,20 @@ #include +#if __ARM_FP == 0 +// WARNING: When building the scalar versions of these functions you need to +// use the compiler flag "-mllvm -disable-loop-idiom-all" to prevent clang ostannard wrote: I think `-fno-builtin-memcpy` would be a be

[compiler-rt] [libunwind] [AArch64] Fix nofp regressions in compiler-rt and libunwind (PR #111235)

2024-10-09 Thread Oliver Stannard via cfe-commits
@@ -238,6 +236,7 @@ END_COMPILERRT_OUTLINE_FUNCTION(__arm_sc_memcpy) DEFINE_COMPILERRT_FUNCTION_ALIAS(__arm_sc_memmove, __arm_sc_memcpy) +#if defined(__aarch64__) && __ARM_FP != 0 ostannard wrote: This could do with a comment explaining why only some are bui

[clang] [clang] Catch missing format attributes (PR #105479)

2024-10-09 Thread Budimir Aranđelović via cfe-commits
https://github.com/budimirarandjelovichtec updated https://github.com/llvm/llvm-project/pull/105479 From 1c05de275761cedb87f642a203ceeb075fccadb8 Mon Sep 17 00:00:00 2001 From: budimirarandjelovicsyrmia Date: Fri, 5 Apr 2024 15:20:37 +0200 Subject: [PATCH] [clang] Catch missing format attribute

[clang] [clang] Catch missing format attributes (PR #105479)

2024-10-09 Thread Budimir Aranđelović via cfe-commits
@@ -0,0 +1,251 @@ +// RUN: %clang_cc1 -fsyntax-only -verify=expected,c_diagnostics -Wmissing-format-attribute %s +// RUN: %clang_cc1 -fsyntax-only -Wmissing-format-attribute -fdiagnostics-parseable-fixits %s 2>&1 | FileCheck %s +// RUN: %clang_cc1 -fsyntax-only -x c++ -verify=ex

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-09 Thread via cfe-commits
eddyz87 wrote: > @eddyz87, do my changes to BPFMISimplifyPatchable.cpp still look good to you? > Now that load-acquires are STX insns, I wanted to make sure that > BPFMISimplifyPatchable::checkADDrr() can still handle them correctly for > CO-RE. The `checkADDrr()` change looks ok. > I'll add

[clang] [clang] Catch missing format attributes (PR #105479)

2024-10-09 Thread Vlad Serebrennikov via cfe-commits
@@ -0,0 +1,251 @@ +// RUN: %clang_cc1 -fsyntax-only -verify=expected,c_diagnostics -Wmissing-format-attribute %s +// RUN: %clang_cc1 -fsyntax-only -Wmissing-format-attribute -fdiagnostics-parseable-fixits %s 2>&1 | FileCheck %s +// RUN: %clang_cc1 -fsyntax-only -x c++ -verify=ex

[clang] [Clang] Avoid a crash when parsing an invalid pseudo-destructor (PR #111666)

2024-10-09 Thread via cfe-commits
https://github.com/cor3ntin updated https://github.com/llvm/llvm-project/pull/111666 >From 61ca96e4ef6aa1476da6758ac7e7dc2b9715b3de Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Wed, 9 Oct 2024 14:10:12 +0200 Subject: [PATCH] [Clang] Avoid a crash when parsing an invalid pseudo-destructo

[clang] [Clang] Avoid a crash when parsing an invalid pseudo-destructor (PR #111666)

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

[clang] [clang][bytecode] Implement __builtin_ai32_addcarryx* (PR #111671)

2024-10-09 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/111671 None >From 73aec534d3b1b320855a08638ce5ef410a5de11c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Wed, 9 Oct 2024 14:55:12 +0200 Subject: [PATCH] [clang][bytecode] Implement __builtin_ai32

[clang] [clang][bytecode] Implement __builtin_ai32_addcarryx* (PR #111671)

2024-10-09 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/111671.diff 2 Files Affected: - (modified) clang/lib/AST/ByteCode/Function.h (+4) - (modified) clang/lib/AST/ByteCode/InterpBuiltin.cpp (+50) `

[clang] [flang] [llvm] [openmp] [Clang][OpenMP] Add permutation clause (PR #92030)

2024-10-09 Thread Michael Kruse via cfe-commits
https://github.com/Meinersbur closed https://github.com/llvm/llvm-project/pull/92030 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2024-10-09 Thread Younan Zhang via cfe-commits
@@ -4008,6 +3996,38 @@ TemplateDeductionResult Sema::FinishTemplateArgumentDeduction( Owner = FunctionTemplate->getLexicalDeclContext(); FunctionDecl *FD = FunctionTemplate->getTemplatedDecl(); + // C++20 [temp.deduct.general]p5: (CWG2369) + // If the function templat

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2024-10-09 Thread Younan Zhang via cfe-commits
@@ -4042,8 +4062,8 @@ TemplateDeductionResult Sema::FinishTemplateArgumentDeduction( // ([temp.constr.decl]), those constraints are checked for satisfaction // ([temp.constr.constr]). If the constraints are not satisfied, type // deduction fails. - if (!IsIncomple

[clang] [RFC][C++20][Modules] Relax ODR check in unnamed modules (PR #111160)

2024-10-09 Thread Dmitry Polukhin via cfe-commits
https://github.com/dmpolukhin updated https://github.com/llvm/llvm-project/pull/60 >From dc4a79c2ee5630eb551ea3a40b4bd67da20c7034 Mon Sep 17 00:00:00 2001 From: Dmitry Polukhin Date: Fri, 4 Oct 2024 06:41:34 -0700 Subject: [PATCH 1/4] [RFC][C++20][Modules] Relax ODR check in unnamed modules

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2024-10-09 Thread Younan Zhang via cfe-commits
@@ -1517,7 +1555,7 @@ substituteParameterMappings(Sema &S, NormalizedConstraint &N, static bool substituteParameterMappings(Sema &S, NormalizedConstraint &N, const ConceptSpecializationExpr *CSE) { MultiLevelTemplateArgumentList MLTAL

[clang] [clang] Change "bad" to "unsupported" in register type error (PR #111550)

2024-10-09 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-hip-vega20` running on `hip-vega20-0` while building `clang` at step 3 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/123/builds/7202 Here is the relevant piece of the build log for

[clang] [clang][bytecode] Emit better diagnostic for invalid shufflevector index (PR #111643)

2024-10-09 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/111643 None >From b4bbdf61030978621c07b25dda7790a43f10ab3a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Wed, 9 Oct 2024 09:22:44 +0200 Subject: [PATCH] [clang][bytecode] Emit better diagnostic f

[clang] [clang][bytecode] Emit better diagnostic for invalid shufflevector index (PR #111643)

2024-10-09 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/111643.diff 5 Files Affected: - (modified) clang/lib/AST/ByteCode/Compiler.cpp (+2-1) - (modified) clang/lib/AST/ByteCode/Interp.cpp (+9) - (modi

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-10-09 Thread Kyungwoo Lee via cfe-commits
@@ -0,0 +1,94 @@ +; This test verifies whether we can outline a singleton instance (i.e., an instance that does not repeat) kyulee-com wrote: Added more comments on the test. https://github.com/llvm/llvm-project/pull/90933 __

[clang] [RFC][C++20][Modules] Relax ODR check in unnamed modules (PR #111160)

2024-10-09 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/60 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] ef739e7 - [clang] Change "bad" to "unsupported" in register type error (#111550)

2024-10-09 Thread via cfe-commits
Author: David Spickett Date: 2024-10-09T09:12:27+01:00 New Revision: ef739e78ff82d15dfdb4d7817c5a2990a89cf5ea URL: https://github.com/llvm/llvm-project/commit/ef739e78ff82d15dfdb4d7817c5a2990a89cf5ea DIFF: https://github.com/llvm/llvm-project/commit/ef739e78ff82d15dfdb4d7817c5a2990a89cf5ea.diff

[clang] [clang] Change "bad" to "unsupported" in register type error (PR #111550)

2024-10-09 Thread David Spickett via cfe-commits
https://github.com/DavidSpickett closed https://github.com/llvm/llvm-project/pull/111550 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RFC][C++20][Modules] Relax ODR check in unnamed modules (PR #111160)

2024-10-09 Thread Dmitry Polukhin via cfe-commits
@@ -2527,7 +2527,7 @@ class BitsUnpacker { inline bool shouldSkipCheckingODR(const Decl *D) { return D->getASTContext().getLangOpts().SkipODRCheckInGMF && - D->isFromGlobalModule(); + (D->isFromGlobalModule() || !D->isInNamedModule()); dmpolu

[clang] [clang] Change "bad" to "unsupported" in register type error (PR #111550)

2024-10-09 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `lldb-arm-ubuntu` running on `linaro-lldb-arm-ubuntu` while building `clang` at step 6 "test". Full details are available at: https://lab.llvm.org/buildbot/#/builders/18/builds/5139 Here is the relevant piece of the build log

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-09 Thread via cfe-commits
@@ -1205,10 +1298,19 @@ class LOAD32 : LOAD32; +class LOAD_ACQUIREi32 +: LOAD_ACQUIRE; + let Predicates = [BPFHasALU32], DecoderNamespace = "BPFALU32" in { def LDW32 : LOADi32; def LDH32 : LOADi32; def LDB32 : LOADi32; + + let Predicates = [BPFHasLoadAcquire]

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-09 Thread via cfe-commits
@@ -622,6 +665,47 @@ let Predicates = [BPFHasLdsx] in { def LDD : LOADi64; +class LOAD_ACQUIRE +: TYPE_LD_ST { + bits<4> dst; + bits<20> addr; + + let Inst{51-48} = dst; + let Inst{55-52} = addr{19-16}; // base reg + let Inst{47-32} = addr{15-0}; // offset + let Ins

[clang] [clang][python] Don't add check-clang-python to check-all if cross-compiling (PR #111657)

2024-10-09 Thread Aaron Ballman via cfe-commits
@@ -47,6 +47,14 @@ if(${LLVM_NATIVE_ARCH} MATCHES "^(AArch64|Hexagon|Sparc|SystemZ)$") set(RUN_PYTHON_TESTS FALSE) endif() +# Tests will fail if cross-compiling for a different target, as tests will try +# to use the host Python3_EXECUTABLE and make FFI calls to functions i

[clang] [compiler-rt] [llvm] [FMV][AArch64] Unify aes with pmull and sve2-aes with sve2-pmull128. (PR #111673)

2024-10-09 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Alexandros Lamprineas (labrinea) Changes According to the Arm Architecture Reference Manual for A-profile architecture you can't have one feature without having the other: ID_AA64ZFR0_EL1.AES, bits [7:4] > FEAT_SVE_AES implements the fun

[clang] [compiler-rt] [libcxx] [llvm] [clang] Warn about memset/memcpy to NonTriviallyCopyable types (PR #111434)

2024-10-09 Thread via cfe-commits
@@ -102,7 +102,7 @@ struct __aliasing_iterator_wrapper { _LIBCPP_HIDE_FROM_ABI _Alias operator*() const _NOEXCEPT { _Alias __val; - __builtin_memcpy(&__val, std::__to_address(__base_), sizeof(value_type)); + __builtin_memcpy(&__val, reinterpret_cast(std::_

[clang] [compiler-rt] [llvm] [FMV][AArch64] Unify aes with pmull and sve2-aes with sve2-pmull128. (PR #111673)

2024-10-09 Thread Alexandros Lamprineas via cfe-commits
https://github.com/labrinea created https://github.com/llvm/llvm-project/pull/111673 According to the Arm Architecture Reference Manual for A-profile architecture you can't have one feature without having the other: ID_AA64ZFR0_EL1.AES, bits [7:4] > FEAT_SVE_AES implements the functionality i

[clang] [compiler-rt] [libcxx] [llvm] [clang] Warn about memset/memcpy to NonTriviallyCopyable types (PR #111434)

2024-10-09 Thread via cfe-commits
https://github.com/serge-sans-paille updated https://github.com/llvm/llvm-project/pull/111434 >From 40974f3a0f7b0de71ec55fbe9baac1f09f35b3a6 Mon Sep 17 00:00:00 2001 From: serge-sans-paille Date: Mon, 7 Oct 2024 15:30:24 +0200 Subject: [PATCH 1/4] [clang] Warn about memset/memcpy to NonTriviall

[clang] [Clang] Avoid a crash when parsing an invalid pseudo-destructor (PR #111666)

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

[clang] [compiler-rt] [libcxx] [llvm] [clang] Warn about memset/memcpy to NonTriviallyCopyable types (PR #111434)

2024-10-09 Thread Nikolas Klauser via cfe-commits
philnik777 wrote: > > ACK. Not a standard requirement though, is it? > > Correct, it's only UB on non-trivially-copyable. My point was more about if > we want to be consistent with GCC or not. I don't have any strong opinion on > that. I can see an argument that a user probably is doing somet

[clang] [flang] [llvm] [mlir] [flang][OpenMP] Add frontend support for ompx_bare clause (PR #111106)

2024-10-09 Thread Ivan R. Ivanov via cfe-commits
https://github.com/ivanradanov updated https://github.com/llvm/llvm-project/pull/06 >From 4326796699c6c28859c9445965443fdac4626864 Mon Sep 17 00:00:00 2001 From: Ivan Radanov Ivanov Date: Fri, 4 Oct 2024 16:20:36 +0900 Subject: [PATCH 01/11] [flang] Add frontend support for OpenMP extension

[clang] [Clang] Avoid a crash when parsing an invalid pseudo-destructor (PR #111666)

2024-10-09 Thread Erich Keane via cfe-commits
erichkeane wrote: Linux failure is an unrelated 'hip driver' test. https://github.com/llvm/llvm-project/pull/111666 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2024-10-09 Thread via cfe-commits
@@ -1517,7 +1555,7 @@ substituteParameterMappings(Sema &S, NormalizedConstraint &N, static bool substituteParameterMappings(Sema &S, NormalizedConstraint &N, const ConceptSpecializationExpr *CSE) { MultiLevelTemplateArgumentList MLTAL

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2024-10-09 Thread via cfe-commits
@@ -4008,6 +3996,38 @@ TemplateDeductionResult Sema::FinishTemplateArgumentDeduction( Owner = FunctionTemplate->getLexicalDeclContext(); FunctionDecl *FD = FunctionTemplate->getTemplatedDecl(); + // C++20 [temp.deduct.general]p5: (CWG2369) + // If the function templat

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2024-10-09 Thread via cfe-commits
@@ -4042,8 +4062,8 @@ TemplateDeductionResult Sema::FinishTemplateArgumentDeduction( // ([temp.constr.decl]), those constraints are checked for satisfaction // ([temp.constr.constr]). If the constraints are not satisfied, type // deduction fails. - if (!IsIncomple

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2024-10-09 Thread via cfe-commits
@@ -1109,12 +1109,50 @@ bool Sema::EnsureTemplateArgumentListConstraints( return false; } -bool Sema::CheckInstantiatedFunctionTemplateConstraints( +static bool CheckFunctionConstraintsWithoutInstantiation( +Sema &SemaRef, SourceLocation PointOfInstantiation, +Functi

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2024-10-09 Thread via cfe-commits
@@ -4008,6 +3996,38 @@ TemplateDeductionResult Sema::FinishTemplateArgumentDeduction( Owner = FunctionTemplate->getLexicalDeclContext(); FunctionDecl *FD = FunctionTemplate->getTemplatedDecl(); + // C++20 [temp.deduct.general]p5: (CWG2369) + // If the function templat

[clang] [libcxx] [Clang] Implement CWG2369 "Ordering between constraints and substitution" (PR #102857)

2024-10-09 Thread via cfe-commits
@@ -1916,9 +1935,33 @@ Decl *TemplateInstantiator::TransformDecl(SourceLocation Loc, Decl *D) { // template parameter. } + if (SemaRef.CurrentInstantiationScope) { +if (isSubstitutingConstraints() && isa(D) && +maybeInstantiateFunctionParameterToScope(cast(

[clang] [clang] Catch missing format attributes (PR #105479)

2024-10-09 Thread Budimir Aranđelović via cfe-commits
https://github.com/budimirarandjelovichtec updated https://github.com/llvm/llvm-project/pull/105479 From 292346c15654b5146a2f863ff023ade4beadb9b1 Mon Sep 17 00:00:00 2001 From: budimirarandjelovicsyrmia Date: Fri, 5 Apr 2024 15:20:37 +0200 Subject: [PATCH] [clang] Catch missing format attribute

[libclc] [libclc] Give a helpful error when an unknown target is requested (PR #111528)

2024-10-09 Thread David Spickett via cfe-commits
https://github.com/DavidSpickett closed https://github.com/llvm/llvm-project/pull/111528 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libclc] a4de127 - [libclc] Give a helpful error when an unknown target is requested (#111528)

2024-10-09 Thread via cfe-commits
Author: David Spickett Date: 2024-10-09T09:13:26+01:00 New Revision: a4de127086ba4e39effb28642973edbb758e9656 URL: https://github.com/llvm/llvm-project/commit/a4de127086ba4e39effb28642973edbb758e9656 DIFF: https://github.com/llvm/llvm-project/commit/a4de127086ba4e39effb28642973edbb758e9656.diff

[clang] [CUDA/HIP] fix propagate -cuid to a host-only compilation. (PR #111650)

2024-10-09 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver @llvm/pr-subscribers-clang Author: Pankaj Dwivedi (PankajDwivedi-25) Changes build failure is observed in the hip test after patch #107483, which complains about a linking error. "/usr/bin/ld: /opt/rocm/share/hip/samples/2_Cookbook/16_ass

[clang] [CUDA/HIP] fix propagate -cuid to a host-only compilation. (PR #111650)

2024-10-09 Thread Pankaj Dwivedi via cfe-commits
https://github.com/PankajDwivedi-25 created https://github.com/llvm/llvm-project/pull/111650 build failure is observed in the hip test after patch #107483, which complains about a linking error. "/usr/bin/ld: /opt/rocm/share/hip/samples/2_Cookbook/16_assembly_to_executable/build/square_asm.ou

[clang] [analyzer] Fix crash when casting the result of a malformed fptr call (PR #111390)

2024-10-09 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat approved this pull request. LGTM. Let's not crash. https://github.com/llvm/llvm-project/pull/111390 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CUDA/HIP] fix propagate -cuid to a host-only compilation. (PR #111650)

2024-10-09 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 1312369afbeb2083094b3d34a88c346b22e86971 7fab0002d9febf440545043d8782d7243a03f17b --e

[clang-tools-extra] [clang-tidy] Avoid repeated hash lookups (NFC) (PR #111628)

2024-10-09 Thread Nikita Popov via cfe-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/111628 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][python] Add CLANG_DISABLE_RUN_PYTHON_TESTS CMake option to disable clang python bindings tests (PR #111367)

2024-10-09 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: > Though now I write this, I'm thinking it would make more sense to set > RUN_PYTHON_TESTS to FALSE if CMAKE_CROSSCOMPILING is set. What do you think? Yes, I like this direction much more. Probably you should also print a message during configuration saying that those tests are

[clang] [clang][Sema] Add instant event when template instantiation is deferred. (PR #111524)

2024-10-09 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/111524 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] Fix crash when casting the result of a malformed fptr call (PR #111390)

2024-10-09 Thread Balazs Benics via cfe-commits
https://github.com/steakhal closed https://github.com/llvm/llvm-project/pull/111390 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-include-cleaner] Fix incorrect directory issue for writing files (PR #111375)

2024-10-09 Thread kadir çetinkaya via cfe-commits
kadircet wrote: > so clang-include-cleaner correctly adjusted the path to > /home/leebc/.cache/bazel/_bazel_leebc/5ea2deb937e75f0bf29ba4c49931e67d/execroot/_main/api/main.cc, > which was correctly symlinked. in our case this is symlinked to an immutable copy of the source file (to make sure b

[clang] 068d76b - [analyzer] Fix crash when casting the result of a malformed fptr call (#111390)

2024-10-09 Thread via cfe-commits
Author: Balazs Benics Date: 2024-10-09T11:39:56+02:00 New Revision: 068d76b48093ccf8b55c4af6a6ccacfc1ce0ae53 URL: https://github.com/llvm/llvm-project/commit/068d76b48093ccf8b55c4af6a6ccacfc1ce0ae53 DIFF: https://github.com/llvm/llvm-project/commit/068d76b48093ccf8b55c4af6a6ccacfc1ce0ae53.diff

[clang] [clang] Set FPOptions at the beginning of CompoundStmt (PR #111654)

2024-10-09 Thread Serge Pavlov via cfe-commits
https://github.com/spavloff created https://github.com/llvm/llvm-project/pull/111654 CompoundStmt has FPOptions, that should be set for IRBuilder when generating code if that statement. It must fix the issue #84648. >From a7f150c90c301cdd5f55cf6eb44f4e8cf77625f1 Mon Sep 17 00:00:00 2001 From:

[clang] [clang] Set FPOptions at the beginning of CompoundStmt (PR #111654)

2024-10-09 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Serge Pavlov (spavloff) Changes CompoundStmt has FPOptions, that should be set for IRBuilder when generating code if that statement. It must fix the issue #84648. --- Full diff: https://github.com/llvm/llvm-project/pull/111654.diff 3 F

[clang] 1be64e5 - [clang][Sema] Add instant event when template instantiation is deferred. (#111524)

2024-10-09 Thread via cfe-commits
Author: ivanaivanovska Date: 2024-10-09T11:42:11+02:00 New Revision: 1be64e5413cbe9cfa89539f70ad02ee1d8945ebe URL: https://github.com/llvm/llvm-project/commit/1be64e5413cbe9cfa89539f70ad02ee1d8945ebe DIFF: https://github.com/llvm/llvm-project/commit/1be64e5413cbe9cfa89539f70ad02ee1d8945ebe.diff

[clang] [clang][Sema] Add instant event when template instantiation is deferred. (PR #111524)

2024-10-09 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 closed https://github.com/llvm/llvm-project/pull/111524 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Allow `ConditionalOperator` fast-math flags to be overridden by `pragma float_control` (PR #105912)

2024-10-09 Thread Serge Pavlov via cfe-commits
spavloff wrote: I made an alternative PR, which does not need changes in ConditionalOperator: https://github.com/llvm/llvm-project/pull/111654. https://github.com/llvm/llvm-project/pull/105912 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[clang-tools-extra] [clang-include-cleaner] Fix incorrect directory issue for writing files (PR #111375)

2024-10-09 Thread Byoungchan Lee via cfe-commits
https://github.com/bc-lee edited https://github.com/llvm/llvm-project/pull/111375 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-include-cleaner] Fix incorrect directory issue for writing files (PR #111375)

2024-10-09 Thread Byoungchan Lee via cfe-commits
https://github.com/bc-lee updated https://github.com/llvm/llvm-project/pull/111375 >From 23b90bba12c010e5882e09e9f6b765a7281324aa Mon Sep 17 00:00:00 2001 From: Byoungchan Lee Date: Mon, 7 Oct 2024 22:19:38 +0900 Subject: [PATCH 1/2] [clang-include-cleaner] Fix incorrect directory issue for wr

[clang] 6f8e855 - [clang][bytecode] Implement __builtin_ai32_addcarryx* (#111671)

2024-10-09 Thread via cfe-commits
Author: Timm Baeder Date: 2024-10-09T15:42:19+02:00 New Revision: 6f8e855150534358ea8c9301960c7c83119b1394 URL: https://github.com/llvm/llvm-project/commit/6f8e855150534358ea8c9301960c7c83119b1394 DIFF: https://github.com/llvm/llvm-project/commit/6f8e855150534358ea8c9301960c7c83119b1394.diff L

[clang] [clang][bytecode] Implement __builtin_ai32_addcarryx* (PR #111671)

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

[clang-tools-extra] [clangd] Let DefineOutline tweak handle member functions (PR #95235)

2024-10-09 Thread Christian Kandeler via cfe-commits
ckandeler wrote: ping https://github.com/llvm/llvm-project/pull/95235 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CLANG]Add Scalable vectors for mfloat8_t (PR #101644)

2024-10-09 Thread via cfe-commits
https://github.com/CarolineConcatto updated https://github.com/llvm/llvm-project/pull/101644 >From 7134302c7e1054021af36a207dbfd0c40c9e8c51 Mon Sep 17 00:00:00 2001 From: Caroline Concatto Date: Fri, 2 Aug 2024 08:47:18 + Subject: [PATCH] [CLANG]Add Scalable vectors for mfloat8_t This patc

[clang] [CLANG]Add Scalable vectors for mfloat8_t (PR #101644)

2024-10-09 Thread via cfe-commits
https://github.com/CarolineConcatto updated https://github.com/llvm/llvm-project/pull/101644 >From 7134302c7e1054021af36a207dbfd0c40c9e8c51 Mon Sep 17 00:00:00 2001 From: Caroline Concatto Date: Fri, 2 Aug 2024 08:47:18 + Subject: [PATCH] [CLANG]Add Scalable vectors for mfloat8_t This patc

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-10-09 Thread Kyungwoo Lee via cfe-commits
@@ -1513,6 +1522,171 @@ class InProcessThinBackend : public ThinBackendProc { return Error::success(); } }; + +/// This backend is utilized in the first round of a two-codegen round process. +/// It first saves optimized bitcode files to disk before the codegen process +/

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-10-09 Thread Kyungwoo Lee via cfe-commits
https://github.com/kyulee-com updated https://github.com/llvm/llvm-project/pull/90933 >From 411fc459e58a65d9599c917f220ba68bb799baac Mon Sep 17 00:00:00 2001 From: Kyungwoo Lee Date: Fri, 13 Sep 2024 08:51:00 -0700 Subject: [PATCH 1/5] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds

[clang] Format clang/lib/Sema/Sema.cpp (PR #111518)

2024-10-09 Thread Boaz Brickner via cfe-commits
bricknerb wrote: Thanks for the feedback! This all makes sense. For context, I was going through some of the code and saw some formatting and thought it would be more readable to fix those. I do understand the tradeoff here, so I'll close this pull request. https://github.com/llvm/llvm-project/

[clang] Format clang/lib/Sema/Sema.cpp (PR #111518)

2024-10-09 Thread Boaz Brickner via cfe-commits
https://github.com/bricknerb closed https://github.com/llvm/llvm-project/pull/111518 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Reapply "[Clang][Sema] Refactor collection of multi-level template argument lists (#106585)" (PR #111173)

2024-10-09 Thread Martin Storsjö via cfe-commits
mstorsjo wrote: This no longer reverts cleanly - 4336f00f2156970cc0af2816331387a0a4039317 (#110387) interferes; can someone more involved in this take it upon themselves to sort this out (revert back to green again)? I can of course revert both too. https://github.com/llvm/llvm-project/pull/11

[clang] Reapply "[Clang][Sema] Refactor collection of multi-level template argument lists (#106585)" (PR #111173)

2024-10-09 Thread Martin Storsjö via cfe-commits
mstorsjo wrote: This still breaks building Qt, in the same source file as before, but with a different error. Standalone reproducible with https://martin.st/temp/qwindowsystem-preproc.cpp: ``` $ clang -target i686-w64-mingw32 -c qwindowsystem-preproc.cpp -w qwindowsystem-preproc.cpp:150631:73:

[clang] [clang][Sema] Add instant event when template instantiation is deferred. (PR #111524)

2024-10-09 Thread via cfe-commits
https://github.com/ivanaivanovska updated https://github.com/llvm/llvm-project/pull/111524 >From 612995748e245c30a3a5f626cb2881ac324426b9 Mon Sep 17 00:00:00 2001 From: Ivana Ivanovska Date: Mon, 7 Oct 2024 12:51:55 + Subject: [PATCH] [Sema] This commit contains Sema changes --- clang/lib

[clang] [clang][Sema] Add instant event when template instantiation is deferred. (PR #111524)

2024-10-09 Thread via cfe-commits
@@ -18146,6 +18148,16 @@ void Sema::MarkFunctionReferenced(SourceLocation Loc, FunctionDecl *Func, std::make_pair(Func, PointOfInstantiation)); // Notify the consumer that a function was implicitly instantiated. Consumer.HandleCXXImplici

[clang] [clang] Catch missing format attributes (PR #105479)

2024-10-09 Thread Budimir Aranđelović via cfe-commits
https://github.com/budimirarandjelovichtec updated https://github.com/llvm/llvm-project/pull/105479 From 370cbff0e8fae37f4bbcf27e7386417396f2c754 Mon Sep 17 00:00:00 2001 From: budimirarandjelovicsyrmia Date: Fri, 5 Apr 2024 15:20:37 +0200 Subject: [PATCH] [clang] Catch missing format attribute

[clang] [clang] Catch missing format attributes (PR #105479)

2024-10-09 Thread Budimir Aranđelović via cfe-commits
@@ -5335,6 +5335,217 @@ static void handlePreferredTypeAttr(Sema &S, Decl *D, const ParsedAttr &AL) { D->addAttr(::new (S.Context) PreferredTypeAttr(S.Context, AL, ParmTSI)); } +// This function is called only if function call is not inside template body. +// TODO: Add call

[clang] [compiler-rt] [libcxx] [llvm] [clang] Warn about memset/memcpy to NonTriviallyCopyable types (PR #111434)

2024-10-09 Thread via cfe-commits
https://github.com/serge-sans-paille updated https://github.com/llvm/llvm-project/pull/111434 >From 1904e7d4a3aeffd6f2f4ff397ae84fde37aa231a Mon Sep 17 00:00:00 2001 From: serge-sans-paille Date: Mon, 7 Oct 2024 15:30:24 +0200 Subject: [PATCH 1/4] [clang] Warn about memset/memcpy to NonTriviall

[clang] [CLANG]Add Scalable vectors for mfloat8_t (PR #101644)

2024-10-09 Thread via cfe-commits
https://github.com/CarolineConcatto updated https://github.com/llvm/llvm-project/pull/101644 >From 4da98aa5ad88276fc957571bfbebdd57a5f3918d Mon Sep 17 00:00:00 2001 From: Caroline Concatto Date: Fri, 2 Aug 2024 08:47:18 + Subject: [PATCH] [CLANG]Add Scalable vectors for mfloat8_t This patc

[clang] [clang] Catch missing format attributes (PR #105479)

2024-10-09 Thread Budimir Aranđelović via cfe-commits
@@ -0,0 +1,251 @@ +// RUN: %clang_cc1 -fsyntax-only -verify=expected,c_diagnostics -Wmissing-format-attribute %s +// RUN: %clang_cc1 -fsyntax-only -Wmissing-format-attribute -fdiagnostics-parseable-fixits %s 2>&1 | FileCheck %s +// RUN: %clang_cc1 -fsyntax-only -x c++ -verify=ex

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Donát Nagy via cfe-commits
@@ -314,6 +449,127 @@ getFuchsiaHandleSymbols(QualType QT, SVal Arg, ProgramStateRef State) { return {}; } +bool FuchsiaHandleChecker::needsInvalidate(const CallEvent &Call) const { + const FunctionDecl *FuncDecl = dyn_cast_or_null(Call.getDecl()); + + assert(FuncDecl &&

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Donát Nagy via cfe-commits
@@ -127,26 +135,30 @@ class HandleState { bool isEscaped() const { return K == Kind::Escaped; } bool isUnowned() const { return K == Kind::Unowned; } - static HandleState getMaybeAllocated(SymbolRef ErrorSym) { -return HandleState(Kind::MaybeAllocated, ErrorSym); + s

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Donát Nagy via cfe-commits
@@ -336,141 +592,55 @@ void FuchsiaHandleChecker::checkPreCall(const CallEvent &Call, SmallVector Handles = getFuchsiaHandleSymbols(PVD->getType(), Call.getArgSVal(Arg), State); -// Handled in checkPostCall. -if (hasFuchsiaAttr(PVD) || -hasFuchsiaA

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Donát Nagy via cfe-commits
@@ -267,12 +286,128 @@ class FuchsiaHandleSymbolVisitor final : public SymbolVisitor { private: SmallVector Symbols; }; + +class FuchsiaBugVisitor final : public BugReporterVisitor { + // Handle that caused a problem. + SymbolRef Sym; + + bool IsLeak; + +public: + Fuchsi

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat edited https://github.com/llvm/llvm-project/pull/111588 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat commented: I read the patch and added my suggestions in inline comments, but I don't promise that I found every little corner case. Moreover, I'm strongly opposed to introducing a `BugReporterVisitor` instead of directly creating the notes, because in this case you

[clang-tools-extra] [clang-include-cleaner] Fix incorrect directory issue for writing files (PR #111375)

2024-10-09 Thread Byoungchan Lee via cfe-commits
bc-lee wrote: > in our case this is symlinked to an immutable copy of the source file (to > make sure builds don't act weird if you edit some sources while the build is > running). hence it'll be a regression. > > What's the concern about not performing this directly as relative to the > proc

[clang] [clang][python] Don't add check-clang-python to check-all if cross-compiling (PR #111657)

2024-10-09 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll approved this pull request. https://github.com/llvm/llvm-project/pull/111657 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][python] Don't add check-clang-python to check-all if cross-compiling (PR #111657)

2024-10-09 Thread Vlad Serebrennikov via cfe-commits
@@ -47,6 +47,14 @@ if(${LLVM_NATIVE_ARCH} MATCHES "^(AArch64|Hexagon|Sparc|SystemZ)$") set(RUN_PYTHON_TESTS FALSE) endif() +# Tests will fail if cross-compiling for a different target, as tests will try +# to use the host Python3_EXECUTABLE and make FFI calls to functions i

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Donát Nagy via cfe-commits
@@ -99,6 +99,7 @@ #include "clang/StaticAnalyzer/Core/PathSensitive/ConstraintManager.h" #include "clang/StaticAnalyzer/Core/PathSensitive/ExplodedGraph.h" #include "clang/StaticAnalyzer/Core/PathSensitive/ProgramState.h" +#include "clang/StaticAnalyzer/Core/PathSensitive/Progr

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Donát Nagy via cfe-commits
@@ -314,6 +449,127 @@ getFuchsiaHandleSymbols(QualType QT, SVal Arg, ProgramStateRef State) { return {}; } +bool FuchsiaHandleChecker::needsInvalidate(const CallEvent &Call) const { + const FunctionDecl *FuncDecl = dyn_cast_or_null(Call.getDecl()); + + assert(FuncDecl &&

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Donát Nagy via cfe-commits
@@ -267,12 +286,128 @@ class FuchsiaHandleSymbolVisitor final : public SymbolVisitor { private: SmallVector Symbols; }; + +class FuchsiaBugVisitor final : public BugReporterVisitor { + // Handle that caused a problem. + SymbolRef Sym; + + bool IsLeak; + +public: + Fuchsi

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Donát Nagy via cfe-commits
@@ -267,12 +286,128 @@ class FuchsiaHandleSymbolVisitor final : public SymbolVisitor { private: SmallVector Symbols; }; + +class FuchsiaBugVisitor final : public BugReporterVisitor { + // Handle that caused a problem. + SymbolRef Sym; + + bool IsLeak; + +public: + Fuchsi

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Donát Nagy via cfe-commits
@@ -314,6 +449,127 @@ getFuchsiaHandleSymbols(QualType QT, SVal Arg, ProgramStateRef State) { return {}; } +bool FuchsiaHandleChecker::needsInvalidate(const CallEvent &Call) const { + const FunctionDecl *FuncDecl = dyn_cast_or_null(Call.getDecl()); + + assert(FuncDecl &&

[clang] [clang] Catch missing format attributes (PR #105479)

2024-10-09 Thread Vlad Serebrennikov via cfe-commits
@@ -0,0 +1,251 @@ +// RUN: %clang_cc1 -fsyntax-only -verify=expected,c_diagnostics -Wmissing-format-attribute %s +// RUN: %clang_cc1 -fsyntax-only -Wmissing-format-attribute -fdiagnostics-parseable-fixits %s 2>&1 | FileCheck %s +// RUN: %clang_cc1 -fsyntax-only -x c++ -verify=ex

[clang] [clang][bytecode] Only allow lossless ptr-to-int casts (PR #111669)

2024-10-09 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/111669 Only allow those casts if the bitwidth of the two types match. >From 6d68260682f723fa7a010e2fd381da32316ed5e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Wed, 9 Oct 2024 14:03:39 +0200 S

[clang] [clang][bytecode] Only allow lossless ptr-to-int casts (PR #111669)

2024-10-09 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes Only allow those casts if the bitwidth of the two types match. --- Full diff: https://github.com/llvm/llvm-project/pull/111669.diff 3 Files Affected: - (modified) clang/lib/AST/ByteCode/Interp.cpp (+41) -

[libcxx] [libcxxabi] [libunwind] [runtimes] Always define cxx_shared, cxx_static & other targets (PR #80007)

2024-10-09 Thread Louis Dionne via cfe-commits
ldionne wrote: @petrhosek Where is the cache generating that build? The fix for this is: ``` # On embedded platforms that don't support shared library targets, CMake implicitly changes shared # library targets to be static library targets. This results in duplicate definitions of the static #

[clang] [llvm] [clang-format] Add CI check confirming ClangFormatStyleOptions.rst is up-to-date. (PR #111513)

2024-10-09 Thread Iuri Chaer via cfe-commits
ichaer wrote: > So I'd prefer to see a patch doing that rather than just asserting that it is > the same. @boomanaiden154, I'm willing to do that, but could we confirm with a clang-format maintainer first? In the course of that code review I referenced [I did introduce an error in the documen

<    1   2   3   4   5   6   >