[clang] [clang]: fix overload resolution in case of converting const value reference to an rvalue reference. (PR #133035)

2025-03-25 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung updated https://github.com/llvm/llvm-project/pull/133035 >From fb9260dd796ae687a000beb550198d155b772625 Mon Sep 17 00:00:00 2001 From: changkhothuychung Date: Wed, 26 Mar 2025 00:55:26 -0400 Subject: [PATCH 1/5] initial commit --- clang/lib/Sema/SemaOverlo

[clang] [clang-repl] Implement LoadDynamicLibrary for clang-repl wasm use cases (PR #133037)

2025-03-25 Thread Vassil Vassilev via cfe-commits
@@ -711,6 +712,14 @@ llvm::Error Interpreter::Undo(unsigned N) { } llvm::Error Interpreter::LoadDynamicLibrary(const char *name) { +#ifdef __EMSCRIPTEN__ + void *handle = dlopen(name, RTLD_NOW | RTLD_GLOBAL); + if (!handle) { +llvm::errs() << dlerror() << '\n'; +retu

[clang] [clang]: fix overload resolution in case of converting const value reference to an rvalue reference. (PR #133035)

2025-03-25 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung ready_for_review https://github.com/llvm/llvm-project/pull/133035 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang]: fix overload resolution in case of converting const value reference to an rvalue reference. (PR #133035)

2025-03-25 Thread Nhat Nguyen via cfe-commits
changkhothuychung wrote: the failing test in clang/test/SemaCXX/copy-assignment.cpp seems like to be another clang bug - https://godbolt.org/z/79bWMscx9 https://github.com/llvm/llvm-project/pull/133035 ___ cfe-commits mailing list cfe-commits@lists.l

[clang] [clang]: fix overload resolution in case of converting const value reference to an rvalue reference. (PR #133035)

2025-03-25 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung updated https://github.com/llvm/llvm-project/pull/133035 >From fb9260dd796ae687a000beb550198d155b772625 Mon Sep 17 00:00:00 2001 From: changkhothuychung Date: Wed, 26 Mar 2025 00:55:26 -0400 Subject: [PATCH 1/4] initial commit --- clang/lib/Sema/SemaOverlo

[clang] [clang]: fix overload resolution in case of converting const value reference to an rvalue reference. (PR #133035)

2025-03-25 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung updated https://github.com/llvm/llvm-project/pull/133035 >From fb9260dd796ae687a000beb550198d155b772625 Mon Sep 17 00:00:00 2001 From: changkhothuychung Date: Wed, 26 Mar 2025 00:55:26 -0400 Subject: [PATCH 1/3] initial commit --- clang/lib/Sema/SemaOverlo

[clang] [llvm] [RISCV] Implement the implications of C extension (PR #132259)

2025-03-25 Thread Sam Elliott via cfe-commits
https://github.com/lenary commented: I commented about the predicates (before i saw the other comments). I thought they'd be ok to do in a follow-up, but you should just to the refactoring now as it won't quite be NFC as I expected. https://github.com/llvm/llvm-project/pull/132259

[clang] [clang]: fix overload resolution in case of converting const value reference to an rvalue reference. (PR #133035)

2025-03-25 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 80d5185bd4288c12e9d5aa0fe2e00f2f4e6397d7 693049e2bdfe31c1243c9d9a5a7bf59363a2b9b1 --e

[libclc] [libclc] Update license headers (PR #132070)

2025-03-25 Thread Kristof Beyls via cfe-commits
kbeyls wrote: Thank you for this change, @frasercrmck ! This all looks good to me. https://github.com/llvm/llvm-project/pull/132070 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang] improve class type sugar preservation in pointers to members (PR #130537)

2025-03-25 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `openmp-offload-libc-amdgpu-runtime` running on `omp-vega20-1` while building `clang-tools-extra,clang` at step 7 "Add check check-offload". Full details are available at: https://lab.llvm.org/buildbot/#/builders/73/builds/149

[clang] Reapply "[clang][bytecode] Implement __builtin_{wcscmp,wcsncmp} (#132… (PR #132963)

2025-03-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes …723)" This reverts commit 1e2ad6793ac205607e7c809283cf69e1cc36a69a. Fix the previous commit on big-endian hosts by _not_ falling through to the `uint8_t` code path. --- Full diff: https://github.com/llv

[clang] [clang]: fix overload resolution in case of converting const value reference to an rvalue reference. (PR #133035)

2025-03-25 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung updated https://github.com/llvm/llvm-project/pull/133035 >From fb9260dd796ae687a000beb550198d155b772625 Mon Sep 17 00:00:00 2001 From: changkhothuychung Date: Wed, 26 Mar 2025 00:55:26 -0400 Subject: [PATCH 1/2] initial commit --- clang/lib/Sema/SemaOverlo

[clang] default clause replaced by otherwise clause for metadirective in OpenMP 5.2 (PR #128640)

2025-03-25 Thread Urvi Rav via cfe-commits
https://github.com/ravurvi20 updated https://github.com/llvm/llvm-project/pull/128640 >From 6ebd5991788608fbd104ea9c23230912044462d3 Mon Sep 17 00:00:00 2001 From: Urvi Rav Date: Tue, 25 Feb 2025 00:49:07 -0600 Subject: [PATCH] default clause replaced by otherwise clause for metadirective ---

[clang] [AMDGPU][clang] provide device implementation for __builtin_logb and … (PR #129347)

2025-03-25 Thread via cfe-commits
https://github.com/choikwa updated https://github.com/llvm/llvm-project/pull/129347 >From 54076ba363db12cd04aefe58b385834a5fb986c2 Mon Sep 17 00:00:00 2001 From: Kevin Choi Date: Fri, 28 Feb 2025 16:52:03 -0600 Subject: [PATCH] [AMDGPU][clang] provide device implementation for __builtin_logb a

[clang] [clang-repl] Implement LoadDynamicLibrary for clang-repl wasm use cases (PR #133037)

2025-03-25 Thread Anutosh Bhat via cfe-commits
anutosh491 wrote: For anyone concerned, Such a feature would be tested out in downstream projects like [cppinterop](https://github.com/compiler-research/CppInterOp) and [xeus-cpp](https://github.com/compiler-research/xeus-cpp) as currently llvm doesn't have a concrete structure to test clang-

[clang] [clang-repl] Implement LoadDynamicLibrary for clang-repl wasm use cases (PR #133037)

2025-03-25 Thread Anutosh Bhat via cfe-commits
https://github.com/anutosh491 updated https://github.com/llvm/llvm-project/pull/133037 >From dfe49e826705a5e9371e17e66e40c31602beea8e Mon Sep 17 00:00:00 2001 From: anutosh491 Date: Wed, 26 Mar 2025 10:33:37 +0530 Subject: [PATCH 1/2] Implement LoadDynamicLibrary for clang-repl wasm use cases

[clang] [clang-repl] Implement LoadDynamicLibrary for clang-repl wasm use cases (PR #133037)

2025-03-25 Thread Anutosh Bhat via cfe-commits
https://github.com/anutosh491 edited https://github.com/llvm/llvm-project/pull/133037 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Allow `Language: Cpp` for C files (PR #133033)

2025-03-25 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/133033 Fix #132832 >From d03c3420218eed7c2db3a5c17abb6a0b3efbba87 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Tue, 25 Mar 2025 21:45:00 -0700 Subject: [PATCH] [clang-format] Allow `Language: Cpp` for C files Fix #13

[clang] [clang-repl] Implement LoadDynamicLibrary for clang-repl wasm use cases (PR #133037)

2025-03-25 Thread Anutosh Bhat via cfe-commits
https://github.com/anutosh491 edited https://github.com/llvm/llvm-project/pull/133037 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL] Add SPIR-V target type for StructuredBuffers (PR #132027)

2025-03-25 Thread Steven Perron via cfe-commits
https://github.com/s-perron updated https://github.com/llvm/llvm-project/pull/132027 >From 78348586c0b237db689b669fcf4352e6b42898a1 Mon Sep 17 00:00:00 2001 From: Steven Perron Date: Wed, 12 Feb 2025 15:45:32 -0500 Subject: [PATCH 1/3] [HLSL] Use hlsl_device address space for getpointer. We ad

[clang] [clang-repl] Implement LoadDynamicLibrary for clang-repl wasm use cases (PR #133037)

2025-03-25 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 80d5185bd4288c12e9d5aa0fe2e00f2f4e6397d7 dfe49e826705a5e9371e17e66e40c31602beea8e --e

[clang] [clang-repl] Implement LoadDynamicLibrary for clang-repl wasm use cases (PR #133037)

2025-03-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Anutosh Bhat (anutosh491) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/133037.diff 1 Files Affected: - (modified) clang/lib/Interpreter/Interpreter.cpp (+10) ``diff diff --git a/clang/lib/Interpreter/Inte

[clang] [clang-repl] Implement LoadDynamicLibrary for clang-repl wasm use cases (PR #133037)

2025-03-25 Thread Anutosh Bhat via cfe-commits
https://github.com/anutosh491 created https://github.com/llvm/llvm-project/pull/133037 None >From dfe49e826705a5e9371e17e66e40c31602beea8e Mon Sep 17 00:00:00 2001 From: anutosh491 Date: Wed, 26 Mar 2025 10:33:37 +0530 Subject: [PATCH] Implement LoadDynamicLibrary for clang-repl wasm use cases

[clang] [clang]: fix overload resolution in case of converting const value reference to an rvalue reference. (PR #133035)

2025-03-25 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung edited https://github.com/llvm/llvm-project/pull/133035 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CodeGen][NFC] Run SROA on complex range tests (PR #131925)

2025-03-25 Thread Mészáros Gergely via cfe-commits
https://github.com/Maetveis closed https://github.com/llvm/llvm-project/pull/131925 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang]: fix overload resolution in case of converting const value reference to an rvalue reference. (PR #133035)

2025-03-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Nhat Nguyen (changkhothuychung) Changes fix #132600 --- Full diff: https://github.com/llvm/llvm-project/pull/133035.diff 1 Files Affected: - (modified) clang/lib/Sema/SemaOverload.cpp (+1-1) ``diff diff --git a/clang/lib/Se

[clang] [clang-format] Allow `Language: Cpp` for C files (PR #133033)

2025-03-25 Thread Owen Pan via cfe-commits
https://github.com/owenca milestoned https://github.com/llvm/llvm-project/pull/133033 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [C23] Implement WG14 N3037 (PR #132939)

2025-03-25 Thread Shafik Yaghmour via cfe-commits
@@ -0,0 +1,472 @@ +// RUN: %clang_cc1 -fsyntax-only -std=c23 -pedantic -Wall -Wno-comment -verify=both,c23 %s +// RUN: %clang_cc1 -fsyntax-only -std=c17 -pedantic -Wall -Wno-comment -Wno-c23-extensions -verify=both,c17 %s + +/* WG14 N3037: + * Improved tag compatibility + * + *

[clang] [clang]: fix overload resolution in case of converting const value reference to an rvalue reference. (PR #133035)

2025-03-25 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung converted_to_draft https://github.com/llvm/llvm-project/pull/133035 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang]: fix overload resolution in case of converting const value reference to an rvalue reference. (PR #133035)

2025-03-25 Thread Nhat Nguyen via cfe-commits
https://github.com/changkhothuychung created https://github.com/llvm/llvm-project/pull/133035 fix #132600 >From fb9260dd796ae687a000beb550198d155b772625 Mon Sep 17 00:00:00 2001 From: changkhothuychung Date: Wed, 26 Mar 2025 00:55:26 -0400 Subject: [PATCH] initial commit --- clang/lib/Sema/

[clang] [AMDGPU][clang] provide device implementation for __builtin_logb and … (PR #129347)

2025-03-25 Thread via cfe-commits
https://github.com/choikwa updated https://github.com/llvm/llvm-project/pull/129347 >From 00827e0ebb8853dfc886e1d6226136ddbdb6e0a4 Mon Sep 17 00:00:00 2001 From: Kevin Choi Date: Fri, 28 Feb 2025 16:52:03 -0600 Subject: [PATCH] [AMDGPU][clang] provide device implementation for __builtin_logb a

[clang] [Clang] Implement CWG2517 Useless restriction on use of parameter in constraint-expression (PR #132919)

2025-03-25 Thread Imad Aldij via cfe-commits
https://github.com/imdj updated https://github.com/llvm/llvm-project/pull/132919 >From 7905577616743f5158560a4b337148ef9cd25f1e Mon Sep 17 00:00:00 2001 From: Imad Aldij Date: Tue, 25 Mar 2025 14:50:55 +0200 Subject: [PATCH 1/6] [Clang] Implement CWG2517 Useless restriction on use of parameter

[clang] [clang] Placement new error when modifying consts (PR #132460)

2025-03-25 Thread marius doerner via cfe-commits
mariusdr wrote: > Thanks. Will you need me to merge that for you? Yes, please https://github.com/llvm/llvm-project/pull/132460 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][analyzer] Correctly handle structured bindings captured by lambda (PR #132579)

2025-03-25 Thread via cfe-commits
flovent wrote: > In this case the proper fix would be to make sure, every declaration is > correctly looked up from a lambda. As i can know, lambdas can only capture variables in program, which seems can only comes from `VarDecl` or `BindingDecl`, so i think we don't need to handle other decl

[clang] [clang-format] Allow `Language: Cpp` for C files (PR #133033)

2025-03-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes Fix #132832 --- Full diff: https://github.com/llvm/llvm-project/pull/133033.diff 2 Files Affected: - (modified) clang/lib/Format/Format.cpp (+10-3) - (modified) clang/unittests/Format/ConfigParseTest.cp

[clang] [Clang] Check PP presence when printing stats (PR #131608)

2025-03-25 Thread Qiu Chaofan via cfe-commits
https://github.com/ecnelises updated https://github.com/llvm/llvm-project/pull/131608 >From 60b1e16b7b297095a50ed8db644b787e35f8eab0 Mon Sep 17 00:00:00 2001 From: Qiu Chaofan Date: Mon, 17 Mar 2025 20:49:02 +0800 Subject: [PATCH 1/2] [Clang] Check PP presence when printing stats --- clang/li

[clang] [llvm] [RISCV][WIP] Add assembler support for Zvma (PR #132965)

2025-03-25 Thread via cfe-commits
https://github.com/SpriteOvO closed https://github.com/llvm/llvm-project/pull/132965 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Improve subsumption. (PR #132849)

2025-03-25 Thread via cfe-commits
@@ -2001,3 +1932,260 @@ NormalizedConstraint::getFoldExpandedConstraint() const { "getFoldExpandedConstraint called on non-fold-expanded constraint."); return cast(Constraint); } + +// +// +// Subsumption ---

[clang] [Clang] Improve subsumption. (PR #132849)

2025-03-25 Thread via cfe-commits
@@ -2001,3 +1932,260 @@ NormalizedConstraint::getFoldExpandedConstraint() const { "getFoldExpandedConstraint called on non-fold-expanded constraint."); return cast(Constraint); } + +// +// +// Subsumption ---

[clang] [compiler-rt] [PGO][Offload] Hide GPU entrypoint on Darwin (PR #132966)

2025-03-25 Thread Joseph Huber via cfe-commits
@@ -1273,6 +1273,7 @@ COMPILER_RT_VISIBILITY int __llvm_profile_set_file_object(FILE *File, return 0; } +#ifdef COMPILER_RT_GPU_ENTRYPOINT jhuber6 wrote: Can't we just use `__APPLE__`? https://github.com/llvm/llvm-project/pull/132966 _

[clang] [NFC][Static Analyzer] Rename and discuss about `NotNullConstraint` & `NotNullBufferConstraint` (PR #131374)

2025-03-25 Thread Balázs Kéri via cfe-commits
@@ -1165,7 +1165,7 @@ ProgramStateRef StdLibraryFunctionsChecker::NotNullConstraint::apply( return State->assume(L, CannotBeNull); } -void StdLibraryFunctionsChecker::NotNullConstraint::describe( +void StdLibraryFunctionsChecker::NullnessConstraint::describe( Descripti

[clang] [libclang/python] Change all global variables to CAPS (PR #132930)

2025-03-25 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-x86_64-linux-android` running on `sanitizer-buildbot-android` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/186/builds/7661 Here is the releva

[clang] [RISCV] Make RequiredExtensions for intrinsics scalable to more than 32 extensions. NFC (PR #132895)

2025-03-25 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-armv8-quick` running on `linaro-clang-armv8-quick` while building `clang` at step 5 "ninja check 1". Full details are available at: https://lab.llvm.org/buildbot/#/builders/154/builds/13969 Here is the relevant piece o

[clang] [llvm] [RISCV][WIP] Add assembler support for Zvma (PR #132965)

2025-03-25 Thread Jiuyang Liu via cfe-commits
sequencer wrote: Appreciate your work! https://github.com/llvm/llvm-project/pull/132965 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libclang/python] Change all global variables to CAPS (PR #132930)

2025-03-25 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `lldb-aarch64-ubuntu` running on `linaro-lldb-aarch64-ubuntu` while building `clang` at step 6 "test". Full details are available at: https://lab.llvm.org/buildbot/#/builders/59/builds/14935 Here is the relevant piece of the

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangir Author: Amr Hesham (AmrDeveloper) Changes This change adds local initialization for ArrayType Issue #130197 --- Patch is 59.03 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/132974.diff 25 Files A

[clang] 1752d52 - [RISCV] Make RequiredExtensions for intrinsics scalable to more than 32 extensions. NFC (#132895)

2025-03-25 Thread via cfe-commits
Author: Craig Topper Date: 2025-03-25T20:46:01-07:00 New Revision: 1752d5292c1472cdfecbf3bfeea5040d09cfaa28 URL: https://github.com/llvm/llvm-project/commit/1752d5292c1472cdfecbf3bfeea5040d09cfaa28 DIFF: https://github.com/llvm/llvm-project/commit/1752d5292c1472cdfecbf3bfeea5040d09cfaa28.diff

[clang] [RISCV] Make RequiredExtensions for intrinsics scalable to more than 32 extensions. NFC (PR #132895)

2025-03-25 Thread Craig Topper via cfe-commits
https://github.com/topperc closed https://github.com/llvm/llvm-project/pull/132895 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Improve subsumption. (PR #132849)

2025-03-25 Thread via cfe-commits
@@ -2001,3 +1932,260 @@ NormalizedConstraint::getFoldExpandedConstraint() const { "getFoldExpandedConstraint called on non-fold-expanded constraint."); return cast(Constraint); } + +// +// +// Subsumption ---

[clang] [Clang] Improve subsumption. (PR #132849)

2025-03-25 Thread via cfe-commits
@@ -2001,3 +1932,260 @@ NormalizedConstraint::getFoldExpandedConstraint() const { "getFoldExpandedConstraint called on non-fold-expanded constraint."); return cast(Constraint); } + +// +// +// Subsumption ---

[clang] [Clang] Improve subsumption. (PR #132849)

2025-03-25 Thread via cfe-commits
https://github.com/MagentaTreehouse edited https://github.com/llvm/llvm-project/pull/132849 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Improve subsumption. (PR #132849)

2025-03-25 Thread via cfe-commits
@@ -2001,3 +1932,260 @@ NormalizedConstraint::getFoldExpandedConstraint() const { "getFoldExpandedConstraint called on non-fold-expanded constraint."); return cast(Constraint); } + +// +// +// Subsumption ---

[clang] [Clang] Improve subsumption. (PR #132849)

2025-03-25 Thread via cfe-commits
@@ -2001,3 +1932,260 @@ NormalizedConstraint::getFoldExpandedConstraint() const { "getFoldExpandedConstraint called on non-fold-expanded constraint."); return cast(Constraint); } + +// +// +// Subsumption ---

[clang] [Clang] Improve subsumption. (PR #132849)

2025-03-25 Thread via cfe-commits
https://github.com/MagentaTreehouse commented: Some comments on map lookup, plus other minor suggestions. https://github.com/llvm/llvm-project/pull/132849 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[clang] [Clang] Check PP presence when printing stats (PR #131608)

2025-03-25 Thread Qiu Chaofan via cfe-commits
https://github.com/ecnelises edited https://github.com/llvm/llvm-project/pull/131608 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Docs] Document freestanding requirements (PR #132232)

2025-03-25 Thread A. Jiang via cfe-commits
@@ -534,11 +534,6 @@ C23 implementation status Clang 16 - - String functions for freestanding implementations - https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2524.htm";>N2524 - No - frederick-vs-ja wrote: I found that

[clang] [NFC][Driver][HIP] Fix mixing `amdgcnspirv` and `gfxXXX` via `--offload-arch` (PR #133024)

2025-03-25 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 approved this pull request. Seems in line with the weird workarounds we already use. https://github.com/llvm/llvm-project/pull/133024 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mail

[clang] [clang] fix constexpr-unknown handling of self-references. (PR #132990)

2025-03-25 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic created https://github.com/llvm/llvm-project/pull/132990 Usually, in constant evaluation, references which are local to the evaluation have to be initialized before they're accessed. However, there's one funny special case: the initializer of a reference can r

[clang] [C23] Implement WG14 N3037 (PR #132939)

2025-03-25 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik edited https://github.com/llvm/llvm-project/pull/132939 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [SYCL] Basic code generation for SYCL kernel caller offload entry point functions. (PR #133030)

2025-03-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Tom Honermann (tahonermann) Changes A function declared with the `sycl_kernel_entry_point` attribute, sometimes called a SYCL kernel entry point function, specifies a pattern from which the parameters and body of an offload entry

[clang] [C23] Implement WG14 N3037 (PR #132939)

2025-03-25 Thread Shafik Yaghmour via cfe-commits
@@ -0,0 +1,472 @@ +// RUN: %clang_cc1 -fsyntax-only -std=c23 -pedantic -Wall -Wno-comment -verify=both,c23 %s +// RUN: %clang_cc1 -fsyntax-only -std=c17 -pedantic -Wall -Wno-comment -Wno-c23-extensions -verify=both,c17 %s + +/* WG14 N3037: + * Improved tag compatibility + * + *

[clang] [C23] Implement WG14 N3037 (PR #132939)

2025-03-25 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik commented: Second round of comments, I may make a third go around but I wouldn't wait for me. https://github.com/llvm/llvm-project/pull/132939 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[clang] [C23] Implement WG14 N3037 (PR #132939)

2025-03-25 Thread Shafik Yaghmour via cfe-commits
@@ -0,0 +1,472 @@ +// RUN: %clang_cc1 -fsyntax-only -std=c23 -pedantic -Wall -Wno-comment -verify=both,c23 %s +// RUN: %clang_cc1 -fsyntax-only -std=c17 -pedantic -Wall -Wno-comment -Wno-c23-extensions -verify=both,c17 %s + +/* WG14 N3037: + * Improved tag compatibility + * + *

[clang] [SYCL] Basic code generation for SYCL kernel caller offload entry point functions. (PR #133030)

2025-03-25 Thread Tom Honermann via cfe-commits
https://github.com/tahonermann created https://github.com/llvm/llvm-project/pull/133030 A function declared with the `sycl_kernel_entry_point` attribute, sometimes called a SYCL kernel entry point function, specifies a pattern from which the parameters and body of an offload entry point functi

[clang] [compiler-rt] [PGO][Offload] Hide GPU entrypoint on Darwin (PR #132966)

2025-03-25 Thread Ethan Luis McDonough via cfe-commits
@@ -1273,6 +1273,7 @@ COMPILER_RT_VISIBILITY int __llvm_profile_set_file_object(FILE *File, return 0; } +#ifdef COMPILER_RT_GPU_ENTRYPOINT EthanLuisMcDonough wrote: My reasoning was that it would give us more configuration power if we had a macro that was

[clang] [clang][ExtractAPI] fix a couple crashes when used via libclang (PR #132297)

2025-03-25 Thread via cfe-commits
@@ -175,28 +175,30 @@ class ExtractAPIVisitorBase : public RecursiveASTVisitor { SmallVector getBases(const CXXRecordDecl *Decl) { // FIXME: store AccessSpecifier given by inheritance SmallVector Bases; -for (const auto &BaseSpecifier : Decl->bases()) { - //

[clang] [HLSL] Finish exposing half types and intrinsics always (PR #132804)

2025-03-25 Thread Sarah Spall via cfe-commits
spall wrote: > > this is not NFC, so we should verify that we can call these intrinsics with > > `half` values even if 16-bit types aren't enabled, and that they properly > > codegen to 32-bit varia > > > > > > > For example, for `abs`, it still depends on the > > > > > > _HLSL_16BIT_AVAILABI

[clang] [Docs] Document freestanding requirements (PR #132232)

2025-03-25 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 approved this pull request. https://github.com/llvm/llvm-project/pull/132232 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/132974 >From 4dc1e77299c71b8f01fb73f7fba5f14e0fbe3edd Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 21 Mar 2025 21:07:11 +0100 Subject: [PATCH 1/2] [CIR] [Upstream local initialization for ArrayType ---

[clang] [CIR] Add binary operators (PR #132420)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -35,6 +83,22 @@ class ScalarExprEmitter : public StmtVisitor { ScalarExprEmitter(CIRGenFunction &cgf, CIRGenBuilderTy &builder) : cgf(cgf), builder(builder) {} + //======// + //

[clang] [compiler-rt] [PGO][Offload] Hide GPU entrypoint on Darwin (PR #132966)

2025-03-25 Thread Ethan Luis McDonough via cfe-commits
https://github.com/EthanLuisMcDonough updated https://github.com/llvm/llvm-project/pull/132966 >From e418000ddb31f6df2aa96061bea6fcc56d7b09a9 Mon Sep 17 00:00:00 2001 From: Ethan Luis McDonough Date: Tue, 25 Mar 2025 12:41:59 -0500 Subject: [PATCH 1/2] [PGO][Offload] Hide GPU entrypoint on Darw

[clang] [compiler-rt] [PGO][Offload] Hide GPU entrypoint on Darwin (PR #132966)

2025-03-25 Thread Joseph Huber via cfe-commits
@@ -1273,13 +1273,11 @@ COMPILER_RT_VISIBILITY int __llvm_profile_set_file_object(FILE *File, return 0; } -int __llvm_write_custom_profile(const char *Target, -const __llvm_profile_data *DataBegin, -const __llv

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

2025-03-25 Thread Oliver Hunt via cfe-commits
@@ -6404,20 +6404,23 @@ def warn_bitfield_width_exceeds_type_width: Warning< def err_bitfield_too_wide : Error< "%select{bit-field %1|anonymous bit-field}0 is too wide (%2 bits)">; def warn_bitfield_too_small_for_enum : Warning< - "bit-field %0 is not wide enough to store al

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
andykaylor wrote: > I already removed some parts like TypeSizeInfoAttr and AddrSpace before > creating the PR for that reason, I will double check again if I can remove > anything else I'm not sure it's worth splitting up now, but you probably could have implemented the zero-initialization ca

[clang-tools-extra] [clang-doc] [feat] add --repository-line-prefix argument (PR #131280)

2025-03-25 Thread Mohamed Emad via cfe-commits
hulxv wrote: Should I modify `HTMLGeneratorTest.cpp` to test `RepositoryLinePrefix`? https://github.com/llvm/llvm-project/blob/7a370748c0928b9ccfe26127e54eb3c1a1827d75/clang-tools-extra/unittests/clang-doc/HTMLGeneratorTest.cpp#L179 https://github.com/llvm/llvm-project/pull/131280 __

[clang] [llvm] cuda clang: Fix argument order for __reduce_max_sync (PR #132881)

2025-03-25 Thread Artem Belevich via cfe-commits
https://github.com/Artem-B approved this pull request. https://github.com/llvm/llvm-project/pull/132881 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,273 @@ +//===--- CIRGenExprAgg.cpp - Emit CIR Code from Aggregate Expressions -===// +// +// 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] [NFC][Driver][HIP] Fix mixing `amdgcnspirv` and `gfxXXX` via `--offload-arch` (PR #133024)

2025-03-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Alex Voicu (AlexVlx) Changes Due to `amdgcnspirv` piggybacking on the HIPAMDToolchain, it loses its immediately apparent SPIR-Vness, which makes the Driver want to go all the way to Assembly emmission. This was problematic as we were tryi

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,273 @@ +//===--- CIRGenExprAgg.cpp - Emit CIR Code from Aggregate Expressions -===// +// +// 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] [llvm] [HLSL] Implement the `smoothstep` intrinsic (PR #132288)

2025-03-25 Thread Kaitlin Peng via cfe-commits
@@ -101,6 +101,52 @@ bool SemaSPIRV::CheckSPIRVBuiltinFunctionCall(unsigned BuiltinID, TheCall->setType(RetTy); break; } + case SPIRV::BI__builtin_spirv_smoothstep: { +if (SemaRef.checkArgCount(TheCall, 3)) + return true; + +// check if the all argument

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -254,3 +254,27 @@ mlir::Type CIRGenTypes::convertTypeForMem(clang::QualType qualType, return convertedType; } + +bool CIRGenTypes::isZeroInitializable(clang::QualType t) { + if (t->getAs()) +return astContext.getTargetNullPointerValue(t) == 0; + + if (const auto *a

[clang] [NFC][Driver][HIP] Fix mixing `amdgcnspirv` and `gfxXXX` via `--offload-arch` (PR #133024)

2025-03-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: Alex Voicu (AlexVlx) Changes Due to `amdgcnspirv` piggybacking on the HIPAMDToolchain, it loses its immediately apparent SPIR-Vness, which makes the Driver want to go all the way to Assembly emmission. This was problematic as we we

[clang] [NFC][Driver][HIP] Fix mixing `amdgcnspirv` and `gfxXXX` via `--offload-arch` (PR #133024)

2025-03-25 Thread Alex Voicu via cfe-commits
https://github.com/AlexVlx created https://github.com/llvm/llvm-project/pull/133024 Due to `amdgcnspirv` piggybacking on the HIPAMDToolchain, it loses its immediately apparent SPIR-Vness, which makes the Driver want to go all the way to Assembly emmission. This was problematic as we were tryin

[clang] [clang-tools-extra] Reland: [clang] NFC: Clear some uses of MemberPointerType::getClass (PR #132317)

2025-03-25 Thread Matheus Izvekov via cfe-commits
mizvekov wrote: If you do revert, please avoid reverting tests if possible. https://github.com/llvm/llvm-project/pull/132317 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] Reland: [clang] NFC: Clear some uses of MemberPointerType::getClass (PR #132317)

2025-03-25 Thread Matheus Izvekov via cfe-commits
mizvekov wrote: You mean crashes caused by this fix, or do you mean crashes not fixed by it? In any case, I won't be available to revert anything until tomorrow. You can go ahead and revert, but I am afraid it won't be straightforward. https://github.com/llvm/llvm-project/pull/132317 _

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -412,3 +412,26 @@ mlir::Attribute ConstantEmitter::tryEmitPrivate(const APValue &value, } llvm_unreachable("Unknown APValue kind"); } + +mlir::Value CIRGenModule::emitNullConstant(QualType t, mlir::Location loc) { + if (t->getAs()) { +return builder.getNullPtr(getT

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,150 @@ +//- LoweringHelpers.cpp - Lowering helper functions ---===// +// +// 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] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -540,6 +542,68 @@ mlir::LogicalResult CIRToLLVMCastOpLowering::matchAndRewrite( return mlir::success(); } +mlir::LogicalResult CIRToLLVMPtrStrideOpLowering::matchAndRewrite( +cir::PtrStrideOp ptrStrideOp, OpAdaptor adaptor, +mlir::ConversionPatternRewriter &rewri

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -620,6 +684,28 @@ mlir::LogicalResult CIRToLLVMStoreOpLowering::matchAndRewrite( return mlir::LogicalResult::success(); } +/// Switches on the type of attribute and calls the appropriate conversion. +mlir::Value lowerCirAttrAsValue(mlir::Operation *parentOp, +

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -658,6 +744,27 @@ mlir::LogicalResult CIRToLLVMConstantOpLowering::matchAndRewrite( } assert(!cir::MissingFeatures::opGlobalViewAttr()); attr = op.getValue(); + } else if (const auto arrTy = mlir::dyn_cast(op.getType())) { +const auto constArr = mlir::dyn_c

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -113,6 +113,11 @@ class CIRGenModule : public CIRGenTypeCache { void emitGlobalVarDefinition(const clang::VarDecl *vd, bool isTentative = false); + // Return the result of value-initializing the given type, i.e. a null + /// expression of

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,273 @@ +//===--- CIRGenExprAgg.cpp - Emit CIR Code from Aggregate Expressions -===// +// +// 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] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -412,3 +412,26 @@ mlir::Attribute ConstantEmitter::tryEmitPrivate(const APValue &value, } llvm_unreachable("Unknown APValue kind"); } + +mlir::Value CIRGenModule::emitNullConstant(QualType t, mlir::Location loc) { + if (t->getAs()) { +return builder.getNullPtr(getT

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -196,6 +196,21 @@ class CIRToLLVMTrapOpLowering : public mlir::OpConversionPattern { mlir::ConversionPatternRewriter &) const override; }; +class CIRToLLVMPtrStrideOpLowering +: public mlir::OpConversionPattern { + mlir::DataLayout const &dataLayout;

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -449,4 +449,48 @@ LValue CIRGenFunction::emitLValue(const Expr *e) { } } +void CIRGenFunction::emitNullInitialization(mlir::Location loc, Address destPtr, +QualType ty) { + // Ignore empty classes in C++. + if (getLangOpts().

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -449,4 +449,48 @@ LValue CIRGenFunction::emitLValue(const Expr *e) { } } +void CIRGenFunction::emitNullInitialization(mlir::Location loc, Address destPtr, +QualType ty) { + // Ignore empty classes in C++. + if (getLangOpts().

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,273 @@ +//===--- CIRGenExprAgg.cpp - Emit CIR Code from Aggregate Expressions -===// +// +// 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] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -620,6 +684,28 @@ mlir::LogicalResult CIRToLLVMStoreOpLowering::matchAndRewrite( return mlir::LogicalResult::success(); } +/// Switches on the type of attribute and calls the appropriate conversion. +mlir::Value lowerCirAttrAsValue(mlir::Operation *parentOp, +

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -540,6 +542,68 @@ mlir::LogicalResult CIRToLLVMCastOpLowering::matchAndRewrite( return mlir::success(); } +mlir::LogicalResult CIRToLLVMPtrStrideOpLowering::matchAndRewrite( +cir::PtrStrideOp ptrStrideOp, OpAdaptor adaptor, +mlir::ConversionPatternRewriter &rewri

[clang] [CIR] [Upstream local initialization for ArrayType (PR #132974)

2025-03-25 Thread Andy Kaylor via cfe-commits
@@ -246,8 +246,8 @@ OpFoldResult cir::ConstantOp::fold(FoldAdaptor /*adaptor*/) { //===--===// LogicalResult cir::CastOp::verify() { - auto resType = getResult().getType(); - auto srcType = getSrc().getTyp

  1   2   3   4   5   6   >