[clang] [Driver][Solaris][NFC] A little bit of clean up (PR #69867)

2023-10-26 Thread Brad Smith via cfe-commits
https://github.com/brad0 updated https://github.com/llvm/llvm-project/pull/69867 >From 9896afcd836cc87a051dd486034c395eda8493eb Mon Sep 17 00:00:00 2001 From: Brad Smith Date: Sun, 22 Oct 2023 00:55:07 -0400 Subject: [PATCH] [Driver][Solaris][NFC] A little bit of clean up --- clang/lib/Driver/

[clang] [Driver] Add ExclusiveGroup feature to multilib.yaml. (PR #69447)

2023-10-26 Thread Fangrui Song via cfe-commits
@@ -96,13 +97,39 @@ bool MultilibSet::select(const Multilib::flags_list &Flags, llvm::SmallVector &Selected) const { llvm::StringSet<> FlagSet(expandFlags(Flags)); Selected.clear(); - llvm::copy_if(Multilibs, std::back_inserter(Selected), -

[clang] [Driver] Add ExclusiveGroup feature to multilib.yaml. (PR #69447)

2023-10-26 Thread Fangrui Song via cfe-commits
@@ -0,0 +1,69 @@ +# REQUIRES: shell +# UNSUPPORTED: system-windows + +# RUN: rm -rf %t + +# RUN: mkdir -p %t/baremetal_multilib/bin +# RUN: ln -s %clang %t/baremetal_multilib/bin/clang + +# RUN: mkdir -p %t/baremetal_multilib/lib/clang-runtimes +# RUN: ln -s %s %t/baremetal_multil

[clang] [Driver] Add ExclusiveGroup feature to multilib.yaml. (PR #69447)

2023-10-26 Thread Fangrui Song via cfe-commits
@@ -152,6 +180,7 @@ template <> struct llvm::yaml::MappingTraits { static void mapping(llvm::yaml::IO &io, MultilibSerialization &V) { io.mapRequired("Dir", V.Dir); io.mapRequired("Flags", V.Flags); +io.mapOptional("ExclusiveGroup", V.ExclusiveGroup); ---

[clang] [Driver] Add ExclusiveGroup feature to multilib.yaml. (PR #69447)

2023-10-26 Thread Fangrui Song via cfe-commits
@@ -0,0 +1,69 @@ +# REQUIRES: shell +# UNSUPPORTED: system-windows + +# RUN: rm -rf %t + +# RUN: mkdir -p %t/baremetal_multilib/bin +# RUN: ln -s %clang %t/baremetal_multilib/bin/clang + +# RUN: mkdir -p %t/baremetal_multilib/lib/clang-runtimes +# RUN: ln -s %s %t/baremetal_multil

[clang] [Driver] Add ExclusiveGroup feature to multilib.yaml. (PR #69447)

2023-10-26 Thread Fangrui Song via cfe-commits
@@ -96,13 +97,39 @@ bool MultilibSet::select(const Multilib::flags_list &Flags, llvm::SmallVector &Selected) const { llvm::StringSet<> FlagSet(expandFlags(Flags)); Selected.clear(); - llvm::copy_if(Multilibs, std::back_inserter(Selected), -

[clang] [Driver] Add ExclusiveGroup feature to multilib.yaml. (PR #69447)

2023-10-26 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay edited https://github.com/llvm/llvm-project/pull/69447 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Add ExclusiveGroup feature to multilib.yaml. (PR #69447)

2023-10-26 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay edited https://github.com/llvm/llvm-project/pull/69447 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Add processor definition for XiangShan-NanHu (PR #70294)

2023-10-26 Thread Alex Bradbury via cfe-commits
asb wrote: > > @dtcxzyw Could you please confirm the status of this core - is it > > commercially available, an academic test chip, something else? > > It's maintained by Beijing Institute of Open Source Chip (BOSC), a non-profit > organziation founded by companies and researech institutions.

[clang] 88934a8 - [clang-format][NFC] Remove extraneous newlines in some unit test files

2023-10-26 Thread Owen Pan via cfe-commits
Author: Owen Pan Date: 2023-10-26T21:43:27-07:00 New Revision: 88934a82dced0116227e4ad9af8896d8fa0943b8 URL: https://github.com/llvm/llvm-project/commit/88934a82dced0116227e4ad9af8896d8fa0943b8 DIFF: https://github.com/llvm/llvm-project/commit/88934a82dced0116227e4ad9af8896d8fa0943b8.diff LOG:

[clang] [Clang] Mark declarators invalid in the presence of ill-formed explicit parameters. (PR #70018)

2023-10-26 Thread Shafik Yaghmour via cfe-commits
@@ -542,3 +542,46 @@ void foo(C c) { } } + + +namespace GH69838 { +struct S { + S(this auto &self) {} // expected-error {{an explicit object parameter cannot appear in a constructor}} + virtual void f(this S self) {} // expected-error {{an explicit object parameter cannot

[clang] [clang-format] Change LLVM style to BreakAfterAttributes == ABS_Leave (PR #70360)

2023-10-26 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/70360 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ExprConst] Fix crash on uninitialized array subobject (PR #67817)

2023-10-26 Thread Takuya Shimizu via cfe-commits
https://github.com/hazohelet updated https://github.com/llvm/llvm-project/pull/67817 >From 7f4db6d81f24adb72416e79bde65a1a13d9a82b8 Mon Sep 17 00:00:00 2001 From: Takuya Shimizu Date: Fri, 29 Sep 2023 23:49:11 +0900 Subject: [PATCH 1/4] [clang][ExprConst] Fix crash on uninitialized array subob

[clang-tools-extra] [clang-tidy]Fix PreferMemberInitializer false positive for reassignment (PR #70316)

2023-10-26 Thread Congcong Cai via cfe-commits
@@ -570,3 +570,19 @@ struct PR52818 { int bar; }; + +struct RefReassignment { + RefReassignment(int &i) : m_i{i} { +m_i = 1; + } + int & m_i; +}; + +struct ReassignmentAfterUnsafetyAssignment { + ReassignmentAfterUnsafetyAssignment() { +int a = 10; +m_i =

[clang] b88a9f9 - [clang][ExprConst] Fix crash on uninitialized array subobject (#67817)

2023-10-26 Thread via cfe-commits
Author: Takuya Shimizu Date: 2023-10-27T14:11:27+09:00 New Revision: b88a9f9670bb71e1eadeea76b16be6b953714883 URL: https://github.com/llvm/llvm-project/commit/b88a9f9670bb71e1eadeea76b16be6b953714883 DIFF: https://github.com/llvm/llvm-project/commit/b88a9f9670bb71e1eadeea76b16be6b953714883.diff

[clang] [clang][ExprConst] Fix crash on uninitialized array subobject (PR #67817)

2023-10-26 Thread Takuya Shimizu via cfe-commits
https://github.com/hazohelet closed https://github.com/llvm/llvm-project/pull/67817 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [libc++] Fix complexity guarantee in std::clamp (PR #68413)

2023-10-26 Thread via cfe-commits
@@ -37,9 +37,10 @@ struct __fn { _LIBCPP_ASSERT_UNCATEGORIZED(!bool(std::invoke(__comp, std::invoke(__proj, __high), std::invoke(__proj, __low))), "Bad bounds passed to std::ranges::clamp"); -if (std::invoke(__comp, std::invoke(__proj,

[clang] [clang][ExprConst] Fix crash on uninitialized array subobject (PR #67817)

2023-10-26 Thread Timm Baeder via cfe-commits
tbaederr wrote: Thanks. Don't forget to trigger a backport to clang 17 https://github.com/llvm/llvm-project/pull/67817 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ExprConst] Fix crash on uninitialized array subobject (PR #67817)

2023-10-26 Thread Takuya Shimizu via cfe-commits
hazohelet wrote: Thanks for the heads up. I'll request backporting in a few hours when buildbots finish running tests. https://github.com/llvm/llvm-project/pull/67817 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-b

[clang] [RISCV] Add processor definition for XiangShan-NanHu (PR #70294)

2023-10-26 Thread Wang Pengcheng via cfe-commits
wangpc-pp wrote: Xiangshan is of great famousness in China and there is already a community in which many individual developers and organiztions/companies like PLCT, T-Head have participated. So I think we needn't worry about the maintenance. :-) https://github.com/llvm/llvm-project/pull/70294

[clang] [clang-format] Change LLVM style to BreakAfterAttributes == ABS_Leave (PR #70360)

2023-10-26 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: [Mozilla](https://firefox-source-docs.mozilla.org/code-quality/coding-style/coding_style_cpp.html), [WebKit](https://webkit.org/code-style-guidelines/), [GCC](https://gcc.gnu.org/codingconventions.html#Cxx_Conventions), [Microsoft](https://learn.microsoft.com/en-us/dotnet/csharp

[clang] [clang] Change representation of CurLexerKind (PR #70381)

2023-10-26 Thread via cfe-commits
serge-sans-paille wrote: Updated compile time metrics: https://llvm-compile-time-tracker.com/compare.php?from=f9906508bc4f05d3950e2219b4c56f6c078a61ef&to=2631a5163de552a8e482f5cbc51525fb8bb5082f&stat=instructions:u https://github.com/llvm/llvm-project/pull/70381

[clang-tools-extra] [clang-tidy]Fix PreferMemberInitializer false positive for reassignment (PR #70316)

2023-10-26 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 updated https://github.com/llvm/llvm-project/pull/70316 >From 41278ca046ae5d4be4ac4ac1bc673b5010668d9c Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Thu, 26 Oct 2023 18:54:05 +0800 Subject: [PATCH 1/2] [clang-tidy]Fix PreferMemberInitializer false positive fo

[clang] [RISCV] Fix wrong implication for zvknhb. (PR #66860)

2023-10-26 Thread Brandon Wu via cfe-commits
4vtomat wrote: ping https://github.com/llvm/llvm-project/pull/66860 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2023-10-26 Thread Brandon Wu via cfe-commits
4vtomat wrote: ping https://github.com/llvm/llvm-project/pull/68296 ___ 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-26 Thread Brandon Wu via cfe-commits
4vtomat wrote: ping https://github.com/llvm/llvm-project/pull/68297 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Fix wrong implication for zvknhb. (PR #66860)

2023-10-26 Thread Craig Topper via cfe-commits
https://github.com/topperc approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/66860 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-10-26 Thread via cfe-commits
@@ -20,7 +20,7 @@ namespace clang { /// Describes the different kinds of linkage /// (C++ [basic.link], C99 6.2.2) that an entity may have. -enum Linkage : unsigned char { +enum Linkage : unsigned { cor3ntin wrote: can you explain this change? https://github

[clang] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-10-26 Thread via cfe-commits
@@ -49,7 +49,7 @@ struct ExprDependenceScope { using ExprDependence = ExprDependenceScope::ExprDependence; struct TypeDependenceScope { - enum TypeDependence : uint8_t { + enum TypeDependence : unsigned { cor3ntin wrote: Can you explain this change? Making

[clang] [clang-format] Don't break between string literal operands of << (PR #69871)

2023-10-26 Thread Petr Hosek via cfe-commits
petrhosek wrote: We have noticed that after this change, `clang-format` would behave differently depending on the input formatting. (I'm using `--style="{BasedOnStyle: google, ColumnLimit: 0}"` in the examples below.) For example, if the input is ``` return os << "ClientEnd<" << "te

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

2023-10-26 Thread Craig Topper via cfe-commits
@@ -813,6 +813,14 @@ def HasVendorXSfcie : Predicate<"Subtarget->hasVendorXSfcie()">, AssemblerPredicate<(all_of FeatureVendorXSfcie), "'XSfcie' (SiFive Custom Instruction Extension SCIE.)">; +def FeatureVendorXSfvfwmaccqqq +

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

2023-10-26 Thread Craig Topper via cfe-commits
https://github.com/topperc edited https://github.com/llvm/llvm-project/pull/68296 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-10-26 Thread Vlad Serebrennikov via cfe-commits
@@ -49,7 +49,7 @@ struct ExprDependenceScope { using ExprDependence = ExprDependenceScope::ExprDependence; struct TypeDependenceScope { - enum TypeDependence : uint8_t { + enum TypeDependence : unsigned { Endilll wrote: The only place this enum is stored is

[clang] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-10-26 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/70349 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2023-10-26 Thread Craig Topper via cfe-commits
@@ -991,6 +992,7 @@ static const char *ImpliedExtsF[] = {"zicsr"}; static const char *ImpliedExtsV[] = {"zvl128b", "zve64d"}; static const char *ImpliedExtsXTHeadVdot[] = {"v"}; static const char *ImpliedExtsXsfvcp[] = {"zve32x"}; +static const char *ImpliedExtsXsfvfwmaccqqq[]

[clang] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-10-26 Thread Vlad Serebrennikov via cfe-commits
@@ -49,7 +49,7 @@ struct ExprDependenceScope { using ExprDependence = ExprDependenceScope::ExprDependence; struct TypeDependenceScope { - enum TypeDependence : uint8_t { + enum TypeDependence : unsigned { Endilll wrote: In this particular case, width of bit

[clang] [clang] Change representation of CurLexerKind (PR #70381)

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

[clang] [clang] Change representation of CurLexerKind (PR #70381)

2023-10-26 Thread via cfe-commits
@@ -751,13 +751,8 @@ class Preprocessor { std::unique_ptr CurTokenLexer; /// The kind of lexer we're currently working with. - enum CurLexerKind { -CLK_Lexer, -CLK_TokenLexer, -CLK_CachingLexer, -CLK_DependencyDirectivesLexer, -CLK_LexAfterModuleImport

[clang] [clang] Change representation of CurLexerKind (PR #70381)

2023-10-26 Thread via cfe-commits
@@ -643,23 +643,7 @@ void Preprocessor::SkipTokensWhileUsingPCH() { while (true) { bool InPredefines = (CurLexer && CurLexer->getFileID() == getPredefinesFileID()); -switch (CurLexerKind) { -case CLK_Lexer: - CurLexer->Lex(Tok); - break; -case

[clang] [clang] Change representation of CurLexerKind (PR #70381)

2023-10-26 Thread via cfe-commits
https://github.com/cor3ntin commented: This is excellent! I made some naming suggestion. Now that we don't have an enum i think it is clearer to drop the "kind" terminology https://github.com/llvm/llvm-project/pull/70381 ___ cfe-commits mailing list c

[clang] [clang] Change representation of CurLexerKind (PR #70381)

2023-10-26 Thread via cfe-commits
@@ -751,13 +751,8 @@ class Preprocessor { std::unique_ptr CurTokenLexer; /// The kind of lexer we're currently working with. - enum CurLexerKind { -CLK_Lexer, -CLK_TokenLexer, -CLK_CachingLexer, -CLK_DependencyDirectivesLexer, -CLK_LexAfterModuleImport

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

2023-10-26 Thread Craig Topper via cfe-commits
https://github.com/topperc approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/68297 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-10-26 Thread Vlad Serebrennikov via cfe-commits
@@ -20,7 +20,7 @@ namespace clang { /// Describes the different kinds of linkage /// (C++ [basic.link], C99 6.2.2) that an entity may have. -enum Linkage : unsigned char { +enum Linkage : unsigned { Endilll wrote: This case is similar to `TypeDependence` we d

[clang] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-10-26 Thread Timm Baeder via cfe-commits
tbaederr wrote: Since this is done unconditionally, doesn't this mean we now need an unreleased clang to compile? Or are `[[clang::]]` attributes just ignored if they are unknown? https://github.com/llvm/llvm-project/pull/70349 ___ cfe-commits mailin

[clang] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-10-26 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: @tbaederr As highlighted in https://github.com/llvm/llvm-project/pull/69104, this attribute doesn't change semantics of the program, so it's safe to ignore. https://github.com/llvm/llvm-project/pull/70349 ___ cfe-commits mailing list cf

[clang] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-10-26 Thread Timm Baeder via cfe-commits
tbaederr wrote: Sure but clang 16 will emit a warning for them: https://godbolt.org/z/jnsc4336G - are we passing `-Wno-unknown-attributes` to the build? https://github.com/llvm/llvm-project/pull/70349 ___ cfe-commits mailing list cfe-commits@lists.llv

[clang] [Driver][NFC] Make use of final (PR #70416)

2023-10-26 Thread Brad Smith via cfe-commits
https://github.com/brad0 created https://github.com/llvm/llvm-project/pull/70416 None >From 6247344956c34137ced2ae89be1154bd31173d46 Mon Sep 17 00:00:00 2001 From: Brad Smith Date: Fri, 27 Oct 2023 02:22:21 -0400 Subject: [PATCH] [Driver][NFC] Make use of final --- clang/lib/Driver/ToolChains

[clang] [clang][NFC] Annotate `Type` bit-fields with `clang::preferred_type` (PR #70349)

2023-10-26 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: That's a good point. I'm not opposed to wrap this attribute if we must. I'd like to hear from @AaronBallman on this matter. https://github.com/llvm/llvm-project/pull/70349 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://

[clang] [Driver] Link Flang runtime on FreeBSD, NetBSD, OpenBSD, DragonFly and Haiku (PR #69817)

2023-10-26 Thread Andrzej WarzyƄski via cfe-commits
https://github.com/banach-space approved this pull request. LGTM, thanks! https://github.com/llvm/llvm-project/pull/69817 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

<    1   2   3   4   5