[PATCH] D142878: Add testing for Fuchsia multilib

2023-02-04 Thread Petr Hosek via Phabricator via cfe-commits
phosek added inline comments. Comment at: clang/lib/Driver/ToolChains/Fuchsia.cpp:316-317 +void Fuchsia::configureMultilibFlags(Multilib::flags_list &Flags, + bool Exceptions, bool Asan, bool Hwasan, + bool I

[PATCH] D141950: Use find_last_of when seraching for code in getRawCommentForDeclNoCacheImpl

2023-02-04 Thread Kugan Vivekanandarajah via Phabricator via cfe-commits
kuganv updated this revision to Diff 494870. kuganv added a comment. Rebasing branch. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D141950/new/ https://reviews.llvm.org/D141950 Files: clang/lib/AST/ASTContext.cpp Index: clang/lib/AST/ASTContex

[PATCH] D141215: [clang-repl][WIP] Implement pretty printing

2023-02-04 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 494865. junaire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D141215/new/ https://reviews.llvm.org/D141215 Files: clang/include/clang/Interpreter/Interpreter.h clang/include/clang/I

[PATCH] D142630: [clang][Interp] Implement virtual function calls

2023-02-04 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142630/new/ https://reviews.llvm.org/D142630 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[PATCH] D143091: [clang-format] PackConstructorInitializers support PCIS_NextLineOnly

2023-02-04 Thread Owen Pan via Phabricator via cfe-commits
owenpan added inline comments. Comment at: clang/lib/Format/Format.cpp:446 IO.enumCase(Value, "NextLine", FormatStyle::PCIS_NextLine); +IO.enumCase(Value, "OnlyNextLine", FormatStyle::PCIS_NextLineOnly); } Comment at: clang/unittes

[PATCH] D142862: [Support] change StringMap hash function from djbHash to xxHash

2023-02-04 Thread Erik Desjardins via Phabricator via cfe-commits
erikdesjardins updated this revision to Diff 494861. erikdesjardins added a comment. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142862/new/ https://reviews.llvm.org/D142862 Files: clang-tools-extra/test/modularize/ProblemsDisplayLists.

[PATCH] D143304: [Coverage] Map regions from system headers

2023-02-04 Thread Petr Hosek via Phabricator via cfe-commits
phosek accepted this revision. phosek added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143304/new/ https://reviews.llvm.org/D143304 ___

[PATCH] D141569: [clang-tidy] Implement CppCoreGuideline F.18

2023-02-04 Thread Chris Cotter via Phabricator via cfe-commits
ccotter updated this revision to Diff 494852. ccotter added a comment. - Update per https://github.com/isocpp/CppCoreGuidelines/issues/2026 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D141569/new/ https://reviews.llvm.org/D141569 Files: clang-t

[PATCH] D141569: [clang-tidy] Implement CppCoreGuideline F.18

2023-02-04 Thread Chris Cotter via Phabricator via cfe-commits
ccotter updated this revision to Diff 494850. ccotter added a comment. - Add parameter name to diagnostic Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D141569/new/ https://reviews.llvm.org/D141569 Files: clang-tools-extra/clang-tidy/cppcoreguide

[PATCH] D143300: [randstruct] Don't allow implicit forward decl to stop struct randomization

2023-02-04 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. `clang/test/CodeGen/init-randomized-struct-fwd-decl.c` passes without this patch. Is it correct? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143300/new/ https://reviews.llvm.org/D143300 _

[PATCH] D143325: [Driver] Add -mllvm= as an alias for -mllvm

2023-02-04 Thread Joseph Huber via Phabricator via cfe-commits
jhuber6 accepted this revision. jhuber6 added a comment. This revision is now accepted and ready to land. This looks good. I've had similar problems when trying to pass things with arguments via the `-Xarch` or `-Xopenmp-target=` options. Repository: rG LLVM Github Monorepo CHANGES SINCE LAS

[PATCH] D141389: [DFSAN] Add support for strnlen, strncat, strsep, sscanf and _tolower

