[PATCH] D146671: Fix Declaration fragments for instancetype in the type position degrade to id

2023-03-22 Thread NagaChaitanya Vellanki via Phabricator via cfe-commits
chaitanyav created this revision. chaitanyav added a reviewer: dang. Herald added a reviewer: ributzka. Herald added a project: All. chaitanyav requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Fixes https://github.com/llvm/llvm-project/issue

[PATCH] D146669: [-Wunsafe-buffer-usage] Hide fixits/suggestions behind an extra flag, -fsafe-buffer-usage-suggestions.

2023-03-22 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 507549. NoQ added a comment. Add some nice assertions. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146669/new/ https://reviews.llvm.org/D146669 Files: clang/include/clang/Analysis/Analyses/UnsafeBufferUsage.h clang/include/clang/Basic/DiagnosticO

[PATCH] D140722: [OpenMP] Prefix outlined and reduction func names with original func's name

2023-03-22 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert accepted this revision. jdoerfert added a comment. This revision is now accepted and ready to land. Assuming this passes all tests, incl. runtime tests in openmp/libomptarget/tests, LGTM. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D140722/new/ https://reviews.llvm.org/D1407

[PATCH] D145591: [clang][HIP][OpenMP] Add warning if mixed HIP / OpenMP offloading

2023-03-22 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert resigned from this revision. jdoerfert added inline comments. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:8635 + "HIP does not support OpenMP target directives; directive has been ignored">, + InGroup; + yaxunl wrote: > mhalk wrote: >

[PATCH] D130181: [clang-tidy] Add readability-use-early-exits check

2023-03-22 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. In D130181#4213779 , @LegalizeAdulthood wrote: > I'm not certain that the result of the transformation is more "readable"; is > this check intended to aid conformance to a style guide? One of the driving factors of this is tha

[PATCH] D146178: [Clang][Sema] Fix comparison of constraint expressions

2023-03-22 Thread Alexander Shaposhnikov via Phabricator via cfe-commits
alexander-shaposhnikov updated this revision to Diff 507560. alexander-shaposhnikov added a comment. Add more tests. P.S. we already have tests with self-friends (in concepts.cpp), the test from Richard's comment is also included (struct S12) (in a slightly simplified form) Repository: rG LLV

[PATCH] D146678: Summary: Fix ArgsAsWritten being null for ConceptSpecializationExpr in certain circumstances when parsing ASTs

2023-03-22 Thread Walter Gray via Phabricator via cfe-commits
yeswalrus created this revision. Herald added a project: All. yeswalrus requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D146678 Files: clang/include/clang/AST/ExprConcepts.h

[PATCH] D146678: Summary: Fix ArgsAsWritten being null for ConceptSpecializationExpr in certain circumstances when parsing ASTs

2023-03-22 Thread Walter Gray via Phabricator via cfe-commits
yeswalrus added a comment. Solves issue: https://github.com/llvm/llvm-project/issues/61486 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146678/new/ https://reviews.llvm.org/D146678 ___ cfe-commits maili

[PATCH] D146654: [clang] replaces numeric SARIF ids with heirarchical names

2023-03-22 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. Comment at: clang/lib/Frontend/SARIFDiagnostic.cpp:51-52 + Diag->getDiags()->getDiagnosticIDs()->getStableName(Diag->getID()).str(); + std::replace(StableName.begin(), StableName.end(), '_', '.'); + SarifRule Rule = SarifRule::create().setRuleId

[PATCH] D146680: Add test for AST Writer crash

2023-03-22 Thread Walter Gray via Phabricator via cfe-commits
yeswalrus created this revision. Herald added a project: All. yeswalrus requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Fix ArgsAsWritten being null in certain circumstances when parsing ASTs Repository: rG LLVM Github Monorepo https:/

[PATCH] D146680: Fix unexpected nullptr in ConceptSpecializationExpr's ArgsAsWritten field

2023-03-22 Thread Walter Gray via Phabricator via cfe-commits
yeswalrus added a comment. Resolves https://github.com/llvm/llvm-project/issues/61486, Similar to https://reviews.llvm.org/D146678 but targeting the llvm-16 series. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146680/new/ https://reviews.llvm.org

[PATCH] D146680: Fix unexpected nullptr in ConceptSpecializationExpr's ArgsAsWritten field

2023-03-22 Thread Walter Gray via Phabricator via cfe-commits
yeswalrus added a comment. Hoping this can make it into clang-16.0.1, since the crash this causes makes clangd unusable in codebases using concepts in template arguments in this manner. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146680/new/ ht

[PATCH] D143704: [flang] Feature list plugin

2023-03-22 Thread Ethan Luis McDonough via Phabricator via cfe-commits
elmcdonough updated this revision to Diff 507572. Herald added a subscriber: mgrang. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143704/new/ https://reviews.llvm.org/D143704 Files: flang/examples/CMakeLists.txt flang/examples/FeatureList/CMake

[PATCH] D144190: [AIX][clang] Storage Locations for Constant Pointers

