[clang] [llvm] [WebAssembly] Change half-precision feature name to fp16. (PR #105434)

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

[clang] [Clang] Re-land Overflow Pattern Exclusions (PR #104889)

2024-08-21 Thread Vitaly Buka via cfe-commits
@@ -293,6 +293,48 @@ To silence reports from unsigned integer overflow, you can set ``-fsanitize-recover=unsigned-integer-overflow``, is particularly useful for providing fuzzing signal without blowing up logs. +Disabling instrumentation for common overflow patterns +

[clang] Create Texture Dimension attribute in HLSL (PR #104239)

2024-08-21 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 edited https://github.com/llvm/llvm-project/pull/104239 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Change CF intrinsics lowering to reconverge on predecessors. (PR #92809)

2024-08-21 Thread Gang Chen via cfe-commits
cmc-rep wrote: @alex-t Just curious about the status of this PR. Both this PR and the register-allocation PR by CD will have significant impact to the generated code. If we decide this is the right direction, then I feel it would be better to get it in earlier, so we can access its impact in

[clang] [Clang] Re-land Overflow Pattern Exclusions (PR #104889)

2024-08-21 Thread Justin Stitt via cfe-commits
@@ -293,6 +293,48 @@ To silence reports from unsigned integer overflow, you can set ``-fsanitize-recover=unsigned-integer-overflow``, is particularly useful for providing fuzzing signal without blowing up logs. +Disabling instrumentation for common overflow patterns +

[clang] [Clang] Fix null pointer dereference in enum debug info generation (PR #105556)

2024-08-21 Thread via cfe-commits
https://github.com/smanna12 ready_for_review https://github.com/llvm/llvm-project/pull/105556 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix null pointer dereference in enum debug info generation (PR #105556)

2024-08-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (smanna12) Changes This commit adds an assertion to the CreateTypeDefinition function in CGDebugInfo.cpp to verify that an enumeration definition (ED) is available before iterating over its enumerators. This prevents potential null p

[clang] [Clang] Fix null pointer dereference in enum debug info generation (PR #105556)

2024-08-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-debuginfo Author: None (smanna12) Changes This commit adds an assertion to the CreateTypeDefinition function in CGDebugInfo.cpp to verify that an enumeration definition (ED) is available before iterating over its enumerators. This prevents potential nu

[clang] [llvm] [AMDGPU] Convert AMDGPUResourceUsageAnalysis pass from Module to MF pass (PR #102913)

2024-08-21 Thread Matt Arsenault via cfe-commits
@@ -0,0 +1,533 @@ +; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -enable-ipra=0 -verify-machineinstrs < %s | FileCheck -check-prefix=GCN %s arsenm wrote: Can drop -verify-machineinstrs https://github.com/llvm/llvm-project/pull/102913 _

[clang] [llvm] [AMDGPU] Convert AMDGPUResourceUsageAnalysis pass from Module to MF pass (PR #102913)

2024-08-21 Thread Matt Arsenault via cfe-commits
@@ -0,0 +1,533 @@ +; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -enable-ipra=0 -verify-machineinstrs < %s | FileCheck -check-prefix=GCN %s + +; SGPR use may not seem equal to the sgpr use provided in comments as the latter includes extra sgprs (e.g., for vcc use). + +; Fun

[clang] [llvm] [AMDGPU] Convert AMDGPUResourceUsageAnalysis pass from Module to MF pass (PR #102913)

2024-08-21 Thread Matt Arsenault via cfe-commits
@@ -1,8 +1,8 @@ ; REQUIRES: asserts -; RUN: not --crash llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -filetype=null %s 2>&1 | FileCheck %s -; RUN: not --crash llc -O0 -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -filetype=null %s 2>&1 | FileCheck %s +; RUN: llc -mtriple=amdgcn-amd-am

[clang] [llvm] [AMDGPU] Convert AMDGPUResourceUsageAnalysis pass from Module to MF pass (PR #102913)

2024-08-21 Thread Matt Arsenault via cfe-commits
@@ -0,0 +1,533 @@ +; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -enable-ipra=0 -verify-machineinstrs < %s | FileCheck -check-prefix=GCN %s + +; SGPR use may not seem equal to the sgpr use provided in comments as the latter includes extra sgprs (e.g., for vcc use).

[clang] [llvm] [NFC][SetTheory] Refactor to use const pointers and range loops (PR #105544)

2024-08-21 Thread Rahul Joshi via cfe-commits
https://github.com/jurahul ready_for_review https://github.com/llvm/llvm-project/pull/105544 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [NFC][SetTheory] Refactor to use const pointers and range loops (PR #105544)

2024-08-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Rahul Joshi (jurahul) Changes - Refactor SetTheory code to use const pointers when possible. - Use auto for variables initialized using dyn_cast<>. - Use range based for loops and early continue. --- Full diff: https://github.com/llvm/llvm

[clang] Create Texture Dimension attribute in HLSL (PR #104239)

2024-08-21 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 updated https://github.com/llvm/llvm-project/pull/104239 >From aaa455933d3703b84634703fd4fcb5c815aa139e Mon Sep 17 00:00:00 2001 From: Joshua Batista Date: Wed, 14 Aug 2024 14:02:22 -0700 Subject: [PATCH 1/3] create texture dimension attr --- clang/include/clang/Ba

[clang] Create Texture Dimension attribute in HLSL (PR #104239)

2024-08-21 Thread Xiang Li via cfe-commits
@@ -0,0 +1,9 @@ +// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.0-compute -x hlsl -ast-dump -o - %s | FileCheck %s + + +// CHECK: -HLSLTextureDimensionAttr 0x{{[0-9a-f]+}} 1 +struct [[hlsl::texture_dimension(1)]] Eg1 { python3kgae wrote: Should we limit this a

[clang] [Clang] Add wraps attribute (for granular integer overflow handling) (PR #86618)

2024-08-21 Thread Oliver Hunt via cfe-commits
ojhunt wrote: I’m a little concerned about not allowing the attribute in C++ - the existence of other options in C++ does not mean they are an option (due to various and sundry restrictions of C++ version upgrades different projects have), but also you trivially end up in cases where header co

[clang] [llvm] [PGO][OpenMP] Instrumentation for GPU devices (Revision of #76587) (PR #102691)

2024-08-21 Thread Jan Patrick Lehr via cfe-commits
jplehr wrote: I did a few local run of this with our buildbot config and that appeared clean for the time being. https://github.com/llvm/llvm-project/pull/102691 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[clang] Create Texture Dimension attribute in HLSL (PR #104239)

2024-08-21 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 edited https://github.com/llvm/llvm-project/pull/104239 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Create Texture Dimension attribute in HLSL (PR #104239)

2024-08-21 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 edited https://github.com/llvm/llvm-project/pull/104239 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Create Texture Dimension attribute in HLSL (PR #104239)

2024-08-21 Thread Joshua Batista via cfe-commits
@@ -0,0 +1,9 @@ +// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.0-compute -x hlsl -ast-dump -o - %s | FileCheck %s + + +// CHECK: -HLSLTextureDimensionAttr 0x{{[0-9a-f]+}} 1 +struct [[hlsl::texture_dimension(1)]] Eg1 { bob80905 wrote: Yes, buffer resources won

[clang] [RFC][C++20][Modules] Fix crash when function and lambda inside loaded from different modules (PR #104512)

2024-08-21 Thread Dmitry Polukhin via cfe-commits
dmpolukhin wrote: > And I am still slightly unclear about how we load the wrong lambda first. Here is stack trace how decl from wrong module becomes canonical. Full stack trace ``` frame #0: 0x5e651e29 clang`clang::ASTDeclReader::VisitCXXRecordDeclImpl(this=0x7ffe0b70, D=0x00

[clang] [RFC][C++20][Modules] Fix crash when function and lambda inside loaded from different modules (PR #104512)

2024-08-21 Thread Dmitry Polukhin via cfe-commits
https://github.com/dmpolukhin converted_to_draft https://github.com/llvm/llvm-project/pull/104512 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [compiler-rt] [ubsan] Display correct runtime messages for negative _BitInt (PR #96240)

2024-08-21 Thread Björn Pettersson via cfe-commits
@@ -3298,22 +3315,40 @@ LValue CodeGenFunction::EmitPredefinedLValue(const PredefinedExpr *E) { /// { i16 TypeKind, i16 TypeInfo } /// \endcode /// -/// followed by an array of i8 containing the type name. TypeKind is 0 for an -/// integer, 1 for a floating point value, and

[clang] Allow installation of Clang .cfg files if they where generated. (PR #105580)

2024-08-21 Thread Vladimir Vereschaka via cfe-commits
https://github.com/vvereschaka created https://github.com/llvm/llvm-project/pull/105580 Add 'install-clang-configs' target to install generated configuration files into the destination 'bin' folder together with clang[++] executables. >From d0e2e1e4037519daaca93b34b069d395c24fc469 Mon Sep 17 0

[clang] [CMake] Install generated Clang .cfg file for cross ARM toolchains. NFC. (PR #105582)

2024-08-21 Thread Vladimir Vereschaka via cfe-commits
https://github.com/vvereschaka created https://github.com/llvm/llvm-project/pull/105582 Allow installation of .cfg generated file together with the clang executables. >From f4d4f7ea14d04631e6d1614f3533f00877440d76 Mon Sep 17 00:00:00 2001 From: Vladimir Vereschaka Date: Wed, 21 Aug 2024 13:43

[clang] [CMake] Install generated Clang .cfg file for cross ARM toolchains. NFC. (PR #105582)

2024-08-21 Thread Vladimir Vereschaka via cfe-commits
vvereschaka wrote: Depends on #105580 https://github.com/llvm/llvm-project/pull/105582 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CMake] Install generated Clang .cfg file for cross ARM toolchains. NFC. (PR #105582)

2024-08-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vladimir Vereschaka (vvereschaka) Changes Allow installation of .cfg generated file together with the clang executables. --- Full diff: https://github.com/llvm/llvm-project/pull/105582.diff 1 Files Affected: - (modified) clang/

[clang] [compiler-rt] [XRay] Add support for instrumentation of DSOs on x86_64 (PR #90959)

2024-08-21 Thread Fangrui Song via cfe-commits
@@ -2887,6 +2887,10 @@ def fxray_selected_function_group : HelpText<"When using -fxray-function-groups, select which group of functions to instrument. Valid range is 0 to fxray-function-groups - 1">, MarshallingInfoInt, "0">; +def fxray_enable_shared : Flag<["-"], "fxray-

[clang] [Clang] Add __builtin_is_within_lifetime to implement P2641R4's std::is_within_lifetime (PR #91895)

2024-08-21 Thread via cfe-commits
cor3ntin wrote: @ldionne and @philnik777 you have an opinion on that builtin? https://github.com/llvm/llvm-project/pull/91895 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Add nuw attribute to GEPs (PR #105496)

2024-08-21 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic approved this pull request. LGTM; the approach here seems appropriate. (The EmitCheckedInBoundsGEP API could probably use a refactor so we don't have calls to isSignedOverflowDefined() scattered all over the place, but that's a separate issue.) https://github.

[clang] [clang] Emit nuw GEPs for array subscript expressions (PR #103088)

2024-08-21 Thread Hari Limaye via cfe-commits
hazzlim wrote: > > adding nuw is also valid for signed indices here > > I don't understand how you think this would work; a-1 and a+-1 are required > to produce the same result. The thinking here RE signed indices was that in this special case, where the base address of the GEP is the start o

[clang] f709cd5 - Revert "[Coroutines] Salvage the debug information for coroutine frames within optimizations"

2024-08-21 Thread Dmitri Gribenko via cfe-commits
Author: Dmitri Gribenko Date: 2024-08-21T23:49:45+02:00 New Revision: f709cd5add0ea36bb14259e9716bd74e5c762128 URL: https://github.com/llvm/llvm-project/commit/f709cd5add0ea36bb14259e9716bd74e5c762128 DIFF: https://github.com/llvm/llvm-project/commit/f709cd5add0ea36bb14259e9716bd74e5c762128.dif

[clang] [llvm] [RISCV] Add CSRs and an instruction for Smctr and Ssctr extensions. (PR #105148)

2024-08-21 Thread Craig Topper via cfe-commits
https://github.com/topperc updated https://github.com/llvm/llvm-project/pull/105148 >From b7a0e87790b1d17201728dba1a9c2149fc7d9a17 Mon Sep 17 00:00:00 2001 From: Craig Topper Date: Tue, 20 Aug 2024 10:13:56 -0700 Subject: [PATCH 1/3] [RISCV] Add CSRs and a instruction for Smctr and Ssctr exten

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-08-21 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ edited https://github.com/llvm/llvm-project/pull/101583 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-08-21 Thread Artem Dergachev via cfe-commits
@@ -443,6 +449,396 @@ AST_MATCHER(ArraySubscriptExpr, isSafeArraySubscript) { return false; } +AST_MATCHER_P(CallExpr, hasNumArgs, unsigned, Num) { + return Node.getNumArgs() == Num; +} + +namespace libc_func_matchers { +// Under `libc_func_matchers`, define a set of matche

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-08-21 Thread Artem Dergachev via cfe-commits
@@ -1025,6 +1421,92 @@ class DataInvocationGadget : public WarningGadget { DeclUseList getClaimedVarUseSites() const override { return {}; } }; +class UnsafeLibcFunctionCallGadget : public WarningGadget { + const CallExpr *const Call; + constexpr static const char *const T

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-08-21 Thread Artem Dergachev via cfe-commits
@@ -12383,6 +12383,13 @@ def warn_unsafe_buffer_operation : Warning< "%select{unsafe pointer operation|unsafe pointer arithmetic|" "unsafe buffer access|function introduces unsafe buffer manipulation|unsafe invocation of span::data}0">, InGroup, DefaultIgnore; +def warn_

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-08-21 Thread Artem Dergachev via cfe-commits
@@ -12383,6 +12383,13 @@ def warn_unsafe_buffer_operation : Warning< "%select{unsafe pointer operation|unsafe pointer arithmetic|" "unsafe buffer access|function introduces unsafe buffer manipulation|unsafe invocation of span::data}0">, InGroup, DefaultIgnore; +def warn_

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-08-21 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ commented: Mostly LGTM! I don't have major concerns. https://github.com/llvm/llvm-project/pull/101583 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-08-21 Thread Artem Dergachev via cfe-commits
@@ -443,6 +449,396 @@ AST_MATCHER(ArraySubscriptExpr, isSafeArraySubscript) { return false; } +AST_MATCHER_P(CallExpr, hasNumArgs, unsigned, Num) { + return Node.getNumArgs() == Num; +} + +namespace libc_func_matchers { +// Under `libc_func_matchers`, define a set of matche

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-08-21 Thread Artem Dergachev via cfe-commits
@@ -0,0 +1,101 @@ +// RUN: %clang_cc1 -std=c++20 -Wno-all -Wunsafe-buffer-usage \ +// RUN:-verify %s + +typedef struct {} FILE; +void memcpy(); +void __asan_memcpy(); +void strcpy(); +void strcpy_s(); +void wcscpy_s(); +unsigned strlen( const char* str ); +int fprintf(

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-08-21 Thread Artem Dergachev via cfe-commits
@@ -443,6 +448,368 @@ AST_MATCHER(ArraySubscriptExpr, isSafeArraySubscript) { return false; } +namespace libc_fun_disjoint_inner_matchers { +// `libc_fun_disjoint_inner_matchers` covers a set of matchers that match +// disjoint node sets. They all take a `CoreName`, which

[clang] Fix the behavior of __COUNT__ macros when PCH is enabled (PR #105591)

2024-08-21 Thread Giuliano Belinassi via cfe-commits
https://github.com/giulianobelinassi created https://github.com/llvm/llvm-project/pull/105591 Previoulsy, calling `ASTUnit::LoadFromCompilerInvocation` with `PrecompilePreambleAfterNParses > 0` caused the `__COUNT__` macro value to be restarted. This commit fixes this by remembering the value

[clang] Fix the behavior of __COUNT__ macros when PCH is enabled (PR #105591)

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

[clang] Fix the behavior of __COUNT__ macros when PCH is enabled (PR #105591)

2024-08-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-modules @llvm/pr-subscribers-clang Author: Giuliano Belinassi (giulianobelinassi) Changes Previoulsy, calling `ASTUnit::LoadFromCompilerInvocation` with `PrecompilePreambleAfterNParses > 0` caused the `__COUNT__` macro value to be restarted. Thi

[clang] Fix the behavior of __COUNT__ macros when PCH is enabled (PR #105591)

2024-08-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 ab86fc74c04ff508f909b7b6131df1551dd833fc 259653e147aff62c70dd2c16d46886ae2c92412d --e

[clang] Fix the behavior of __COUNT__ macros when PCH is enabled (PR #105591)

2024-08-21 Thread Giuliano Belinassi via cfe-commits
https://github.com/giulianobelinassi updated https://github.com/llvm/llvm-project/pull/105591 >From 914427af9b83848ac395bbff663133aadf387161 Mon Sep 17 00:00:00 2001 From: Giuliano Belinassi Date: Wed, 21 Aug 2024 18:31:36 -0300 Subject: [PATCH] Fix the behavior of __COUNT__ macros when PCH is

[clang] [DirectX] Add DirectXTargetCodeGenInfo (PR #104856)

2024-08-21 Thread Helena Kotas via cfe-commits
https://github.com/hekota updated https://github.com/llvm/llvm-project/pull/104856 >From 44e814b925a1ad8ac40fe6904542cbade516c065 Mon Sep 17 00:00:00 2001 From: Helena Kotas Date: Mon, 19 Aug 2024 13:34:13 -0700 Subject: [PATCH 1/3] [DirectX] Add DirectXTargetCodeGenInfo Adds TargetCodeGenInfo

[clang] [DirectX] Add DirectXTargetCodeGenInfo (PR #104856)

2024-08-21 Thread Helena Kotas via cfe-commits
@@ -0,0 +1,54 @@ +//===- DirectX.cpp +//---===// hekota wrote: Oops ;) https://github.com/llvm/llvm-project/pull/104856 ___ cfe-commits mailing list cfe-commits@l

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-08-21 Thread Ziqing Luo via cfe-commits
@@ -0,0 +1,101 @@ +// RUN: %clang_cc1 -std=c++20 -Wno-all -Wunsafe-buffer-usage \ +// RUN:-verify %s + +typedef struct {} FILE; +void memcpy(); +void __asan_memcpy(); +void strcpy(); +void strcpy_s(); +void wcscpy_s(); +unsigned strlen( const char* str ); +int fprintf(

[clang] [-Wunsafe-buffer-usage] Warning Libc functions (PR #101583)

2024-08-21 Thread Ziqing Luo via cfe-commits
@@ -0,0 +1,101 @@ +// RUN: %clang_cc1 -std=c++20 -Wno-all -Wunsafe-buffer-usage \ +// RUN:-verify %s + +typedef struct {} FILE; +void memcpy(); +void __asan_memcpy(); +void strcpy(); +void strcpy_s(); +void wcscpy_s(); +unsigned strlen( const char* str ); +int fprintf(

[clang] [llvm] [NFC][SetTheory] Refactor to use const pointers and range loops (PR #105544)

2024-08-21 Thread Craig Topper via cfe-commits
https://github.com/topperc approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/105544 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] clang-format: Add "AllowShortNamespacesOnASingleLine" option (PR #105597)

2024-08-21 Thread Galen Elias via cfe-commits
https://github.com/galenelias created https://github.com/llvm/llvm-project/pull/105597 This addresses: https://github.com/llvm/llvm-project/issues/101363 which is a resurrection of a previously opened but never completed review: https://reviews.llvm.org/D11851 The feature is to allow code lik

[clang] clang-format: Add "AllowShortNamespacesOnASingleLine" option (PR #105597)

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

[clang] clang-format: Add "AllowShortNamespacesOnASingleLine" option (PR #105597)

2024-08-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Galen Elias (galenelias) Changes This addresses: https://github.com/llvm/llvm-project/issues/101363 which is a resurrection of a previously opened but never completed review: https://reviews.llvm.org/D11851 The feature is to allow

[clang] [Clang] Implement C++26’s P2893R3 ‘Variadic friends’ (PR #101448)

2024-08-21 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: @Sirraide CWG looked at 2917 last week, and changed the status of the issue. Can you revisit your test for it? https://cplusplus.github.io/CWG/issues/2917.html https://github.com/llvm/llvm-project/pull/101448 ___ cfe-commits mailing li

[clang] [Clang] Implement C++26’s P2893R3 ‘Variadic friends’ (PR #101448)

2024-08-21 Thread via cfe-commits
Sirraide wrote: > CWG looked at 2917 last week, and changed the status of the issue. Can you > revisit your test for it? Ah, something that was previously accepted is now disallowed; I’ll implement that tomorrow. https://github.com/llvm/llvm-project/pull/101448 ___

[clang] clang-format: Add "AllowShortNamespacesOnASingleLine" option (PR #105597)

2024-08-21 Thread Galen Elias via cfe-commits
https://github.com/galenelias updated https://github.com/llvm/llvm-project/pull/105597 >From 3819c15c8c6258d1d29a38fcfb71db8567fb34e5 Mon Sep 17 00:00:00 2001 From: Galen Elias Date: Wed, 21 Aug 2024 15:46:35 -0700 Subject: [PATCH] clang-format: Add "AllowShortNamespacesOnASingleLine" option T

[clang] clang-format: Add "AllowShortNamespacesOnASingleLine" option (PR #105597)

2024-08-21 Thread Galen Elias via cfe-commits
https://github.com/galenelias updated https://github.com/llvm/llvm-project/pull/105597 >From 4118b7dde9adbee7b6aaf5d094d34cb6b64f6c77 Mon Sep 17 00:00:00 2001 From: Galen Elias Date: Wed, 21 Aug 2024 16:33:42 -0700 Subject: [PATCH] clang-format: Add "AllowShortNamespacesOnASingleLine" option T

[clang] Create Texture Dimension attribute in HLSL (PR #104239)

2024-08-21 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 updated https://github.com/llvm/llvm-project/pull/104239 >From aaa455933d3703b84634703fd4fcb5c815aa139e Mon Sep 17 00:00:00 2001 From: Joshua Batista Date: Wed, 14 Aug 2024 14:02:22 -0700 Subject: [PATCH 1/4] create texture dimension attr --- clang/include/clang/Ba

[clang] [llvm] [WebAssembly] Change half-precision feature name to fp16. (PR #105434)

2024-08-21 Thread Thomas Lively via cfe-commits
https://github.com/tlively approved this pull request. https://github.com/llvm/llvm-project/pull/105434 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [WebAssembly] Change half-precision feature name to fp16. (PR #105434)

2024-08-21 Thread Brendan Dahl via cfe-commits
https://github.com/brendandahl updated https://github.com/llvm/llvm-project/pull/105434 >From e992578b7269c365e619fe201e7cc703149c7067 Mon Sep 17 00:00:00 2001 From: Brendan Dahl Date: Tue, 20 Aug 2024 21:55:47 + Subject: [PATCH] [WebAssembly] Change half-precision feature name to fp16. Th

[clang] 64e4643 - [BPF] introduce __attribute__((bpf_fastcall)) (#105417)

2024-08-21 Thread via cfe-commits
Author: eddyz87 Date: 2024-08-22T03:40:56+03:00 New Revision: 64e464349bfca0d90e07f6db2f710d4d53cdacd4 URL: https://github.com/llvm/llvm-project/commit/64e464349bfca0d90e07f6db2f710d4d53cdacd4 DIFF: https://github.com/llvm/llvm-project/commit/64e464349bfca0d90e07f6db2f710d4d53cdacd4.diff LOG:

[clang] [llvm] [BPF] introduce __attribute__((bpf_fastcall)) (PR #105417)

2024-08-21 Thread via cfe-commits
https://github.com/eddyz87 closed https://github.com/llvm/llvm-project/pull/105417 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix the behavior of __COUNT__ macros when PCH is enabled (PR #105591)

2024-08-21 Thread Giuliano Belinassi via cfe-commits
https://github.com/giulianobelinassi updated https://github.com/llvm/llvm-project/pull/105591 >From 3a1a241f925e7b6dcc6c8701ab83b5fb04f18853 Mon Sep 17 00:00:00 2001 From: Giuliano Belinassi Date: Wed, 21 Aug 2024 18:31:36 -0300 Subject: [PATCH] Fix the behavior of __COUNT__ macros when PCH is

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

2024-08-21 Thread Damyan Pepper via cfe-commits
@@ -31,6 +31,7 @@ class SemaHLSL : public SemaBase { public: SemaHLSL(Sema &S); + HLSLResourceAttr *mergeHLSLResourceAttr(bool CBuffer); damyanp wrote: I don't think `mergeHLSLResourceAttr` exists any more? https://github.com/llvm/llvm-project/pull/97103

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

2024-08-21 Thread Damyan Pepper via cfe-commits
@@ -0,0 +1,71 @@ +// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library -x hlsl -o - -fsyntax-only %s -verify + +// This test validates the diagnostics that are emitted when a variable with a "resource" type +// is bound to a register using the register annotation + +/* +tem

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

2024-08-21 Thread Damyan Pepper via cfe-commits
https://github.com/damyanp requested changes to this pull request. https://github.com/llvm/llvm-project/pull/97103 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2024-08-21 Thread Damyan Pepper via cfe-commits
@@ -459,7 +467,408 @@ void SemaHLSL::handleResourceClassAttr(Decl *D, const ParsedAttr &AL) { D->addAttr(HLSLResourceClassAttr::Create(getASTContext(), RC, ArgLoc)); } -void SemaHLSL::handleResourceBindingAttr(Decl *D, const ParsedAttr &AL) { +struct RegisterBindingFlags {

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

2024-08-21 Thread Damyan Pepper via cfe-commits
@@ -0,0 +1,131 @@ +// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library -x hlsl -o - -fsyntax-only %s -verify + +// TODO: Implement "Buffer", we use a substitute UDT +// to test the 't' binding type for this test. + +template +struct [[hlsl::resource_class(SRV)]] MyTemplated

[clang] [clang-format] Don't insert a space between :: and * (PR #105043)

2024-08-21 Thread Owen Pan via cfe-commits
https://github.com/owenca updated https://github.com/llvm/llvm-project/pull/105043 >From 4aa47d190a84ecd0432dc9b6db1d38b296f4df23 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Tue, 20 Aug 2024 06:44:41 -0700 Subject: [PATCH 1/2] [clang-format] Don't insert a space between :: and * Also, don't

[clang] [clang-format] Don't insert a space between :: and * (PR #105043)

2024-08-21 Thread Owen Pan via cfe-commits
@@ -4591,7 +4589,9 @@ bool TokenAnnotator::spaceRequiredBetween(const AnnotatedLine &Line, if (!BeforeLeft) return false; if (BeforeLeft->is(tok::coloncolon)) { - return Left.is(tok::star) && + const auto *Prev = BeforeLeft->Previous; + return Left

[clang] [clang-format] Don't insert a space between :: and * (PR #105043)

2024-08-21 Thread Owen Pan via cfe-commits
@@ -4591,7 +4589,9 @@ bool TokenAnnotator::spaceRequiredBetween(const AnnotatedLine &Line, if (!BeforeLeft) return false; if (BeforeLeft->is(tok::coloncolon)) { - return Left.is(tok::star) && + const auto *Prev = BeforeLeft->Previous; + return Left

[clang] 0ca77f6 - [RISCV] Add CSRs and an instruction for Smctr and Ssctr extensions. (#105148)

2024-08-21 Thread via cfe-commits
Author: Craig Topper Date: 2024-08-21T19:23:07-07:00 New Revision: 0ca77f6656a772624a591261957f6b313a0d544e URL: https://github.com/llvm/llvm-project/commit/0ca77f6656a772624a591261957f6b313a0d544e DIFF: https://github.com/llvm/llvm-project/commit/0ca77f6656a772624a591261957f6b313a0d544e.diff

[clang] [llvm] [RISCV] Add CSRs and an instruction for Smctr and Ssctr extensions. (PR #105148)

2024-08-21 Thread Craig Topper via cfe-commits
https://github.com/topperc closed https://github.com/llvm/llvm-project/pull/105148 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [DirectX] Add DirectXTargetCodeGenInfo (PR #104856)

2024-08-21 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,53 @@ +//===- DirectX.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: Apa

[clang] [DirectX] Add DirectXTargetCodeGenInfo (PR #104856)

2024-08-21 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/104856 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [DirectX] Add DirectXTargetCodeGenInfo (PR #104856)

2024-08-21 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl edited https://github.com/llvm/llvm-project/pull/104856 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][AArch64] Fix typo with colon-separated syntax for system registers (PR #105608)

2024-08-21 Thread via cfe-commits
https://github.com/v01dXYZ created https://github.com/llvm/llvm-project/pull/105608 The range for Op0 was set to 1 instead of 3. The description of e493f17784a9c6000ca7c92499233490f1d1 visually explains the encoding of implementation-defined system registers. Gobolt: https://godbolt.org/z

[clang] [Clang][AArch64] Fix typo with colon-separated syntax for system registers (PR #105608)

2024-08-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-aarch64 @llvm/pr-subscribers-backend-arm Author: None (v01dXYZ) Changes The range for Op0 was set to 1 instead of 3. The description of e493f17784a9c6000ca7c92499233490f1d1 visually explains the encoding of implementation-defined system reg

[clang] [Clang][AArch64] Fix typo with colon-separated syntax for system registers (PR #105608)

2024-08-21 Thread via cfe-commits
https://github.com/v01dXYZ updated https://github.com/llvm/llvm-project/pull/105608 >From faef073dab6d45f1b50fc877e5cf336a3427ecfa Mon Sep 17 00:00:00 2001 From: v01dxyz Date: Thu, 22 Aug 2024 03:55:27 +0200 Subject: [PATCH] [Clang][AArch64] Fix typo with colon-separated syntax for system regi

[clang] [Sparc] Add flags to enable errata workaround pass for GR712RC and UT700 (PR #104742)

2024-08-21 Thread via cfe-commits
koachan wrote: > We have also developed some performance related patches for the Sparc > backend, but it has been difficult to get them upstreamed as, as you say, few > people are working on the Sparc backend. This is off-topic but is it possible for you to submit it (or if I can see those)?

[clang] [llvm] [PGO][OpenMP] Instrumentation for GPU devices (Revision of #76587) (PR #102691)

2024-08-21 Thread Ethan Luis McDonough via cfe-commits
https://github.com/EthanLuisMcDonough updated https://github.com/llvm/llvm-project/pull/102691 >From 24b1a99a1c014e1015fbba137430c5c6f3e414c5 Mon Sep 17 00:00:00 2001 From: Ethan Luis McDonough Date: Fri, 28 Jun 2024 12:39:19 -0500 Subject: [PATCH 1/6] Changes from old gpuprof branch --- clan

[clang] [Clang][AArch64] Fix typo with colon-separated syntax for system registers (PR #105608)

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

[clang] [clang][NFC] remove resolved issue from StandardCPlusPlusModules.rst (PR #105610)

2024-08-21 Thread via cfe-commits
https://github.com/h-vetinari created https://github.com/llvm/llvm-project/pull/105610 This landed as https://github.com/llvm/llvm-project/pull/102287 for main & https://github.com/llvm/llvm-project/pull/102561 for 19.x CC @ChuanqiXu9 >From 866b4834ec847c8459defd1b63b5d227d03e2761 Mon Sep 17

[clang] [clang][NFC] remove resolved issue from StandardCPlusPlusModules.rst (PR #105610)

2024-08-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (h-vetinari) Changes This landed as https://github.com/llvm/llvm-project/pull/102287 for main & https://github.com/llvm/llvm-project/pull/102561 for 19.x CC @ChuanqiXu9 --- Full diff: https://github.com/llvm/llvm-project/pull/10561

[clang] [clang][NFC] remove resolved issue from StandardCPlusPlusModules.rst (PR #105610)

2024-08-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-modules Author: None (h-vetinari) Changes This landed as https://github.com/llvm/llvm-project/pull/102287 for main & https://github.com/llvm/llvm-project/pull/102561 for 19.x CC @ChuanqiXu9 --- Full diff: https://github.com/llvm/llvm-project/pu

[clang] [flang] [llvm] [mlir] Make MMIWP not have ownership over MMI + Remove Move Constructor of MMI + Make MMI Only Use and Externally-Created MCContext (PR #105541)

2024-08-21 Thread Matin Raayai via cfe-commits
https://github.com/matinraayai ready_for_review https://github.com/llvm/llvm-project/pull/105541 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [flang][driver] Add pre-processing type to `.i` (pre-processed) files (PR #104664)

2024-08-21 Thread Kareem Ergawy via cfe-commits
ergawy wrote: > Please bear with me, it's been a while since I've touched this and also, I am > afk 😅 No worries. I am new to this part of the code and might be misinterpreting things myself. > IIRC, the generated temp files (e.g. *.i) are used for the subsequent > compilation phases. So, af

[clang] [clang][bytecode] Fix 'if consteval' in non-constant contexts (PR #104707)

2024-08-21 Thread Timm Baeder via cfe-commits
@@ -4368,8 +4363,19 @@ template bool Compiler::visitIfStmt(const IfStmt *IS) { if (!visitDeclStmt(CondDecl)) return false; - if (!this->visitBool(IS->getCond())) -return false; + // Compile condition. + if (IS->isNonNegatedConsteval()) { +if (!this->emit

[clang] [flang] [flang][driver] Add pre-processing type to `.i` (pre-processed) files (PR #104664)

2024-08-21 Thread Kareem Ergawy via cfe-commits
https://github.com/ergawy updated https://github.com/llvm/llvm-project/pull/104664 >From 205ed1497a145664471055b24ea0391f93b30711 Mon Sep 17 00:00:00 2001 From: ergawy Date: Sat, 17 Aug 2024 00:20:11 -0500 Subject: [PATCH] [flang][driver] Add pre-processing type to `.i` files This diff allows

[clang] [RISCV][FMV] Support target_clones (PR #85786)

2024-08-21 Thread Piyou Chen via cfe-commits
@@ -2854,10 +2854,121 @@ void CodeGenFunction::EmitMultiVersionResolver( case llvm::Triple::aarch64: EmitAArch64MultiVersionResolver(Resolver, Options); return; + case llvm::Triple::riscv32: + case llvm::Triple::riscv64: +EmitRISCVMultiVersionResolver(Resolver,

[clang] [llvm] [PGO][OpenMP] Instrumentation for GPU devices (Revision of #76587) (PR #102691)

2024-08-21 Thread Ethan Luis McDonough via cfe-commits
https://github.com/EthanLuisMcDonough updated https://github.com/llvm/llvm-project/pull/102691 >From 24b1a99a1c014e1015fbba137430c5c6f3e414c5 Mon Sep 17 00:00:00 2001 From: Ethan Luis McDonough Date: Fri, 28 Jun 2024 12:39:19 -0500 Subject: [PATCH 1/6] Changes from old gpuprof branch --- clan

[clang] [clang-format] Correctly compute SplitPenalty of TrailingReturnArrow (PR #105613)

2024-08-21 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/105613 Fixes #105480. >From 4bb6856deb83b89a5530efca2155da40663753e1 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Wed, 21 Aug 2024 21:45:12 -0700 Subject: [PATCH] [clang-format] Correctly compute SplitPenalty of Trai

[clang] [clang-format] Correctly compute SplitPenalty of TrailingReturnArrow (PR #105613)

2024-08-21 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes Fixes #105480. --- Full diff: https://github.com/llvm/llvm-project/pull/105613.diff 2 Files Affected: - (modified) clang/lib/Format/TokenAnnotator.cpp (+2-2) - (modified) clang/unittests/Format/TokenAnn

[libunwind] [libunwind] Stop installing the mach-o module map (PR #105616)

2024-08-21 Thread Ian Anderson via cfe-commits
https://github.com/ian-twilightcoder created https://github.com/llvm/llvm-project/pull/105616 libunwind shouldn't know that compact_unwind_encoding.h is part of a MachO module that it doesn't own. Delete the mach-o module map, and let whatever is in charge of the mach-o directory be the one to

[clang] [clang][NFC] remove resolved issue from StandardCPlusPlusModules.rst (PR #105610)

2024-08-21 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. Oh, I forgot it. Thanks~ https://github.com/llvm/llvm-project/pull/105610 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] ded6dd2 - [clang][NFC] remove resolved issue from StandardCPlusPlusModules.rst (#105610)

2024-08-21 Thread via cfe-commits
Author: h-vetinari Date: 2024-08-22T13:32:40+08:00 New Revision: ded6dd244cce3e683201a668ce321d4474baa8fb URL: https://github.com/llvm/llvm-project/commit/ded6dd244cce3e683201a668ce321d4474baa8fb DIFF: https://github.com/llvm/llvm-project/commit/ded6dd244cce3e683201a668ce321d4474baa8fb.diff LO

[clang] [clang][NFC] remove resolved issue from StandardCPlusPlusModules.rst (PR #105610)

2024-08-21 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 closed https://github.com/llvm/llvm-project/pull/105610 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

<    1   2   3   4   >