[PATCH] D63508: make -frewrite-includes handle __has_include wrapped in a macro

2019-06-18 Thread Luboš Luňák via Phabricator via cfe-commits
llunak created this revision. llunak added reviewers: vsapsai, bkramer. llunak added a project: clang. Herald added subscribers: cfe-commits, dexonsmith. Qt5 has a wrapper macro that makes __has_include simpler to use: #ifdef __has_include 1. define QT_HAS_INCLUDE(x) __has_include(x)

[PATCH] D63508: make -frewrite-includes handle __has_include wrapped in a macro

2019-06-19 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. The code uses a raw lexer, so it doesn't expand macros. Thus the piece of code quoted will not get the "#if QT_HAS_INCLUDE()" part rewritten. My specific use case is the Icecream distributed build tool which does remote builds in a chroot and so this #if will be false an

[PATCH] D63508: make -frewrite-includes handle __has_include wrapped in a macro

2019-06-19 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Icecream's usage of -frewrite-includes is not special, the purpose is always to merge everything necessary for the compilation into one source file that can be later compiled on its own as if the original file was compiled. The #include expansion done during -frewrite-in

[PATCH] D63508: make -frewrite-includes handle __has_include wrapped in a macro

2019-06-19 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D63508#1550668 , @rsmith wrote: > Perhaps we should rewrite all `#if`-like directives to `#if 0` or `#if 1`? I think that would work too and it'd be in fact a reliable simple solution. Repository: rC Clang CHANGES SINCE LA

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-07-16 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added inline comments. Comment at: clang/test/Frontend/rewrite-includes-conditions.c:17 +line4 +#elif value2 < value2 +line5 rsmith wrote: > Did you mean for this to be `value1 < value2` rather than `value2 < value2`? Yes, not that it'd matter in practice.

[PATCH] D65371: do not emit -Wunused-macros warnings in -frewrite-includes mode (PR15614)

2019-07-27 Thread Luboš Luňák via Phabricator via cfe-commits
llunak created this revision. llunak added a reviewer: rsmith. Herald added a project: clang. Herald added a subscriber: cfe-commits. This is an updated patch from https://bugs.llvm.org/show_bug.cgi?id=15614. See there for testcase etc. Repository: rC Clang https://reviews.llvm.org/D65371 F

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-06-21 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 206070. llunak retitled this revision from "make -frewrite-includes handle __has_include wrapped in a macro" to "make -frewrite-includes also rewrite conditions in #if/#elif". llunak edited the summary of this revision. Repository: rC Clang CHANGES SINCE

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-06-21 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Implemented in the current version of the patch. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63508/new/ https://reviews.llvm.org/D63508 ___ cfe-commits mailing list cfe-commits@lists.llvm.or

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-06-30 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D63508#1558390 , @rsmith wrote: > Patch generally looks good; just a minor concern about the output format. > Also, we don't need parentheses around the constant 0 or 1. That was consistent with what the current code does, b

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-06-30 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 207220. llunak added a comment. Updated patch, removed ()'s around 1/0, fixed to use CommentOutDirective(). Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63508/new/ https://reviews.llvm.org/D63508 Files: clang/lib/Frontend/

[PATCH] D63979: actually also compile output in tests for -frewrite-includes

2019-06-30 Thread Luboš Luňák via Phabricator via cfe-commits
llunak created this revision. llunak added a project: clang. Herald added a subscriber: cfe-commits. This depends on https://reviews.llvm.org/D63508 (where I posted one version of a patch that created broken output without the tests catching it). Repository: rC Clang https://reviews.llvm.org

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-06-30 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 207229. llunak added a comment. Updated the patch again, commenting out just a part of #if didn't work either, so it seems there's no good way to comment out unwanted #if. This patch surrounds rewritten #if conditions by extra #if 0 #endif block to disable th

[PATCH] D64284: (WIP) share template instantiations from PCH in one .o if -building-pch-with-obj

2019-07-06 Thread Luboš Luňák via Phabricator via cfe-commits
llunak created this revision. llunak added reviewers: rsmith, dblaikie, hans. Herald added a project: clang. Herald added a subscriber: cfe-commits. This is a WIP patch that can significantly reduce build time by avoiding needlessly repeatedly instantiating templates when using PCH. As described

[PATCH] D61822: make -ftime-trace also print template arguments