2023-02-04 Thread Tomasz Kuchta via Phabricator via cfe-commits
tkuchta added inline comments. Comment at: compiler-rt/lib/dfsan/dfsan_custom.cpp:213 + char *res = strsep(s, delim); + s_label = dfsan_read_label(base, strlen(base)); + if (res && (res != base)) { browneee wrote: > tkuchta wrote: > > browneee wrote: > > > tku

[PATCH] D143325: [Driver] Add -mllvm= as an alias for -mllvm

2023-02-04 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 494844. MaskRay added a comment. fix test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143325/new/ https://reviews.llvm.org/D143325 Files: clang/include/clang/Driver/Options.td clang/test/Driver/hip-optio

[PATCH] D143305: [clang] Fix -Xarch_ for -mllvm and alike

2023-02-04 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. An option value treating a space differently (as a delimiter in this case) is uncommon. I suggest an alias `-mllvm=` (D143325 ) which is more inline with the convention of the majority of options that take a value (`=` instead of ` `).

[PATCH] D143325: [Driver] Add -mllvm= as an alias for -mllvm

2023-02-04 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay created this revision. MaskRay added reviewers: jdoerfert, jhuber6, tra, yaxunl. Herald added a reviewer: sscalpone. Herald added a subscriber: jeroen.dobbelaere. Herald added a project: All. MaskRay requested review of this revision. Herald added a project: clang. Herald added a subscriber

[clang] 7e3943f - [clang-linker-wrapper] Fix build after MapVector change

2023-02-04 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2023-02-04T12:54:26-08:00 New Revision: 7e3943f5767d63b24c99aad056ad01cf7e6bfe52 URL: https://github.com/llvm/llvm-project/commit/7e3943f5767d63b24c99aad056ad01cf7e6bfe52 DIFF: https://github.com/llvm/llvm-project/commit/7e3943f5767d63b24c99aad056ad01cf7e6bfe52.diff

[PATCH] D142862: [Support] change StringMap hash function from djbHash to xxHash

2023-02-04 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay accepted this revision. MaskRay added inline comments. Comment at: llvm/test/ObjectYAML/Offload/multiple_members.yaml:21 Value:"gfx908" Content: "cafefeed" Rebase:) I fixed obj2yaml Comment at: llvm/

[PATCH] D143306: [Driver] Default to -fno-openmp-implicit-rpath

2023-02-04 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D143306#4104208 , @JonChesterfield wrote: > Added some people I can remember from the original discussion. > > The effect of this patch will be that clang -fopenmp foo.cpp will build an > executable that doesn't know where it

[PATCH] D143318: [Support] Move ItaniumManglingCanonicalizer and SymbolRemappingReader from Support to ProfileData

2023-02-04 Thread Simon Pilgrim via Phabricator via cfe-commits
RKSimon added a comment. In D143318#4104408 , @MaskRay wrote: > `ItaniumManglingCanonicalizer.cpp` doesn't have many includes. I think it is > fine to remain in llvm/lib/Support ... The frontend cost might not be high - but ItaniumManglingCanonicalizer.

[PATCH] D143318: [Support] Move ItaniumManglingCanonicalizer and SymbolRemappingReader from Support to ProfileData

2023-02-04 Thread Petr Hosek via Phabricator via cfe-commits
phosek added a comment. Another alternative would be to move these classes to the Demangle library. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143318/new/ https://reviews.llvm.org/D143318 ___ cfe-comm

[PATCH] D143318: [Support] Move ItaniumManglingCanonicalizer and SymbolRemappingReader from Support to ProfileData

2023-02-04 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. `ItaniumManglingCanonicalizer.cpp` doesn't have many includes. I think it is fine to remain in llvm/lib/Support ... Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143318/new/ https://reviews.llvm.org/D143318 __

[PATCH] D142891: [clang-format] Recognize Verilog non-blocking assignment

2023-02-04 Thread sstwcw via Phabricator via cfe-commits
sstwcw updated this revision to Diff 494839. sstwcw added a comment. - add parentheses - rename field Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142891/new/ https://reviews.llvm.org/D142891 Files: clang/lib/Format/TokenAnnotator.cpp clang/l

[PATCH] D141569: [clang-tidy] Implement CppCoreGuideline F.18

