[PATCH] D149912: [clangd] downgrade missing-includes diagnostic to Information level

2023-05-12 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet accepted this revision. kadircet added a comment. This revision is now accepted and ready to land. thanks, lgtm! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149912/new/ https://reviews.llvm.org/D149912 __

[PATCH] D141215: [clang-repl] Introduce Value to capture expression results

2023-05-12 Thread Jun Zhang via Phabricator via cfe-commits
junaire marked 10 inline comments as done. junaire added inline comments. Comment at: clang/include/clang/Interpreter/Value.h:160-162 + // Interpreter, QualType are stored as void* to reduce dependencies. + void *Interp = nullptr; + void *OpaqueType = nullptr;

[PATCH] D128612: RISC-V big-endian support implementation

2023-05-12 Thread Djordje Todorovic via Phabricator via cfe-commits
djtodoro added a comment. Herald added a subscriber: luke. Hi! I wondering if someone knows what is the status of this. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128612/new/ https://reviews.llvm.org/D128612

[clang] 80a21ea - [clang][analyzer] Cleanup tests of StdCLibraryFunctionsChecker (NFC)

2023-05-12 Thread Balázs Kéri via cfe-commits
Author: Balázs Kéri Date: 2023-05-12T09:54:01+02:00 New Revision: 80a21ea8006fe7bc7ae2b1c9381625aa69b4dace URL: https://github.com/llvm/llvm-project/commit/80a21ea8006fe7bc7ae2b1c9381625aa69b4dace DIFF: https://github.com/llvm/llvm-project/commit/80a21ea8006fe7bc7ae2b1c9381625aa69b4dace.diff L

[PATCH] D149158: [clang][analyzer] Cleanup tests of StdCLibraryFunctionsChecker (NFC)

2023-05-12 Thread Balázs Kéri via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG80a21ea8006f: [clang][analyzer] Cleanup tests of StdCLibraryFunctionsChecker (NFC) (authored by balazske). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D1491

[PATCH] D144943: [clang][Interp] Implement bitcasts (WIP)

2023-05-12 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder updated this revision to Diff 521574. tbaeder marked 3 inline comments as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D144943/new/ https://reviews.llvm.org/D144943 Files: clang/lib/AST/Interp/Boolean.h clang/lib/AST/Interp/ByteCodeExprGen.cpp clang/lib/AST/Interp/Byt

[PATCH] D150124: [index][clangd] Consider labels when indexing function bodies

2023-05-12 Thread Christian Kandeler via Phabricator via cfe-commits
ckandeler updated this revision to Diff 521577. ckandeler marked 2 inline comments as done. ckandeler added a comment. Addressed review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150124/new/ https://reviews.llvm.org/D150124 Files: c

[PATCH] D150430: Implement BufferOverlap check for sprint/snprintf

2023-05-12 Thread Arnaud Bienner via Phabricator via cfe-commits
ArnaudBienner created this revision. Herald added subscribers: steakhal, martong. Herald added a reviewer: NoQ. Herald added a project: All. ArnaudBienner edited the summary of this revision. ArnaudBienner added a subscriber: dergachev.a. ArnaudBienner published this revision for review. Herald add

[PATCH] D103930: [clang][HeaderSearch] Fix implicit module when using header maps

2023-05-12 Thread Ivan Murashko via Phabricator via cfe-commits
ivanmurashko updated this revision to Diff 521580. ivanmurashko added a comment. typo fixed + rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103930/new/ https://reviews.llvm.org/D103930 Files: clang/lib/Lex/HeaderSearch.cpp clang/test/Mo

[PATCH] D150354: [OpenMP][MLIR][Flang][bbc][Driver] Add fopenmp-version and generate corresponding MLIR attribute