2019-05-11 Thread Luboš Luňák via Phabricator via cfe-commits
llunak created this revision. llunak added a reviewer: anton-afanasyev. Herald added a project: clang. Herald added a subscriber: cfe-commits. Without this, I get e.g. 'PerformPendingInstantiations' -> 'std::fill', now I get 'std::fill'. Repository: rC Clang https://reviews.llvm.org/D61822

[PATCH] D61822: make -ftime-trace also print template arguments

2019-05-11 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 199133. llunak added a comment. Removed the parse case, getNameForDiagnostic() apparently prints nothing there. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61822/new/ https://reviews.llvm.org/D61822 Files: lib/CodeGen/CodeGenModule.cpp lib/Sem

[PATCH] D61822: make -ftime-trace also print template arguments

2019-05-12 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC360539: make -ftime-trace also print template arguments (authored by llunak, committed by ). Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61822/new/ https://reviews.llvm.

[PATCH] D65371: do not emit -Wunused-macros warnings in -frewrite-includes mode (PR15614)

2019-09-16 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGa507a5ec8f1d: do not emit -Wunused-macros warnings in -frewrite-includes mode (PR15614) (authored by llunak). Changed prior to commit: https://reviews.llvm.org/D65371?vs=219370&id=220370#toc Repository

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-09-16 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 220378. llunak added a comment. - updated to apply to current trunk - changed misleading condition in a test Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63508/new/ https://reviews.llvm.org/D63508 Files: clang/lib/Frontend

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-09-16 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. I've noticed that the Developer Policy says that it's actually allowed to commit patches without approval for parts "that you have contributed or maintain". Given that I'm the author of -rewrite-includes I take it that it's ok if I commit this if there are no further com

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-09-17 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D63508#1671776 , @torarnv wrote: > So, this will make `-frewrite-includes` do more work, to ensure that it not > only covers the "top level" `#include` or `__has_include` case, but also > `__has_include` in one or more levels o

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-09-18 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL372248: make -frewrite-includes also rewrite conditions in #if/#elif (authored by llunak, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D63979: actually also compile output in tests for -frewrite-includes

2019-09-18 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rL372250: actually also compile output in tests for -frewrite-includes (authored by llunak, committed by ). Herald added a p

[PATCH] D69585: Add option to instantiate templates already in the PCH

2020-05-25 Thread Luboš Luňák via Phabricator via cfe-commits
llunak marked an inline comment as done. llunak added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:5610 + if (Args.hasFlag(options::OPT_fpch_instantiate_templates, + options::OPT_fno_pch_instantiate_templates, false)) +CmdArgs.push_bac

[PATCH] D69585: Add option to instantiate templates already in the PCH

2020-05-25 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 265918. llunak edited the summary of this revision. llunak added a comment. Enabled the option by default for clang-cl to match MSVC. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69585/new/ https://reviews.llvm.org/D69585 Fi

[PATCH] D69585: Add option to instantiate templates already in the PCH

2020-05-25 Thread Luboš Luňák via Phabricator via cfe-commits
llunak marked an inline comment as done. llunak added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:5610 + if (Args.hasFlag(options::OPT_fpch_instantiate_templates, + options::OPT_fno_pch_instantiate_templates, false)) +CmdArgs.push_bac

[PATCH] D83652: Merge some of the PCH object support with modular codegen

2020-07-21 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. > @llunak Would you be able to test this on anything you've got? No, but thinking more about this, I think dllexport specifically voids the possible problems I listed. If I'm getting it right, dllexport is used only for code in the current library, so codegen won't creat

[PATCH] D83623: add -fpch-codegen/debuginfo options mapping to -fmodules-codegen/debuginfo

2020-07-22 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG54eea6127c4d: add -fpch-codegen/debuginfo mapping to -fmodules-codegen/debuginfo (authored by llunak). Herald added a project: clang. Herald added a subscriber: cfe-commits. Changed prior to commit: htt

[Differential] D83623: add -fpch-codegen/debuginfo options mapping to -fmodules-codegen/debuginfo

2020-07-22 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG54eea6127c4d: add -fpch-codegen/debuginfo mapping to -fmodules-codegen/debuginfo (authored by llunak). Herald added a project: clang. Herald added a subscriber: cfe-commits. Changed prior to commit: htt

[PATCH] D83716: Accept 'clang++ -c a.pch -o a.o' to create PCH's object file

2020-07-22 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG3895466e2c33: accept 'clang++ -c a.pch -o a.o' to create PCH's object file (authored by llunak). Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorep

