[PATCH] D33499: [PPC] PPC32/Darwin ABI info

2017-06-22 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. This seems like a reasonable start, and is a step forward. For the VAArgs, this will be self-consistent, but to be compliant with the system ABI, I think you'll need to account the different padding rules for small aggregates, as per pp14 of "Mac_OS_X_ABI_Function_Calls".

[PATCH] D33499: [PPC] PPC32/Darwin ABI info

2018-12-29 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. Since that's my understanding too - I am (slowly) bringing my patches forward to 7.0 - at the moment testing the MC layer changes on powerpc-darwin9 (looking reasonable, as an assembler for GCC, so far). When things are "ready" (at least not broken as far as I can tell)

[PATCH] D128328: [C++20][Modules] Improve handing of Private Module Fragment diagnostics.

2022-06-27 Thread Iain Sandoe via Phabricator via cfe-commits
iains planned changes to this revision. iains added a comment. In D128328#3611194 , @ChuanqiXu wrote: > From the discussion, it looks like the 'export' part is not necessary here > and we don't need to care about linkage in this revision. Indeed. > In

[PATCH] D126189: [C++20][Modules] Build module static initializers per P1874R1.

2022-06-29 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D126189#3617850 , @ChuanqiXu wrote: > @iains may I ask what's the issue to not land this? It looks like you're > waiting for the behavior to be consistency with GCC? > > Since this patch could fix https://github.com/llvm/llvm-pr

[PATCH] D126694: [C++20][Modules] Implementation of GMF decl elision.

2022-06-29 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 440915. iains marked an inline comment as done. iains added a comment. rebased after D113545 was landed and removed that as a parent. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.or

[PATCH] D126694: [C++20][Modules] Implementation of GMF decl elision.

2022-06-29 Thread Iain Sandoe via Phabricator via cfe-commits
iains added inline comments. Comment at: clang/include/clang/AST/DeclBase.h:624 bool isModulePrivate() const { return getModuleOwnershipKind() == ModuleOwnershipKind::ModulePrivate; } ChuanqiXu wrote: > According to the opinion from @rsmith, the discar

[PATCH] D126189: [C++20][Modules] Build module static initializers per P1874R1.

2022-06-29 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 440924. iains added a comment. rebased, corrected some spellings. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126189/new/ https://reviews.llvm.org/D126189 Files: clang/include/clang/AST/ASTContext.h clang/

[PATCH] D126189: [C++20][Modules] Build module static initializers per P1874R1.

2022-06-29 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D126189#3598568 , @urnathan wrote: > please sed /initialiser/initializer/, I noticed a few had crept in. should be done now. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126189/n

[PATCH] D128981: [C++20][Modules] Implement include translation.

