[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -63,6 +64,7 @@ class LLVM_LIBRARY_VISIBILITY WebAssemblyTargetInfo : public TargetInfo { bool HasMutableGlobals = false; bool HasNontrappingFPToInt = false; bool HasReferenceTypes = false; + bool HasCallIndirectOverlong = false; aheejin wrote: Nit:

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -326,7 +326,7 @@ void TableSection::addTable(InputTable *table) { // to assign table number 0 to the indirect function table. for (const auto *culprit : out.importSec->importedSymbols) { if (isa(culprit)) { - error("object file not built with 're

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -63,6 +67,10 @@ def FeatureReferenceTypes : SubtargetFeature<"reference-types", "HasReferenceTypes", "true", "Enable reference types">; +def FeatureCallIndirectOverlong : aheejin wrote: Nit: This can go after `FeatureBulkMemory

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -49,6 +50,7 @@ class WebAssemblySubtarget final : public WebAssemblyGenSubtargetInfo { bool HasMutableGlobals = false; bool HasNontrappingFPToInt = false; bool HasReferenceTypes = false; + bool HasCallIndirectOverlong = false; aheejin wrote: Nit: Th

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -284,7 +285,7 @@ void ObjFile::addLegacyIndirectFunctionTableIfNeeded( return; // It's possible for an input to define tables and also use the indirect - // function table, but forget to compile with -mattr=+reference-types. + // function table, but forget to compil

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -68,6 +72,10 @@ def HasReferenceTypes : Predicate<"Subtarget->hasReferenceTypes()">, AssemblerPredicate<(all_of FeatureReferenceTypes), "reference-types">; +def HasCallIndirectOverlong : aheejin wrote: Nit: This can go after `HasBulkMemoryOpt` for

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin edited https://github.com/llvm/llvm-project/pull/117087 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin edited https://github.com/llvm/llvm-project/pull/117087 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [llvm][NFC] `APFloat`: Add missing semantics to enum (PR #117291)

2024-11-21 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 836d2dcf601a736804670ba6fbc85ec5cfbfeff1 35848f59ef8a680e0ed264c5fb03edb7d4a6d6ff --e

[clang] [llvm] [llvm][NFC] `APFloat`: Add missing semantics to enum (PR #117291)

2024-11-21 Thread Matthias Springer via cfe-commits
matthias-springer wrote: There are various places in `APFloat.h` and `APFloat.cpp` that contain switch-case / if-check sequences for checking the type of semantics. I'm trying to reduce these. What I had in mind: * Removing `APFloatBase::IEEEhalf()`, `APFloatBase::BFloat()`, ..., and use a si

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-21 Thread Utkarsh Saxena via cfe-commits
@@ -268,6 +268,40 @@ void Sema::inferLifetimeBoundAttribute(FunctionDecl *FD) { } } +static bool IsPointerLikeType(QualType QT) { + QT = QT.getNonReferenceType(); + if (QT->isPointerType()) +return true; + auto *RD = QT->getAsCXXRecordDecl(); + if (!RD) +return f

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-21 Thread Utkarsh Saxena via cfe-commits
@@ -268,6 +268,40 @@ void Sema::inferLifetimeBoundAttribute(FunctionDecl *FD) { } } +static bool IsPointerLikeType(QualType QT) { + QT = QT.getNonReferenceType(); + if (QT->isPointerType()) +return true; + auto *RD = QT->getAsCXXRecordDecl(); + if (!RD) +return f

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-21 Thread Utkarsh Saxena via cfe-commits
@@ -1757,6 +1757,9 @@ class Sema final : public SemaBase { /// Add [[clang:::lifetimebound]] attr for std:: functions and methods. void inferLifetimeBoundAttribute(FunctionDecl *FD); + /// Add [[clang:::lifetime_capture(this)]] to STL container methods. u

[clang] [clang] Infer lifetime_capture_by for STL containers (PR #117122)

2024-11-21 Thread Utkarsh Saxena via cfe-commits
@@ -268,6 +268,40 @@ void Sema::inferLifetimeBoundAttribute(FunctionDecl *FD) { } } +static bool IsPointerLikeType(QualType QT) { usx95 wrote: Done. https://github.com/llvm/llvm-project/pull/117122 ___ cfe-commit

[clang] [clang][APINotes] Do not add duplicate lifetimebound annotation (PR #117194)

2024-11-21 Thread Egor Zhdan via cfe-commits
https://github.com/egorzhdan approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/117194 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL] Implement elementwise firstbitlow builtin (PR #116858)

2024-11-21 Thread Steven Perron via cfe-commits
@@ -3158,6 +3172,166 @@ bool SPIRVInstructionSelector::selectFirstBitHigh(Register ResVReg, } } +bool SPIRVInstructionSelector::selectFirstBitLow16(Register ResVReg, + const SPIRVType *ResType, +

[clang] [llvm] [HLSL] Implement elementwise firstbitlow builtin (PR #116858)

2024-11-21 Thread Steven Perron via cfe-commits
https://github.com/s-perron edited https://github.com/llvm/llvm-project/pull/116858 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL] Implement elementwise firstbitlow builtin (PR #116858)

2024-11-21 Thread Steven Perron via cfe-commits
@@ -0,0 +1,104 @@ +; RUN: llc -verify-machineinstrs -O0 -mtriple=spirv-unknown-unknown %s -o - | FileCheck %s +; RUN: %if spirv-tools %{ llc -O0 -mtriple=spirv-unknown-unknown %s -o - -filetype=obj | spirv-val %} + +; CHECK-DAG: [[glsl_450_ext:%.+]] = OpExtInstImport "GLSL.std.4

[clang] [clang][APINotes] Do not add duplicate lifetimebound annotation (PR #117194)

2024-11-21 Thread Saleem Abdulrasool via cfe-commits
https://github.com/compnerd approved this pull request. https://github.com/llvm/llvm-project/pull/117194 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ObjC] Enable diagnose_if on Objective-C methods (PR #115056)

2024-11-21 Thread via cfe-commits
apple-fcloutier wrote: I think there's limited value to diagnose_if on blocks, since that will apply to a variable of block type and not to the block type. In other words, given this: ```c void (^block)(int *) = ^(int *p) __attribute__((diagnose_if(p == 0, "p is NULL"))) { ... }; block(0); ``

[clang] [TargetVersion] Only enable on RISC-V and AArch64 (PR #115991)

2024-11-21 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-ppc64le-linux` running on `ppc64le-sanitizer` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/72/builds/5536 Here is the relevant piece of the bu

[clang] [TBAA] Only emit pointer tbaa metedata for record types. (PR #116991)

2024-11-21 Thread John McCall via cfe-commits
@@ -230,6 +243,12 @@ llvm::MDNode *CodeGenTBAA::getTypeInfoHelper(const Type *Ty) { ->getString(); TyName = Name; } else { + // Be conservative if the type isn't a RecordType. We are specifically rjmccall wrote: ```suggestion

[clang] [TBAA] Only emit pointer tbaa metedata for record types. (PR #116991)

2024-11-21 Thread John McCall via cfe-commits
@@ -18,10 +20,23 @@ struct A {}; // CHECK-LABEL: define {{.*}} @_Z1g const int *(A::*const *g(const int *(A::* const **p)[3], int *(A::***q)[3]))[3] { + // CHECK: load ptr, ptr %p.addr // CHECK: load ptr, {{.*}}, !tbaa ![[MEMPTR_TBAA:[^,]*]] const int *(A::*const *x)[3

[clang] [llvm] [HLSL] Implement elementwise firstbitlow builtin (PR #116858)

2024-11-21 Thread Sarah Spall via cfe-commits
@@ -3158,6 +3172,166 @@ bool SPIRVInstructionSelector::selectFirstBitHigh(Register ResVReg, } } +bool SPIRVInstructionSelector::selectFirstBitLow16(Register ResVReg, + const SPIRVType *ResType, +

[clang] [TBAA] Only emit pointer tbaa metedata for record types. (PR #116991)

2024-11-21 Thread John McCall via cfe-commits
@@ -205,14 +205,27 @@ llvm::MDNode *CodeGenTBAA::getTypeInfoHelper(const Type *Ty) { llvm::MDNode *AnyPtr = createScalarTypeNode("any pointer", getChar(), Size); if (!CodeGenOpts.PointerTBAA) return AnyPtr; -// Compute the depth of the pointer and generate a

[clang] [rtsan] NFC: Update docs with suppress_equal_stacks (PR #117187)

2024-11-21 Thread Florian Mayer via cfe-commits
https://github.com/fmayer approved this pull request. https://github.com/llvm/llvm-project/pull/117187 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2024-11-21 Thread Paul Kirth via cfe-commits
@@ -0,0 +1,731 @@ +//===-- Mustache.cpp --===// +// +// 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: Ap

[clang] [CUDA] pass -fno-threadsafe-statics to GPU sub-compilations. (PR #117074)

2024-11-21 Thread Artem Belevich via cfe-commits
https://github.com/Artem-B updated https://github.com/llvm/llvm-project/pull/117074 >From 1c8829a1defa6dd06aacb9a2047e7f79db238e2b Mon Sep 17 00:00:00 2001 From: Artem Belevich Date: Wed, 20 Nov 2024 14:24:00 -0800 Subject: [PATCH 1/2] [CUDA] pass -fno-threadsafe-statics to GPU sub-compilation

[clang] [CUDA] pass -fno-threadsafe-statics to GPU sub-compilations. (PR #117074)

2024-11-21 Thread Artem Belevich via cfe-commits
Artem-B wrote: Done. https://github.com/llvm/llvm-project/pull/117074 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Prevent potential null pointer dereferences (PR #117176)

2024-11-21 Thread via cfe-commits
@@ -627,7 +627,7 @@ class Analyzer { IsNoexcept = isNoexcept(FD); } else if (auto *BD = dyn_cast(D)) { if (auto *TSI = BD->getSignatureAsWritten()) { -auto *FPT = TSI->getType()->getAs(); +auto *FPT = TSI->getType()->castAs();

[clang] [llvm] AMDGPU: Add v_mfma_f32_16x16x32_bf16 for gfx950 (PR #117053)

2024-11-21 Thread Sirish Pande via cfe-commits
https://github.com/srpande approved this pull request. lgtm https://github.com/llvm/llvm-project/pull/117053 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Prevent potential null pointer dereferences (PR #117176)

2024-11-21 Thread via cfe-commits
@@ -627,7 +627,7 @@ class Analyzer { IsNoexcept = isNoexcept(FD); } else if (auto *BD = dyn_cast(D)) { if (auto *TSI = BD->getSignatureAsWritten()) { -auto *FPT = TSI->getType()->getAs(); +auto *FPT = TSI->getType()->castAs();

[clang] [Clang] Prevent potential null pointer dereferences (PR #117176)

2024-11-21 Thread via cfe-commits
@@ -627,7 +627,7 @@ class Analyzer { IsNoexcept = isNoexcept(FD); } else if (auto *BD = dyn_cast(D)) { if (auto *TSI = BD->getSignatureAsWritten()) { -auto *FPT = TSI->getType()->getAs(); +auto *FPT = TSI->getType()->castAs();

[clang] Added more descriptive message (issue 116808) (PR #117201)

2024-11-21 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: Thank you for the improved wording! You also need to update some tests so they're expecting the new wording instead of the old wording. Precommit CI found the failures: https://buildkite.com/llvm-project/github-pull-requests/builds/121942#01934feb-9f8

[clang] [TBAA] Only emit pointer tbaa metedata for record types. (PR #116991)

2024-11-21 Thread Florian Hahn via cfe-commits
https://github.com/fhahn edited https://github.com/llvm/llvm-project/pull/116991 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Prevent potential null pointer dereferences (PR #117176)

2024-11-21 Thread via cfe-commits
https://github.com/Sirraide edited https://github.com/llvm/llvm-project/pull/117176 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Implement a header only distance intrinsic (PR #117240)

2024-11-21 Thread Damyan Pepper via cfe-commits
@@ -853,6 +853,45 @@ float3 degrees(float3); _HLSL_BUILTIN_ALIAS(__builtin_hlsl_elementwise_degrees) float4 degrees(float4); +//===--===// +// distance builtins +//===--

[clang] [TBAA] Don't emit pointer tbaa for unnamed structs or unions. (PR #116596)

2024-11-21 Thread Florian Hahn via cfe-commits
https://github.com/fhahn closed https://github.com/llvm/llvm-project/pull/116596 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 41a0c66 - [TBAA] Don't emit pointer tbaa for unnamed structs or unions. (#116596)

2024-11-21 Thread via cfe-commits
Author: Florian Hahn Date: 2024-11-21T22:20:27Z New Revision: 41a0c66f4379d43dcf7643bced22b9048e7ace96 URL: https://github.com/llvm/llvm-project/commit/41a0c66f4379d43dcf7643bced22b9048e7ace96 DIFF: https://github.com/llvm/llvm-project/commit/41a0c66f4379d43dcf7643bced22b9048e7ace96.diff LOG:

[clang] [clang] Warn on mismatched RequiresCapability attributes (PR #67520)

2024-11-21 Thread Aaron Puchert via cfe-commits
@@ -4054,7 +4054,9 @@ def warn_acquired_before : Warning< def warn_acquired_before_after_cycle : Warning< "cycle in acquired_before/after dependencies, starting with '%0'">, InGroup, DefaultIgnore; - +def warn_attribute_mismatch : Warning< + "attribute mismatch between fun

[clang] [llvm] Introduce symbol versioning for clang-cpp (PR #116556)

2024-11-21 Thread Aaron Puchert via cfe-commits
aaronpuchert wrote: > LLVM Buildbot has detected a new failure on builder `clang-ppc64-aix` running > on `aix-ppc64` while building `clang,llvm` at step 3 "clean-build-dir". > > Full details are available at: > https://lab.llvm.org/buildbot/#/builders/64/builds/1496 > Here is the relevant piec

[clang] [Clang] Enable -fpointer-tbaa by default. (PR #117244)

2024-11-21 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 a62e1c8eddcda420abec57976dc48f97669277dc 58f3bcf35074b0d2e823cf0804e637d1f78dc53e --e

[clang] [llvm] AMDGPU: Add v_smfmac_f32_32x32x32_bf16 for gfx950 (PR #117212)

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

[clang] 95ddc1a - AMDGPU: Add v_smfmac_f32_16x16x64_bf16 for gfx950 (#117211)

2024-11-21 Thread via cfe-commits
Author: Matt Arsenault Date: 2024-11-21T14:46:43-08:00 New Revision: 95ddc1a63b47a5dcfb044632eec2e840d41ff793 URL: https://github.com/llvm/llvm-project/commit/95ddc1a63b47a5dcfb044632eec2e840d41ff793 DIFF: https://github.com/llvm/llvm-project/commit/95ddc1a63b47a5dcfb044632eec2e840d41ff793.diff

[clang] [llvm] AMDGPU: Add v_smfmac_f32_16x16x64_bf16 for gfx950 (PR #117211)

2024-11-21 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm closed https://github.com/llvm/llvm-project/pull/117211 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [emacs][clang-format] Add elisp API for clang-format on git diffs (PR #112792)

2024-11-21 Thread via cfe-commits
goldsteinn wrote: > > All things considered, I think requiring `vc` is a lot less intrusive than > > essentially our own `vc` wrapper > > Not sure what you mean exactly by a wrapper, if git/diff logic can be > abstracted away - that seems a net gain. If ugly/fragile logic is required to >

[clang] [Webkit Checkers] Introduce a Webkit checker for memory unsafe casts (PR #114606)

2024-11-21 Thread Rashmi Mudduluru via cfe-commits
https://github.com/t-rasmud updated https://github.com/llvm/llvm-project/pull/114606 >From cc19550fdbaca4b77e90de57c472a31a8c3f8293 Mon Sep 17 00:00:00 2001 From: Rashmi Mudduluru Date: Fri, 1 Nov 2024 14:10:50 -0700 Subject: [PATCH 1/8] [Webkit Checkers] Introduce a Webkit checker for memory

[clang] [llvm] AMDGPU: Add v_smfmac_f32_32x32x32_bf16 for gfx950 (PR #117212)

2024-11-21 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm updated https://github.com/llvm/llvm-project/pull/117212 >From aa1fd6ceeb474654c0f46638b2022decc50dbc2b Mon Sep 17 00:00:00 2001 From: Matt Arsenault Date: Fri, 2 Feb 2024 15:01:35 +0530 Subject: [PATCH] AMDGPU: Add v_smfmac_f32_32x32x32_bf16 for gfx950 --- clang/inc

[clang] [llvm] AMDGPU: Add v_smfmac_f32_32x32x32_bf16 for gfx950 (PR #117212)

2024-11-21 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm updated https://github.com/llvm/llvm-project/pull/117212 >From 173e920981ebd6edce3a0cf1794ab65facad94dd Mon Sep 17 00:00:00 2001 From: Matt Arsenault Date: Fri, 2 Feb 2024 15:01:35 +0530 Subject: [PATCH] AMDGPU: Add v_smfmac_f32_32x32x32_bf16 for gfx950 --- clang/inc

[clang] 42dd114 - AMDGPU: Add v_smfmac_f32_32x32x32_bf16 for gfx950 (#117212)

2024-11-21 Thread via cfe-commits
Author: Matt Arsenault Date: 2024-11-21T14:52:11-08:00 New Revision: 42dd114a464885a93daa7d2beacc3437cde6ea01 URL: https://github.com/llvm/llvm-project/commit/42dd114a464885a93daa7d2beacc3437cde6ea01 DIFF: https://github.com/llvm/llvm-project/commit/42dd114a464885a93daa7d2beacc3437cde6ea01.diff

[clang] [llvm] AMDGPU: Add v_smfmac_i32_16x16x128_i8 for gfx950 (PR #117213)

2024-11-21 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm updated https://github.com/llvm/llvm-project/pull/117213 >From 944451f6a075dc775b496c62868bec4570757d65 Mon Sep 17 00:00:00 2001 From: Matt Arsenault Date: Fri, 2 Feb 2024 15:52:26 +0530 Subject: [PATCH] AMDGPU: Add v_smfmac_i32_16x16x128_i8 for gfx950 --- clang/incl

[clang] [llvm] AMDGPU: Add v_smfmac_i32_16x16x128_i8 for gfx950 (PR #117213)

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

[clang] [llvm] AMDGPU: Add v_smfmac_f32_32x32x32_bf16 for gfx950 (PR #117212)

2024-11-21 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm closed https://github.com/llvm/llvm-project/pull/117212 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Add ByteAddressBuffer definition to HLSLExternalSemaSource #113477 (PR #116699)

2024-11-21 Thread Helena Kotas via cfe-commits
https://github.com/hekota edited https://github.com/llvm/llvm-project/pull/116699 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

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

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

2024-11-21 Thread Julian Schmidt via cfe-commits
@@ -0,0 +1,41 @@ +//===--- UseIntegerSignComparisonCheck.h - clang-tidy ---*- C++ -*-===// +// +// 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: Apa

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

2024-11-21 Thread Julian Schmidt via cfe-commits
https://github.com/5chmidti requested changes to this pull request. The check will currently not flag the use of literals like so: ```c++ void foo(unsigned short *uArray){ uArray[0] <= 10; } ``` https://godbolt.org/z/a6W9xGcMY because they do not contain an implicit cast. Only one of the tw

[clang] [llvm] AMDGPU: Add v_smfmac_f32_16x16x128_bf8_bf8 for gfx950 (PR #117232)

2024-11-21 Thread Matt Arsenault via cfe-commits
arsenm wrote: ### Merge activity * **Nov 21, 7:53 PM EST**: A user started a stack merge that includes this pull request via [Graphite](https://app.graphite.dev/github/pr/llvm/llvm-project/117232). https://github.com/llvm/llvm-project/pull/117232 _

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -310,6 +332,18 @@ bool WebAssemblyTargetInfo::handleTargetFeatures( << Feature << "-target-feature"; return false; } + + // The reference-types feature included the change to `call_indirect` + // encodings to support overlong immediates. + if (HasReferenceTy

[clang] [lld] [llvm] [RISCV] Make A implies Zaamo and Zalrsc (PR #116907)

2024-11-21 Thread Jim Lin via cfe-commits
https://github.com/tclin914 closed https://github.com/llvm/llvm-project/pull/116907 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Webkit Checkers] Introduce a Webkit checker for memory unsafe casts (PR #114606)

2024-11-21 Thread Ryosuke Niwa via cfe-commits
@@ -0,0 +1,185 @@ +//===- MemoryUnsafeCastChecker.cpp -*- C++ -*-==// +// +// 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: Apach

[clang] [Webkit Checkers] Introduce a Webkit checker for memory unsafe casts (PR #114606)

2024-11-21 Thread Ryosuke Niwa via cfe-commits
@@ -0,0 +1,185 @@ +//===- MemoryUnsafeCastChecker.cpp -*- C++ -*-==// +// +// 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: Apach

[clang] [flang] [flang][Driver] Support -print-supported-cpus and associated aliases (PR #117199)

2024-11-21 Thread Tarun Prabhu via cfe-commits
https://github.com/tarunprabhu updated https://github.com/llvm/llvm-project/pull/117199 >From a7d176ed8c7aa9d22944600a301fb690b845935d Mon Sep 17 00:00:00 2001 From: Tarun Prabhu Date: Thu, 21 Nov 2024 09:53:49 -0700 Subject: [PATCH 1/5] [flang][Driver] Support -print-supported-cpus and associ

[clang] [ObjC] Enable diagnose_if on Objective-C methods (PR #115056)

2024-11-21 Thread Akira Hatanaka via cfe-commits
ahatanak wrote: > There is almost certainly value in introducing a base class beneath > ObjCMethodDecl and FunctionDecl that is both a NamedDecl and a DeclContext, > because I'm not the first person to run into this problem. If I do the work, > whose review/approval do we need? Is it deep enou

[clang] [llvm] AMDGPU: Add v_smfmac_f32_32x32x64_bf8_bf8 for gfx950 (PR #117256)

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

[clang] [llvm] AMDGPU: Add v_smfmac_f32_32x32x64_bf8_bf8 for gfx950 (PR #117256)

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

[clang] [AMDGPU] Do not allow the region address space to be converted to generic (PR #117171)

2024-11-21 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. Should also forbid the buffers (probably should forbid using the buffers at all) https://github.com/llvm/llvm-project/pull/117171 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://li

[clang] [llvm] [SanitizerCoverage] Add gated tracing callbacks support to trace-cmp (PR #113227)

2024-11-21 Thread via cfe-commits
https://github.com/thetruestblue edited https://github.com/llvm/llvm-project/pull/113227 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Dan Gohman via cfe-commits
https://github.com/sunfishcode updated https://github.com/llvm/llvm-project/pull/117087 >From 48808d43f41b61a419790fd25f99b5e897e5a419 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Fri, 11 Oct 2024 04:30:32 -0700 Subject: [PATCH 1/8] [WebAssembly] Define call-indirect-overlong and bulk-memor

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Dan Gohman via cfe-commits
https://github.com/sunfishcode updated https://github.com/llvm/llvm-project/pull/117087 >From 48808d43f41b61a419790fd25f99b5e897e5a419 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Fri, 11 Oct 2024 04:30:32 -0700 Subject: [PATCH 1/9] [WebAssembly] Define call-indirect-overlong and bulk-memor

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Dan Gohman via cfe-commits
https://github.com/sunfishcode updated https://github.com/llvm/llvm-project/pull/117087 >From 48808d43f41b61a419790fd25f99b5e897e5a419 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Fri, 11 Oct 2024 04:30:32 -0700 Subject: [PATCH 01/10] [WebAssembly] Define call-indirect-overlong and bulk-mem

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Dan Gohman via cfe-commits
https://github.com/sunfishcode updated https://github.com/llvm/llvm-project/pull/117087 >From 48808d43f41b61a419790fd25f99b5e897e5a419 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Fri, 11 Oct 2024 04:30:32 -0700 Subject: [PATCH 01/11] [WebAssembly] Define call-indirect-overlong and bulk-mem

[clang] [Driver] Support fprofile-sample-use= for CL (PR #117282)

2024-11-21 Thread Haohai Wen via cfe-commits
https://github.com/HaohaiWen created https://github.com/llvm/llvm-project/pull/117282 Sampling PGO has already been supported on Windows. This patch adds /fprofile-sample-use= /fprofile-sample-use: /fno-profile-sample-use and supports -fprofile-sample-use= for CL. >From 8fbe3ed35afd38e2d7b36a89

[clang] [Driver] Support fprofile-sample-use= for CL (PR #117282)

2024-11-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: Haohai Wen (HaohaiWen) Changes Sampling PGO has already been supported on Windows. This patch adds /fprofile-sample-use= /fprofile-sample-use: /fno-profile-sample-use and supports -fprofile-sample-use= for CL. --- Full diff: https:/

[clang] [Driver] Support fprofile-sample-use= for CL (PR #117282)

2024-11-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Haohai Wen (HaohaiWen) Changes Sampling PGO has already been supported on Windows. This patch adds /fprofile-sample-use= /fprofile-sample-use: /fno-profile-sample-use and supports -fprofile-sample-use= for CL. --- Full diff: https://github

[clang] [llvm] AMDGPU: Add v_smfmac_f32_32x32x64_bf8_bf8 for gfx950 (PR #117256)

2024-11-21 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm updated https://github.com/llvm/llvm-project/pull/117256 >From 8fdaaf05f2bd983315c3b9d2b11985ad926261d2 Mon Sep 17 00:00:00 2001 From: Matt Arsenault Date: Sat, 3 Feb 2024 20:48:16 +0530 Subject: [PATCH] AMDGPU: Add v_smfmac_f32_32x32x64_bf8_bf8 for gfx950 --- clang/

[clang] [llvm] AMDGPU: Add v_smfmac_f32_16x16x128_bf8_bf8 for gfx950 (PR #117232)

2024-11-21 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm updated https://github.com/llvm/llvm-project/pull/117232 >From e85d020ba41586a1892822f8825f3e07c112b39d Mon Sep 17 00:00:00 2001 From: Matt Arsenault Date: Fri, 2 Feb 2024 21:37:17 +0530 Subject: [PATCH] AMDGPU: Add v_smfmac_f32_16x16x128_bf8_bf8 for gfx950 --- clang

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -79,6 +81,8 @@ void WebAssemblyTargetInfo::getTargetDefines(const LangOptions &Opts, Builder.defineMacro("__wasm_atomics__"); if (HasBulkMemory) Builder.defineMacro("__wasm_bulk_memory__"); + if (HasBulkMemoryOpt) +Builder.defineMacro("__wasm_bulk_memory_opt_

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -114,19 +122,20 @@ def : ProcessorModel<"mvp", NoSchedModel, []>; // consideration given to available support in relevant engines and tools, and // the importance of the features. def : ProcessorModel<"generic", NoSchedModel, - [FeatureBulkMemory, Featur

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -114,19 +122,20 @@ def : ProcessorModel<"mvp", NoSchedModel, []>; // consideration given to available support in relevant engines and tools, and // the importance of the features. def : ProcessorModel<"generic", NoSchedModel, - [FeatureBulkMemory, Featur

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -265,6 +279,14 @@ bool WebAssemblyTargetInfo::handleTargetFeatures( HasReferenceTypes = false; continue; } +if (Feature == "+call-indirect-overlong") { + HasCallIndirectOverlong = true; + continue; +} +if (Feature == "-call-indirect-over

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin edited https://github.com/llvm/llvm-project/pull/117087 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin commented: All of the below are nits on feature name ordering: https://github.com/llvm/llvm-project/pull/117087 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commi

[clang] [llvm] [HLSL] Print struct body definition when within the context of defining a target extension type (PR #115971)

2024-11-21 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 updated https://github.com/llvm/llvm-project/pull/115971 >From 7413ceb21a6e0ac9212ef6317763ee0eff559612 Mon Sep 17 00:00:00 2001 From: Joshua Batista Date: Tue, 12 Nov 2024 16:44:00 -0800 Subject: [PATCH 1/4] print struct body within target ext ty context --- .../t

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Dan Gohman via cfe-commits
@@ -79,6 +81,8 @@ void WebAssemblyTargetInfo::getTargetDefines(const LangOptions &Opts, Builder.defineMacro("__wasm_atomics__"); if (HasBulkMemory) Builder.defineMacro("__wasm_bulk_memory__"); + if (HasBulkMemoryOpt) +Builder.defineMacro("__wasm_bulk_memory_opt_

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Dan Gohman via cfe-commits
https://github.com/sunfishcode updated https://github.com/llvm/llvm-project/pull/117087 >From 48808d43f41b61a419790fd25f99b5e897e5a419 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Fri, 11 Oct 2024 04:30:32 -0700 Subject: [PATCH 1/4] [WebAssembly] Define call-indirect-overlong and bulk-memor

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -34,6 +34,15 @@ WebAssemblySubtarget::initializeSubtargetDependencies(StringRef CPU, CPU = "generic"; ParseSubtargetFeatures(CPU, /*TuneCPU*/ CPU, FS); + + // reference-types implies call-indirect-overlong + if (HasReferenceTypes) +HasCallIndirectOverlong = tru

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 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 668f2c7fab288db90d474a7f6f72b11e5a120328 2423264970431230d5057de41f4bc2285613fd80 --e

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Dan Gohman via cfe-commits
@@ -114,19 +122,20 @@ def : ProcessorModel<"mvp", NoSchedModel, []>; // consideration given to available support in relevant engines and tools, and // the importance of the features. def : ProcessorModel<"generic", NoSchedModel, - [FeatureBulkMemory, Featur

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Dan Gohman via cfe-commits
@@ -34,6 +34,15 @@ WebAssemblySubtarget::initializeSubtargetDependencies(StringRef CPU, CPU = "generic"; ParseSubtargetFeatures(CPU, /*TuneCPU*/ CPU, FS); + + // reference-types implies call-indirect-overlong + if (HasReferenceTypes) +HasCallIndirectOverlong = tru

[clang] 836d2dc - AMDGPU: Add v_smfmac_f32_16x16x128_fp8_fp8 for gfx950 (#117235)

2024-11-21 Thread via cfe-commits
Author: Matt Arsenault Date: 2024-11-21T17:06:06-08:00 New Revision: 836d2dcf601a736804670ba6fbc85ec5cfbfeff1 URL: https://github.com/llvm/llvm-project/commit/836d2dcf601a736804670ba6fbc85ec5cfbfeff1 DIFF: https://github.com/llvm/llvm-project/commit/836d2dcf601a736804670ba6fbc85ec5cfbfeff1.diff

[clang] [llvm] AMDGPU: Add v_smfmac_f32_16x16x128_fp8_bf8 for gfx950 (PR #117234)

2024-11-21 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm updated https://github.com/llvm/llvm-project/pull/117234 >From f18dccf5d17ae5a90e1fa58fc50a7211e6ae19e7 Mon Sep 17 00:00:00 2001 From: Matt Arsenault Date: Sat, 3 Feb 2024 20:15:31 +0530 Subject: [PATCH] AMDGPU: Add v_smfmac_f32_16x16x128_fp8_bf8 for gfx950 --- clang

[clang] [llvm] AMDGPU: Add v_smfmac_f32_16x16x128_fp8_fp8 for gfx950 (PR #117235)

2024-11-21 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm closed https://github.com/llvm/llvm-project/pull/117235 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] AMDGPU: Add v_smfmac_f32_32x32x64_bf8_bf8 for gfx950 (PR #117256)

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

[clang] [Clang] Fix -Wunused-private-field false negative with defaulted comparison operators (PR #116871)

2024-11-21 Thread Chris White via cfe-commits
https://github.com/whiteio edited https://github.com/llvm/llvm-project/pull/116871 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] Handle [[assume(cond)]] as __builtin_assume(cond) (PR #116462)

2024-11-21 Thread Vinay Deshmukh via cfe-commits
vinay-deshmukh wrote: > We should have a look at what the codegen does with this attribute, or even > with the builtin assume call - because we should do something very similar. > We should gather the constraints and apply them, just like codegen does (I > assume). I think a suitable place to

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

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

[clang] [llvm] AMDGPU: Add v_smfmac_f32_16x16x128_bf8_fp8 for gfx950 (PR #117233)

2024-11-21 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm updated https://github.com/llvm/llvm-project/pull/117233 >From 4855f1c470565870e949fcac47a234508e39586c Mon Sep 17 00:00:00 2001 From: Matt Arsenault Date: Fri, 2 Feb 2024 23:21:12 +0530 Subject: [PATCH] AMDGPU: Add v_smfmac_f32_16x16x128_bf8_fp8 for gfx950 --- clang

[clang] [lld] [llvm] [WebAssembly] Define call-indirect-overlong and bulk-memory-opt features (PR #117087)

2024-11-21 Thread Heejin Ahn via cfe-commits
@@ -114,19 +122,20 @@ def : ProcessorModel<"mvp", NoSchedModel, []>; // consideration given to available support in relevant engines and tools, and // the importance of the features. def : ProcessorModel<"generic", NoSchedModel, - [FeatureBulkMemory, Featur

[clang] [llvm] [HLSL] Adding Flatten and Branch if attributes (PR #116331)

2024-11-21 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi commented: LGTM from me, and thanks for cleaning this up so promptly. Also, for the record, if you want to put things in MD_prof, please do add support to ProfDataUtils. We're happy to support all the various usecases, so if your stuff belongs there, please add it.

<    1   2   3   4   5   6   >