[Differential] D83716: Accept 'clang++ -c a.pch -o a.o' to create PCH's object file

2020-07-22 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG3895466e2c33: accept 'clang++ -c a.pch -o a.o' to create PCH's object file (authored by llunak). Herald added a project: clang. Herald added a subscriber: cfe-commits. Changed prior to commit: https://r

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-07-06 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping ... Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69778/new/ https://reviews.llvm.org/D69778 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-07-09 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG31b05692cd33: make -fmodules-codegen and -fmodules-debuginfo work also with PCHs (authored by llunak). Changed prior to commit: https://reviews.llvm.org/D69778?vs=263839&id=276726#toc Repository: rG

[PATCH] D83652: Merge some of the PCH object support with modular codegen

2020-07-13 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. The patch is incomplete, isn't it? It removes DeclIsFromPCHWithObjectFile(), but it's still called from ASTContext::DeclMustBeEmitted(). The description also mentions updating of the pch-codegen test, but that's not included. But assuming this is intended to replace the

[PATCH] D83622: document -fpch-instantiate-templates in release notes

2020-07-14 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGd1ca9960bc19: document -fpch-instantiate-templates in release notes (authored by llunak). Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo CHAN

[PATCH] D83652: Merge some of the PCH object support with modular codegen

2020-07-14 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D83652#2147539 , @dblaikie wrote: > Not quite - it's intended to implement the D48426 > functionality using an implementation > strategy that is closer to modular code generation. Removing the

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-06-21 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. So what more needs to be done here to get this change accepted? It's already missed 10.0 and 11.1 is getting branched off in about 3 weeks. - The change was already accepted once and the problem leading to its revert has already been fixed. - It just enables for PCH some

[PATCH] D69585: Add option to instantiate templates already in the PCH

2020-06-21 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGa45f713c6730: add option to instantiate templates already in the PCH (authored by llunak). Changed prior to commit: https://reviews.llvm.org/D69585?vs=265918&id=272312#toc Repository: rG LLVM Github

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-06-30 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69778/new/ https://reviews.llvm.org/D69778 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[PATCH] D74846: fix -fcodegen-modules code when used with PCH (PR44953)

2020-04-19 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping... Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74846/new/ https://reviews.llvm.org/D74846 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/

[PATCH] D73846: [PCH] make sure to not warn about unused macros from -D

2020-04-19 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping.. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D73846/new/ https://reviews.llvm.org/D73846 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D69585: Add option to instantiate templates already in the PCH

2020-04-19 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 258605. llunak retitled this revision from "PerformPendingInstatiations() already in the PCH" to "Add option to instantiate templates already in the PCH". llunak edited the summary of this revision. llunak added a comment. Changed to use -fpch-instantiate-temp

[PATCH] D73846: [PCH] make sure to not warn about unused macros from -D

2020-04-21 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D73846#1991330 , @rsmith wrote: > Looks OK as a workaround. Do you know why we consider these to be in the main > file? If we could fix that in the source manager, that'd seem preferable. According to my testing, SourceManager

[PATCH] D69585: Add option to instantiate templates already in the PCH

2020-04-27 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69585/new/ https://reviews.llvm.org/D69585 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[PATCH] D74846: fix -fcodegen-modules code when used with PCH (PR44953)

2020-04-27 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74846/new/ https://reviews.llvm.org/D74846 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman

[PATCH] D73846: [PCH] make sure to not warn about unused macros from -D

2020-04-27 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG5c8c9905c249: make sure to not warn about unused macros from -D (authored by llunak). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D73846/new/ https://revie

[PATCH] D74846: fix -fcodegen-modules code when used with PCH (PR44953)

2020-04-28 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. @aganea: This change reverts only a small part of my previous change (see my comment here from Feb 23). Hans reverted the original change only until this problem gets sorted out (see his comment from Feb 27 right before the revert). Repository: rC Clang CHANGES SINCE

[PATCH] D74846: fix -fcodegen-modules code when used with PCH (PR44953)

2020-04-28 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. What is the practical difference? Either way the end result will be the same. And given that I get to wait ages for reviews of my PCH changes I find it more likely to get a review for a small patch rather than a large one. Repository: rC Clang CHANGES SINCE LAST ACTI

[PATCH] D74846: fix -fcodegen-modules code when used with PCH (PR44953)