2023-05-12 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. All in all LGTM, but I'm not sure whether Flang should be defaulting to OpenMP 5.0. AFAIK, that's not supported yet. Comment at: clang/lib/Driver/ToolChains/Flang.cpp:34 + Args.AddAllArgs(CmdArgs, {options::OPT_ffixed_form, +

[PATCH] D148381: [WIP][Clang] Add element_count attribute

2023-05-12 Thread Florian Hahn via Phabricator via cfe-commits
fhahn added reviewers: rapidsna, fcloutier. fhahn added a comment. Adding a few people who have been working on `-fbounds-safety` proposal (https://llvm.swoogo.com/2023eurollvm/session/1414468/keynote-“-fbounds-safety”-enforcing-bounds-safety-for-production-c-code) Repository: rG LLVM Github

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

2023-05-12 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added inline comments. Comment at: clang/lib/AST/Interp/Interp.h:1560 + // is the furthest we might go up in the hierarchy. + ThisPtr = ThisPtr.getDeclPtr(); +} Just so I don't forget: The assignment to `ThisPtr` here is dead. Repository:

[PATCH] D150191: [clang][Diagnostics] Provide a source range for 'use of undeclared identifier' diagnostics

2023-05-12 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added inline comments. Comment at: clang/lib/Sema/SemaExpr.cpp:2187 else - SemaRef.Diag(TypoLoc, DiagnosticID) << Typo; + SemaRef.Diag(TypoRange.getEnd(), DiagnosticID) << Typo; return; aaron.ballman wrote: > tbaeder wrote: > > I'm not

[PATCH] D150291: [Clang] Rename internal type identifier(s) for __bf16 to BF16Ty

2023-05-12 Thread Ties Stuij via Phabricator via cfe-commits
stuij accepted this revision. stuij added a comment. Regarding this particular change, we at Arm are happy with the name change. I saw BFloat16 instead of BF16 as tech debt that we didn't get round to fixing. I do wonder if we need two bfloat implementations, but for that I'll leave a comment o

[PATCH] D147626: [clang] Reject flexible array member in a union in C++

2023-05-12 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon added a comment. > Well that's... a bit shorter... than I would have expected that union to be. > (I'm not apologizing for the pun.) In clang `union x { short x[]; }; static_assert(sizeof(x)==2);` evaluates to '0 == 2'. That is even shorter, I guess? This is also the reason why uni

[PATCH] D150435: [clang] Fix crash on attempt to initialize union with flexible array member

2023-05-12 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon created this revision. Herald added a project: All. Fznamznon requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Due to missing check on union, there was a null expression added to init list that caused crash later. Fixes https://gi

[PATCH] D147626: [clang] Reject flexible array member in a union in C++

2023-05-12 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon added a comment. I posted a pure crash fix here - https://reviews.llvm.org/D150435 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147626/new/ https://reviews.llvm.org/D147626 ___ cfe-commits m

[PATCH] D150352: [clang][dataflow] Don't analyze templated declarations.

2023-05-12 Thread Martin Böhme via Phabricator via cfe-commits
mboehme updated this revision to Diff 521603. mboehme added a comment. Changes in response to review comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150352/new/ https://reviews.llvm.org/D150352 Files: clang/include/clang/Analysis/FlowSens

[PATCH] D150352: [clang][dataflow] Don't analyze templated declarations.

2023-05-12 Thread Martin Böhme via Phabricator via cfe-commits
mboehme marked an inline comment as done. mboehme added inline comments. Comment at: clang/include/clang/Analysis/FlowSensitive/ControlFlowContext.h:36 + /// `S` resides. `D.isTemplated()` must be false. + static llvm::Expected build(const Decl &D, Stmt &S, +

[PATCH] D149838: [clang][dataflow] Eliminate `SkipPast::ReferenceThenPointer`.

2023-05-12 Thread Martin Böhme via Phabricator via cfe-commits
mboehme updated this revision to Diff 521607. mboehme added a comment. Eliminate unnecessary `else`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149838/new/ https://reviews.llvm.org/D149838 Files: clang/include/clang/Analysis/FlowSensitive/Dat

[PATCH] D149838: [clang][dataflow] Eliminate `SkipPast::ReferenceThenPointer`.

2023-05-12 Thread Martin Böhme via Phabricator via cfe-commits
mboehme marked an inline comment as done. mboehme added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/DataflowEnvironment.cpp:840 +return nullptr; + } else { +return cast(Loc); ymandel wrote: > nit: no need for `else` since `if` branch al

[PATCH] D149573: [Clang][C++23] Implement core language changes from P1467R9 extended floating-point types and standard names and introduce Bfloat16 arithmetic type.

2023-05-12 Thread Ties Stuij via Phabricator via cfe-commits
stuij added a comment. I made a comment on the RFC to understand if we really need/want a new bfloat16 type. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149573/new/ https://reviews

[PATCH] D150258: [clang][parser] Fix namespace dropping after malformed declarations

2023-05-12 Thread Alejandro Álvarez Ayllón via Phabricator via cfe-commits
alejandro-alvarez-sonarsource updated this revision to Diff 521625. alejandro-alvarez-sonarsource added a comment. Applied suggested changes. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150258/new/ https://reviews.llvm.org/D150258 Files: clang/docs/ReleaseNotes.rst clang/lib/Pars

[PATCH] D150258: [clang][parser] Fix namespace dropping after malformed declarations

2023-05-12 Thread Alejandro Álvarez Ayllón via Phabricator via cfe-commits
alejandro-alvarez-sonarsource added inline comments. Comment at: clang/lib/Parse/ParseDecl.cpp:2306-2310 // Otherwise things are very confused and we skip to recover. if (!isDeclarationSpecifier(ImplicitTypenameContext::No)) { - SkipUntil(tok::r_brace, StopAtSemi |

[PATCH] D149997: [clang] [test] Narrow down MSVC specific behaviours from "any windows" to only MSVC/clang-cl

2023-05-12 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added a subscriber: rnk. mstorsjo added a comment. So, the reason why this failed, is that when invoked as `%clang_cc1` in a MSVC/clang-cl style build, `_MSC_VER` isn't predefined, while `_WIN32` is. When invoked via the Clang driver instead of directly going at `-cc1`, `_MSC_VER` does

[PATCH] D150446: [analyzer] Check ArraySubscriptExprs in ArrayBoundCheckerV2

2023-05-12 Thread Donát Nagy via Phabricator via cfe-commits
donat.nagy created this revision. donat.nagy added reviewers: dkrupp, gamesh411, steakhal. Herald added subscribers: manas, ASDenysPetrov, martong, Szelethus, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: NoQ. Herald added a project: All. don

[PATCH] D149986: AMDGPU: Force sc0 and sc1 on stores for gfx940 and gfx941

2023-05-12 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added inline comments. Comment at: llvm/lib/TargetParser/TargetParser.cpp:330-332 case GK_GFX940: + Features["force-store-sc0-sc1"] = true; + [[fallthrough]]; I don't see a reason to set this here. There's no need to expose this to the IR.

[PATCH] D150446: [analyzer] Check ArraySubscriptExprs in ArrayBoundCheckerV2

2023-05-12 Thread Donát Nagy via Phabricator via cfe-commits
donat.nagy added a comment. After some thinking and internal discussion I decided that it'd be better to replace the callback used by this checker. This is a clean but rough draft of this concept; for a final version I'd consider: - adding a secondary callback that handles `*ptr` equivalently

[PATCH] D150446: [analyzer] Check ArraySubscriptExprs in ArrayBoundCheckerV2

2023-05-12 Thread Donát Nagy via Phabricator via cfe-commits
donat.nagy updated this revision to Diff 521640. donat.nagy added a comment. //(Re-uploaded patch to apply clang-format changes and remove a stray temporary comment.)// Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150446/new/ https://reviews.llvm

[PATCH] D148094: [clang][CodeGen] Break up TargetInfo.cpp [8/8]

2023-05-12 Thread Sergei Barannikov via Phabricator via cfe-commits
barannikov88 updated this revision to Diff 521642. barannikov88 added a comment. Undo reformatting in arch-specific files This should help in resolving merge conflicts downstream Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148094/new/ https://rev

[PATCH] D150191: [clang][Diagnostics] Provide a source range for 'use of undeclared identifier' diagnostics

2023-05-12 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/Sema/SemaExpr.cpp:2187 else - SemaRef.Diag(TypoLoc, DiagnosticID) << Typo; + SemaRef.Diag(TypoRange.getEnd(), DiagnosticID) << Typo; return; tbaeder wrote: > aaron.ballman wrote: > > t

[PATCH] D150364: [clang][Interp] Add 'Invalid' opcode and use it for throw/asm stmts

2023-05-12 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM Comment at: clang/test/AST/Interp/records.cpp:341 + +/// FIXME: Wrong source location below. +return 12; // expected-note {{in call to '&S{}->~S()'

[PATCH] D149133: [clang][Interp] BaseToDerived casts

2023-05-12 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. Ping CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149133/new/ https://reviews.llvm.org/D149133 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D144164: [clang][Interp] Handle PtrMemOps

2023-05-12 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/D144164/new/ https://reviews.llvm.org/D144164 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[PATCH] D149550: [clang][Interp] Fix compound assign operator evaluation order

2023-05-12 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. Ping CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149550/new/ https://reviews.llvm.org/D149550 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Erich Keane via Phabricator via cfe-commits
erichkeane created this revision. erichkeane added reviewers: clang-language-wg, aaron.ballman. Herald added a project: All. erichkeane requested review of this revision. Herald added a subscriber: MaskRay. Now that we've updated to C++23, we need to add C++26/C++2c command line flags, as discusse

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added inline comments. Comment at: clang/include/clang/Basic/DiagnosticGroups.td:310 DiagGroup<"pre-c++23-compat-pedantic", [CXXPre23Compat]>; +def CXXPre26Compat : DiagGroup<"pre-c++26-compat">; +def CXXPre26CompatPedantic : Aaron: note the names o

[PATCH] D145343: [AMDGPU] Emit predefined macro `__AMDGCN_CUMODE__`

2023-05-12 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added inline comments. Comment at: clang/include/clang/Basic/DiagnosticDriverKinds.td:121-123 +def warn_drv_unsupported_option_for_processor : Warning< + "ignoring '%0' option as it is not currently supported for processor '%1'">, + InGroup; I'm surprise

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added a comment. Similar PR here https://reviews.llvm.org/D149875 Comment at: clang/docs/ReleaseNotes.rst:114 +^ +- Compiler flags -std=c++2c and -std=gnu++2c have been added for experimental C++26 implementation work. + This shoul

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added inline comments. Comment at: clang/lib/Frontend/InitPreprocessor.cpp:456 + // FIXME: Use correct value for C++26. + Builder.defineMacro("__cplusplus", "202102L"); +// FIXME: Use correct value for C++23, and update C++26 to be 'one more'. -

[PATCH] D146054: [RISCV] Add --print-supported-extensions and -march=help support

2023-05-12 Thread Kito Cheng via Phabricator via cfe-commits
kito-cheng added a comment. GCC ins't implement yet, but planed, so add it later I think? @4vtomat already drop -march=help, @MaskRay did you mind take a look again? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146054/new/ https://reviews.llvm.or

[PATCH] D145343: [AMDGPU] Emit predefined macro `__AMDGCN_CUMODE__`

2023-05-12 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added inline comments. Comment at: clang/include/clang/Basic/DiagnosticDriverKinds.td:121-123 +def warn_drv_unsupported_option_for_processor : Warning< + "ignoring '%0' option as it is not currently supported for processor '%1'">, + InGroup; arsenm wrote

[PATCH] D150258: [clang][parser] Fix namespace dropping after malformed declarations

2023-05-12 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM! Do you need me to commit on your behalf? If so, what name and email address would you like used for patch attribution? Comment at: clang/lib/Parse/ParseD

[PATCH] D150452: [clang-format] Recognize nested blocks

2023-05-12 Thread sstwcw via Phabricator via cfe-commits
sstwcw created this revision. Herald added projects: All, clang, clang-format. Herald added a subscriber: cfe-commits. Herald added reviewers: rymiel, HazardyKnusperkeks, owenpan, MyDeveloperDay. sstwcw requested review of this revision. Now a block gets recognized as a block if it contains a bloc

[PATCH] D144654: [Lex] Warn when defining or undefining any builtin macro

2023-05-12 Thread John Brawn via Phabricator via cfe-commits
john.brawn planned changes to this revision. john.brawn added a comment. The clang-tidy failures in pre-merge are because - clang-tidy tests use the compile database from building llvm (though you have to manually copy it otherwise the tests silently pass without actually running the test, whic

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Erich Keane via Phabricator via cfe-commits
erichkeane marked 4 inline comments as done. erichkeane added a subscriber: Mordante. erichkeane added a comment. In D150450#4337858 , @cor3ntin wrote: > Similar PR here https://reviews.llvm.org/D149875 Ah! I'd not noticed that one (or maybe someone ment

[PATCH] D149562: [clang-format] Stop comment disrupting indentation of Verilog ports

2023-05-12 Thread sstwcw via Phabricator via cfe-commits
sstwcw added a comment. > I agree if the brace doesn't start a block, but clang-format sometimes got it > wrong and misannotates a block as a braced list. (See > https://github.com/llvm/llvm-project/issues/33891 for an example.) This patch isn't affected by the problem. The Verilog port list i

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 521661. erichkeane added a comment. Update based on @cor3ntin s feedback. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150450/new/ https://reviews.llvm.org/D150450 Files: clang/docs/CommandGuide/clang.rst clang/docs/ReleaseNotes.rst clang

[clang] fd55636 - [clang] Restores some -std=c++2b tests.

2023-05-12 Thread Mark de Wever via cfe-commits
Author: Mark de Wever Date: 2023-05-12T17:44:59+02:00 New Revision: fd556368a1a85eda27c2490331646b2913f16527 URL: https://github.com/llvm/llvm-project/commit/fd556368a1a85eda27c2490331646b2913f16527 DIFF: https://github.com/llvm/llvm-project/commit/fd556368a1a85eda27c2490331646b2913f16527.diff

[PATCH] D150063: [clang] Restores some -std=c++2b tests.

2023-05-12 Thread Mark de Wever via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGfd556368a1a8: [clang] Restores some -std=c++2b tests. (authored by Mordante). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150063/new/ https://reviews.llvm

[PATCH] D150452: [clang-format] Recognize nested blocks

2023-05-12 Thread sstwcw via Phabricator via cfe-commits
sstwcw updated this revision to Diff 521667. sstwcw added a comment. - Remove the special case for operator[], it isn't necessary. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150452/new/ https://reviews.llvm.org/D150452 Files: clang/lib/Format

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Mark de Wever via Phabricator via cfe-commits
Mordante added a comment. In D150450#4337952 , @erichkeane wrote: > In D150450#4337858 , @cor3ntin > wrote: > >> Similar PR here https://reviews.llvm.org/D149875 > > Ah! I'd not noticed that one (or maybe someon

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 521675. erichkeane marked an inline comment as done. erichkeane added a comment. fix init-preprocessor, remove fixme. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150450/new/ https://reviews.llvm.org/D150450 Files: clang/docs/CommandGuide/cla

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. In D150450#4338034 , @Mordante wrote: > In D150450#4337952 , @erichkeane > wrote: > >> In D150450#4337858 , @cor3ntin >> wrote: >> >>> Simila

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 521680. erichkeane added a comment. Added clang-cl versioning as stolen from @Mordante CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150450/new/ https://reviews.llvm.org/D150450 Files: clang/docs/CommandGuide/clang.rst clang/docs/ReleaseNote

[PATCH] D145343: [AMDGPU] Emit predefined macro `__AMDGCN_CUMODE__`

2023-05-12 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added inline comments. Comment at: clang/lib/Driver/ToolChains/CommonArgs.cpp:146 +return false; + return TargetFeature == "no-cumode"; +} yaxunl wrote: > arsenm wrote: > > I don't understand the use of "no-cumode". Where is this defined? > This funct

[PATCH] D150291: [Clang] Rename internal type identifier(s) for __bf16 to BF16Ty

2023-05-12 Thread Tom Honermann via Phabricator via cfe-commits
tahonermann requested changes to this revision. tahonermann added a comment. This revision now requires changes to proceed. > I do wonder if we need two bfloat implementations, but for that I'll leave a > comment on D149573 . Given the discussions occurring in D

[PATCH] D150427: [AMDGPU] Non hostcall printf support for HIP

2023-05-12 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added inline comments. Comment at: clang/include/clang/Basic/LangOptions.def:274 LANGOPT(OffloadingNewDriver, 1, 0, "use the new driver for generating offloading code.") +ENUM_LANGOPT(AMDGPUPrintfKindVal, AMDGPUPrintfKind, 2, AMDGPUPrintfKind::Buffered, "printf lowering

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Mark de Wever via Phabricator via cfe-commits
Mordante accepted this revision. Mordante added a comment. This revision is now accepted and ready to land. In D150450#4338065 , @erichkeane wrote: > In D150450#4338034 , @Mordante > wrote: > >> In D150450#43379

[PATCH] D150427: [AMDGPU] Non hostcall printf support for HIP

2023-05-12 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added inline comments. Comment at: clang/include/clang/Driver/Options.td:1036 + NormalizedValues<["Hostcall", "Buffered"]>, + MarshallingInfoEnum, "Hostcall">; def fgpu_default_stream_EQ : Joined<["-"], "fgpu-default-stream=">, as a target option, usual

[PATCH] D149573: [Clang][C++23] Implement core language changes from P1467R9 extended floating-point types and standard names and introduce Bfloat16 arithmetic type.

2023-05-12 Thread M. Zeeshan Siddiqui via Phabricator via cfe-commits
codemzs marked an inline comment as done. codemzs added a comment. In D149573#4337480 , @stuij wrote: > I made a comment on the RFC > > to understand

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 521688. erichkeane added a comment. Updated last few things @Mordante mentioned, did a rebase. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150450/new/ https://reviews.llvm.org/D150450 Files: clang/docs/CommandGuide/clang.rst clang/docs/Re

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin accepted this revision. cor3ntin added a comment. LGTM. I'm looking forward to start implementing upcoming proposals CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150450/new/ https://reviews.llvm.org/D150450 ___ cfe-commits mailing l

[PATCH] D150226: [Clang] Remove ability to downgrade warning on the diagnostic for setting a non fixed enum to a value outside the range of the enumeration values

2023-05-12 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment. In D150226#4336755 , @rupprecht wrote: > We're still using `-Wno-enum-constexpr-conversion`, although I'm not sure if > we need that or if we just forgot to remove it after doing some cleanup. I'm > trying it out now. (Sorry, I'm

[PATCH] D150461: [OpenMP] Naturally align internal global variables in the OpenMPIRBuilder

2023-05-12 Thread Joseph Huber via Phabricator via cfe-commits
jhuber6 created this revision. jhuber6 added reviewers: jdoerfert, tianshilei1992, ABataev, JonChesterfield, tstellar, gchatelet. Herald added subscribers: sunshaoce, guansong, hiraditya, yaxunl. Herald added a project: All. jhuber6 requested review of this revision. Herald added subscribers: llvm

[PATCH] D150461: [OpenMP] Naturally align internal global variables in the OpenMPIRBuilder

2023-05-12 Thread Shilei Tian via Phabricator via cfe-commits
tianshilei1992 accepted this revision. tianshilei1992 added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150461/new/ https://reviews.llvm.org/D150461 _

[PATCH] D149997: [clang] [test] Narrow down MSVC specific behaviours from "any windows" to only MSVC/clang-cl

2023-05-12 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. In D149997#4337548 , @mstorsjo wrote: > So, the reason why this failed, is that when invoked as `%clang_cc1` in a > MSVC/clang-cl style build, `_MSC_VER` isn't predefined, while `_WIN32` is. > When invoked via the Clang driver inste

[PATCH] D150226: [Clang] Remove ability to downgrade warning on the diagnostic for setting a non fixed enum to a value outside the range of the enumeration values

2023-05-12 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment. In D150226#4336771 , @manojgupta wrote: > We also use Wno-enum-constexpr-conversion in ChromeOS. There are many > packages that break with this warning. One of them is boost which is used in > many other packages. > > The errors

[PATCH] D150427: [AMDGPU] Non hostcall printf support for HIP

2023-05-12 Thread Joseph Huber via Phabricator via cfe-commits
jhuber6 added a comment. Where does the runtime implementation of this live? I'm not very familiar with the HIP / hostcall ecosystem. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150427/new/ https://reviews.llvm.org/D150427 _

[PATCH] D145343: [AMDGPU] Emit predefined macro `__AMDGCN_CUMODE__`

2023-05-12 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 521714. yaxunl marked an inline comment as done. yaxunl added a comment. revised by Matt's comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D145343/new/ https://reviews.llvm.org/D145343 Files: clang/include/clang/Basic/DiagnosticDriverKinds.t

[PATCH] D150427: [AMDGPU] Non hostcall printf support for HIP

2023-05-12 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added inline comments. Comment at: clang/include/clang/Basic/LangOptions.def:274 LANGOPT(OffloadingNewDriver, 1, 0, "use the new driver for generating offloading code.") +ENUM_LANGOPT(AMDGPUPrintfKindVal, AMDGPUPrintfKind, 2, AMDGPUPrintfKind::Buffered, "printf lowering

[PATCH] D150226: [Clang] Remove ability to downgrade warning on the diagnostic for setting a non fixed enum to a value outside the range of the enumeration values

2023-05-12 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment. In D150226#4336803 , @thesamesam wrote: > Adding to the concerns raised above, I don't think we're there yet. See > https://bugs.gentoo.org/buglist.cgi?quicksearch=enum-constexpr-conversion&list_id=6843355 > and keep in mind tha

[clang] 49b87b0 - [Driver] -ftime-trace: derive trace file names from -o and -dumpdir

2023-05-12 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2023-05-12T10:46:06-07:00 New Revision: 49b87b05726b4395503230c3d400f93c626e6dce URL: https://github.com/llvm/llvm-project/commit/49b87b05726b4395503230c3d400f93c626e6dce DIFF: https://github.com/llvm/llvm-project/commit/49b87b05726b4395503230c3d400f93c626e6dce.diff

[PATCH] D150282: [Driver] -ftime-trace: derive trace file names from -o and -dumpdir

2023-05-12 Thread Fangrui Song via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG49b87b05726b: [Driver] -ftime-trace: derive trace file names from -o and -dumpdir (authored by MaskRay). Repository: rG LLVM Github Monorepo CHAN

[PATCH] D150403: [clang-format] Adjust braced list detection (try 2)

2023-05-12 Thread Galen Elias via Phabricator via cfe-commits
galenelias added a subscriber: sstwcw. galenelias added a comment. Looks like @sstwcw also submitted a fix for the same issue, with a bit of a different approach: https://reviews.llvm.org/D150452 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150403

[PATCH] D150452: [clang-format] Recognize nested blocks

2023-05-12 Thread Galen Elias via Phabricator via cfe-commits
galenelias added a comment. Coincidentally I also sent out a review to fix this issue yesterday, but went with a different approach of trying to scope the ProbablyBracedList logic by just looking at the lbrace previous token. https://reviews.llvm.org/D150403 Repository: rG LLVM Github Monor

[PATCH] D150461: [OpenMP] Naturally align internal global variables in the OpenMPIRBuilder

2023-05-12 Thread Guillaume Chatelet via Phabricator via cfe-commits
gchatelet accepted this revision. gchatelet added a comment. You beat me to it :) Thx for the fix. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150461/new/ https://reviews.llvm.org/D150461 ___ cfe-commi

[PATCH] D150461: [OpenMP] Naturally align internal global variables in the OpenMPIRBuilder

2023-05-12 Thread Guillaume Chatelet via Phabricator via cfe-commits
gchatelet added a comment. quick question, did you try to build the openmp runtime as well to check if the tests still pass? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150461/new/ https://reviews.llvm.org/D150461 __

[PATCH] D150461: [OpenMP] Naturally align internal global variables in the OpenMPIRBuilder

2023-05-12 Thread Joseph Huber via Phabricator via cfe-commits
jhuber6 added a comment. In D150461#4338498 , @gchatelet wrote: > quick question, did you try to build the openmp runtime as well to check if > the tests still pass? I'm an OpenMP developer so I always have it built : ). Yes they still pass. Repositor

[PATCH] D150221: Add option -fkeep-static-variables to emit all static variables

2023-05-12 Thread Zheng Qian via Phabricator via cfe-commits
qianzhen added a comment. This is useful in keeping the static variables in a patchable function (https://clang.llvm.org/docs/AttributeReference.html#patchable-function-entry), so that they can be directly addressed by a hot patch when the optimization to merge them is enabled (https://llvm.or

[PATCH] D150461: [OpenMP] Naturally align internal global variables in the OpenMPIRBuilder

2023-05-12 Thread Guillaume Chatelet via Phabricator via cfe-commits
gchatelet added a comment. In D150461#4338499 , @jhuber6 wrote: > In D150461#4338498 , @gchatelet > wrote: > >> quick question, did you try to build the openmp runtime as well to check if >> the tests still pass

[PATCH] D150461: [OpenMP] Naturally align internal global variables in the OpenMPIRBuilder

2023-05-12 Thread Joseph Huber via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGdd02984519ab: [OpenMP] Naturally align internal global variables in the OpenMPIRBuilder (authored by jhuber6). Repository: rG LLVM Github Monorepo

[clang] dd02984 - [OpenMP] Naturally align internal global variables in the OpenMPIRBuilder

2023-05-12 Thread Joseph Huber via cfe-commits
Author: Joseph Huber Date: 2023-05-12T13:14:27-05:00 New Revision: dd02984519abafe7637cdafcf4ede8b303f385ab URL: https://github.com/llvm/llvm-project/commit/dd02984519abafe7637cdafcf4ede8b303f385ab DIFF: https://github.com/llvm/llvm-project/commit/dd02984519abafe7637cdafcf4ede8b303f385ab.diff

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay accepted this revision. MaskRay added inline comments. Comment at: clang/docs/ReleaseNotes.rst:114 +^ +- Compiler flags -std=c++2c and -std=gnu++2c have been added for experimental C++26 implementation work. + cor3ntin wrote: > This s

[PATCH] D148654: Modify BoundsSan to improve debuggability

2023-05-12 Thread Oskar Wirga via Phabricator via cfe-commits
oskarwirga added a comment. CC: @nlopes @chandlerc @jgalenson I have y'all added here because of your past work on BoundsSan, if you know of anyone else who may be able to provide review please tag them! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.or

[PATCH] D148094: [clang][CodeGen] Break up TargetInfo.cpp [8/8]

2023-05-12 Thread Sergei Barannikov via Phabricator via cfe-commits
barannikov88 added a comment. ping :) Any comments / questions / suggestions are welcome Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148094/new/ https://reviews.llvm.org/D148094 ___ cfe-commits mailing

[PATCH] D146389: [clang-repl][CUDA] Initial interactive CUDA support for clang-repl

2023-05-12 Thread Anubhab Ghosh via Phabricator via cfe-commits
argentite updated this revision to Diff 521742. argentite marked an inline comment as done. argentite added a comment. Add some CUDA basic functionality tests. Disallow undo-ing of the initial PTU. This should fix the undo command test. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST A

[PATCH] D150450: Add C++26 compile flags.

2023-05-12 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 521743. erichkeane marked an inline comment as done. erichkeane added a comment. Added double-backticks, updated the tests for the new __cplusplus entries I changed during review. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150450/new/ https:/

[PATCH] D150291: [Clang] Rename internal type identifier(s) for __bf16 to BF16Ty

2023-05-12 Thread M. Zeeshan Siddiqui via Phabricator via cfe-commits
codemzs added a comment. In D150291#4338118 , @tahonermann wrote: >> I do wonder if we need two bfloat implementations, but for that I'll leave a >> comment on D149573 . > > Given the discussions occurring in D149573 >

[PATCH] D146342: [-Wunsafe-buffer-usage] Move the whole analysis to the end of a translation unit

2023-05-12 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 marked an inline comment as done. ziqingluo-90 added inline comments. Comment at: clang/lib/Sema/AnalysisBasedWarnings.cpp:2364 + Node->getBeginLoc())) { + UnsafeBufferUsageReporter R(S); + clang::checkUnsafeBufferUsage(Node, R, Unsa

[PATCH] D150446: [analyzer] Check ArraySubscriptExprs in ArrayBoundCheckerV2

2023-05-12 Thread Balázs Benics via Phabricator via cfe-commits
steakhal added a comment. I still struggle to see the motivation. Please consider adding a test demonstraing a case when the diagnostic is not relevant or easily misunderstood by the users. Alternatively, give an evaluation of this change so that I can see it myself. In the end it would still m

[PATCH] D150282: [Driver] -ftime-trace: derive trace file names from -o and -dumpdir

2023-05-12 Thread Douglas Yung via Phabricator via cfe-commits
dyung added inline comments. Comment at: clang/test/Driver/ftime-trace.cpp:54 +// RUN: %clang -### -ftime-trace=e -ftime-trace-granularity=0 d/a.cpp d/b.c -o f/x -dumpdir f/ 2>&1 | FileCheck %s --check-prefix=LINK3 +// LINK3: -cc1{{.*}} "-ftime-trace=e/a-{{[^.]*}}.json" "-ftime

[PATCH] D146342: [-Wunsafe-buffer-usage] Move the whole analysis to the end of a translation unit

2023-05-12 Thread Ziqing Luo via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. ziqingluo-90 marked an inline comment as done. Closed by commit rG6d861d498de1: [-Wunsafe-buffer-usage] Move the whole analysis to the end of a translation unit (author

[clang] 6d861d4 - [-Wunsafe-buffer-usage] Move the whole analysis to the end of a translation unit

2023-05-12 Thread via cfe-commits
Author: ziqingluo-90 Date: 2023-05-12T11:50:51-07:00 New Revision: 6d861d498de1320d22771c329ec69f9419ef06b7 URL: https://github.com/llvm/llvm-project/commit/6d861d498de1320d22771c329ec69f9419ef06b7 DIFF: https://github.com/llvm/llvm-project/commit/6d861d498de1320d22771c329ec69f9419ef06b7.diff

[PATCH] D150226: [Clang] Remove ability to downgrade warning on the diagnostic for setting a non fixed enum to a value outside the range of the enumeration values

2023-05-12 Thread Manoj Gupta via Phabricator via cfe-commits
manojgupta added a comment. > I was under the impression from https://github.com/boostorg/mpl/issues/69 > that this was fixed but there are a number of issues off of the main one and > maybe I am confused. Seems like boost 1.81 has the mentioned fix. I can try it and see if the warning still f

[clang] d66417f - [test] Fix ftime-trace.cpp on Windows

2023-05-12 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2023-05-12T12:23:30-07:00 New Revision: d66417f0ae9d6b5e1be9b80c0c3630601169818d URL: https://github.com/llvm/llvm-project/commit/d66417f0ae9d6b5e1be9b80c0c3630601169818d DIFF: https://github.com/llvm/llvm-project/commit/d66417f0ae9d6b5e1be9b80c0c3630601169818d.diff

[PATCH] D150473: [clang/Driver] Also consider `gnu++` standard when checking for modules support

2023-05-12 Thread Argyrios Kyrtzidis via Phabricator via cfe-commits
akyrtzi created this revision. Herald added a project: All. akyrtzi requested review of this revision. Herald added subscribers: cfe-commits, MaskRay. Herald added a project: clang. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D150473 Files: clang/lib/Driver/ToolChains/Clang.

[PATCH] D148654: Modify BoundsSan to improve debuggability

2023-05-12 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added a reviewer: melver. smeenai added a comment. The patch should be uploaded with full context to make review easier. Adding another potential reviewer. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148654/new/ https://reviews.llvm.org/

[PATCH] D148654: Modify BoundsSan to improve debuggability

2023-05-12 Thread Oskar Wirga via Phabricator via cfe-commits
oskarwirga updated this revision to Diff 521767. oskarwirga added a comment. Add full context Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D148654/new/ https://reviews.llvm.org/D148654 Files: clang/lib/CodeGen/CGExpr.cpp clang/test/CodeGen/bou

[PATCH] D146054: [RISCV] Add --print-supported-extensions and -march=help support

2023-05-12 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D146054#4337866 , @kito-cheng wrote: > GCC ins't implement yet, but planed, so add it later I think? > > @4vtomat already drop -march=help, @MaskRay did you mind take a look again? Done. But this update still doesn't look qui

  1   2   >