[clang] [clang][analyzer] MmapWriteExecChecker improvements (PR #97078)

2024-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 Author: Balázs Kéri (balazske) Changes Read the 'mmap' flags from macro values and use a better test for the error situation. --- Full diff: https://github.com/llvm/llvm-project/pull/97078.diff 2 Files Affected: - (modified)

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Shilei Tian via cfe-commits
@@ -444,32 +444,81 @@ template struct omptarget_nvptx_LoopSupport { // KMP interface implementation (dyn loops) -// TODO: This is a stopgap. We probably want to expand the dispatch API to take

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
@@ -444,32 +444,81 @@ template struct omptarget_nvptx_LoopSupport { // KMP interface implementation (dyn loops) -// TODO: This is a stopgap. We probably want to expand the dispatch API to take

[clang] [clang][NFC] Use range-based for loops (PR #96831)

2024-06-28 Thread Mital Ashok via cfe-commits
@@ -2056,40 +2056,41 @@ void CXXRecordDecl::completeDefinition() { completeDefinition(nullptr); } +static bool hasPureVirtualFinalOverrider( +const CXXRecordDecl &RD, const CXXFinalOverriderMap *FinalOverriders) { + auto ExistsIn = [](const CXXFinalOverriderMap &FinalOv

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Shilei Tian via cfe-commits
@@ -444,32 +444,81 @@ template struct omptarget_nvptx_LoopSupport { // KMP interface implementation (dyn loops) -// TODO: This is a stopgap. We probably want to expand the dispatch API to take

[clang] [clang] Default to -fno-sized-deallocation for AIX (PR #97076)

2024-06-28 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay approved this pull request. https://github.com/llvm/llvm-project/pull/97076 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Tomas Matheson via cfe-commits
@@ -11465,6 +11465,10 @@ static bool CheckMultiVersionFirstFunction(Sema &S, FunctionDecl *FD) { // otherwise it is treated as a normal function. if (TA && !TA->isDefaultVersion()) return false; + // The target_version attribute only causes Multiversioning if this +

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Tomas Matheson via cfe-commits
https://github.com/tmatheson-arm deleted https://github.com/llvm/llvm-project/pull/96628 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [WebAssembly] support getVT from `externref` and `funcref` (PR #97080)

2024-06-28 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 created https://github.com/llvm/llvm-project/pull/97080 Fixes: #69894 >From b49737505ad3ad84e977787daf141b98fe3e6607 Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Sat, 29 Jun 2024 00:24:30 +0800 Subject: [PATCH] [WebAssembly] support getVT from wasm externre

[clang] [llvm] [WebAssembly] support getVT from `externref` and `funcref` (PR #97080)

2024-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-llvm-ir Author: Congcong Cai (HerrCai0907) Changes Fixes: #69894 --- Full diff: https://github.com/llvm/llvm-project/pull/97080.diff 4 Files Affected: - (added) clang/test/CodeGen/WebAssembly/wasm-externref-novec.c (+18) - (modified) llvm/include/l

[clang] [llvm] [WebAssembly] support getVT from `externref` and `funcref` (PR #97080)

2024-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Congcong Cai (HerrCai0907) Changes Fixes: #69894 --- Full diff: https://github.com/llvm/llvm-project/pull/97080.diff 4 Files Affected: - (added) clang/test/CodeGen/WebAssembly/wasm-externref-novec.c (+18) - (modified) llvm/include/llv

[clang] [llvm] [WebAssembly] support getVT from `externref` and `funcref` (PR #97080)

2024-06-28 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 edited https://github.com/llvm/llvm-project/pull/97080 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Tomas Matheson via cfe-commits
@@ -102,8 +102,9 @@ int __attribute__((target_version("sha2"))) combine(void) { return 1; } // expected-error@+1 {{multiversioned function declaration has a different calling convention}} int __attribute__((aarch64_vector_pcs, target_version("sha3"))) combine(void) { return 2

[clang] [llvm] [openmp] [PGO][OpenMP] Instrumentation for GPU devices (PR #76587)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
doru1004 wrote: This is failing for me: ``` ld.lld: error: undefined symbol: llvm::InstrProfSymtab::create(llvm::StringRef) >>> referenced by GlobalHandler.cpp >>> >>> GlobalHandler.cpp.o:(llvm::omp::target::plugin::GPUProfGlobals::dump() >>> const) in archive >>> /home/dobercea

[clang] [llvm] [AArch64][NEON] Add intrinsics for LUTI (PR #96883)

2024-06-28 Thread David Green via cfe-commits
https://github.com/davemgreen commented: Thanks this looks great. I've not checked the C / ACLE intrinsics though - I will defer to @CarolineConcatto and @momchil-velikov for those parts if that is OK. https://github.com/llvm/llvm-project/pull/96883

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Tomas Matheson via cfe-commits
@@ -102,8 +102,9 @@ int __attribute__((target_version("sha2"))) combine(void) { return 1; } // expected-error@+1 {{multiversioned function declaration has a different calling convention}} int __attribute__((aarch64_vector_pcs, target_version("sha3"))) combine(void) { return 2

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Tomas Matheson via cfe-commits
https://github.com/tmatheson-arm edited https://github.com/llvm/llvm-project/pull/96628 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [openmp] [PGO][OpenMP] Instrumentation for GPU devices (PR #76587)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
doru1004 wrote: Should this be reverted? https://github.com/llvm/llvm-project/pull/76587 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [openmp] [PGO][OpenMP] Instrumentation for GPU devices (PR #76587)

2024-06-28 Thread Ethan Luis McDonough via cfe-commits
EthanLuisMcDonough wrote: Which platform are you building this on? https://github.com/llvm/llvm-project/pull/76587 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] Revert: [clangd] Replace an include with a forward declaration (PR #97082)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
https://github.com/doru1004 created https://github.com/llvm/llvm-project/pull/97082 Reverting due to failures on several buildbots. >From beb28561c632a9c76412d78210f6c7cdcf50819a Mon Sep 17 00:00:00 2001 From: Doru Bercea Date: Fri, 28 Jun 2024 12:37:31 -0400 Subject: [PATCH] Revert: [clangd]

[clang-tools-extra] Revert: [clangd] Replace an include with a forward declaration (PR #97082)

2024-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangd @llvm/pr-subscribers-clang-tools-extra Author: Gheorghe-Teodor Bercea (doru1004) Changes Reverting due to failures on several buildbots. --- Full diff: https://github.com/llvm/llvm-project/pull/97082.diff 1 Files Affected: - (modified) clang-t

[clang-tools-extra] Revert: [clangd] Replace an include with a forward declaration (PR #97082)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
https://github.com/doru1004 updated https://github.com/llvm/llvm-project/pull/97082 >From beb28561c632a9c76412d78210f6c7cdcf50819a Mon Sep 17 00:00:00 2001 From: Doru Bercea Date: Fri, 28 Jun 2024 12:37:31 -0400 Subject: [PATCH] Revert: [clangd] Replace an include with a forward declaration -

[clang] [OpenMP] [NFC] SemaOpenMP.cpp and StmtOpenMP.cpp spelling fixes (PR #96814)

2024-06-28 Thread Krzysztof Parzyszek via cfe-commits
https://github.com/kparzysz approved this pull request. https://github.com/llvm/llvm-project/pull/96814 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [openmp] [PGO][OpenMP] Instrumentation for GPU devices (PR #76587)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
doru1004 wrote: I'm building on an x86 + AMD GPU. What fails is this command: ``` [8/14] Performing build step for 'runtimes' [1/4] Linking CXX shared library /home/dobercea/upstream/llvm-project/build/lib/libomptarget.so.19.0git FAILED: /home/dobercea/upstream/llvm-project/build/lib/libomptarg

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
@@ -444,32 +444,81 @@ template struct omptarget_nvptx_LoopSupport { // KMP interface implementation (dyn loops) -// TODO: This is a stopgap. We probably want to expand the dispatch API to take

[clang] [llvm] [openmp] [PGO][OpenMP] Instrumentation for GPU devices (PR #76587)

2024-06-28 Thread Ethan Luis McDonough via cfe-commits
EthanLuisMcDonough wrote: > I'm building on an x86 + AMD GPU. What fails is this command: > > ``` > [8/14] Performing build step for 'runtimes' > [1/4] Linking CXX shared library > /home/dobercea/upstream/llvm-project/build/lib/libomptarget.so.19.0git > FAILED: /home/dobercea/upstream/llvm-proj

[clang] [llvm] [openmp] [PGO][OpenMP] Instrumentation for GPU devices (PR #76587)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
doru1004 wrote: Yes of course: ``` cmake \ -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_INSTALL_PREFIX=~/rocm/trunk_1.0 \ -DLLVM_ENABLE_PROJECTS="clang;lld;llvm;clang-tools-extra;compiler-rt;flang" \ -DLLVM_LIT_ARGS="-vv --show-unsupported --show-xfail -j 32" \ -DLLVM_TARGETS_TO_BUILD="X86;AMD

[clang-tools-extra] Revert: [clangd] Replace an include with a forward declaration (PR #97082)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
https://github.com/doru1004 updated https://github.com/llvm/llvm-project/pull/97082 >From beb28561c632a9c76412d78210f6c7cdcf50819a Mon Sep 17 00:00:00 2001 From: Doru Bercea Date: Fri, 28 Jun 2024 12:37:31 -0400 Subject: [PATCH] Revert: [clangd] Replace an include with a forward declaration -

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Alexandros Lamprineas via cfe-commits
@@ -11465,6 +11465,10 @@ static bool CheckMultiVersionFirstFunction(Sema &S, FunctionDecl *FD) { // otherwise it is treated as a normal function. if (TA && !TA->isDefaultVersion()) return false; + // The target_version attribute only causes Multiversioning if this +

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Alexandros Lamprineas via cfe-commits
@@ -11523,10 +11525,17 @@ static bool CheckTargetCausesMultiVersioning(Sema &S, FunctionDecl *OldFD, const auto *OldTVA = OldFD->getAttr(); // If the old decl is NOT MultiVersioned yet, and we don't cause that // to change, this is a simple redeclaration. - if ((NewTA &

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Alexandros Lamprineas via cfe-commits
https://github.com/labrinea edited https://github.com/llvm/llvm-project/pull/96628 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Alexandros Lamprineas via cfe-commits
@@ -11576,22 +11584,6 @@ static bool CheckTargetCausesMultiVersioning(Sema &S, FunctionDecl *OldFD, } } - if (NewTVA) { labrinea wrote: The assertion should be conditional when NewTVA is not null because the function is used for the target attribute

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Johannes Doerfert via cfe-commits
@@ -444,32 +444,81 @@ template struct omptarget_nvptx_LoopSupport { // KMP interface implementation (dyn loops) -// TODO: This is a stopgap. We probably want to expand the dispatch API to take

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
@@ -444,32 +444,81 @@ template struct omptarget_nvptx_LoopSupport { // KMP interface implementation (dyn loops) -// TODO: This is a stopgap. We probably want to expand the dispatch API to take

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Johannes Doerfert via cfe-commits
@@ -0,0 +1,57 @@ +// clang-format off +// RUN: %libomptarget-compilexx-generic && %libomptarget-run-generic 2>&1 | %fcheck-generic +// clang-format on + +// UNSUPPORTED: aarch64-unknown-linux-gnu +// UNSUPPORTED: aarch64-unknown-linux-gnu-LTO +// UNSUPPORTED: x86_64-pc-linux-gnu

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Johannes Doerfert via cfe-commits
@@ -444,32 +444,81 @@ template struct omptarget_nvptx_LoopSupport { // KMP interface implementation (dyn loops) -// TODO: This is a stopgap. We probably want to expand the dispatch API to take

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Johannes Doerfert via cfe-commits
@@ -3044,6 +3046,9 @@ void CodeGenFunction::EmitOMPForOuterLoop( OuterLoopArgs.DKind = LoopArgs.DKind; EmitOMPOuterLoop(DynamicOrOrdered, IsMonotonic, S, LoopScope, OuterLoopArgs, emitOMPLoopBodyWithStopPoint, CodeGenOrdered); + if (DynamicOrOrdered) { -

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Johannes Doerfert via cfe-commits
@@ -0,0 +1,84 @@ +// clang-format off +// RUN: %libomptarget-compile-generic && %libomptarget-run-generic 2>&1 | %fcheck-generic +// clang-format on + +// UNSUPPORTED: aarch64-unknown-linux-gnu +// UNSUPPORTED: aarch64-unknown-linux-gnu-LTO +// UNSUPPORTED: x86_64-pc-linux-gnu +/

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Johannes Doerfert via cfe-commits
@@ -444,32 +444,81 @@ template struct omptarget_nvptx_LoopSupport { // KMP interface implementation (dyn loops) -// TODO: This is a stopgap. We probably want to expand the dispatch API to take

[clang] [Clang] Fix __is_trivially_equality_comparable returning true with ineligebile defaulted overloads (PR #93113)

2024-06-28 Thread Zequan Wu via cfe-commits
ZequanWu wrote: I have a partially reduced repro: ``` $ clang++ "-cc1" "-triple" "arm64-apple-macosx10.15.0" "-Wundef-prefix=TARGET_OS_" "-Werror=undef-prefix" "-Wdeprecated-objc-isa-usage" "-Werror=deprecated-objc-isa-usage" "-emit-llvm-bc" "-flto=thin" "-flto-unit" "-disable-free" "-clear-a

[clang-tools-extra] Revert: [clangd] Replace an include with a forward declaration (PR #97082)

2024-06-28 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 approved this pull request. Seems reasonable as I believe there were extra uses that needed the size. https://github.com/llvm/llvm-project/pull/97082 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.

[clang-tools-extra] 319e11d - Revert: [clangd] Replace an include with a forward declaration (#97082)

2024-06-28 Thread via cfe-commits
Author: Gheorghe-Teodor Bercea Date: 2024-06-28T13:20:38-04:00 New Revision: 319e11daee807981db61dad3da90d9bf36317e03 URL: https://github.com/llvm/llvm-project/commit/319e11daee807981db61dad3da90d9bf36317e03 DIFF: https://github.com/llvm/llvm-project/commit/319e11daee807981db61dad3da90d9bf36317

[clang-tools-extra] Revert: [clangd] Replace an include with a forward declaration (PR #97082)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
https://github.com/doru1004 closed https://github.com/llvm/llvm-project/pull/97082 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [OpenMPIRBuilder][Clang][NFC] - Combine `emitOffloadingArrays` and `emitOffloadingArraysArgument` in OpenMPIRBuilder (PR #97088)

2024-06-28 Thread Pranav Bhandarkar via cfe-commits
https://github.com/bhandarkar-pranav created https://github.com/llvm/llvm-project/pull/97088 This PR introduces a new interface in `OpenMPIRBuilder` that combines the creation of the so-called offloading pointer arrays and their subsequent preparation as arguments to the OpenMP runtime library

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
@@ -3044,6 +3046,9 @@ void CodeGenFunction::EmitOMPForOuterLoop( OuterLoopArgs.DKind = LoopArgs.DKind; EmitOMPOuterLoop(DynamicOrOrdered, IsMonotonic, S, LoopScope, OuterLoopArgs, emitOMPLoopBodyWithStopPoint, CodeGenOrdered); + if (DynamicOrOrdered) { -

[clang] [llvm] [openmp] [OpenMP][offload] Fix dynamic schedule tracking (PR #97065)

2024-06-28 Thread Gheorghe-Teodor Bercea via cfe-commits
@@ -444,32 +444,81 @@ template struct omptarget_nvptx_LoopSupport { // KMP interface implementation (dyn loops) -// TODO: This is a stopgap. We probably want to expand the dispatch API to take

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Alexandros Lamprineas via cfe-commits
https://github.com/labrinea edited https://github.com/llvm/llvm-project/pull/96628 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 2c8b912 - Revert "[PGO][OpenMP] Instrumentation for GPU devices (#76587)"

2024-06-28 Thread Ethan Luis McDonough via cfe-commits
Author: Ethan Luis McDonough Date: 2024-06-28T12:30:45-05:00 New Revision: 2c8b912f630f9ec647a4870b9c5ee922c2ec1298 URL: https://github.com/llvm/llvm-project/commit/2c8b912f630f9ec647a4870b9c5ee922c2ec1298 DIFF: https://github.com/llvm/llvm-project/commit/2c8b912f630f9ec647a4870b9c5ee922c2ec129

[clang] [llvm] [openmp] [PGO][OpenMP] Instrumentation for GPU devices (PR #76587)

2024-06-28 Thread Ethan Luis McDonough via cfe-commits
EthanLuisMcDonough wrote: > Yes of course: > > ``` > cmake \ > -DCMAKE_BUILD_TYPE=Release \ > -DCMAKE_INSTALL_PREFIX=~/rocm/trunk_1.0 \ > -DLLVM_ENABLE_PROJECTS="clang;lld;llvm;clang-tools-extra;compiler-rt;flang" > \ > -DLLVM_LIT_ARGS="-vv --show-unsupported --show-xfail -j 32" \ > -

[clang] 6ba764a - [OpenMP] [NFC] SemaOpenMP.cpp and StmtOpenMP.cpp spelling fixes (#96814)

2024-06-28 Thread via cfe-commits
Author: Julian Brown Date: 2024-06-28T12:36:20-05:00 New Revision: 6ba764a54e2ce359117bf9a9d615e06dc3da6144 URL: https://github.com/llvm/llvm-project/commit/6ba764a54e2ce359117bf9a9d615e06dc3da6144 DIFF: https://github.com/llvm/llvm-project/commit/6ba764a54e2ce359117bf9a9d615e06dc3da6144.diff

[clang] [OpenMP] [NFC] SemaOpenMP.cpp and StmtOpenMP.cpp spelling fixes (PR #96814)

2024-06-28 Thread Krzysztof Parzyszek via cfe-commits
https://github.com/kparzysz closed https://github.com/llvm/llvm-project/pull/96814 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [OpenMP] [NFC] SemaOpenMP.cpp and StmtOpenMP.cpp spelling fixes (PR #96814)

2024-06-28 Thread via cfe-commits
github-actions[bot] wrote: @jtb20 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, y

[clang] [Sema] LambdaScopeForCallOperatorInstantiationRAII - fix typo in early out logic (PR #96888)

2024-06-28 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon updated https://github.com/llvm/llvm-project/pull/96888 >From 7f6614d8df9a5ed2027f90d813695bc43f1044b2 Mon Sep 17 00:00:00 2001 From: Simon Pilgrim Date: Thu, 27 Jun 2024 11:09:32 +0100 Subject: [PATCH] [Sema] LambdaScopeForCallOperatorInstantiationRAII - fix typo in

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Alexandros Lamprineas via cfe-commits
@@ -11465,6 +11465,10 @@ static bool CheckMultiVersionFirstFunction(Sema &S, FunctionDecl *FD) { // otherwise it is treated as a normal function. if (TA && !TA->isDefaultVersion()) return false; + // The target_version attribute only causes Multiversioning if this +

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Alexandros Lamprineas via cfe-commits
https://github.com/labrinea updated https://github.com/llvm/llvm-project/pull/96628 >From ff4635208e9cd83c6735c95ebf12125ca737029a Mon Sep 17 00:00:00 2001 From: Alexandros Lamprineas Date: Tue, 25 Jun 2024 00:27:45 +0100 Subject: [PATCH 1/3] [clang][FMV] Do not omit explicit default target_ver

[clang] [Sema] LambdaScopeForCallOperatorInstantiationRAII - fix typo in early out logic (PR #96888)

2024-06-28 Thread Simon Pilgrim via cfe-commits
RKSimon wrote: Cheers - I'll push this (without the assert) in a moment - that shouldn't get in the way of working out why they aren't always paired. https://github.com/llvm/llvm-project/pull/96888 ___ cfe-commits mailing list cfe-commits@lists.llvm.o

[clang] [llvm] [llvm][AArch64][TableGen] Create a ProcessorAlias record (PR #96249)

2024-06-28 Thread Jon Roelofs via cfe-commits
https://github.com/jroelofs updated https://github.com/llvm/llvm-project/pull/96249 >From ee1389a36aac9eecf00513d98cc99787b2cfe17a Mon Sep 17 00:00:00 2001 From: Jon Roelofs Date: Thu, 20 Jun 2024 16:26:45 -0700 Subject: [PATCH 1/5] [llvm][AArch64][TableGen] Create a ProcessorAlias record. NFC

[clang] [clang] force libc linked with --no-as-needed when using compiler-rt (PR #95848)

2024-06-28 Thread Fangrui Song via cfe-commits
MaskRay wrote: (Sorry for the late reply. I have many notifications.) Can you print the relevant command line arguments before and after this patch? I think the current `-lc` is added in the normal no-as-needed mode: `... --no-as-needed -lc ` https://github.com/llvm/llvm-project/pull/95848 _

[clang] [Clang] Prevent null pointer dereferences in SVE tuple functions (PR #94267)

2024-06-28 Thread via cfe-commits
https://github.com/smanna12 updated https://github.com/llvm/llvm-project/pull/94267 >From 14e4f23d90d3a1590de5b9a1350ecf56aa89cc17 Mon Sep 17 00:00:00 2001 From: "Manna, Soumi" Date: Mon, 3 Jun 2024 11:17:33 -0700 Subject: [PATCH 1/5] [Clang] Prevent null pointer dereferencein SVE tuple functi

[clang] [Clang] Prevent null pointer dereferences in SVE tuple functions (PR #94267)

2024-06-28 Thread via cfe-commits
@@ -10226,7 +10229,7 @@ Value *CodeGenFunction::EmitSVETupleCreate(const SVETypeFlags &TypeFlags, ArrayRef Ops) { assert(TypeFlags.isTupleCreate() && "Expects TypleFlag isTupleCreate"); - auto *SrcTy = dyn_cast(Ops[0]->getType()

[clang] dac3661 - [Sema] LambdaScopeForCallOperatorInstantiationRAII - fix typo in early out logic (#96888)

2024-06-28 Thread via cfe-commits
Author: Simon Pilgrim Date: 2024-06-28T18:54:36+01:00 New Revision: dac366111e5560c117a06330efee14a2052d3a46 URL: https://github.com/llvm/llvm-project/commit/dac366111e5560c117a06330efee14a2052d3a46 DIFF: https://github.com/llvm/llvm-project/commit/dac366111e5560c117a06330efee14a2052d3a46.diff

[clang] [Sema] LambdaScopeForCallOperatorInstantiationRAII - fix typo in early out logic (PR #96888)

2024-06-28 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon closed https://github.com/llvm/llvm-project/pull/96888 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Prevent null pointer dereferences in SVE tuple functions (PR #94267)

2024-06-28 Thread via cfe-commits
https://github.com/smanna12 edited https://github.com/llvm/llvm-project/pull/94267 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][OpenMP] Implement `isOpenMPExecutableDirective` (PR #97089)

2024-06-28 Thread Krzysztof Parzyszek via cfe-commits
https://github.com/kparzysz created https://github.com/llvm/llvm-project/pull/97089 What is considered "executable" in clang differs slightly from the OpenMP's "executable" category. In addition to the executable category, subsidiary directives, and OMPD_error are considered executable. Imple

[clang] [clang][OpenMP] Implement `isOpenMPExecutableDirective` (PR #97089)

2024-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Krzysztof Parzyszek (kparzysz) Changes What is considered "executable" in clang differs slightly from the OpenMP's "executable" category. In addition to the executable category, subsidiary directives, and OMPD_error are considered executa

[clang] 592abf2 - [Driver] BuildOffloadingActions: Actually stabilize iteration order

2024-06-28 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2024-06-28T11:06:29-07:00 New Revision: 592abf29f9f7f73e6be28bef4574172125e4ab3f URL: https://github.com/llvm/llvm-project/commit/592abf29f9f7f73e6be28bef4574172125e4ab3f DIFF: https://github.com/llvm/llvm-project/commit/592abf29f9f7f73e6be28bef4574172125e4ab3f.diff

[clang] [clang][OpenMP] Implement `isOpenMPExecutableDirective` (PR #97089)

2024-06-28 Thread Alexey Bataev via cfe-commits
https://github.com/alexey-bataev edited https://github.com/llvm/llvm-project/pull/97089 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][OpenMP] Implement `isOpenMPExecutableDirective` (PR #97089)

2024-06-28 Thread Alexey Bataev via cfe-commits
https://github.com/alexey-bataev approved this pull request. LG with nits https://github.com/llvm/llvm-project/pull/97089 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][OpenMP] Implement `isOpenMPExecutableDirective` (PR #97089)

2024-06-28 Thread Alexey Bataev via cfe-commits
@@ -368,6 +368,14 @@ bool needsTaskBasedThreadLimit(OpenMPDirectiveKind DKind); /// is restricted only to memory order clauses of "OMPC_acquire", /// "OMPC_relaxed" and "OMPC_seq_cst". bool checkFailClauseParameter(OpenMPClauseKind FailClauseParameter); + +/// Checks if the spe

[clang] [clang][OpenMP] Implement `isOpenMPExecutableDirective` (PR #97089)

2024-06-28 Thread Alexey Bataev via cfe-commits
@@ -368,6 +368,14 @@ bool needsTaskBasedThreadLimit(OpenMPDirectiveKind DKind); /// is restricted only to memory order clauses of "OMPC_acquire", /// "OMPC_relaxed" and "OMPC_seq_cst". bool checkFailClauseParameter(OpenMPClauseKind FailClauseParameter); + +/// Checks if the spe

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Alexandros Lamprineas via cfe-commits
https://github.com/labrinea edited https://github.com/llvm/llvm-project/pull/96628 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [X86][CodeGen] security check cookie execute only when needed (PR #95904)

2024-06-28 Thread Fangrui Song via cfe-commits
@@ -0,0 +1,243 @@ +//=== X86FixupStackProtector.cpp Fix Stack Protector Call --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache

[clang] [llvm] [X86][CodeGen] security check cookie execute only when needed (PR #95904)

2024-06-28 Thread Fangrui Song via cfe-commits
@@ -0,0 +1,243 @@ +//=== X86FixupStackProtector.cpp Fix Stack Protector Call --===// MaskRay wrote: Since this is Windows specific (`/GS`) https://learn.microsoft.com/en-us/cpp/build/reference/gs-buffer-security-check?view=msvc-170 , a filename with

[clang] [clang][FMV] Do not omit explicit default target_version attribute. (PR #96628)

2024-06-28 Thread Alexandros Lamprineas via cfe-commits
https://github.com/labrinea edited https://github.com/llvm/llvm-project/pull/96628 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Implement function pointer type discrimination (PR #96992)

2024-06-28 Thread Akira Hatanaka via cfe-commits
@@ -3140,6 +3140,269 @@ ASTContext::getPointerAuthVTablePointerDiscriminator(const CXXRecordDecl *RD) { return llvm::getPointerAuthStableSipHash(Str); } +/// Encode a function type for use in the discriminator of a function pointer +/// type. We can't use the itanium scheme

[clang] [clang][OpenMP] Implement `isOpenMPExecutableDirective` (PR #97089)

2024-06-28 Thread Krzysztof Parzyszek via cfe-commits
@@ -368,6 +368,14 @@ bool needsTaskBasedThreadLimit(OpenMPDirectiveKind DKind); /// is restricted only to memory order clauses of "OMPC_acquire", /// "OMPC_relaxed" and "OMPC_seq_cst". bool checkFailClauseParameter(OpenMPClauseKind FailClauseParameter); + +/// Checks if the spe

[clang] [clang][OpenMP] Implement `isOpenMPExecutableDirective` (PR #97089)

2024-06-28 Thread Krzysztof Parzyszek via cfe-commits
https://github.com/kparzysz updated https://github.com/llvm/llvm-project/pull/97089 >From 789ec614d285e3fe632aae6280f6c4cf01746cdf Mon Sep 17 00:00:00 2001 From: Krzysztof Parzyszek Date: Fri, 28 Jun 2024 12:27:10 -0500 Subject: [PATCH 1/2] [clang][OpenMP] Implement `isOpenMPExecutableDirective

[clang] [clang][OpenMP] Implement `isOpenMPExecutableDirective` (PR #97089)

2024-06-28 Thread Krzysztof Parzyszek via cfe-commits
@@ -368,6 +368,14 @@ bool needsTaskBasedThreadLimit(OpenMPDirectiveKind DKind); /// is restricted only to memory order clauses of "OMPC_acquire", /// "OMPC_relaxed" and "OMPC_seq_cst". bool checkFailClauseParameter(OpenMPClauseKind FailClauseParameter); + +/// Checks if the spe

[clang] [clang][OpenMP] Implement `isOpenMPExecutableDirective` (PR #97089)

2024-06-28 Thread Alexey Bataev via cfe-commits
@@ -368,6 +368,14 @@ bool needsTaskBasedThreadLimit(OpenMPDirectiveKind DKind); /// is restricted only to memory order clauses of "OMPC_acquire", /// "OMPC_relaxed" and "OMPC_seq_cst". bool checkFailClauseParameter(OpenMPClauseKind FailClauseParameter); + +/// Checks if the spe

[clang] [clang] Implement function pointer type discrimination (PR #96992)

2024-06-28 Thread Akira Hatanaka via cfe-commits
@@ -470,6 +470,9 @@ ENUM_LANGOPT(StrictFlexArraysLevel, StrictFlexArraysLevelKind, 2, COMPATIBLE_VALUE_LANGOPT(MaxTokens, 32, 0, "Max number of tokens per TU or 0") +BENIGN_LANGOPT(FunctionPointerTypeDiscrimination, 1, 0, ahatanak wrote: I moved the langopt

[clang] [clang] Implement function pointer type discrimination (PR #96992)

2024-06-28 Thread Akira Hatanaka via cfe-commits
https://github.com/ahatanak updated https://github.com/llvm/llvm-project/pull/96992 >From cf22a4be007f7e6fdc6e4c17c1f32fa70440b123 Mon Sep 17 00:00:00 2001 From: Akira Hatanaka Date: Wed, 26 Jun 2024 13:02:31 -0700 Subject: [PATCH 1/3] [clang] Implement function pointer type discrimination Giv

[clang] [Driver] Support using toolchain libc and libc++ for baremetal (PR #96736)

2024-06-28 Thread via cfe-commits
https://github.com/PiJoules approved this pull request. https://github.com/llvm/llvm-project/pull/96736 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Support using toolchain libc and libc++ for baremetal (PR #96736)

2024-06-28 Thread Fangrui Song via cfe-commits
@@ -26,6 +26,20 @@ // RUN: --sysroot=%S/Inputs/baremetal_arm | FileCheck --check-prefix=CHECK-V6M-LIBINC %s // CHECK-V6M-LIBINC-NOT: "-internal-isystem" +// RUN: %clang %s -### --target=armv6m-none-eabi -o %t.out 2>&1 \ +// RUN: -ccc-install-dir %S/Inputs/basic_bareme

[clang] [Driver] Support using toolchain libc and libc++ for baremetal (PR #96736)

2024-06-28 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay approved this pull request. The description can specify the target triple you are adding support for. LGTM, but other folks more familiar with your planned changes need to stamp as well. https://github.com/llvm/llvm-project/pull/96736 _

[clang] [clang] Implement function pointer type discrimination (PR #96992)

2024-06-28 Thread Eli Friedman via cfe-commits
@@ -3140,6 +3140,269 @@ ASTContext::getPointerAuthVTablePointerDiscriminator(const CXXRecordDecl *RD) { return llvm::getPointerAuthStableSipHash(Str); } +/// Encode a function type for use in the discriminator of a function pointer +/// type. We can't use the itanium scheme

[clang] [clang] Implement function pointer type discrimination (PR #96992)

2024-06-28 Thread Eli Friedman via cfe-commits
@@ -3140,6 +3140,269 @@ ASTContext::getPointerAuthVTablePointerDiscriminator(const CXXRecordDecl *RD) { return llvm::getPointerAuthStableSipHash(Str); } +/// Encode a function type for use in the discriminator of a function pointer +/// type. We can't use the itanium scheme

[clang] [clang] Implement function pointer type discrimination (PR #96992)

2024-06-28 Thread Eli Friedman via cfe-commits
@@ -2220,6 +2220,11 @@ llvm::Constant *ConstantLValueEmitter::emitPointerAuthPointer(const Expr *E) { // The assertions here are all checked by Sema. assert(Result.Val.isLValue()); + auto *Base = Result.Val.getLValueBase().get(); + if (auto *Decl = dyn_cast_or_null(Base

[clang] [Clang] Prevent null pointer dereference in DiagnoseDeclAvailability() (PR #97095)

2024-06-28 Thread via cfe-commits
https://github.com/smanna12 created https://github.com/llvm/llvm-project/pull/97095 This patch adds an assertion in the DiagnoseDeclAvailabilit() function to ensure that the expected availability attribute is not null before they are passed to hasMatchingEnvironmentOrNone() to prevent potentia

[clang] [Clang] Prevent null pointer dereference in DiagnoseDeclAvailability() (PR #97095)

2024-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (smanna12) Changes This patch adds an assertion in the DiagnoseDeclAvailabilit() function to ensure that the expected availability attribute is not null before they are passed to hasMatchingEnvironmentOrNone() to prevent potential nu

[clang] [Clang] Introduce 'clang-nvlink-wrapper' to work around 'nvlink' (PR #96561)

2024-06-28 Thread Johannes Doerfert via cfe-commits
https://github.com/jdoerfert edited https://github.com/llvm/llvm-project/pull/96561 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Extend -Wnonportable-include-path with a warning about trailing whitespace or dots (PR #96960)

2024-06-28 Thread via cfe-commits
@@ -361,7 +361,11 @@ class NonportablePath : Warning< "non-portable path to file '%0'; specified path differs in case from file" " name on disk">; def pp_nonportable_path : NonportablePath, - InGroup>; + InGroup; +def pp_nonportable_path_trailing_whitespace : Warning< +

[clang] [clang] Implement function pointer type discrimination (PR #96992)

2024-06-28 Thread Daniil Kovalev via cfe-commits
@@ -3140,6 +3140,269 @@ ASTContext::getPointerAuthVTablePointerDiscriminator(const CXXRecordDecl *RD) { return llvm::getPointerAuthStableSipHash(Str); } +/// Encode a function type for use in the discriminator of a function pointer +/// type. We can't use the itanium scheme

[clang] [clang][CodeGen] Add query for a target's flat address space (PR #95728)

2024-06-28 Thread Eli Friedman via cfe-commits
efriedma-quic wrote: I mean, this is conceptually fine as far as it goes, but I'm not sure where we actually want to use it. As noted on the other PRs, llvm.used/llvm.global_ctors/llvm.global_dtors don't really want a flat address-space. The "address-space" for llvm.used, and for the "associ

[clang] [Clang] Prevent null pointer dereference in template deduction guide … (PR #97097)

2024-06-28 Thread via cfe-commits
https://github.com/smanna12 created https://github.com/llvm/llvm-project/pull/97097 …creation This patch addresses static analyzer concerns where `TSI` could be dereferenced after being assigned a null value from `SubstType` in `ConvertConstructorToDeductionGuideTransform()`. The fixes now c

[clang] [Clang] Prevent null pointer dereference in template deduction guide … (PR #97097)

2024-06-28 Thread via cfe-commits
https://github.com/smanna12 edited https://github.com/llvm/llvm-project/pull/97097 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Prevent null pointer dereference in template deduction guide creation (PR #97097)

2024-06-28 Thread via cfe-commits
https://github.com/smanna12 edited https://github.com/llvm/llvm-project/pull/97097 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Prevent null pointer dereference in template deduction guide creation (PR #97097)

2024-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (smanna12) Changes This patch addresses static analyzer concerns where `TSI` could be dereferenced after being assigned a null value from `SubstType` in `ConvertConstructorToDeductionGuideTransform()`. The fixes now check null value

[clang] Implement resource binding type prefix mismatch errors (PR #97103)

2024-06-28 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 created https://github.com/llvm/llvm-project/pull/97103 There are currently no diagnostics being emitted for when a resource is bound to a register with an incorrect binding type prefix. For example, a CBuffer type resource should be bound with a a binding type pref

[clang] Implement resource binding type prefix mismatch errors (PR #97103)

2024-06-28 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-hlsl Author: Joshua Batista (bob80905) Changes There are currently no diagnostics being emitted for when a resource is bound to a register with an incorrect binding type prefix. For example, a CBuffer type resource should be

[clang] 6b4a13a - [llvm][AArch64][TableGen] Create a ProcessorAlias record (#96249)

2024-06-28 Thread via cfe-commits
Author: Jon Roelofs Date: 2024-06-28T12:45:02-07:00 New Revision: 6b4a13a15aef64bf284612fcdbe07662b96a881b URL: https://github.com/llvm/llvm-project/commit/6b4a13a15aef64bf284612fcdbe07662b96a881b DIFF: https://github.com/llvm/llvm-project/commit/6b4a13a15aef64bf284612fcdbe07662b96a881b.diff L

<    1   2   3   4   5   >