2020-05-03 Thread Luboš Luňák via Phabricator via cfe-commits
llunak abandoned this revision. llunak added a comment. This review did make sense when it was created, it's just that it took so long to get this processed that it was simpler to revert the original patch. Anyway, I've merged the change to https://reviews.llvm.org/D69778 . Repository: rC Cl

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-05-03 Thread Luboš Luňák via Phabricator via cfe-commits
llunak reopened this revision. llunak added a comment. This revision is now accepted and ready to land. Reopening because of https://reviews.llvm.org/D74846, updated version includes the partial revert from there. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D697

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-05-03 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 261722. llunak added a comment. Reopening because of https://reviews.llvm.org/D74846, updated version includes the partial revert from there. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69778/new/ https://reviews.llvm.org/D

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-05-12 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping? I've reopened this one as suggested in D74846 , but apparently it's kept the accepted state, so I'm not sure if this needs another approval or what to do here. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llv

[PATCH] D69585: Add option to instantiate templates already in the PCH

2020-05-12 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69585/new/ https://reviews.llvm.org/D69585 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-05-13 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 263838. llunak edited the summary of this revision. llunak added a comment. Updated commit message. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69778/new/ https://reviews.llvm.org/D69778 Files: clang/lib/Serialization/AST

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-05-13 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 263839. llunak edited the summary of this revision. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69778/new/ https://reviews.llvm.org/D69778 Files: clang/lib/Serialization/ASTReader.cpp clang/lib/Serialization/ASTReaderDecl

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-05-13 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D69778#2032363 , @dblaikie wrote: > So the original commit ( cbc9d22e49b4 > ) was > reverted at some point, and now you're proposing recommitting it with a

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-05-14 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a subscriber: aganea. llunak added a comment. In D69778#2035318 , @dblaikie wrote: > Do you have a sense of the larger testing that PR44953 was reduced from? Have > you tried compiling a non-trivial codebase (I assume you might've tested it

[PATCH] D63508: make -frewrite-includes also rewrite conditions in #if/#elif

2019-08-31 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63508/new/ https://reviews.llvm.org/D63508 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[PATCH] D65371: do not emit -Wunused-macros warnings in -frewrite-includes mode (PR15614)

2019-08-31 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65371/new/ https://reviews.llvm.org/D65371 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[PATCH] D65371: do not emit -Wunused-macros warnings in -frewrite-includes mode (PR15614)

2019-09-09 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 219370. llunak added a comment. Added a test. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65371/new/ https://reviews.llvm.org/D65371 Files: clang/lib/Lex/PPDirectives.cpp clang/test/Frontend/rewrite-includes-warnings.c

[PATCH] D65371: do not emit -Wunused-macros warnings in -frewrite-includes mode (PR15614)

2019-09-09 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D65371#1659929 , @dblaikie wrote: > A test case would be good (in the clang/test directory - probably near/in the > other tests for -frewrite-includes) Done. > And does the same bug occur for other preprocessor-related warnin

[PATCH] D69779: -fmodules-codegen should not emit extern templates

2020-01-07 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D69779#1801771 , @dblaikie wrote: > Ah, if I mark the standalone function template 'inline' (the implicit linkage > of member functions) then I get the same failure for both. Haven't tested > whether the fix is the same fix for

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2020-01-08 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69585/new/ https://reviews.llvm.org/D69585 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D69779: -fmodules-codegen should not emit extern templates

2020-01-13 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Do you need some more information about the patch? It'd be nice if this could make it into 10.0. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69779/new/ https://reviews.llvm.org/D69779 ___ c

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2020-01-14 Thread Luboš Luňák via Phabricator via cfe-commits
llunak marked 2 inline comments as done. llunak added a comment. In D69585#1818205 , @rnk wrote: > I'm interested in making clang do this, but I think this needs significantly > more work until this is ready to land. It needs in-tree tests. What tests s

[PATCH] D69779: -fmodules-codegen should not emit extern templates

2020-01-14 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 238086. llunak added a comment. I've updated the test as requested. However I've noticed that a PCH-based test for this relies on https://reviews.llvm.org/D69585 . The fix works (of course), but it requires a PCH/module with the instantiation. CHANGES SINC

[PATCH] D69779: -fmodules-codegen should not emit extern templates

2020-01-14 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 238089. llunak added a comment. This version uses a module based on the code posted above. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69779/new/ https://reviews.llvm.org/D69779 Files: clang/lib/Serialization/ASTWriterDecl.cpp clang/test/Modul

