[clang] [Clang][InstrProf] Allow mix-up of absolute path with relative path on command line when using -fprofile-list= (PR #67519)

2023-11-08 Thread Shivam Gupta via cfe-commits
https://github.com/xgupta edited https://github.com/llvm/llvm-project/pull/67519 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][InstrProf] Allow mix-up of absolute path with relative path on command line when using -fprofile-list= (PR #67519)

2023-11-08 Thread Shivam Gupta via cfe-commits
https://github.com/xgupta edited https://github.com/llvm/llvm-project/pull/67519 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][InstrProf] Allow mix-up of absolute path with relative path on command line when using -fprofile-list= (PR #67519)

2023-11-08 Thread Shivam Gupta via cfe-commits
https://github.com/xgupta edited https://github.com/llvm/llvm-project/pull/67519 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Handle variable declarations in BreakAfterAttributes (PR #71755)

2023-11-08 Thread Owen Pan via cfe-commits
owenca wrote: > However this doesn't address the second part of the linked issue (with the > `if`) does it? Nope! That part is a duplicate of #64474. I was going to add a note in #71563 before merging this PR but now just saw that @FalcoGer closed the old issue and opened the new one, which i

[clang] Llvm modules on demand bmi (PR #71773)

2023-11-08 Thread Iain Sandoe via cfe-commits
iains wrote: > There are 2 things in the patch. One is to generate the BMI and the object > file in one phase (phase here means preprocess, precompile, compile, ...). This is the main point of the patch - to do this efficiently. >Another is to allow us to generate BMI from a `.cpp` file. (Cu

[clang] [clang] Refactor `IdentifierInfo::ObjcOrBuiltinID` (PR #71709)

2023-11-08 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: Oh, I didn't look into the identifier's system before. I took a while to look at the patch but I failed to understand it and I failed to find the relationships between this patch and header units... https://github.com/llvm/llvm-project/pull/71709

[clang] [clang] Refactor `IdentifierInfo::ObjcOrBuiltinID` (PR #71709)

2023-11-08 Thread Chuanqi Xu via cfe-commits
@@ -86,19 +87,26 @@ enum { IdentifierInfoAlignment = 8 }; static constexpr int ObjCOrBuiltinIDBits = 16; /// The "layout" of ObjCOrBuiltinID is: -/// - The first value (0) represents "not a special identifier". -/// - The next (NUM_OBJC_KEYWORDS - 1) values represent ObjCKey

[clang] [Clang][InstrProf] Allow mix-up of absolute path with relative path on command line when using -fprofile-list= (PR #67519)

2023-11-08 Thread Shivam Gupta via cfe-commits
https://github.com/xgupta edited https://github.com/llvm/llvm-project/pull/67519 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][dataflow][NFC] Fix stale comments. (PR #71654)

2023-11-08 Thread via cfe-commits
https://github.com/martinboehme closed https://github.com/llvm/llvm-project/pull/71654 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] ae74370 - [clang][dataflow][NFC] Fix stale comments. (#71654)

2023-11-08 Thread via cfe-commits
Author: martinboehme Date: 2023-11-09T08:39:06+01:00 New Revision: ae743705113d5ec818517aefa94e704a1257ec95 URL: https://github.com/llvm/llvm-project/commit/ae743705113d5ec818517aefa94e704a1257ec95 DIFF: https://github.com/llvm/llvm-project/commit/ae743705113d5ec818517aefa94e704a1257ec95.diff

[clang] 427f13b - [NFC] [C++20] [Modules] Remove 'ModuleInterface' bit in Sema::ModuleScope

2023-11-08 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2023-11-09T15:20:32+08:00 New Revision: 427f13bd724d332681ca5adb2455b7241af7177d URL: https://github.com/llvm/llvm-project/commit/427f13bd724d332681ca5adb2455b7241af7177d DIFF: https://github.com/llvm/llvm-project/commit/427f13bd724d332681ca5adb2455b7241af7177d.diff LO

[clang] [clang-format] Handle variable declarations in BreakAfterAttributes (PR #71755)

2023-11-08 Thread Emilia Kond via cfe-commits
https://github.com/rymiel approved this pull request. However this doesn't address the second part of the linked issue (with the `if`) does it? https://github.com/llvm/llvm-project/pull/71755 ___ cfe-commits mailing list cfe-commits@lists.llvm.org htt

[lldb] [clang] Reland "[clang][DebugInfo] Emit global variable definitions for static data members with constant initializers" (PR #71780)

2023-11-08 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/71780 >From e5bc858c35b479d29174c9945c6c67f4d2dc085b Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Thu, 9 Nov 2023 01:13:21 + Subject: [PATCH 1/2] Reland "[clang][DebugInfo] Emit global variable definitions

[lldb] [clang] Reland "[clang][DebugInfo] Emit global variable definitions for static data members with constant initializers" (PR #71780)

2023-11-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Michael Buch (Michael137) Changes This patch relands https://github.com/llvm/llvm-project/pull/70639 It was reverted because under certain conditions we triggered an assertion in `DIBuilder`. Specifically, in the original patch we called

[lldb] [clang] Reland "[clang][DebugInfo] Emit global variable definitions for static data members with constant initializers" (PR #71780)

2023-11-08 Thread Michael Buch via cfe-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/71780 This patch relands https://github.com/llvm/llvm-project/pull/70639 It was reverted because under certain conditions we triggered an assertion in `DIBuilder`. Specifically, in the original patch we called `Emi

[clang] [clang-tools-extra] [clang-tidy] fix match for binaryOperator in ExprMutationAnalyzer for misc-const-correctness (PR #70559)

2023-11-08 Thread Piotr Zegar via cfe-commits
PiotrZSL wrote: In tests we usually use `-fno-delayed-template-parsing` to overcome this issue with templates and windows. https://github.com/llvm/llvm-project/pull/70559 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/c

[clang] [clang] Refactor `IdentifierInfo::ObjcOrBuiltinID` (PR #71709)

2023-11-08 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: @ChuanqiXu9 Can I use some of your help? This PR breaks two module tests: ``` Clang :: Modules/cxx20-hu-04.cpp Clang :: Modules/cxx20-module-file-info-macros.cpp ``` Apparently I somehow break import or export of header unit macros. In `cxx20-module-file-info-macros.cpp`, the

[clang] 8feb083 - [clang][Interp] Consider bit width in IntegralAP::toAPSInt() (#71646)

2023-11-08 Thread via cfe-commits
Author: Timm Baeder Date: 2023-11-09T07:46:55+01:00 New Revision: 8feb0830cb5c731a34dc74ff6f0c1c4702bc4734 URL: https://github.com/llvm/llvm-project/commit/8feb0830cb5c731a34dc74ff6f0c1c4702bc4734 DIFF: https://github.com/llvm/llvm-project/commit/8feb0830cb5c731a34dc74ff6f0c1c4702bc4734.diff L

[clang] [clang][Interp] Consider bit width in IntegralAP::toAPSInt() (PR #71646)

2023-11-08 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr closed https://github.com/llvm/llvm-project/pull/71646 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] b7b5907 - [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (#71014)

2023-11-08 Thread via cfe-commits
Author: Chuanqi Xu Date: 2023-11-09T14:42:07+08:00 New Revision: b7b5907b56e98719b1dba8364ebcfb264fc09bfe URL: https://github.com/llvm/llvm-project/commit/b7b5907b56e98719b1dba8364ebcfb264fc09bfe DIFF: https://github.com/llvm/llvm-project/commit/b7b5907b56e98719b1dba8364ebcfb264fc09bfe.diff LO

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

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

[clang] [llvm] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-08 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: Thanks for reviewing this! https://github.com/llvm/llvm-project/pull/71014 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Llvm modules on demand bmi (PR #71773)

2023-11-08 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: This is a little bit far from what I imaged. There are 2 things in the patch. One is to generate the BMI and the object file in one phase (phase here means preprocess, precompile, compile, ...). Another is to allow us to generate BMI from a `.cpp` file. (Currently we only do

[clang] [Clang][InstrProf] Allow absolute path in fun.list of -fprofile-list= (PR #67519)

2023-11-08 Thread Shivam Gupta via cfe-commits
@@ -139,9 +139,23 @@ std::optional ProfileList::isFileExcluded(StringRef FileName, CodeGenOptions::ProfileInstrKind Kind) const { StringRef Section = getSectionName(Kind); - // Check for "source:=" + + // Convert the input file path to its canoni

[clang] [Clang][InstrProf] Allow absolute path in fun.list of -fprofile-list= (PR #67519)

2023-11-08 Thread Shivam Gupta via cfe-commits
https://github.com/xgupta updated https://github.com/llvm/llvm-project/pull/67519 >From 8fdc14ad3a3060407800fe2c570a3631d2a6e1cc Mon Sep 17 00:00:00 2001 From: Shivam Gupta Date: Thu, 19 Oct 2023 18:20:05 +0530 Subject: [PATCH 1/2] [Clang][InstrProf] Allow absolute path in fun.list of -fprofil

[clang] [Clang][InstrProf] Allow absolute path in fun.list of -fprofile-list= (PR #67519)

2023-11-08 Thread Shivam Gupta via cfe-commits
https://github.com/xgupta updated https://github.com/llvm/llvm-project/pull/67519 >From 400c889a4f0e867e3e2ceee43ae5c91f62f63c4d Mon Sep 17 00:00:00 2001 From: Shivam Gupta Date: Thu, 19 Oct 2023 18:20:05 +0530 Subject: [PATCH 1/2] [Clang][InstrProf] Allow absolute path in fun.list of -fprofil

[clang] Llvm modules on demand bmi (PR #71773)

2023-11-08 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 21861991e760e7e845dc1be5b804c950543d699a 6fa533ecaef0f75c87554fb646b0e5dca8ea7255 --

[clang] Llvm modules on demand bmi (PR #71773)

2023-11-08 Thread Iain Sandoe via cfe-commits
https://github.com/iains created https://github.com/llvm/llvm-project/pull/71773 Here is a **draft** of the patch series that allows for emitting both an object and a BMI from the same compiler invocation. Because of point 1) below it's fairly limited in the command lines supported, you can do

[clang] Fix clang to recognize new C23 modifiers %w and %wf when printing (PR #71771)

2023-11-08 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 21861991e760e7e845dc1be5b804c950543d699a 06c4cf02dfb4b20c8349c5f3c7209276f6d56edf --

[libunwind] MIPS/libunwind: Use -mfp64 if compiler is FPXX (PR #68521)

2023-11-08 Thread YunQiang Su via cfe-commits
wzssyqa wrote: @brad0 can you have a look at this PR? https://github.com/llvm/llvm-project/pull/68521 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix clang to recognize new C23 modifiers %w and %wf when printing (PR #71771)

2023-11-08 Thread via cfe-commits
@@ -85,4 +86,31 @@ void z_test(void *p) { scanf("%Z", p); // expected-warning{{invalid conversion specifier 'Z'}} } +void w_int_test(void) { ZijunZhaoCCK wrote: 1. I can't find any tests to verify the print result is correct. Do I miss something? 2. One mo

[clang] Clang/MIPS: Use -mnan value for -mabs if not specified (PR #71157)

2023-11-08 Thread YunQiang Su via cfe-commits
wzssyqa wrote: @brad0 can you have a look at this? https://github.com/llvm/llvm-project/pull/71157 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix clang to recognize new C23 modifiers %w and %wf when printing (PR #71771)

2023-11-08 Thread via cfe-commits
https://github.com/ZijunZhaoCCK created https://github.com/llvm/llvm-project/pull/71771 None >From 06c4cf02dfb4b20c8349c5f3c7209276f6d56edf Mon Sep 17 00:00:00 2001 From: zijunzhao Date: Thu, 9 Nov 2023 02:21:46 + Subject: [PATCH] Fix clang to recognize new C23 modifiers %w and %wf when p

[openmp] [clang] [OpenMP] Cleanup and fixes for ABI agnostic DeviceRTL (PR #71234)

2023-11-08 Thread Saiyedul Islam via cfe-commits
https://github.com/saiislam closed https://github.com/llvm/llvm-project/pull/71234 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 2186199 - [OpenMP] Cleanup and fixes for ABI agnostic DeviceRTL (#71234)

2023-11-08 Thread via cfe-commits
Author: Saiyedul Islam Date: 2023-11-09T10:34:35+05:30 New Revision: 21861991e760e7e845dc1be5b804c950543d699a URL: https://github.com/llvm/llvm-project/commit/21861991e760e7e845dc1be5b804c950543d699a DIFF: https://github.com/llvm/llvm-project/commit/21861991e760e7e845dc1be5b804c950543d699a.diff

[openmp] [clang] [OpenMP] Cleanup and fixes for ABI agnostic DeviceRTL (PR #71234)

2023-11-08 Thread Saiyedul Islam via cfe-commits
https://github.com/saiislam updated https://github.com/llvm/llvm-project/pull/71234 >From a6627248612fd2ab577b456a791e08164674efcc Mon Sep 17 00:00:00 2001 From: Saiyedul Islam Date: Fri, 3 Nov 2023 16:16:25 -0500 Subject: [PATCH 1/3] [OpenMP] Cleanup and fixes for ABI agnostic DeviceRTL Fixes

[clang] [llvm] [clang-tools-extra] [CodeGen] Revamp counted_by calculations (PR #70606)

2023-11-08 Thread Bill Wendling via cfe-commits
@@ -859,53 +860,93 @@ CodeGenFunction::emitBuiltinObjectSize(const Expr *E, unsigned Type, } if (IsDynamic) { -LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel = -getLangOpts().getStrictFlexArraysLevel(); +// The code generated here calculates

[clang] [clang-tools-extra] [llvm] [CodeGen] Revamp counted_by calculations (PR #70606)

2023-11-08 Thread Bill Wendling via cfe-commits
@@ -859,53 +860,93 @@ CodeGenFunction::emitBuiltinObjectSize(const Expr *E, unsigned Type, } if (IsDynamic) { -LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel = -getLangOpts().getStrictFlexArraysLevel(); +// The code generated here calculates

[clang] [clang-format] Handle variable declarations in BreakAfterAttributes (PR #71755)

2023-11-08 Thread Owen Pan via cfe-commits
https://github.com/owenca updated https://github.com/llvm/llvm-project/pull/71755 >From 17921d5a1d74017128691428815ede53ac1a4d67 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Wed, 8 Nov 2023 17:55:56 -0800 Subject: [PATCH] [clang-format] Handle variable declarations in BreakAfterAttributes Al

[clang] 1f21e49 - Revert "Revert "[AMDGPU] const-fold imm operands of (#71669)

2023-11-08 Thread via cfe-commits
Author: Pravin Jagtap Date: 2023-11-09T10:09:22+05:30 New Revision: 1f21e49870feebe6971be4db8d32eee646368cc4 URL: https://github.com/llvm/llvm-project/commit/1f21e49870feebe6971be4db8d32eee646368cc4 DIFF: https://github.com/llvm/llvm-project/commit/1f21e49870feebe6971be4db8d32eee646368cc4.diff

[clang] Revert "Revert "[AMDGPU] const-fold imm operands of (PR #71669)

2023-11-08 Thread Pravin Jagtap via cfe-commits
https://github.com/pravinjagtap closed https://github.com/llvm/llvm-project/pull/71669 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [openmp] [OpenMP] Cleanup and fixes for ABI agnostic DeviceRTL (PR #71234)

2023-11-08 Thread Saiyedul Islam via cfe-commits
https://github.com/saiislam updated https://github.com/llvm/llvm-project/pull/71234 >From 91c64e83b3d8d405e71f8e3108483b88ee4758d8 Mon Sep 17 00:00:00 2001 From: Saiyedul Islam Date: Fri, 3 Nov 2023 16:16:25 -0500 Subject: [PATCH 1/3] [OpenMP] Cleanup and fixes for ABI agnostic DeviceRTL Fixes

[clang] Revert "Revert "[AMDGPU] const-fold imm operands of (PR #71669)

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

[clang] [clang-format] Handle variable declarations in BreakAfterAttributes (PR #71755)

2023-11-08 Thread Owen Pan via cfe-commits
https://github.com/owenca updated https://github.com/llvm/llvm-project/pull/71755 >From c85d3c4879a5ff9d6f3ab318ebd7b63410249062 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Wed, 8 Nov 2023 17:55:56 -0800 Subject: [PATCH] [clang-format] Handle variable declarations in BreakAfterAttributes Al

[clang] Revert "Revert "[AMDGPU] const-fold imm operands of (PR #71669)

2023-11-08 Thread Pravin Jagtap via cfe-commits
https://github.com/pravinjagtap updated https://github.com/llvm/llvm-project/pull/71669 >From 63f870074df10d0e2624632ac2ab0cb0996b436c Mon Sep 17 00:00:00 2001 From: Pravin Jagtap Date: Wed, 8 Nov 2023 07:08:03 -0500 Subject: [PATCH 1/2] Revert "Revert "[AMDGPU] const-fold imm operands of amdg

[clang] Revert "Revert "[AMDGPU] const-fold imm operands of (PR #71669)

2023-11-08 Thread Matt Arsenault via cfe-commits
@@ -0,0 +1,48 @@ +// REQUIRES: amdgpu-registered-target + +// RUN: %clang --offload-arch=gfx906 -S -o - -emit-llvm --cuda-device-only -nogpuinc -nogpulib\ arsenm wrote: This should use %clang_cc1, look at some of the other CodeGen* test run lines for examples

[llvm] [clang] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-08 Thread Wei Wang via cfe-commits
https://github.com/apolloww approved this pull request. https://github.com/llvm/llvm-project/pull/71014 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[llvm] [clang] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-08 Thread Wei Wang via cfe-commits
@@ -0,0 +1,59 @@ +// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -std=c++20 \ +// RUN: -disable-llvm-passes -emit-llvm %s -o - | FileCheck %s + +// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -std=c++20 \ +// RUN: -O3 -emit-llvm %s -o - | FileCheck %s --check-pre

[clang] [X86][AVX10] Permit AVX512 options/features used together with AVX10 (PR #71318)

2023-11-08 Thread Evgenii Kudriashov via cfe-commits
e-kud wrote: I'm a little bit confused, What's the expected behavior of `+avx10.1-512 -avx10.1-256` in codegen aspect. Should we generate only instructions in the difference of sets? Or do we consider `avx10.1-256` as a base of `avx10.1-512` and if it is disabled `avx10.1-512` can't be enabled

[clang] [clang][analyzer] Support `fputc` in StreamChecker (PR #71518)

2023-11-08 Thread Ben Shi via cfe-commits
https://github.com/benshi001 updated https://github.com/llvm/llvm-project/pull/71518 >From 2ebbb60c04968f9c953790daa5c791f072d975b8 Mon Sep 17 00:00:00 2001 From: Ben Shi Date: Tue, 7 Nov 2023 16:44:05 +0800 Subject: [PATCH] [clang][analyzer] Support `fputc` in StreamChecker --- .../StaticAna

[clang] [clang][analyzer] Support `fputc` in StreamChecker (PR #71518)

2023-11-08 Thread Ben Shi via cfe-commits
https://github.com/benshi001 updated https://github.com/llvm/llvm-project/pull/71518 >From 7918014a23d4e4e996896164139dafe3c98aa8a5 Mon Sep 17 00:00:00 2001 From: Ben Shi Date: Tue, 7 Nov 2023 16:44:05 +0800 Subject: [PATCH] [clang][analyzer] Support `fputc` in StreamChecker --- .../StaticAna

[libcxx] [compiler-rt] [clang] [lld] [flang] [libcxxabi] [clang-tools-extra] [llvm] [libc] [libc++] Fix the behavior of throwing `operator new` under -fno-exceptions (PR #69498)

2023-11-08 Thread Louis Dionne via cfe-commits
https://github.com/ldionne updated https://github.com/llvm/llvm-project/pull/69498 >From 77c0256c3ae99808a8def68bfcf5eee2fad704ca Mon Sep 17 00:00:00 2001 From: Louis Dionne Date: Wed, 14 Jun 2023 17:49:22 -0700 Subject: [PATCH 1/9] [libc++] Fix the behavior of throwing `operator new` under -f

[clang] [clang-format] Add ability for clang-format-diff to exit with non-0 status (PR #70883)

2023-11-08 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/70883 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 68d618f - [clang-format] Add ability for clang-format-diff to exit with non-0 status (#70883)

2023-11-08 Thread via cfe-commits
Author: Conrad Donahue Date: 2023-11-08T18:13:03-08:00 New Revision: 68d618f908458e7513e2a56be292216ea0e4ef3f URL: https://github.com/llvm/llvm-project/commit/68d618f908458e7513e2a56be292216ea0e4ef3f DIFF: https://github.com/llvm/llvm-project/commit/68d618f908458e7513e2a56be292216ea0e4ef3f.diff

[clang] [clang-format] Add ability for clang-format-diff to exit with non-0 status (PR #70883)

2023-11-08 Thread Owen Pan via cfe-commits
https://github.com/owenca approved this pull request. https://github.com/llvm/llvm-project/pull/70883 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [X86][AVX10] Permit AVX512 options/features used together with AVX10 (PR #71318)

2023-11-08 Thread Shengchen Kan via cfe-commits
@@ -131,35 +135,50 @@ bool X86TargetInfo::initFeatureMap( continue; } -if (Feature.substr(0, 7) == "+avx10.") { - HasAVX10 = true; - HasAVX512F = true; - if (Feature.substr(Feature.size() - 3, 3) == "512") { -HasEVEX512 = true; - } els

[clang] [clang-format] Handle variable declarations in BreakAfterAttributes (PR #71755)

2023-11-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes Also cleaned up some old test cases. Fixes #71563. --- Full diff: https://github.com/llvm/llvm-project/pull/71755.diff 4 Files Affected: - (modified) clang/docs/ClangFormatStyleOptions.rst (+2-2) - (mo

[llvm] [compiler-rt] [clang-tools-extra] [clang] [InferAddressSpaces] Fix constant replace to avoid modifying other functions (PR #70611)

2023-11-08 Thread Wenju He via cfe-commits
@@ -334,6 +335,15 @@ template<> struct simplify_type { } }; +template <> struct GraphTraits { wenju-he wrote: > For the specific problem here, I'd consider expanding all constant > expressions in the function upfront, and then not having to deal with it.

[clang] [clang-format] Handle variable declarations in BreakAfterAttributes (PR #71755)

2023-11-08 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/71755 Also cleaned up some old test cases. Fixes #71563. >From 40769fdc8163e61c8a89bc983a7fa50b08ba5e04 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Wed, 8 Nov 2023 17:55:56 -0800 Subject: [PATCH] [clang-format] Hand

[clang] [X86][AVX10] Permit AVX512 options/features used together with AVX10 (PR #71318)

2023-11-08 Thread Evgenii Kudriashov via cfe-commits
@@ -131,35 +135,50 @@ bool X86TargetInfo::initFeatureMap( continue; } -if (Feature.substr(0, 7) == "+avx10.") { - HasAVX10 = true; - HasAVX512F = true; - if (Feature.substr(Feature.size() - 3, 3) == "512") { -HasEVEX512 = true; - } els

[clang] [X86][AVX10] Permit AVX512 options/features used together with AVX10 (PR #71318)

2023-11-08 Thread Shengchen Kan via cfe-commits
@@ -131,35 +135,50 @@ bool X86TargetInfo::initFeatureMap( continue; } -if (Feature.substr(0, 7) == "+avx10.") { - HasAVX10 = true; - HasAVX512F = true; - if (Feature.substr(Feature.size() - 3, 3) == "512") { -HasEVEX512 = true; - } els

[llvm] [clang] [Coroutines] Introduce [[clang::coro_only_destroy_when_complete]] (PR #71014)

2023-11-08 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 updated https://github.com/llvm/llvm-project/pull/71014 >From 4531d8b95ecaf08e672939a49fa18415851d136e Mon Sep 17 00:00:00 2001 From: Chuanqi Xu Date: Thu, 2 Nov 2023 11:11:59 +0800 Subject: [PATCH 1/2] [Coroutines] Introduce [[clang::coro_only_destroy_when_comple

[clang] [X86][AVX10] Permit AVX512 options/features used together with AVX10 (PR #71318)

2023-11-08 Thread Shengchen Kan via cfe-commits
@@ -131,35 +135,50 @@ bool X86TargetInfo::initFeatureMap( continue; } -if (Feature.substr(0, 7) == "+avx10.") { - HasAVX10 = true; - HasAVX512F = true; - if (Feature.substr(Feature.size() - 3, 3) == "512") { -HasEVEX512 = true; - } els

[clang] [X86][AVX10] Permit AVX512 options/features used together with AVX10 (PR #71318)

2023-11-08 Thread Shengchen Kan via cfe-commits
@@ -50,11 +50,11 @@ typedef __bf16 __m128bh __attribute__((__vector_size__(16), __aligned__(16))); /* Define the default attributes for the functions in this file. */ #define __DEFAULT_FN_ATTRS \ - __attribute__((__always_

[clang] [X86][AVX10] Permit AVX512 options/features used together with AVX10 (PR #71318)

2023-11-08 Thread Shengchen Kan via cfe-commits
@@ -15,8 +15,12 @@ #define __AVX2INTRIN_H /* Define the default attributes for the functions in this file. */ -#define __DEFAULT_FN_ATTRS256 __attribute__((__always_inline__, __nodebug__, __target__("avx2"), __min_vector_width__(256))) -#define __DEFAULT_FN_ATTRS128 __attribu

[clang] [clang][DependencyScanner] Remove all warning flags when suppressing warnings (PR #71612)

2023-11-08 Thread Michael Spencer via cfe-commits
Bigcheese wrote: Added test comments and added a test for `-Wsystem-headers` being present. https://github.com/llvm/llvm-project/pull/71612 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

[clang] ExtractAPI: use zero-based indices for line/column in symbol graph (PR #71753)

2023-11-08 Thread via cfe-commits
QuietMisdreavus wrote: An unfortunate side effect of changing the source location representation is that it required changing almost all the ExtractAPI tests. 😅 But the overall diff is rather small. cc @daniel-grumberg https://github.com/llvm/llvm-project/pull/71753 _

[clang] [clang][DependencyScanner] Remove all warning flags when suppressing warnings (PR #71612)

2023-11-08 Thread Michael Spencer via cfe-commits
https://github.com/Bigcheese updated https://github.com/llvm/llvm-project/pull/71612 >From 6c8c4cde5698a1693ad64a14a156030f249032a6 Mon Sep 17 00:00:00 2001 From: Michael Spencer Date: Tue, 7 Nov 2023 14:02:38 -1000 Subject: [PATCH 1/2] [clang][DependencyScanner] Remove all warning flags when

[clang] ExtractAPI: use zero-based indices for line/column in symbol graph (PR #71753)

2023-11-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: QuietMisdreavus (QuietMisdreavus) Changes Other implementations of the symbol graph format use zero-based indices for source locations, which causes problems when combined with clang's current one-based indices. This commit sets ExtractAP

[clang] ExtractAPI: use zero-based indices for line/column in symbol graph (PR #71753)

2023-11-08 Thread via cfe-commits
https://github.com/QuietMisdreavus created https://github.com/llvm/llvm-project/pull/71753 Other implementations of the symbol graph format use zero-based indices for source locations, which causes problems when combined with clang's current one-based indices. This commit sets ExtractAPI's sym

[clang] [X86][AVX10] Permit AVX512 options/features used together with AVX10 (PR #71318)

2023-11-08 Thread Shengchen Kan via cfe-commits
@@ -119,9 +119,13 @@ bool X86TargetInfo::initFeatureMap( setFeatureEnabled(Features, F, true); std::vector UpdatedFeaturesVec; - bool HasEVEX512 = true; + std::vector UpdatedAVX10FeaturesVec; + int HasEVEX512 = -1; KanRobert wrote: Use std::optional

[clang] [MS-ABI] create unique vftable name for vftable defined with internal alias. (PR #71748)

2023-11-08 Thread Eli Friedman via cfe-commits
efriedma-quic wrote: > Why are we creating a comdat here in the first place? I guess that's b2615aa4... but I'm pretty sure we fixed -fdata-sections so the backend automatically generates comdats. So maybe we should just revert that. > If we allow creating a comdat associated with an interna

[clang-tools-extra] [llvm] [clang] [CodeGen] Revamp counted_by calculations (PR #70606)

2023-11-08 Thread Yeoul Na via cfe-commits
@@ -859,53 +860,93 @@ CodeGenFunction::emitBuiltinObjectSize(const Expr *E, unsigned Type, } if (IsDynamic) { -LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel = -getLangOpts().getStrictFlexArraysLevel(); +// The code generated here calculates

[clang] [clang][DependencyScanner] Remove all warning flags when suppressing warnings (PR #71612)

2023-11-08 Thread Michael Spencer via cfe-commits
https://github.com/Bigcheese edited https://github.com/llvm/llvm-project/pull/71612 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][DependencyScanner] Remove all warning flags when suppressing warnings (PR #71612)

2023-11-08 Thread Michael Spencer via cfe-commits
@@ -0,0 +1,84 @@ +// RUN: rm -rf %t +// RUN: split-file %s %t +// RUN: sed -e "s|DIR|%/t|g" %t/build/compile-commands.json.in > %t/build/compile-commands.json +// RUN: clang-scan-deps -compilation-database %t/build/compile-commands.json \ +// RUN: -j 1 -format experimental-full

[clang] [clang][DependencyScanner] Remove all warning flags when suppressing warnings (PR #71612)

2023-11-08 Thread Michael Spencer via cfe-commits
@@ -0,0 +1,84 @@ +// RUN: rm -rf %t +// RUN: split-file %s %t +// RUN: sed -e "s|DIR|%/t|g" %t/build/compile-commands.json.in > %t/build/compile-commands.json +// RUN: clang-scan-deps -compilation-database %t/build/compile-commands.json \ +// RUN: -j 1 -format experimental-full

[clang] [MS-ABI] create unique vftable name for vftable defined with internal alias. (PR #71748)

2023-11-08 Thread Eli Friedman via cfe-commits
efriedma-quic wrote: Why are we creating a comdat here in the first place? Creating a comdat associated with an internal symbol doesn't do anything useful: an internal symbol can't be defined in any other translation unit, so the comdat will never be discarded. If we allow creating a comdat

[clang] [clang][DependencyScanner] Remove all warning flags when suppressing warnings (PR #71612)

2023-11-08 Thread Michael Spencer via cfe-commits
@@ -0,0 +1,84 @@ +// RUN: rm -rf %t +// RUN: split-file %s %t +// RUN: sed -e "s|DIR|%/t|g" %t/build/compile-commands.json.in > %t/build/compile-commands.json +// RUN: clang-scan-deps -compilation-database %t/build/compile-commands.json \ +// RUN: -j 1 -format experimental-full

[clang] [clang][DependencyScanner] Remove all warning flags when suppressing warnings (PR #71612)

2023-11-08 Thread Michael Spencer via cfe-commits
@@ -52,6 +52,28 @@ static void optimizeHeaderSearchOpts(HeaderSearchOptions &Opts, Opts.UserEntries.push_back(Entries[Idx]); } +static void optimizeDiagnosticOpts(DiagnosticOptions &Opts, + bool IsSystemModule) { + // If this is not a sy

[clang] [clang][driver] Add \/../include/c++/v1 to include path on Darwin (PR #70817)

2023-11-08 Thread Louis Dionne via cfe-commits
@@ -2494,6 +2494,19 @@ void DarwinClang::AddClangCXXStdlibIncludeArgs( << "\"\n"; } +// Check for the folder where the executable is located, if different. +if (getDriver().getInstalledDir() != getDriver().Dir) { + InstallBin = llvm::StringR

[clang-tools-extra] [clang] [clang-tidy] fix match for binaryOperator in ExprMutationAnalyzer for misc-const-correctness (PR #70559)

2023-11-08 Thread Julian Schmidt via cfe-commits
5chmidti wrote: > how about adding a function call like `f()`? will this can prevent clang > to emit empty function body? Yep, thanks. I went this route, but I had to define a conversion operator to compile and keep the `<<` a `BinaryOperator`. The CI now passes https://github.com/llvm/llvm-p

[openmp] [clang] [llvm] [OpenMP] Rework handling of global ctor/dtors in OpenMP (PR #71739)

2023-11-08 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/71739 >From 5e378ae3efdebedb044528167131c8cae4571a59 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 7 Nov 2023 17:12:31 -0600 Subject: [PATCH] [OpenMP] Rework handling of global ctor/dtors in OpenMP Summary: T

[clang] [llvm] [PowerPC][X86] Make cpu id builtins target independent and lower for PPC (PR #68919)

2023-11-08 Thread Eli Friedman via cfe-commits
@@ -359,6 +359,13 @@ class LLVM_LIBRARY_VISIBILITY PPCTargetInfo : public TargetInfo { bool isSPRegName(StringRef RegName) const override { return RegName.equals("r1") || RegName.equals("x1"); } + + // We support __builtin_cpu_supports/__builtin_cpu_is on targets that

[clang] [MS-ABI] create unique vftable name for vftable defined with internal alias. (PR #71748)

2023-11-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: None (jyu2-git) Changes We got a error: LLVM ERROR: Associative COMDAT symbol '??_7?$T@V6B@' is not a key for its COMDAT Current we create internal alias for vftable when lambd is used. For the test, IR generate: $"??

[clang] [MS-ABI] create unique vftable name for vftable defined with internal alias. (PR #71748)

2023-11-08 Thread via cfe-commits
https://github.com/jyu2-git created https://github.com/llvm/llvm-project/pull/71748 We got a error: LLVM ERROR: Associative COMDAT symbol '??_7?$T@V6B@' is not a key for its COMDAT Current we create internal alias for vftable when lambd is used. For the test, IR generate: $"??_7?$T@V@@$0A@

[clang-tools-extra] [clang] [llvm] [CodeGen] Revamp counted_by calculations (PR #70606)

2023-11-08 Thread Bill Wendling via cfe-commits
@@ -859,53 +860,93 @@ CodeGenFunction::emitBuiltinObjectSize(const Expr *E, unsigned Type, } if (IsDynamic) { -LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel = -getLangOpts().getStrictFlexArraysLevel(); +// The code generated here calculates

[lldb] [clang] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-11-08 Thread Michael Buch via cfe-commits
Michael137 wrote: > This causes Clang to assert: > > ``` > llvm/lib/IR/Metadata.cpp:689: > void llvm::MDNode::resolve(): Assertion `isUniqued() && "Expected this > to be uniqued"' failed. > ``` > > See https://bugs.chromium.org/p/chromium/issues/detail?id=1500262#c1 for a > reprod

[llvm] [clang] [libc++][hardening] Fix references to old names for hardening modes (PR #71743)

2023-11-08 Thread Konstantin Varlamov via cfe-commits
https://github.com/var-const closed https://github.com/llvm/llvm-project/pull/71743 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 4a9c71b - [libc++][hardening] Fix references to old names for hardening modes (#71743)

2023-11-08 Thread via cfe-commits
Author: Konstantin Varlamov Date: 2023-11-08T13:16:01-10:00 New Revision: 4a9c71b8c2d01bf4efacf488d46ed2d92e71f355 URL: https://github.com/llvm/llvm-project/commit/4a9c71b8c2d01bf4efacf488d46ed2d92e71f355 DIFF: https://github.com/llvm/llvm-project/commit/4a9c71b8c2d01bf4efacf488d46ed2d92e71f355

[clang] [llvm] [libc++][hardening] Fix references to old names for hardening modes (PR #71743)

2023-11-08 Thread Louis Dionne via cfe-commits
https://github.com/ldionne edited https://github.com/llvm/llvm-project/pull/71743 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][CodeGen] Ensure consistent `mustprogress` attribute emission across all paths (PR #71452)

2023-11-08 Thread Eli Friedman via cfe-commits
@@ -1482,6 +1477,11 @@ void CodeGenFunction::GenerateCode(GlobalDecl GD, llvm::Function *Fn, } else llvm_unreachable("no definition for emitted function"); + // This is checked after emitting the function body so we know if there + // are any permitted infinite loops.

[clang] [llvm] [libc++][hardening] Fix references to old names for hardening modes (PR #71743)

2023-11-08 Thread Louis Dionne via cfe-commits
@@ -116,7 +116,7 @@ else() set(LIBCXX_ABI_VERSION 2 CACHE STRING "") set(LIBCXX_ENABLE_SHARED OFF CACHE BOOL "") set(LIBCXX_ENABLE_STATIC_ABI_LIBRARY ON CACHE BOOL "") - set(LIBCXX_HARDENING_MODE "unchecked" CACHE STRING "") + set(LIBCXX_HARDENING_MODE "none" CACHE STRI

[clang] [llvm] [libc++][hardening] Fix references to old names for hardening modes (PR #71743)

2023-11-08 Thread Louis Dionne via cfe-commits
https://github.com/ldionne approved this pull request. https://github.com/llvm/llvm-project/pull/71743 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [libc++][hardening] Fix references to old names for hardening modes (PR #71743)

2023-11-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Konstantin Varlamov (var-const) Changes This should fix some builds broken by https://github.com/llvm/llvm-project/pull/70575 --- Full diff: https://github.com/llvm/llvm-project/pull/71743.diff 3 Files Affected: - (modified) clang/cma

[clang] [clang-tools-extra] [llvm] [CodeGen] Revamp counted_by calculations (PR #70606)

2023-11-08 Thread Bill Wendling via cfe-commits
@@ -859,53 +860,93 @@ CodeGenFunction::emitBuiltinObjectSize(const Expr *E, unsigned Type, } if (IsDynamic) { -LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel = -getLangOpts().getStrictFlexArraysLevel(); +// The code generated here calculates

[clang] [llvm] [libc++][hardening] Fix references to old names for hardening modes (PR #71743)

2023-11-08 Thread Konstantin Varlamov via cfe-commits
https://github.com/var-const created https://github.com/llvm/llvm-project/pull/71743 This should fix some builds broken by https://github.com/llvm/llvm-project/pull/70575 >From 11dad502fa66c6f7d0377a554c7f22ef21a9faee Mon Sep 17 00:00:00 2001 From: Konstantin Varlamov Date: Wed, 8 Nov 2023 1

[clang] [clang-tools-extra] [llvm] [CodeGen] Revamp counted_by calculations (PR #70606)

2023-11-08 Thread Bill Wendling via cfe-commits
@@ -859,53 +860,93 @@ CodeGenFunction::emitBuiltinObjectSize(const Expr *E, unsigned Type, } if (IsDynamic) { -LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel = -getLangOpts().getStrictFlexArraysLevel(); +// The code generated here calculates

[clang] [clang-tools-extra] [llvm] [CodeGen] Revamp counted_by calculations (PR #70606)

2023-11-08 Thread Bill Wendling via cfe-commits
@@ -859,53 +860,93 @@ CodeGenFunction::emitBuiltinObjectSize(const Expr *E, unsigned Type, } if (IsDynamic) { -LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel = -getLangOpts().getStrictFlexArraysLevel(); +// The code generated here calculates

[clang] [clang-tools-extra] [llvm] [CodeGen] Revamp counted_by calculations (PR #70606)

2023-11-08 Thread Yeoul Na via cfe-commits
@@ -859,53 +860,93 @@ CodeGenFunction::emitBuiltinObjectSize(const Expr *E, unsigned Type, } if (IsDynamic) { -LangOptions::StrictFlexArraysLevelKind StrictFlexArraysLevel = -getLangOpts().getStrictFlexArraysLevel(); +// The code generated here calculates

[clang] [openmp] [OpenMP] Add support for Solaris/x86_64 (PR #70593)

2023-11-08 Thread Shilei Tian via cfe-commits
@@ -70,6 +72,15 @@ struct kmp_sys_timer { struct timespec start; }; +#ifdef KMP_OS_SOLARIS +// Convert timeval to timespec. +#define TIMEVAL_TO_TIMESPEC(tv, ts) \ shiltian wrote: It looks like this macro is not gu

  1   2   3   4   5   >