[clang-tools-extra] [MLIR][Presburger] Fix reduce bug in Fraction class and add tests (PR #68298)

2023-10-06 Thread Arjun P via cfe-commits
Superty wrote: Thanks! https://github.com/llvm/llvm-project/pull/68298 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [MLIR][Presburger] Fix reduce bug in Fraction class and add tests (PR #68298)

2023-10-06 Thread Arjun P via cfe-commits
Superty wrote: Thanks! https://github.com/llvm/llvm-project/pull/68298 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [MLIR][Presburger] Fix reduce bug in Fraction class and add tests (PR #68298)

2023-10-06 Thread Arjun P via cfe-commits
https://github.com/Superty closed https://github.com/llvm/llvm-project/pull/68298 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Add check for bitfield assignments to larger integral types (PR #68276)

2023-10-06 Thread Aaron Ballman via cfe-commits
@@ -6171,6 +6171,9 @@ def warn_signed_bitfield_enum_conversion : Warning< "signed bit-field %0 needs an extra bit to represent the largest positive " "enumerators of %1">, InGroup, DefaultIgnore; +def warn_bitfield_too_small_for_integral_type : Warning< + "bit-field %0 (

[clang] [Driver] Silence stdlib warning when linking C on FreeBSD (PR #68011)

2023-10-06 Thread via cfe-commits
dankm wrote: > The Darwin toolchain also does this. This change LGTM, although I'm not an > expert in FreeBSD. Thanks. I think I'd like some FreeBSD folks to take a look. I wonder if it's rude to @ mention a few... maybe I will. The ones I can think of immediately are @DimitryAndric, @emaste,

[clang] [Driver] Silence stdlib warning when linking C on FreeBSD (PR #68011)

2023-10-06 Thread Ed Maste via cfe-commits
https://github.com/emaste approved this pull request. https://github.com/llvm/llvm-project/pull/68011 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Silence stdlib warning when linking C on FreeBSD (PR #68011)

2023-10-06 Thread Ed Maste via cfe-commits
emaste wrote: Yeah, I don't see any reason there'd be a problem with this. It seems a bit silly for build systems to pass this in, but if they do there's no value in reporting it. https://github.com/llvm/llvm-project/pull/68011 ___ cfe-commits mailin

[clang] [HIP] Document func ptr and virtual func (PR #68126)

2023-10-06 Thread Yaxun Liu via cfe-commits
@@ -176,3 +176,70 @@ Predefined Macros * - ``HIP_API_PER_THREAD_DEFAULT_STREAM`` - Alias to ``__HIP_API_PER_THREAD_DEFAULT_STREAM__``. Deprecated. +Function Pointers Support in Clang with HIP +=== + +Function pointers' support va

[clang] [HIP] Document func ptr and virtual func (PR #68126)

2023-10-06 Thread Yaxun Liu via cfe-commits
@@ -176,3 +176,65 @@ Predefined Macros * - ``HIP_API_PER_THREAD_DEFAULT_STREAM`` - Alias to ``__HIP_API_PER_THREAD_DEFAULT_STREAM__``. Deprecated. +Function Pointers Support in Clang with HIP +=== + +Function pointers' support va

[clang] [libcxx] Allow string to use SSO in constant evaluation. (PR #66576)

2023-10-06 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > > I don't think I will be able to work on that the discussed Clang > > diagnostics anytime soon. Unless someone else is volunteering to implement > > it, that may not be implemented at all. > > So, I'd like to hear explicit consensus is that folks are generally OK to > >

[clang-tools-extra] [libcxx] Allow string to use SSO in constant evaluation. (PR #66576)

2023-10-06 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > > I don't think I will be able to work on that the discussed Clang > > diagnostics anytime soon. Unless someone else is volunteering to implement > > it, that may not be implemented at all. > > So, I'd like to hear explicit consensus is that folks are generally OK to > >

[clang] [clang] remove ClassScopeFunctionSpecializationDecl (PR #66636)

2023-10-06 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: Do you need someone to land these changes on your behalf? https://github.com/llvm/llvm-project/pull/66636 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] use absolute path for builtin headers during module compilation (PR #68023)

2023-10-06 Thread Richard Howell via cfe-commits
rmaz wrote: I had a go at this approach this morning, it mostly works but fails for the case where we have a module with a textual header with the same name as a builtin header. When using relative paths for the builtin headers we now prefer the module's textual header instead of the builtin h

[clang] [Driver] Silence stdlib warning when linking C on FreeBSD (PR #68011)

2023-10-06 Thread Dimitry Andric via cfe-commits
DimitryAndric wrote: Does this only affect cases where one passes `-stdlib=libc++`? What happens if somebody passes `-stdlib=libstdc++`? https://github.com/llvm/llvm-project/pull/68011 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://l

[clang] [RISCV] Support Xsfvqmaccdod and Xsfvqmaccqoq extensions (PR #68295)

2023-10-06 Thread Brandon Wu via cfe-commits
@@ -318,6 +345,16 @@ multiclass VPseudoVC_XVW { + def "Pseudo" # NAME # "_VV_" # mx : VPseudoTernaryNoMaskWithPolicy; 4vtomat wrote: Got it, I agree that td files should also follow the rule of 80 characters. https://github.com/llvm/llvm-project/pull/68295

[clang] Add -fkeep-system-includes modifier for -E (PR #67684)

2023-10-06 Thread Paul T Robinson via cfe-commits
pogo59 wrote: Ping @erichkeane were you willing to approve both this and #67613? https://github.com/llvm/llvm-project/pull/67684 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Make -frewrite-includes put an endif at the end of the included text (PR #67613)

2023-10-06 Thread Paul T Robinson via cfe-commits
pogo59 wrote: Ping https://github.com/llvm/llvm-project/pull/67613 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Support Xsfvfnrclipxfqf extensions (PR #68297)

2023-10-06 Thread Brandon Wu via cfe-commits
@@ -630,7 +630,7 @@ TEST(getTargetFeatureForExtension, RetrieveTargetFeatureFromOneExt) { TEST(RiscvExtensionsHelp, CheckExtensions) { std::string ExpectedOutput = -R"(All available -march extensions for RISC-V + R"(All available -march extensions for RISC-V --

[clang] Make -frewrite-includes put an endif at the end of the included text (PR #67613)

2023-10-06 Thread Erich Keane via cfe-commits
https://github.com/erichkeane commented: The clang-format tool still has a complaint, so this isn't passing CI. Unfortunately it doesn't seem to print it in the CI, so you'll have to run it locally. Delta that, LGTM. https://github.com/llvm/llvm-project/pull/67613 ___

[clang] [RISCV] Support Xsfvfwmaccqqq extensions (PR #68296)

2023-10-06 Thread Brandon Wu via cfe-commits
https://github.com/4vtomat updated https://github.com/llvm/llvm-project/pull/68296 >From e5a746541509727210e5e561ecb85607939ec0f4 Mon Sep 17 00:00:00 2001 From: Brandon Wu Date: Wed, 4 Oct 2023 10:23:52 -0700 Subject: [PATCH 1/3] [RISCV] Support Xsfvfwmaccqqq extensions Bfloat16 Matrix Multipl

[clang] Diagnose problematic uses of constructor/destructor attribute (PR #67673)

2023-10-06 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: Ping, especially @MaskRay https://github.com/llvm/llvm-project/pull/67673 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Make -frewrite-includes put an endif at the end of the included text (PR #67613)

2023-10-06 Thread Paul T Robinson via cfe-commits
https://github.com/pogo59 updated https://github.com/llvm/llvm-project/pull/67613 >From 0f63068d1085e5064d47916a86fac089c4417e57 Mon Sep 17 00:00:00 2001 From: Paul Robinson Date: Wed, 27 Sep 2023 14:54:13 -0700 Subject: [PATCH 1/5] Make -frewrite-includes put an endif at the end of the includ

[clang] Add -fkeep-system-includes modifier for -E (PR #67684)

2023-10-06 Thread Erich Keane via cfe-commits
https://github.com/erichkeane commented: This too fails the formatter. That said, I have no comments, though preprocessing isn't my place of expertise. Most of the changes are pretty mild though, and the approach of just replacing the output file with a null-OS seems appropriate. Fix the fo

[clang] [Driver] Silence stdlib warning when linking C on FreeBSD (PR #68011)

2023-10-06 Thread via cfe-commits
dankm wrote: > Does this only affect cases where one passes `-stdlib=libc++`? What happens > if somebody passes `-stdlib=libstdc++`? It handles both cases. It simply claims all the `-stdlib=` arguments. This is the same behaviour as the Gnu driver used by Linux, but seems to diverge from Darw

[clang] Make -frewrite-includes put an endif at the end of the included text (PR #67613)

2023-10-06 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. Approved, assuming this passes CI. https://github.com/llvm/llvm-project/pull/67613 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com

[clang] [Driver] Silence stdlib warning when linking C on FreeBSD (PR #68011)

2023-10-06 Thread via cfe-commits
dankm wrote: You do bring up an interesting point, though. When linking C code with this change, for both Gnu and FreeBSD, `-stdlib=libbad` is ignored for C and raises an error for C++. Also for reference, the toolchains that ignore the stdlib argument for C are: baremetal, Darwin, Fuchsia, G

[clang] [Driver] Silence stdlib warning when linking C on FreeBSD (PR #68011)

2023-10-06 Thread Ed Maste via cfe-commits
emaste wrote: > It handles both cases. It simply claims all the -stdlib= arguments. If I understand correctly this means in effect `-stdlib=` becomes a don't-care when linking C, and anyhow it already had no effect. https://github.com/llvm/llvm-project/pull/68011 __

[clang] [mlir][sparse] introduce MapRef, unify conversion/codegen for reader (PR #68360)

2023-10-06 Thread Peiming Liu via cfe-commits
https://github.com/PeimingLiu approved this pull request. https://github.com/llvm/llvm-project/pull/68360 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Silence stdlib warning when linking C on FreeBSD (PR #68011)

2023-10-06 Thread via cfe-commits
dankm wrote: > If I understand correctly this means in effect `-stdlib=` becomes a > don't-care when linking C, and anyhow it already had no effect. That's correct. It was previously a harmless warning at link time, and is now (with this change) completely ignored. https://github.com/llvm/llv

[PATCH] D137149: Use PassGate from LLVMContext if any otherwise global one

2023-10-06 Thread Valentin Churavy via Phabricator via cfe-commits
vchuravy added a comment. Herald added a subscriber: wangpc. Late to the party here, but passing an `LLVMContext` seems really strange from a JIT perspective. We construct a pipeline that may be run over many modules each of them maybe using a different LLVM Context. Repository: rG LLVM Gith

[clang] Add -fkeep-system-includes modifier for -E (PR #67684)

2023-10-06 Thread Paul T Robinson via cfe-commits
pogo59 wrote: Many of the clang-format complaints on this one are from the first commit, which I wanted to make as minimalist as possible. I believe I didn't make the file any _less_ conformant in that commit. :) I will fix the others. https://github.com/llvm/llvm-project/pull/67684 _

[clang] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
@@ -0,0 +1,1248 @@ +; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 3 +; ## Support i16x2 instructions +; RUN: llc < %s -mtriple=nvptx64-nvidia-cuda -mcpu=sm_90 -mattr=+ptx80 \ +; RUN: -O0 -disable-post-ra -frame-pointer=

[clang] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
Artem-B wrote: I see one suspicious failure in tensorflow tests. I suspect I've messed something up in v4i8 comparison. https://github.com/llvm/llvm-project/pull/67866 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[clang] [sema] Improve -Wsign-compare (PR #65684)

2023-10-06 Thread Aaron Ballman via cfe-commits
=?utf-8?q?Félix?= Cloutier Message-ID: In-Reply-To: https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/65684 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com

[clang] [sema] Improve -Wsign-compare (PR #65684)

2023-10-06 Thread Aaron Ballman via cfe-commits
=?utf-8?q?F=C3=A9lix?= Cloutier Message-ID: In-Reply-To: @@ -7237,8 +7237,12 @@ def warn_tautological_compare_value_range : Warning< InGroup, DefaultIgnore; def warn_mixed_sign_comparison : Warning< - "comparison of integers of different signs: %0 and %1">, - InGroup, D

[clang] [sema] Improve -Wsign-compare (PR #65684)

2023-10-06 Thread Aaron Ballman via cfe-commits
=?utf-8?q?Félix?= Cloutier Message-ID: In-Reply-To: https://github.com/AaronBallman commented: Thank you for this! Overall, I like the improvements. I think the note and the fix-it are helpful. I'm more comfortable with the note than I am the fix-it, however, because the fix-it could result

[clang] [sema] Improve -Wsign-compare (PR #65684)

2023-10-06 Thread Aaron Ballman via cfe-commits
=?utf-8?q?Félix?= Cloutier Message-ID: In-Reply-To: @@ -14160,10 +14193,58 @@ static void AnalyzeComparison(Sema &S, BinaryOperator *E) { return; } - S.DiagRuntimeBehavior(E->getOperatorLoc(), E, -S.PDiag(diag::warn_mixed_sign_comparison) -

[clang] [sema] Improve -Wsign-compare (PR #65684)

2023-10-06 Thread Aaron Ballman via cfe-commits
=?utf-8?q?Félix?= Cloutier Message-ID: In-Reply-To: @@ -14043,28 +14039,63 @@ static bool CheckTautologicalComparison(Sema &S, BinaryOperator *E, return true; } +namespace { +struct AnalyzeImplicitConversionsWorkItem { + Expr *E; AaronBallman wrote: Be

[clang] [sema] Improve -Wsign-compare (PR #65684)

2023-10-06 Thread Aaron Ballman via cfe-commits
=?utf-8?q?Félix?= Cloutier Message-ID: In-Reply-To: @@ -14160,10 +14193,58 @@ static void AnalyzeComparison(Sema &S, BinaryOperator *E) { return; } - S.DiagRuntimeBehavior(E->getOperatorLoc(), E, -S.PDiag(diag::warn_mixed_sign_comparison) -

[clang] [sema] Improve -Wsign-compare (PR #65684)

2023-10-06 Thread Aaron Ballman via cfe-commits
=?utf-8?q?Félix?= Cloutier Message-ID: In-Reply-To: @@ -14160,10 +14193,58 @@ static void AnalyzeComparison(Sema &S, BinaryOperator *E) { return; } - S.DiagRuntimeBehavior(E->getOperatorLoc(), E, -S.PDiag(diag::warn_mixed_sign_comparison) -

[clang] Diagnose problematic uses of constructor/destructor attribute (PR #67673)

2023-10-06 Thread Joseph Huber via cfe-commits
jhuber6 wrote: I already changed the `init_fini_array_test` while I fixed an unrelated problem, so it should be fine now. https://github.com/llvm/llvm-project/pull/67673 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cg

[clang] [RISCV][GISel] Select G_SELECT (PR #67614)

2023-10-06 Thread Nitin John Raj via cfe-commits
https://github.com/nitinjohnraj closed https://github.com/llvm/llvm-project/pull/67614 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [RISCV][GISel] Select G_SELECT (PR #67614)

2023-10-06 Thread Nitin John Raj via cfe-commits
https://github.com/nitinjohnraj closed https://github.com/llvm/llvm-project/pull/67614 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [sema] Improve -Wsign-compare (PR #65684)

2023-10-06 Thread Aaron Ballman via cfe-commits
=?utf-8?q?Félix?= Cloutier Message-ID: In-Reply-To: AaronBallman wrote: > Thank you for this! Overall, I like the improvements. > > I think the note and the fix-it are helpful. I'm more comfortable with the > note than I am the fix-it, however, because the fix-it could result in a > change

[clang] Make -frewrite-includes put an endif at the end of the included text (PR #67613)

2023-10-06 Thread Paul T Robinson via cfe-commits
https://github.com/pogo59 updated https://github.com/llvm/llvm-project/pull/67613 >From 0f63068d1085e5064d47916a86fac089c4417e57 Mon Sep 17 00:00:00 2001 From: Paul Robinson Date: Wed, 27 Sep 2023 14:54:13 -0700 Subject: [PATCH 1/6] Make -frewrite-includes put an endif at the end of the includ

[clang] [AST] Use explicit type erasure in TypeSourceInfo constructor (PR #68435)

2023-10-06 Thread via cfe-commits
https://github.com/bonktree created https://github.com/llvm/llvm-project/pull/68435 When this file is included in a project compiled with GCC 13 `-Werror`, compilation fails with the following diagnostic: /usr/lib/llvm-17.0/include/clang/AST/TypeLoc.h: In constructor 'clang::TypeSourceInfo::T

[clang] [sema] Improve -Wsign-compare (PR #65684)

2023-10-06 Thread Christopher Di Bella via cfe-commits
=?utf-8?q?Félix?= Cloutier Message-ID: In-Reply-To: https://github.com/cjdb commented: Generally speaking, I'm in favour of this; thanks so much for identifying this problem! When C++20 is available, we ought to suggest using `std:: is_lt` and friends instead. Possibly something like ``` n

[clang] [mlir][sparse] introduce MapRef, unify conversion/codegen for reader (PR #68360)

2023-10-06 Thread Yinying Li via cfe-commits
@@ -729,3 +729,92 @@ Value sparse_tensor::createOrFoldSliceStrideOp(OpBuilder &builder, Location loc, return constantIndex(builder, loc, *stride); return builder.create(loc, tensor, APInt(64, dim)); } + +void sparse_tensor::fillDimShape(OpBuilder &builder, Location loc,

[clang] Add -fkeep-system-includes modifier for -E (PR #67684)

2023-10-06 Thread Paul T Robinson via cfe-commits
https://github.com/pogo59 updated https://github.com/llvm/llvm-project/pull/67684 >From 2a0dd575dbbcf80d1cd264d6dbc8de8fa897 Mon Sep 17 00:00:00 2001 From: Paul Robinson Date: Wed, 27 Sep 2023 15:30:52 -0700 Subject: [PATCH 1/5] [NFC] Change a reference member to pointer This will allow th

[clang] [mlir][sparse] introduce MapRef, unify conversion/codegen for reader (PR #68360)

2023-10-06 Thread Yinying Li via cfe-commits
https://github.com/yinying-lisa-li approved this pull request. https://github.com/llvm/llvm-project/pull/68360 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Add -fkeep-system-includes modifier for -E (PR #67684)

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

[clang] clang: Add pragma clang fp reciprocal (PR #68267)

2023-10-06 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor edited https://github.com/llvm/llvm-project/pull/68267 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] clang: Add pragma clang fp reciprocal (PR #68267)

2023-10-06 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor commented: Thanks for adding this! I have just a few minor comments. https://github.com/llvm/llvm-project/pull/68267 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/c

[clang] clang: Add pragma clang fp reciprocal (PR #68267)

2023-10-06 Thread Andy Kaylor via cfe-commits
@@ -4609,6 +4609,22 @@ The pragma can take two values: ``on`` and ``off``. float v = t + z; } +``#pragma clang fp reciprocal`` allows control over using reciprocal +approximations in floating point expressions. When enabled, this +pragma allows the expression ``x / y`` t

[clang] clang: Add pragma clang fp reciprocal (PR #68267)

2023-10-06 Thread Andy Kaylor via cfe-commits
@@ -1309,6 +1309,13 @@ void Sema::ActOnPragmaFPReassociate(SourceLocation Loc, bool IsEnabled) { CurFPFeatures = NewFPFeatures.applyOverrides(getLangOpts()); } +void Sema::ActOnPragmaFPReciprocal(SourceLocation Loc, bool IsEnabled) { andykaylor wrote: This

[clang] clang: Add pragma clang fp reciprocal (PR #68267)

2023-10-06 Thread Andy Kaylor via cfe-commits
andykaylor wrote: err_pragma_fp_invalid_option needs to be updated to add 'reciprocal' https://github.com/llvm/llvm-project/pull/68267 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[clang] [libc] Fix linking of AMDGPU device runtime control constants for math (PR #65676)

2023-10-06 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/65676 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [libc] Fix linking of AMDGPU device runtime control constants for math (PR #65676)

2023-10-06 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/65676 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Use explicit type erasure in TypeSourceInfo constructor (PR #68435)

2023-10-06 Thread via cfe-commits
https://github.com/bonktree edited https://github.com/llvm/llvm-project/pull/68435 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Use explicit type erasure in TypeSourceInfo constructor (PR #68435)

2023-10-06 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 7f9a50ff0628e80743e5f4048274b5783f47a5cc 753c2e0ad0c15d0af14368c574b3fa53d70416f9 --

[clang] Fixes and closes #53952. Setting the ASTHasCompilerErrors member variable correctly based on the PP diagnostics. (PR #68127)

2023-10-06 Thread Kazu Hirata via cfe-commits
kazutakahirata wrote: Thank you @AaronBallman! https://github.com/llvm/llvm-project/pull/68127 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Use explicit type erasure in TypeSourceInfo constructor (PR #68435)

2023-10-06 Thread via cfe-commits
https://github.com/bonktree updated https://github.com/llvm/llvm-project/pull/68435 >From 2b8af8b3dfc5f1dcd31599d9a4cda35c1af742db Mon Sep 17 00:00:00 2001 From: Arseny Maslennikov Date: Thu, 5 Oct 2023 10:05:14 +0300 Subject: [PATCH] [AST] Use explicit type erasure in TypeSourceInfo constructo

[clang] [time-trace] Add a new time trace scope variable named "ParseDeclarationOrFunctionDefinition". (PR #65268)

2023-10-06 Thread Aaron Ballman via cfe-commits
@@ -1224,6 +1225,9 @@ Parser::DeclGroupPtrTy Parser::ParseDeclOrFunctionDefInternal( Parser::DeclGroupPtrTy Parser::ParseDeclarationOrFunctionDefinition( ParsedAttributes &Attrs, ParsedAttributes &DeclSpecAttrs, ParsingDeclSpec *DS, AccessSpecifier AS) { + // Add an e

[clang] [time-trace] Add a new time trace scope variable named "ParseDeclarationOrFunctionDefinition". (PR #65268)

2023-10-06 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/65268 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [time-trace] Add a new time trace scope variable named "ParseDeclarationOrFunctionDefinition". (PR #65268)

2023-10-06 Thread Aaron Ballman via cfe-commits
@@ -1224,6 +1225,9 @@ Parser::DeclGroupPtrTy Parser::ParseDeclOrFunctionDefInternal( Parser::DeclGroupPtrTy Parser::ParseDeclarationOrFunctionDefinition( ParsedAttributes &Attrs, ParsedAttributes &DeclSpecAttrs, ParsingDeclSpec *DS, AccessSpecifier AS) { + // Add an e

[clang] [time-trace] Add a new time trace scope variable named "ParseDeclarationOrFunctionDefinition". (PR #65268)

2023-10-06 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: Apologies on the delayed review! Thank you for working on this; we really could use better time trace output in Clang to start helping us get a better handle on improving compile time performance. https://github.com/llvm/llvm-project/pull/65268 __

[clang] [PowerPC] Fix use of FPSCR builtins in smmintrin.h (PR #67299)

2023-10-06 Thread Stefan Pintilie via cfe-commits
https://github.com/stefanp-ibm commented: I think this makes sense to me overall. Thank you for adding the tests for C++ as well! I only had a couple of comments about this patch. https://github.com/llvm/llvm-project/pull/67299 ___ cfe-commits mailing

[clang] [PowerPC] Fix use of FPSCR builtins in smmintrin.h (PR #67299)

2023-10-06 Thread Stefan Pintilie via cfe-commits
@@ -219,9 +234,14 @@ extern __inline __m128 */ __asm__("" : : "wa"(__r)); /* Restore enabled exceptions. */ -__fpscr_save.__fr = __builtin_mffsl(); +#ifdef _ARCH_PWR9 +__fpscr_save.__fr = __builtin_ppc_mffsl(); +#else +__fpscr_save.__fr = __builtin_ppc

[clang] [PowerPC] Fix use of FPSCR builtins in smmintrin.h (PR #67299)

2023-10-06 Thread Stefan Pintilie via cfe-commits
@@ -68,10 +68,10 @@ extern __inline __m128d __asm__("mffsce %0" : "=f"(__fpscr_save.__fr)); __enables_save.__fpscr = __fpscr_save.__fpscr & 0xf8; #else -__fpscr_save.__fr = __builtin_mffs(); +__fpscr_save.__fr = __builtin_ppc_mffs(); stefanp-ibm

[clang] [PowerPC] Fix use of FPSCR builtins in smmintrin.h (PR #67299)

2023-10-06 Thread Stefan Pintilie via cfe-commits
https://github.com/stefanp-ibm edited https://github.com/llvm/llvm-project/pull/67299 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] clang: Add pragma clang fp reciprocal (PR #68267)

2023-10-06 Thread Zahira Ammarguellat via cfe-commits
zahiraam wrote: and a test for it. https://github.com/llvm/llvm-project/pull/68267 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D137149: Use PassGate from LLVMContext if any otherwise global one

2023-10-06 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks added a comment. we don't currently support reusing a pipeline so I'm surprised that you're able to share/reuse pipelines without running into any issues Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137149/new/ https://reviews.llvm.org/D

[clang] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
Artem-B wrote: > I see one suspicious failure in tensorflow tests. I suspect I've messed > something up in v4i8 comparison. Yup, there is a problem: ``` Successfully custom legalized node ... replacing: t10: v4i8 = BUILD_VECTOR Constant:i16<-128>, Constant:i16<-128>, Constant:i16<-128>, Const

[clang-tools-extra] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
Artem-B wrote: > I see one suspicious failure in tensorflow tests. I suspect I've messed > something up in v4i8 comparison. Yup, there is a problem: ``` Successfully custom legalized node ... replacing: t10: v4i8 = BUILD_VECTOR Constant:i16<-128>, Constant:i16<-128>, Constant:i16<-128>, Const

[clang] [OpenMP][Clang] Force use of `num_teams` and `thread_limit` for bare kernel (PR #68373)

2023-10-06 Thread Johannes Doerfert via cfe-commits
jdoerfert wrote: I think the follow up, to force the user bound for bare kernels, make sense. I am not sold on this patch though. Why would we disallow users to do the same looping we do in the deviceRTL while hoping the offload runtime will pick a good grid size? https://github.com/llvm/llvm

[clang] clang: Add pragma clang fp reciprocal (PR #68267)

2023-10-06 Thread Zahira Ammarguellat via cfe-commits
zahiraam wrote: Can you please fix the description of the patch. Please note that Melanie has retired. You can add me as a reviewer for all FP related work. Thanks. https://github.com/llvm/llvm-project/pull/68267 ___ cfe-commits mailing list cfe-commi

[clang-tools-extra] Adding Separate OpenMP Offloading Backend to `libcxx/include/__algorithm/pstl_backends` (PR #66968)

2023-10-06 Thread Anton Rydahl via cfe-commits
@@ -807,6 +815,11 @@ else() Valid backends are: serial, std_thread and libdispatch") endif() +config_define_if(LIBCXX_ENABLE_GPU_OFFLOAD _LIBCPP_PSTL_GPU_OFFLOAD) AntonRydahl wrote: I have tried to restructure the CMake file as sugegste

[clang] Adding Separate OpenMP Offloading Backend to `libcxx/include/__algorithm/pstl_backends` (PR #66968)

2023-10-06 Thread Anton Rydahl via cfe-commits
@@ -807,6 +815,11 @@ else() Valid backends are: serial, std_thread and libdispatch") endif() +config_define_if(LIBCXX_ENABLE_GPU_OFFLOAD _LIBCPP_PSTL_GPU_OFFLOAD) AntonRydahl wrote: I have tried to restructure the CMake file as sugegste

[clang] clang: Add pragma clang fp reciprocal (PR #68267)

2023-10-06 Thread Matt Arsenault via cfe-commits
@@ -1309,6 +1309,13 @@ void Sema::ActOnPragmaFPReassociate(SourceLocation Loc, bool IsEnabled) { CurFPFeatures = NewFPFeatures.applyOverrides(getLangOpts()); } +void Sema::ActOnPragmaFPReciprocal(SourceLocation Loc, bool IsEnabled) { arsenm wrote: Why does

[clang] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
@@ -2150,58 +2179,94 @@ NVPTXTargetLowering::LowerCONCAT_VECTORS(SDValue Op, SelectionDAG &DAG) const { return DAG.getBuildVector(Node->getValueType(0), dl, Ops); } -// We can init constant f16x2 with a single .b32 move. Normally it +// We can init constant f16x2/v2i16/v4i

[clang-tools-extra] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
@@ -2150,58 +2179,94 @@ NVPTXTargetLowering::LowerCONCAT_VECTORS(SDValue Op, SelectionDAG &DAG) const { return DAG.getBuildVector(Node->getValueType(0), dl, Ops); } -// We can init constant f16x2 with a single .b32 move. Normally it +// We can init constant f16x2/v2i16/v4i

[clang] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
https://github.com/Artem-B deleted https://github.com/llvm/llvm-project/pull/67866 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
https://github.com/Artem-B deleted https://github.com/llvm/llvm-project/pull/67866 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [mlir][llvm] Fix elem type passing into `getelementptr` (PR #68136)

2023-10-06 Thread Stella Laurenzo via cfe-commits
stellaraccident wrote: Thank you for the revert. We were failing on assertion when integrating this patch: ``` iree-compile: /home/stella/megabump/work/iree/third_party/llvm-project/llvm/include/llvm/Support/Casting.h:566: decltype(auto) llvm::cast(const From &) [To = mlir::LLVM::LLVMPointerT

[clang] [OpenMP][Clang] Force use of `num_teams` and `thread_limit` for bare kernel (PR #68373)

2023-10-06 Thread Shilei Tian via cfe-commits
shiltian wrote: > I think the follow up, to force the user bound for bare kernels, make sense. > I am not sold on this patch though. Why would we disallow users to do the > same looping we do in the deviceRTL while hoping the offload runtime will > pick a good grid size? Because we don't have

[clang] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
@@ -2150,58 +2179,94 @@ NVPTXTargetLowering::LowerCONCAT_VECTORS(SDValue Op, SelectionDAG &DAG) const { return DAG.getBuildVector(Node->getValueType(0), dl, Ops); } -// We can init constant f16x2 with a single .b32 move. Normally it +// We can init constant f16x2/v2i16/v4i

[clang-tools-extra] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
@@ -2150,58 +2179,94 @@ NVPTXTargetLowering::LowerCONCAT_VECTORS(SDValue Op, SelectionDAG &DAG) const { return DAG.getBuildVector(Node->getValueType(0), dl, Ops); } -// We can init constant f16x2 with a single .b32 move. Normally it +// We can init constant f16x2/v2i16/v4i

[clang] clang: Add pragma clang fp reciprocal (PR #68267)

2023-10-06 Thread Andy Kaylor via cfe-commits
@@ -1309,6 +1309,13 @@ void Sema::ActOnPragmaFPReassociate(SourceLocation Loc, bool IsEnabled) { CurFPFeatures = NewFPFeatures.applyOverrides(getLangOpts()); } +void Sema::ActOnPragmaFPReciprocal(SourceLocation Loc, bool IsEnabled) { andykaylor wrote: Ther

[libunwind] [libunwind][libc++][libc++abi] Add cross-compilation flags to tests (PR #67201)

2023-10-06 Thread Alexander Richardson via cfe-commits
https://github.com/arichardson updated https://github.com/llvm/llvm-project/pull/67201 >From 6fba1ce12731a7b81384a3aea5422419c7ecb335 Mon Sep 17 00:00:00 2001 From: Alex Richardson Date: Wed, 6 Sep 2023 11:41:56 -0700 Subject: [PATCH] [libunwind][libc++][libc++abi] Add cross-compilation flags t

[clang] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
Artem-B wrote: > > I see one suspicious failure in tensorflow tests. I suspect I've messed > > something up in v4i8 comparison. > > Yup, there is a problem: > > ``` > Successfully custom legalized node > ... replacing: t10: v4i8 = BUILD_VECTOR Constant:i16<-128>, > Constant:i16<-128>, Consta

[clang-tools-extra] [NVPTX] Improve lowering of v4i8 (PR #67866)

2023-10-06 Thread Artem Belevich via cfe-commits
Artem-B wrote: > > I see one suspicious failure in tensorflow tests. I suspect I've messed > > something up in v4i8 comparison. > > Yup, there is a problem: > > ``` > Successfully custom legalized node > ... replacing: t10: v4i8 = BUILD_VECTOR Constant:i16<-128>, > Constant:i16<-128>, Consta

[libunwind] [libunwind][libc++][libc++abi] Add cross-compilation flags to tests (PR #67201)

2023-10-06 Thread Alexander Richardson via cfe-commits
@@ -44,12 +44,8 @@ BACKDEPLOYMENT_PARAMETERS = [ config.substitutions.append(('%{flags}', '-isysroot {}'.format('@CMAKE_OSX_SYSROOT@') if '@CMAKE_OSX_SYSROOT@' else '' )) -config.substitutions.append(('%{compile_flags}', -'-nostdinc++ -I %{include} -I %{libcxx}/test/su

[clang] 4a16b51 - Make -frewrite-includes put an endif at the end of the included text (#67613)

2023-10-06 Thread via cfe-commits
Author: Paul T Robinson Date: 2023-10-06T12:27:07-07:00 New Revision: 4a16b51f438ad2827220bd21799bfee5ff3d55ef URL: https://github.com/llvm/llvm-project/commit/4a16b51f438ad2827220bd21799bfee5ff3d55ef DIFF: https://github.com/llvm/llvm-project/commit/4a16b51f438ad2827220bd21799bfee5ff3d55ef.dif

[clang] Make -frewrite-includes put an endif at the end of the included text (PR #67613)

2023-10-06 Thread Paul T Robinson via cfe-commits
https://github.com/pogo59 closed https://github.com/llvm/llvm-project/pull/67613 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Add -fkeep-system-includes modifier for -E (PR #67684)

2023-10-06 Thread Paul T Robinson via cfe-commits
https://github.com/pogo59 updated https://github.com/llvm/llvm-project/pull/67684 >From 2a0dd575dbbcf80d1cd264d6dbc8de8fa897 Mon Sep 17 00:00:00 2001 From: Paul Robinson Date: Wed, 27 Sep 2023 15:30:52 -0700 Subject: [PATCH 1/5] [NFC] Change a reference member to pointer This will allow th

[clang-tools-extra] Add -fkeep-system-includes modifier for -E (PR #67684)

2023-10-06 Thread Paul T Robinson via cfe-commits
https://github.com/pogo59 updated https://github.com/llvm/llvm-project/pull/67684 >From 2a0dd575dbbcf80d1cd264d6dbc8de8fa897 Mon Sep 17 00:00:00 2001 From: Paul Robinson Date: Wed, 27 Sep 2023 15:30:52 -0700 Subject: [PATCH 1/5] [NFC] Change a reference member to pointer This will allow th

[PATCH] D145214: [TSAN] add support for riscv64

2023-10-06 Thread Aditya Kumar via Phabricator via cfe-commits
hiraditya added inline comments. Comment at: compiler-rt/lib/tsan/rtl/CMakeLists.txt:5 append_list_if(COMPILER_RT_HAS_MSSE4_2_FLAG -msse4.2 TSAN_RTL_CFLAGS) -append_list_if(SANITIZER_LIMIT_FRAME_SIZE -Wframe-larger-than=530 +append_list_if(SANITIZER_LIMIT_FRAME_SIZE -Wframe-larg

[clang] [clang][Sema] Use original template pattern when declaring implicit deduction guides for nested template classes (PR #68379)

2023-10-06 Thread via cfe-commits
https://github.com/antangelo updated https://github.com/llvm/llvm-project/pull/68379 >From e4f4a7bbaad90103e87ad6e6ba80f10fad1e0b58 Mon Sep 17 00:00:00 2001 From: Antonio Abbatangelo Date: Thu, 5 Oct 2023 21:07:37 -0400 Subject: [PATCH 1/2] [clang][Sema] Use original template pattern when decl

[PATCH] D145284: WIP [clang] adds capabilities for SARIF to be written to file

2023-10-06 Thread Christoph Rüthing via Phabricator via cfe-commits
kolrami added a comment. Hi @cjdb , I would be interested in this change also since GCC supports the same sarif-stderr and sarif-file options. Is there a further plan that it might be integrated? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D14528

[clang] 0dfb5da - [clang][modules] Remove preloaded SLocEntries from PCM files (#66962)

2023-10-06 Thread via cfe-commits
Author: Jan Svoboda Date: 2023-10-06T12:50:16-07:00 New Revision: 0dfb5dadc6df0fdc1a25b02921d1faa3d955cd5d URL: https://github.com/llvm/llvm-project/commit/0dfb5dadc6df0fdc1a25b02921d1faa3d955cd5d DIFF: https://github.com/llvm/llvm-project/commit/0dfb5dadc6df0fdc1a25b02921d1faa3d955cd5d.diff L

<    1   2   3   >