[PATCH] D69779: -fmodules-codegen should not emit extern templates

2020-01-14 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG729530f68fe1: -fmodules-codegen should not emit extern templates (authored by llunak). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69779/new/ https://revi

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2020-01-14 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGcbc9d22e49b4: make -fmodules-codegen and -fmodules-debuginfo work also with PCHs (authored by llunak). Changed prior to commit: https://reviews.llvm.org/D69778?vs=227634&id=238115#toc Repository: rG

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2020-01-15 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 238217. llunak edited the summary of this revision. llunak removed a project: OpenMP. llunak added a comment. In order to simplify this, I've updated the patch to remove any reference to OpenMP and I've moved that part to https://reviews.llvm.org/D72759 . Thi

[PATCH] D88680: Add ability to turn off -fpch-instantiate-templates in clang-cl

2020-10-01 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. > I tried pretty hard to get a small repro for these failures, but couldn't. Can you get at least some testcase, even if not small? You can use -E -frewrite-includes to create a single large file from all the input. Although the patch looks fine to me as such, I consider

[PATCH] D88680: Add ability to turn off -fpch-instantiate-templates in clang-cl

2020-10-06 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. LGTM, although I'm not sure if me saying that is enough. I'll commit this in few days if nobody says anything else. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88680/new/ https://reviews.llvm.org/D88680 _

[PATCH] D73846: [PCH] make sure to not warn about unused macros from -D

2020-03-24 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D73846/new/ https://reviews.llvm.org/D73846 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D74846: fix -fcodegen-modules code when used with PCH (PR44953)

2020-03-24 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping.. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74846/new/ https://reviews.llvm.org/D74846 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/l

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2020-03-24 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69585/new/ https://reviews.llvm.org/D69585 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mai

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2020-03-26 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D69585#1942431 , @rsmith wrote: > This needs to be done behind a flag. It's an explicit design goal that > compilation behavior using a PCH or precompiled preamble behaves identically > to compilation not using a PCH / precompi

[PATCH] D74846: fix -fcodegen-modules code when used with PCH (PR44958)

2020-02-19 Thread Luboš Luňák via Phabricator via cfe-commits
llunak created this revision. llunak added reviewers: hans, dblaikie. llunak added a project: clang. Herald added a subscriber: cfe-commits. In D69778 I incorrectly handled two cases (checking for -building-pch-with-obj without also checking -fmodules-codegen).

[PATCH] D74846: fix -fcodegen-modules code when used with PCH (PR44953)

2020-02-23 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 246122. llunak retitled this revision from "fix -fcodegen-modules code when used with PCH (PR44958)" to "fix -fcodegen-modules code when used with PCH (PR44953)". llunak edited the summary of this revision. llunak added a comment. Upon further investigation it

[PATCH] D74846: fix -fcodegen-modules code when used with PCH (PR44953)

2020-02-25 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D74846#1889826 , @dblaikie wrote: > I know it's a bit of an awkward situation to test - but please include one to > demonstrate why the original code was inappropriate. At least useful for > reviewing/validating the patch, but

[PATCH] D74846: fix -fcodegen-modules code when used with PCH (PR44953)

2020-02-25 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D74846#1891580 , @dblaikie wrote: > In D74846#1891486 , @llunak wrote: > > > But before we get to this, can we please first fix my patch for 10.0? I > > didn't check properly for -fmodule

[PATCH] D73846: make sure to not warn about unused macros from -D

2020-02-28 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping... CHANGES SINCE LAST ACTION https://reviews.llvm.org/D73846/new/ https://reviews.llvm.org/D73846 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2020-02-28 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping.. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69585/new/ https://reviews.llvm.org/D69585 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D73852: [clang] detect switch fallthrough marked by a comment (PR43465)

2020-03-02 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D73852#1901186 , @rsmith wrote: > We shouldn't enable the warning under -Wextra in language modes where there's > no standard way to suppress it. That may be true, but that is not what the bugreport is about, it explicitly me

[PATCH] D73852: [clang] detect switch fallthrough marked by a comment (PR43465)

2020-03-03 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D73852#1901895 , @rsmith wrote: > Thank you, Luboš, and sorry for the process problems here. FWIW, the Clang repository here in Phabricator is still 'Inactive', so even though https://llvm.org/docs/Phabricator.html#requesting

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2019-10-29 Thread Luboš Luňák via Phabricator via cfe-commits
llunak created this revision. llunak added reviewers: ABataev, rsmith, dblaikie. llunak added projects: clang, OpenMP. Herald added a reviewer: jdoerfert. Herald added a subscriber: cfe-commits. This patch makes template instantiations be already performed in the PCH instead of it being done in e