2023-02-04 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added inline comments. Comment at: clang-tools-extra/clang-tidy/cppcoreguidelines/RvalueReferenceParamNotMovedCheck.cpp:88 + + if (!Param) { +return; Nit: the style convention in LLVM is to not use braces with one-line `if/else`. ===

[PATCH] D142592: [clang-tidy][libc] Add an inline function checker for the libc project.

2023-02-04 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added inline comments. Comment at: clang-tools-extra/clang-tidy/llvmlibc/LLVMLibcTidyModule.cpp:28 +CheckFactories.registerCheck( +"llvmlibc-inline-function-decl-check"); CheckFactories.registerCheck( Remove Comme

[PATCH] D142862: [Support] change StringMap hash function from djbHash to xxHash

2023-02-04 Thread Erik Desjardins via Phabricator via cfe-commits
erikdesjardins updated this revision to Diff 494836. erikdesjardins edited the summary of this revision. erikdesjardins added a comment. update description Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142862/new/ https://reviews.llvm.org/D142862

[PATCH] D142862: [Support] change StringMap hash function from djbHash to xxHash

2023-02-04 Thread Erik Desjardins via Phabricator via cfe-commits
erikdesjardins updated this revision to Diff 494835. erikdesjardins added a comment. rebase, remove now-unnecessary test changes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142862/new/ https://reviews.llvm.org/D142862 Files: clang-tools-extra/

[PATCH] D142592: [clang-tidy][libc] Add an inline function checker for the libc project.

2023-02-04 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added inline comments. Comment at: clang-tools-extra/docs/clang-tidy/checks/llvmlibc/inline-function-decl-check.rst:8 +tagged with the ``LIBC_INLINE`` macro. See the `libc style guide +`_ for more information about this macro

[PATCH] D142592: [clang-tidy][libc] Add an inline function checker for the libc project.

2023-02-04 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added inline comments. Comment at: clang-tools-extra/clang-tidy/llvmlibc/InlineFunctionDeclCheck.cpp:27 + // Consider only explicitly or implicitly inline functions. + if (!FuncDecl->isInlined()) +return; Check if FuncDecl is not a nullptr bef

[PATCH] D142800: [Clang][Diagnostic] Add `-Wcomparison-op-parentheses` to warn on chained comparisons

2023-02-04 Thread Takuya Shimizu via Phabricator via cfe-commits
hazohelet added a comment. > Also, why are these diagnostics off by default? Do we have some idea as to > the false positive rate? As for the false positive rate, I have checked for instances of this warning in the codebases for 'oneapi-src/oneTBB', 'rui314/mold', and 'microsoft/lightgbm', but

[PATCH] D143091: [clang-format] PackConstructorInitializers support PCIS_OnlyNextLine

2023-02-04 Thread Zhikai Zeng via Phabricator via cfe-commits
Backl1ght updated this revision to Diff 494821. Backl1ght added a comment. add more unittest CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143091/new/ https://reviews.llvm.org/D143091 Files: clang/docs/ClangFormatStyleOptions.rst clang/include/clang/Format/Format.h clang/lib/Form

[PATCH] D143109: [Sema] Push a LambdaScopeInfo before calling SubstDefaultArgument

2023-02-04 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added a comment. My question is, why do we need to mess up with scopes in that way outside of parsing (there are only a couple places where we do that at the moment, and they are dummy scopes which only exist to balance some push and pop, afaict they serve no other purpose). As i said

[PATCH] D143319: [clangd] Support iwyu pragma: no_include

2023-02-04 Thread Younan Zhang via Phabricator via cfe-commits
zyounan created this revision. Herald added subscribers: kadircet, arphaman. Herald added a project: All. zyounan updated this revision to Diff 494815. zyounan added a comment. zyounan updated this revision to Diff 494816. zyounan added reviewers: hokein, sammccall, kadircet, nridge. zyounan publis

[PATCH] D143306: [Driver] Default to -fno-openmp-implicit-rpath

2023-02-04 Thread Jon Chesterfield via Phabricator via cfe-commits
JonChesterfield added reviewers: tianshilei1992, ye-luo, RaviNarayanaswamy. JonChesterfield added a comment. Added some people I can remember from the original discussion. The effect of this patch will be that clang -fopenmp foo.cpp will build an executable that doesn't know where its runtime li

[PATCH] D143318: [Support] Move ItaniumManglingCanonicalizer and SymbolRemappingReader from Support to ProfileData

2023-02-04 Thread Simon Pilgrim via Phabricator via cfe-commits
RKSimon created this revision. RKSimon added reviewers: rsmith, chapuni, MaskRay, kristina, erik.pilkington. Herald added subscribers: wenlei, hiraditya. Herald added a project: All. RKSimon requested review of this revision. Herald added projects: clang, LLVM. Herald added a subscriber: cfe-commit

cfe-commits@lists.llvm.org

2023-02-04 Thread Owen Pan via Phabricator via cfe-commits
owenpan accepted this revision. owenpan added inline comments. Comment at: clang/lib/Format/TokenAnnotator.cpp:123 private: + ScopeType getScopeType(FormatToken &Token) { +switch (Token.getType()) { As suggested before. Comment at: clang/

[PATCH] D140723: [clang][Interp] Only check constructors for global variables

2023-02-04 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D140723/new/ https://reviews.llvm.org/D140723 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[PATCH] D142891: [clang-format] Recognize Verilog non-blocking assignment

2023-02-04 Thread Owen Pan via Phabricator via cfe-commits
owenpan added inline comments. Comment at: clang/lib/Format/TokenAnnotator.cpp:1628 bool InCSharpAttributeSpecifier = false; +bool AssignmentFound = false; enum { Comment at: clang/lib/Format/TokenAnnotator.cpp:1935-1936 + }

[PATCH] D143091: [clang-format] PackConstructorInitializers support PCIS_OnlyNextLine

2023-02-04 Thread Owen Pan via Phabricator via cfe-commits
owenpan added inline comments. Comment at: clang/docs/ClangFormatStyleOptions.rst:3891 + * ``PCIS_OnlyNextLine`` (in configuration: ``OnlyNextLine``) +Put all constructor initializers on the next line if they fit. Backl1ght wrote: > @HazardyKnusperkeks M

[PATCH] D143287: [Clang][x86] Change x86 cast intrinsics to use __builtin_nondeterministic_value

2023-02-04 Thread Simon Pilgrim via Phabricator via cfe-commits
RKSimon added a comment. What do we gain from using __builtin_nondeterministic_value instead of just setzero? https://godbolt.org/z/zrb6858Mr Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143287/new/ https://reviews.llvm.org/D143287 _