2022-07-01 Thread Iain Sandoe via Phabricator via cfe-commits
iains created this revision. Herald added a project: All. iains requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This addresses [cpp.include]/7 (when encountering #include header-name) If the header identified by the header-name denotes an

[PATCH] D128981: [C++20][Modules] Implement include translation.

2022-07-02 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 441871. iains added a comment. fix a state transition after include translation. This update fixes an (apparently pre-existing) bug in handling: module; #include "translated-header.h" import "header-unit.h"; The translation process pushes a tok::annot

[PATCH] D129045: [C++20][Modules] Update handling of implicit inlines [P1779R3]

2022-07-03 Thread Iain Sandoe via Phabricator via cfe-commits
iains created this revision. Herald added a project: All. iains added reviewers: urnathan, ChuanqiXu. iains added a subscriber: clang-modules. iains published this revision for review. iains added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. the other provision

[PATCH] D129045: [C++20][Modules] Update handling of implicit inlines [P1779R3]

2022-07-03 Thread Iain Sandoe via Phabricator via cfe-commits
iains marked 4 inline comments as done. iains added inline comments. Comment at: clang/lib/AST/TextNodeDumper.cpp:1723-1725 + if (!D->isInlineSpecified() && D->isInlined()) { +OS << " implicit-inline"; + } ChuanqiXu wrote: > Is this necessary to this revisi

[PATCH] D129045: [C++20][Modules] Update handling of implicit inlines [P1779R3]

2022-07-04 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 442029. iains marked 4 inline comments as done. iains added a comment. rebased, factored code to address comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129045/new/ https://reviews.llvm.org/D129045 Files

[PATCH] D129045: [C++20][Modules] Update handling of implicit inlines [P1779R3]

2022-07-04 Thread Iain Sandoe via Phabricator via cfe-commits
iains added inline comments. Comment at: clang/lib/Sema/SemaDecl.cpp:9363-9365 +Module *M = NewFD->getOwningModule(); +if (!M || M->isGlobalModule()) + NewFD->setImplicitlyInline(); iains wrote: > ChuanqiXu wrote: > > nit: this is not re

[PATCH] D128981: [C++20][Modules] Implement include translation.

2022-07-04 Thread Iain Sandoe via Phabricator via cfe-commits
iains marked 3 inline comments as done. iains added inline comments. Comment at: clang/include/clang/Lex/Preprocessor.h:434 +/// Saw a 'module' identifier. +void handleModule(bool ATLTS) { + // This was the first module identifier and not preceded by any token --

[PATCH] D129045: [C++20][Modules] Update handling of implicit inlines [P1779R3]

2022-07-04 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D129045#3627856 , @ChuanqiXu wrote: > It looks like the tests lack the cast that the methods are attached to the > global module fragment. (maybe I misunderstand what you are saying here) bool ImplicitInlineCXX20 = !getLangO

[PATCH] D129045: [C++20][Modules] Update handling of implicit inlines [P1779R3]

2022-07-04 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 442072. iains added a comment. updated testcases to fix a missing new line and add included header in a GMF. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129045/new/ https://reviews.llvm.org/D129045 Files: cl

[PATCH] D129045: [C++20][Modules] Update handling of implicit inlines [P1779R3]

2022-07-04 Thread Iain Sandoe via Phabricator via cfe-commits
iains marked an inline comment as done. iains added a comment. In D129045#3627901 , @ChuanqiXu wrote: > In D129045#3627878 , @iains wrote: > >> In D129045#3627856 , @Chuan

[PATCH] D128981: [C++20][Modules] Implement include translation.

2022-07-04 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 442085. iains marked 7 inline comments as done. iains added a comment. rebased, addressed review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128981/new/ https://reviews.llvm.org/D128981 Files: clan

[PATCH] D128981: [C++20][Modules] Implement include translation.

2022-07-04 Thread Iain Sandoe via Phabricator via cfe-commits
iains marked an inline comment as done. iains added inline comments. Comment at: clang/lib/Lex/PPDirectives.cpp:2226-2227 + + // FIXME: We do not have a good way to disambiguate C++ clang modules from + // C++ standard modules (other than use/non-use of Header Units). + Module

[PATCH] D126694: [C++20][Modules] Implementation of GMF decl elision.

2022-07-05 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D126694#3629094 , @ChuanqiXu wrote: > BTW, after I applied the patch, the compiler crashes at > https://github.com/ChuanqiXu9/stdmodules. That link points to a project - is there (say) a gist of the crash information? > I woul

[PATCH] D128981: [C++20][Modules] Implement include translation.

2022-07-05 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 442242. iains added a comment. addressed review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128981/new/ https://reviews.llvm.org/D128981 Files: clang/include/clang/Lex/Preprocessor.h clang/lib/Le

[PATCH] D129174: [C++20][Modules] Invalidate internal-linkage functions in overload sets [P1815R2 part 1]

2022-07-06 Thread Iain Sandoe via Phabricator via cfe-commits
iains created this revision. Herald added a project: All. iains added reviewers: urnathan, ChuanqiXu. iains added a subscriber: clang-modules. iains published this revision for review. Herald added a project: clang. Herald added a subscriber: cfe-commits. This is an implementation of the first par

[PATCH] D129138: [clang] [docs] Update the changes of C++20 Modules in clang15

2022-07-06 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. Perhaps we could be a little more bold about the completeness of the implementation (at least, w.r.t the base paper `P1103`) - we pass the relevant test cases. As for the follow-on papers, I think we have more that can be added notes below: There are some test cases to be

[PATCH] D129138: [clang] [docs] Update the changes of C++20 Modules in clang15

2022-07-06 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. I would not expect to add all this information to the release notes, or any of the phab links - just single lines to say that paper numbers are implemented - the details are just to help us track the situation up to 26th July. CHANGES SINCE LAST ACTION https://reviews.

[PATCH] D129174: [C++20][Modules] Invalidate internal-linkage functions in overload sets [P1815R2 part 1]

2022-07-06 Thread Iain Sandoe via Phabricator via cfe-commits
iains marked 2 inline comments as done. iains added inline comments. Comment at: clang/lib/Sema/SemaOverload.cpp:6406 +if (Function->getFormalLinkage() <= Linkage::InternalLinkage && +getLangOpts().CPlusPlus20 && MF != getCurrentModule()) { + Candidate.Viable = f

[PATCH] D129174: [C++20][Modules] Invalidate internal-linkage functions in overload sets [P1815R2 part 1]

2022-07-06 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 442505. iains marked 4 inline comments as done. iains added a comment. address review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129174/new/ https://reviews.llvm.org/D129174 Files: clang/include/c

[PATCH] D129174: [C++20][Modules] Invalidate internal-linkage functions in overload sets [P1815R2 part 1]

2022-07-06 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. TODO: second test-case for cases that should succeed, split out basic-link / p10-ex2 test case. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129174/new/ https://reviews.llvm.org/D129174

[PATCH] D126694: [C++20][Modules] Implementation of GMF decl elision.

2022-07-07 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 442849. iains marked 25 inline comments as done. iains added a comment. rebased, addressed review comments, added another test. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126694/new/ https://reviews.llvm.org/D

[PATCH] D126694: [C++20][Modules] Implementation of GMF decl elision.

2022-07-07 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. @rsmith, @ChuanqiXu apologies for the multiple revisions, this has turned out to be much more involved than I imagined from the standard's text. In D126694#3629254 , @ChuanqiXu wrote: > In D126694#3629251

[PATCH] D128328: [C++20][Modules] Improve handing of Private Module Fragment diagnostics.

2022-07-07 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 442942. iains marked 3 inline comments as done. iains added a comment. rebased, reworked - to follow the changes proposed by core - to make the diagnostics follow that and a compromise for the proposed revision before the core amendment. Repository: rG LLV

[PATCH] D128328: [C++20][Modules] Improve handing of Private Module Fragment diagnostics.

2022-07-07 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. the revised diagnostics look like this: ` error: {un-}exported inline function not defined before the private module fragment` with ` note: private module fragment begins here` pointing to the start of the PMF If there is no PMF then we just say: ` error: {un-}exported

[PATCH] D128328: [C++20][Modules] Improve handing of Private Module Fragment diagnostics.

2022-07-08 Thread Iain Sandoe via Phabricator via cfe-commits
iains added inline comments. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:11155 +def err_export_inline_not_defined : Error< + "exported inline functions must be defined within the module purview" + " and before any private module fragment">; Chu

[PATCH] D126694: [C++20][Modules] Implementation of GMF decl elision.

2022-07-08 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D126694#3637690 , @ChuanqiXu wrote: > In D126694#3635207 , @iains wrote: > >> @rsmith, @ChuanqiXu apologies for the multiple revisions, this has turned >> out to be much more involved th

[PATCH] D129174: [C++20][Modules] Update ADL to handle basic.lookup.argdep p4 [P1815R2 part 1]

2022-07-08 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 443194. iains retitled this revision from "[C++20][Modules] Invalidate internal-linkage functions in overload sets [P1815R2 part 1]" to "[C++20][Modules] Update ADL to handle basic.lookup.argdep p4 [P1815R2 part 1]". iains edited the summary of this revision. i

[PATCH] D127624: [C++20][Modules] Allow for redeclarations in partitions.

2022-07-08 Thread Iain Sandoe 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 rGbc2a6defc853: [C++20][Modules] Allow for redeclarations in partitions. (authored by iains). Repository: rG LLVM Github Monorepo CHANGES SINCE LAS

[PATCH] D126189: [C++20][Modules] Build module static initializers per P1874R1.

2022-07-09 Thread Iain Sandoe 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 rGac507102d258: [C++20][Modules] Build module static initializers per P1874R1. (authored by iains). Repository: rG LLVM Github Monorepo CHANGES SIN

[PATCH] D129045: [C++20][Modules] Update handling of implicit inlines [P1779R3]

2022-07-09 Thread Iain Sandoe 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 rGef0fa9f0ef3e: [C++20][Modules] Update handling of implicit inlines [P1779R3] (authored by iains). Repository: rG LLVM Github Monorepo CHANGES SIN

[PATCH] D122394: [C++20][Modules] Correct an assert for modules-ts.

2022-03-24 Thread Iain Sandoe via Phabricator via cfe-commits
iains created this revision. Herald added a project: All. iains added a reviewer: urnathan. iains published this revision for review. iains added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. somewhat on the trivial side. When adding the support for modules pa

[PATCH] D122394: [C++20][Modules] Correct an assert for modules-ts.

2022-03-24 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D122394#3405338 , @urnathan wrote: > Is this because of history that ModulesTS option != p1103 modules? I thought > we wanted to make the former become the latter (i.e. ModuleTS is the same as > CPlusPlusModules) This seems t

[PATCH] D122413: [C++20][Modules] Limit ModuleInternalLinkage to modules-ts.

2022-03-24 Thread Iain Sandoe via Phabricator via cfe-commits
iains created this revision. Herald added a project: All. iains added reviewers: urnathan, dblaikie, Bigcheese, rsmith, ChuanqiXu. iains published this revision for review. Herald added a project: clang. Herald added a subscriber: cfe-commits. At present, we are generating wrong code for C++20 mod

[PATCH] D122119: [C++20][Modules] Adjust handling of exports of namespaces and using-decls.

2022-03-24 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D122119#3400267 , @dblaikie wrote: > SOrry, I don't have much context here - the more informative (module/internal > linkage) diagnostic does seem better to me than saying "is not exported", > even if it's a bit esoteric for so

[PATCH] D122119: [C++20][Modules] Adjust handling of exports of namespaces and using-decls.

2022-03-24 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418038. iains marked 3 inline comments as done. iains added a comment. rebased, addressed review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122119/new/ https://reviews.llvm.org/D122119 Files: clan

[PATCH] D122119: [C++20][Modules] Adjust handling of exports of namespaces and using-decls.

2022-03-24 Thread Iain Sandoe via Phabricator via cfe-commits
iains added inline comments. Comment at: clang/lib/Sema/SemaModule.cpp:814-815 +diagExportedUnnamedDecl(S, UnnamedDeclKind::Namespace, D, BlockStart); + else +; // We allow an empty named namespace decl. +} else if (DC->getRedeclContext()->isFileContext()

[PATCH] D121095: [C++20][Modules][HU 1/5] Introduce header units as a module type.

2022-03-24 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418041. iains added a comment. rebased, renamed helper method. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121095/new/ https://reviews.llvm.org/D121095 Files: clang/include/clang/Basic/LangOptions.def clan

[PATCH] D121096: [C++20][Modules][HU 2/5] Support searching Header Units in user or system search paths.

2022-03-24 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418079. iains added a comment. rebased, added a testcase for multiple inputs. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121096/new/ https://reviews.llvm.org/D121096 Files: clang/include/clang/Basic/Diagnos

[PATCH] D121097: [C++20][Modules][HU 3/5] Emit module macros for header units.

2022-03-24 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418081. iains added a comment. rebased Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121097/new/ https://reviews.llvm.org/D121097 Files: clang/include/clang/Basic/Module.h clang/include/clang/Serialization/A

[PATCH] D121098: [C++20][Modules][HU 4/5] Handle pre-processed header units.

2022-03-24 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418082. iains added a comment. rebased Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121098/new/ https://reviews.llvm.org/D121098 Files: clang/lib/Frontend/FrontendAction.cpp clang/lib/Sema/SemaModule.cpp

[PATCH] D121099: [C++20][Modules][HU 5/5] Add fdirectives-only mode for preprocessing output.

2022-03-24 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418083. iains added a comment. rebased Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121099/new/ https://reviews.llvm.org/D121099 Files: clang/include/clang/Driver/Options.td clang/include/clang/Frontend/Pre

[PATCH] D121095: [C++20][Modules][HU 1/5] Introduce header units as a module type.

2022-03-25 Thread Iain Sandoe via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6c0e60e884a2: [C++20][Modules][HU 1/5] Introduce header units as a module type. (authored by iains). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121095/new

[PATCH] D121589: [C++20][Modules][Driver][HU 2/N] Add fmodule-header, fmodule-header=

2022-03-25 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418171. iains added a comment. Herald added a subscriber: MaskRay. rebased, fix testcase for windows, add command line options to docs. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121589/new/ https://reviews.ll

[PATCH] D121589: [C++20][Modules][Driver][HU 2/N] Add fmodule-header, fmodule-header=

2022-03-25 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418172. iains added a comment. fix some formatting. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121589/new/ https://reviews.llvm.org/D121589 Files: clang/docs/ClangCommandLineReference.rst clang/include/cl

[PATCH] D121589: [C++20][Modules][Driver][HU 2/N] Add fmodule-header, fmodule-header=

2022-03-25 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418187. iains added a comment. amend filecheck match to avoid quoting windows pathnames. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121589/new/ https://reviews.llvm.org/D121589 Files: clang/docs/ClangComman

[PATCH] D121589: [C++20][Modules][Driver][HU 2/N] Add fmodule-header, fmodule-header=

2022-03-25 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418188. iains added a comment. amend second testcase for windows Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121589/new/ https://reviews.llvm.org/D121589 Files: clang/docs/ClangCommandLineReference.rst cla

[PATCH] D121589: [C++20][Modules][Driver][HU 2/N] Add fmodule-header, fmodule-header=

2022-03-25 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418196. iains added a comment. another tweak to the second testcase for windows *sigh* ... I will get the recipe right eventually. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121589/new/ https://reviews.llvm.or

[PATCH] D121589: [C++20][Modules][Driver][HU 2/N] Add fmodule-header, fmodule-header=

2022-03-25 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418220. iains added a comment. we need the quotes around the components. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121589/new/ https://reviews.llvm.org/D121589 Files: clang/docs/ClangCommandLineReference.r

[PATCH] D122394: [C++20][Modules] Correct an assert for modules-ts.

2022-03-25 Thread Iain Sandoe via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGcf396c56e7df: [C++20][Modules] Correct an assert for modules-ts. (authored by iains). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122394/new/ https://revi

[PATCH] D121590: [C++20][Modules][Driver][HU 3/N] Handle foo.h with -fmodule-header and/or C++ invocation.

2022-03-25 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418267. iains added a comment. Herald added a subscriber: MaskRay. rebased, addrssed review comment, amend testcase for windows. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121590/new/ https://reviews.llvm.org/

[PATCH] D121590: [C++20][Modules][Driver][HU 3/N] Handle foo.h with -fmodule-header and/or C++ invocation.

2022-03-25 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418268. iains added a comment. another testcase ajustment for windows. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121590/new/ https://reviews.llvm.org/D121590 Files: clang/lib/Driver/Driver.cpp clang/test

[PATCH] D121591: [C++20][Modules][Driver][HU 4/N] Add fdirectives-only mode for preprocessing output.

2022-03-25 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 418274. iains added a comment. Herald added a subscriber: MaskRay. rebased, adjusted testcases to avoid using clang++. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121591/new/ https://reviews.llvm.org/D121591 F

[PATCH] D121096: [C++20][Modules][HU 2/5] Support searching Header Units in user or system search paths.

2022-03-26 Thread Iain Sandoe via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG0687578728ea: [C++20][Modules][HU 2/5] Support searching Header Units in user or system… (authored by iains). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D1

[PATCH] D121097: [C++20][Modules][HU 3/5] Emit module macros for header units.

2022-03-26 Thread Iain Sandoe via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGf8846229c41f: [C++20][Modules][HU 3/5] Emit module macros for header units. (authored by iains). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121097/new/ h

[PATCH] D119409: [C++20] [Modules] Remain dynamic initializing internal-linkage variables in module interface unit

2022-03-26 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. I think that this problem might well be a consequence of the bug which is fixed by D122413 . We have been generating code with module internal entities (always) given the special ModuleInternalLinkage (which means that, although the linka

[PATCH] D119409: [C++20] [Modules] Remain dynamic initializing internal-linkage variables in module interface unit

2022-03-26 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. addendum: note we still have work to do on the module initialisers - those are not correct yet (so probably some nesting of modules might not work). CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119409/new/ https://reviews.llvm.org/D119409 __

[PATCH] D121098: [C++20][Modules][HU 4/5] Handle pre-processed header units.

2022-03-27 Thread Iain Sandoe via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGd9cea8d3a8ff: [C++20][Modules][HU 4/5] Handle pre-processed header units. (authored by iains). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121098/new/ htt

[PATCH] D121099: [C++20][Modules][HU 5/5] Add fdirectives-only mode for preprocessing output.

2022-03-27 Thread Iain Sandoe via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG85b1354098ba: [C++20][Modules][HU 5/5] Add fdirectives-only mode for preprocessing output. (authored by iains). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/

[PATCH] D119409: [C++20] [Modules] Remain dynamic initializing internal-linkage variables in module interface unit

2022-03-28 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D119409#3410474 , @ChuanqiXu wrote: > In D119409#3409806 , @iains wrote: > >> I think that this problem might well be a consequence of the bug which is >> fixed by D122413

[PATCH] D120874: [C++20] [Modules] Use '-' as the separator of partitions when searching in filesystems

2022-03-30 Thread Iain Sandoe via Phabricator via cfe-commits
iains accepted this revision. iains added a comment. This revision is now accepted and ready to land. In D120874#3416130 , @arames wrote: > I was was asked to chime in to assess whether this patch could be a problem > for > the prebuilt-implicit clang mo

[PATCH] D121271: [C++20] [Modules] Don't generate strong function of a partition in importing modules

2022-03-30 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. it looks like the first part of the C++20 mangling was just landed, so perhaps you can revisit this? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121271/new/ https://reviews.llvm.org/D121271 ___

[PATCH] D121271: [C++20] [Modules] Don't generate strong function of a partition in importing modules

2022-03-31 Thread Iain Sandoe via Phabricator via cfe-commits
iains accepted this revision. iains added a comment. This revision is now accepted and ready to land. LGTM, thanks. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121271/new/ https://reviews.llvm.org/D121271 ___ cfe-commits mailing list cfe-co

[PATCH] D122413: [C++20][Modules] Limit ModuleInternalLinkage to modules-ts.

2022-04-01 Thread Iain Sandoe via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGc7ed65b4bcbd: [C++20][Modules] Limit ModuleInternalLinkage to modules-ts. (authored by iains). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122413/new/ htt

[PATCH] D121097: [C++20][Modules][HU 3/5] Emit module macros for header units.

2022-04-01 Thread Iain Sandoe via Phabricator via cfe-commits
iains added inline comments. Comment at: clang/test/Modules/cxx20-hu-04.cpp:22 +// RUN: %clang_cc1 -std=c++20 -emit-module-interface importer-01.cpp \ +// RUN: -fmodule-file=hu-02.pcm -o B.pcm -DTDIR=%t -verify + hvdijk wrote: > On Windows, when the path starts

[PATCH] D121097: [C++20][Modules][HU 3/5] Emit module macros for header units.

2022-04-03 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. applied [C++20][Modules] Fix a testcase warning on Windows [NFC]. https://github.com/llvm/llvm-project/commit/1f0b8ba47ab0f1dc678099d4830d0cc0d10850b6 should be fixed now. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121097/n

[PATCH] D122885: [clang] Draft: Implement P1703R1

2022-04-06 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. FWIW probably these 5 patches are pretty independent of changes to the preprocessor... ... the first four of those are extremely unlikely to clash - since they are concerned with the driver. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://revi

[PATCH] D122119: [C++20][Modules] Adjust handling of exports of namespaces and using-decls.

2022-04-06 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. @dblaikie - is the explanation for the change in diagnostics at the same time OK? (if not I can split the patch, but either way I'd like to land what is acceptable soonish). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D1221

[PATCH] D119409: [C++20] [Modules] Remain dynamic initializing internal-linkage variables in module interface unit

2022-04-06 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D119409#3410893 , @ChuanqiXu wrote: > In D119409#3410868 , @iains wrote: > >> In D119409#3410474 , @ChuanqiXu >> wrote: >> >>> In D119409#340980

[PATCH] D130871: [C++20] [Modules] Handle initializer for Header Units

2022-08-01 Thread Iain Sandoe via Phabricator via cfe-commits
iains accepted this revision. iains added a comment. This revision is now accepted and ready to land. LGTM, one small point about the test, Comment at: clang/test/CodeGenCXX/module-initializer-header.cppm:5-7 +// RUN: %clang_cc1 -std=c++20 -triple=x86_64-unknown-linux-gnu -xc+

[PATCH] D130864: [NFC] Introduce ASTContext::isInSameModule()

2022-08-02 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D130864#3693022 , @ChuanqiXu wrote: > In D130864#3693019 , @ilya-biryukov > wrote: > >> Thanks for working on this. I have a few major concerns here: >> >> - Do we know that it's a bottl

[PATCH] D131062: [docs] Add "C++20 Modules"

2022-08-08 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. @h-vetinari you are right, this has become difficult to review - I will try and do some more later - just the one comment for now. Comment at: clang/docs/CPlusPlus20Modules.rst:676-678 +So the final answer for why we don't reuse the interface of Clang mo

[PATCH] D131388: [docs] Add "C++20 Modules"

2022-08-08 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. general comment. Do we encourage contractions (don't, can't) etc. in documentation? I would suggest that to assist in any translation process it is better to write "do not" or "can not" instead (but that's just an opinion, not a matter of correctness).

[PATCH] D131388: [docs] Add "C++20 Modules"

2022-08-08 Thread Iain Sandoe via Phabricator via cfe-commits
iains added inline comments. Comment at: clang/docs/CPlusPlus20Modules.rst:673-674 + +Another reason is that there are proposals to introduce module mappers to the C++ standard (for example, https://wg21.link/p1184r2). +If we decide to reuse Clang's modulemap, we may get in trou

[PATCH] D121096: [C++20][Modules][HU 2/5] Support searching Header Units in user or system search paths.

2022-03-08 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D121096#3368996 , @ChuanqiXu wrote: > BTW, all the tests uses ``clang_cc1`. How should the users do with `clang`? > Could them use `-Xclang` only? The driver changes are in separate patches (they will make the same user-facing

[PATCH] D121271: [C++20] [Modules] Don't generate strong function of a partition in importing modules

2022-03-09 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. thanks, this looks OK to me, but I would leave some time for other comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121271/new/ https://reviews.llvm.org/D121271 ___ cfe-comm

[PATCH] D121095: [C++20][Modules][HU 1/5] Introduce header units as a module type.

2022-03-12 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 414888. iains marked 4 inline comments as done. iains added a comment. rebased, address review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121095/new/ https://reviews.llvm.org/D121095 Files: clang/

[PATCH] D121095: [C++20][Modules][HU 1/5] Introduce header units as a module type.

2022-03-12 Thread Iain Sandoe via Phabricator via cfe-commits
iains added inline comments. Comment at: clang/include/clang/Sema/Sema.h:2978-2980 + /// The parser has begun a translation unit to be compiled as a C++20 + /// Header Unit. + void ActOnStartOfHeaderUnit(); ChuanqiXu wrote: > From the implementation, I think i

[PATCH] D121096: [C++20][Modules][HU 2/5] Support searching Header Units in user or system search paths.

2022-03-12 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 414889. iains marked 6 inline comments as done. iains added a comment. rebased, address review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121096/new/ https://reviews.llvm.org/D121096 Files: clang/

[PATCH] D121096: [C++20][Modules][HU 2/5] Support searching Header Units in user or system search paths.

2022-03-12 Thread Iain Sandoe via Phabricator via cfe-commits
iains added inline comments. Comment at: clang/include/clang/Frontend/FrontendOptions.h:157 + unsigned HeaderUnit : 3; + unsigned Header : 1; ChuanqiXu wrote: > I prefer `IsHeader` OK. Comment at: clang/include/clang/Frontend/FrontendOption

[PATCH] D121097: [C++20][Modules][HU 3/5] Emit module macros for header units.

2022-03-12 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 414890. iains added a comment. rebased. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121097/new/ https://reviews.llvm.org/D121097 Files: clang/include/clang/Serialization/ASTWriter.h clang/lib/Serialization

[PATCH] D121098: [C++20][Modules][HU 4/5] Handle pre-processed header units.

2022-03-12 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 414891. iains added a comment. rebased. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121098/new/ https://reviews.llvm.org/D121098 Files: clang/lib/Frontend/FrontendAction.cpp clang/lib/Sema/SemaModule.cpp

[PATCH] D121099: [C++20][Modules][HU 5/5] Add fdirectives-only mode for preprocessing output.

2022-03-12 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 414892. iains added a comment. rebased. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121099/new/ https://reviews.llvm.org/D121099 Files: clang/include/clang/Driver/Options.td clang/include/clang/Frontend/Pr

[PATCH] D121588: [C++20][Modules][Driver][HU 1/N] Initial handling for -xc++-{system,user}-header.

2022-03-14 Thread Iain Sandoe via Phabricator via cfe-commits
iains created this revision. Herald added a project: All. iains added reviewers: rsmith, urnathan, ChuanqiXu. iains added a subscriber: clang-modules. iains published this revision for review. iains added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. This is a s

[PATCH] D121589: [C++20][Modules][Driver][HU 2/N] Add fmodule-header, fmodule-header=

2022-03-14 Thread Iain Sandoe via Phabricator via cfe-commits
iains created this revision. Herald added a subscriber: dang. Herald added a project: All. iains added reviewers: rsmith, urnathan, ChuanqiXu. iains published this revision for review. Herald added a project: clang. Herald added a subscriber: cfe-commits. These command-line flags are alternates to

[PATCH] D121590: [C++20][Modules][Driver][HU 3/N] Handle foo.h with -fmodule-header and/or C++ invocation.

2022-03-14 Thread Iain Sandoe via Phabricator via cfe-commits
iains created this revision. Herald added a project: All. iains added reviewers: rsmith, urnathan, ChuanqiXu. iains published this revision for review. Herald added a project: clang. Herald added a subscriber: cfe-commits. Allow an invocation like clang -fmodule-header bar.h (which will be a C++ c

[PATCH] D121591: [C++20][Modules][Driver][HU 4/N] Add fdirectives-only mode for preprocessing output.

2022-03-14 Thread Iain Sandoe via Phabricator via cfe-commits
iains created this revision. Herald added a project: All. iains added reviewers: rsmith, urnathan, ChuanqiXu. iains published this revision for review. Herald added a project: clang. Herald added a subscriber: cfe-commits. When the -fdirectives-only option is used together with -E, the preprocesso

[PATCH] D120540: [Driver] Enable to use C++20 modules standalone by -fcxx-modules

2022-03-15 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. I am still concerned that there is an expectation that. the fcxx-modules option is connected with clang modules. .. see, for example: https://github.com/llvm/llvm-project/blob/d90d45fc9029cc7dbb6d44798f51131df6b2eef1/clang/lib/Driver/ToolChains/Clang.cpp#L3579 and https:

[PATCH] D121588: [C++20][Modules][Driver][HU 1/N] Initial handling for -xc++-{system,user}-header.

2022-03-15 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. note: I do not plan to fix the formatting issue in clang/lib/Driver/Types.cpp, since I am adding one line and the format change would mean ≈ 110 lines of changes. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D121588/new/ ht

[PATCH] D121589: [C++20][Modules][Driver][HU 2/N] Add fmodule-header, fmodule-header=

2022-03-15 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D121589#3381343 , @ChuanqiXu wrote: >> It's not practical to recognise a header without any suffix so > > -fmodule-header=system foo isn't going to happen. > > May I ask the reason? It looks not so good with `-fmodule-header=syst

[PATCH] D120540: [Driver] Enable to use C++20 modules standalone by -fcxx-modules

2022-03-15 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. I'm not sure it is exactly chaos, but it is certainly fragile and somewhat hard(er than necessary) to maintain. We (@ChuanqiXu and I at least) agree that there should be some way to make "which modules mode" unambiguous in both the driver and the compiler (I think we're

[PATCH] D121098: [C++20][Modules][HU 4/5] Handle pre-processed header units.

2022-03-15 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D121098#3378375 , @ChuanqiXu wrote: > It lacks tests. This is not NFC, right? Right, (there are tests with the next patch which introduces the mechanism for producing the pre-processed output) but, I will find a suitable one f

[PATCH] D120540: [Driver] Enable to use C++20 modules standalone by -fcxx-modules

2022-03-16 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D120540#3384644 , @ChuanqiXu wrote: > @rsmith told me that the ideal situation would combine C++20 modules and > clang modules together in D113391 Maybe I understand something slightly differe

  1   2   3   4   5   >