[PATCH] D64284: (WIP) share template instantiations from PCH in one .o if -building-pch-with-obj

2019-10-29 Thread Luboš Luňák via Phabricator via cfe-commits
llunak abandoned this revision. llunak added a comment. Due to some technical problems with this approach and lack of feedback, I'm scratching this one. A new approach is at https://reviews.llvm.org/D69585 . Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64284/new

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2019-11-02 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 227575. llunak added a comment. Let's go a different route. This patch fully passes all tests and so should be ready to be committed. It does so by opting out for OpenMP, which can be handled later whenever somebody who know about OpenMP looks at it. Repos

[PATCH] D69750: make -ftime-trace also trace time spent creating debug info

2019-11-02 Thread Luboš Luňák via Phabricator via cfe-commits
llunak created this revision. llunak added a reviewer: anton-afanasyev. llunak added a project: clang. Herald added subscribers: cfe-commits, aprantl. In debug builds a noticeable time can be spent generating debug info, so make -ftime-trace track that too. Repository: rC Clang https://revie

[PATCH] D69750: make -ftime-trace also trace time spent creating debug info

2019-11-02 Thread Luboš Luňák via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG4f2104c5adbc: make -ftime-trace also trace time spent creating debug info (authored by llunak). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69750/new/ htt

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2019-11-03 Thread Luboš Luňák via Phabricator via cfe-commits
llunak created this revision. llunak added a reviewer: dblaikie. llunak added a project: clang. Herald added a subscriber: cfe-commits. This patch allows to build PCH's (with -building-pch-with-obj and the extra .o file) with -fmodules-codegen -fmodules-debuginfo to allow emitting shared code in

[PATCH] D69779: -fmodules-codegen should not emit extern templates

2019-11-03 Thread Luboš Luňák via Phabricator via cfe-commits
llunak created this revision. llunak added a reviewer: dblaikie. llunak added a project: clang. Herald added a subscriber: cfe-commits. See the test for a testcase. If a header contains 'extern template', then the template should be provided somewhere by an explicit instantiation, so it is not n

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2019-11-17 Thread Luboš Luňák via Phabricator via cfe-commits
llunak updated this revision to Diff 229722. llunak added a comment. It turns out that this patch may introduce unwanted changes, specifically it can cause err_specialization_after_instantiation if the specialization is done in a source file but needed already by code in the PCH. But this seems

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2019-12-05 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69585/new/ https://reviews.llvm.org/D69585 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2019-12-05 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69778/new/ https://reviews.llvm.org/D69778 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[PATCH] D69779: -fmodules-codegen should not emit extern templates

2019-12-05 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69779/new/ https://reviews.llvm.org/D69779 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2019-12-06 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D69778#1771799 , @rsmith wrote: > It's a bit weird for this to be controlled by a `-fmodules` flag, but it's > only a `-cc1` flag, so I'm OK with that; we can rename it if/when we expose > it from the driver. It's a bit weird

[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

2019-12-11 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D69778#1776472 , @dblaikie wrote: > I guess one aspect is that -building-pch-with-obj seems like it duplicates > the fmodules-codegen concept (both basically are a flag passed during pcm/pch > build time that says "I promise to

[PATCH] D73846: make sure to not warn about unused macros from -D

2020-03-06 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping CHANGES SINCE LAST ACTION https://reviews.llvm.org/D73846/new/ https://reviews.llvm.org/D73846 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2020-03-06 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping... CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69585/new/ https://reviews.llvm.org/D69585 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D74846: fix -fcodegen-modules code when used with PCH (PR44953)

2020-03-06 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. Ping. I don't particularly care about the declspec(selectany) corner case, but at least the mistake from D69778 should be fixed (and it's a simple fix), so that it can be committed again. Repository: rC Clang CHANGES SINCE LAST ACTI

[PATCH] D69585: PerformPendingInstatiations() already in the PCH

2020-03-13 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D69585#1922108 , @dblaikie wrote: > Does this still have an OpenMP special case? The production code changes > don't seem to mention OpenMP anymore, but there's still a lot of test updates > for OpenMP - what are they for? It

  1   2   >