2023-03-22 Thread Hubert Tong via Phabricator via cfe-commits
hubert.reinterpretcast added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:5250 + if (Args.hasArg(options::OPT_mroptr) || Args.hasArg(options::OPT_mno_roptr)) { +bool HasRoptr = qiongsiwu1 wrote: > hubert.reinterpretcast wrote: > > Th

[PATCH] D145646: [clang][driver] Enable '-flto' on AVR

2023-03-22 Thread Ben Shi via Phabricator via cfe-commits
benshi001 added a comment. In D145646#4213975 , @MaskRay wrote: > In D145646#4213547 , @gulfem wrote: > >> We started seeing a test failure in `avr-ld.c`. >> >> /b/s/w/ir/x/w/llvm-llvm-project/clang/test/Driver/

[PATCH] D146669: [-Wunsafe-buffer-usage] Hide fixits/suggestions behind an extra flag, -fsafe-buffer-usage-suggestions.

2023-03-22 Thread Jan Korous via Phabricator via cfe-commits
jkorous accepted this revision. jkorous added a comment. This revision is now accepted and ready to land. LGTM. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:11792 "change type of '%0' to '%select{std::span|std::array|std::span::iterator}1' to preserve bounds

[PATCH] D126959: [C++20][Modules] Introduce an implementation module.

2023-03-22 Thread Chuanqi Xu via Phabricator via cfe-commits
ChuanqiXu added a comment. LGTM. Thanks. Comment at: clang/include/clang/Sema/Sema.h:2278 + + /// For an interface unit, this is the implicitly imported interface unit. + clang::Module *ThePrimaryInterface = nullptr; Comment at: clang/lib/

[PATCH] D133375: [CMake] Remove CLANG_DEFAULT_STD_C/CLANG_DEFAULT_STD_CXX

2023-03-22 Thread Sam James via Phabricator via cfe-commits
thesamesam added a comment. In D133375#4214214 , @tambre wrote: > I've now run into a snag with this. Having `clang++.cfg` with `-std=c++2b` > makes `/usr/bin/clang++ -E -dM -` fail with `error: invalid argument > '-std=c++2b' not allowed with 'C'`. > T

[clang] 25557aa - Recommit [Modules] Remove unnecessary check when generating name lookup table in ASTWriter

2023-03-22 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2023-03-23T11:21:35+08:00 New Revision: 25557aa38a0dab76f5b7a4518942f69d879693c0 URL: https://github.com/llvm/llvm-project/commit/25557aa38a0dab76f5b7a4518942f69d879693c0 DIFF: https://github.com/llvm/llvm-project/commit/25557aa38a0dab76f5b7a4518942f69d879693c0.diff LO

[PATCH] D146401: [clang-format] Don't squash Verilog escaped identifiers

2023-03-22 Thread sstwcw via Phabricator via cfe-commits
sstwcw marked an inline comment as done. sstwcw added inline comments. Comment at: clang/unittests/Format/FormatTestVerilog.cpp:897 } +} // namespace +} // namespace test MyDeveloperDay wrote: > is this correct? do you have an anonymous namespace? It is correct.

[clang] 45a0433 - [-Wunsafe-buffer-usage] Add [[fallthrough]] after D143206

2023-03-22 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2023-03-22T21:02:00-07:00 New Revision: 45a0433b39ffbd7cee9cc8a92f2300324b3548e0 URL: https://github.com/llvm/llvm-project/commit/45a0433b39ffbd7cee9cc8a92f2300324b3548e0 DIFF: https://github.com/llvm/llvm-project/commit/45a0433b39ffbd7cee9cc8a92f2300324b3548e0.diff

[PATCH] D146686: [Driver] Fix rpath for compiler-rt

2023-03-22 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl created this revision. yaxunl added reviewers: MaskRay, tra. Herald added a subscriber: dberris. Herald added a project: All. yaxunl requested review of this revision. The compiler-rt library path has changed to {resource_dir}/lib/{triple} from {resource_dir}/lib/{OS}/{arch} but the rpath h

[PATCH] D146503: Fix highlighting issue with _complex and initialization list with more than 2 items

2023-03-22 Thread NagaChaitanya Vellanki via Phabricator via cfe-commits
chaitanyav marked an inline comment as done. chaitanyav added a comment. I reported the flang failures https://github.com/llvm/llvm-project/issues/61634 and it was reverted. How can i trigger a new build with TOT? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://revie

[PATCH] D146603: [docs] Document -fomit-frame-pointer

2023-03-22 Thread Vitaly Buka via Phabricator via cfe-commits
vitalybuka accepted this revision. vitalybuka added inline comments. This revision is now accepted and ready to land. Comment at: clang/include/clang/Driver/Options.td:2643 + HelpText<"Omit the frame pointer from functions that don't need it. " + "Some stack unwinding cases lik

[PATCH] D146501: [clang-format] Don't format already formatted integer literals

2023-03-22 Thread Owen Pan via Phabricator via cfe-commits
owenpan added a comment. In D146501#4209026 , @MyDeveloperDay wrote: > Do we have any unit tests for this that we can pump a shed load of examples > at? I would need to make `checkSeparator()` public to add unit tests for it. Even then, the tests woul

[PATCH] D146501: [clang-format] Don't format already formatted integer literals

2023-03-22 Thread Owen Pan via Phabricator via cfe-commits
owenpan updated this revision to Diff 507622. owenpan added a comment. Simplifies the fix. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146501/new/ https://reviews.llvm.org/D146501 Files: clang/lib/Format/IntegerLiteralSeparatorFixer.cpp Index: clang/lib/Format/IntegerLiteralSepar

<    1   2   3