[PATCH] D104462: [clang][lex] Add minimizer option to pad the output to the input size

2021-06-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, arphaman. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch adds a configuration point to the source minimizer to pad the output

[PATCH] D104460: [clang][lex] NFC: Extract source variable in minimizer tests

2021-06-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 abandoned this revision. jansvoboda11 added a comment. Found a way to do the thing in a follow up with less churn. Sorry for the noise. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D104460/new/ https://reviews.llvm.org/D104460 ___

[PATCH] D104465: [clang][deps] Prevent PCH validation failures by padding minimized files

2021-06-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, arphaman. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch fixes dependency scanning of a TU with prebuilt modular/PCH dependen

[PATCH] D104459: [clang][lex] Ensure minimizer output is never larger than input

2021-06-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 352726. jansvoboda11 added a comment. Fix assert wording Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D104459/new/ https://reviews.llvm.org/D104459 Files: clang/lib/Lex/DependencyDirectivesSourceMinimiz

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

2021-06-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. I don't have any comments regarding header maps. Comment at: clang/test/Modules/implicit-module-header-maps.cpp:17 +// +// RUN: sed -e "s:OUTPUTS_DIR:%t:g" %S/Inputs/implicit-module-header-maps/b.hmap.json > %t/hmap.json +// RUN: %hmaptool write %

[PATCH] D104536: WIP: [clang][deps] Avoid minimizing PCH input files

2021-06-18 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch avoid minimizing input files that contributed to a PCH or its modules. This prevents the implicit modular build to fail on unexpect

[PATCH] D104465: [clang][deps] Prevent PCH validation failures by padding minimized files

2021-06-18 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Thanks for sharing your ideas! I've left my initial thoughts below, but I want to revisit this and think about it some more. In D104465#2825343 , @dexonsmith wrote: > I'm not sure this is the right approach. > > - Don't PC

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

2021-06-18 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D103930#2825181 , @dexonsmith wrote: > In D103930#2820725 , @bruno wrote: > >> Thanks for working on this, comments inline. @vsapsai @jansvoboda11 >> @dexonsmith any headermap re

[PATCH] D106862: [clang][modules] Avoid creating partial FullSourceLoc for explicit modules imports

2021-07-30 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 363033. jansvoboda11 edited the summary of this revision. jansvoboda11 added a comment. Remove assertion altogether. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D106862/new/ https://reviews.llvm.org/D106862 Files: clang/include/clang/Basic/

[PATCH] D106862: [clang][modules] Avoid creating partial FullSourceLoc for explicit modules imports

2021-07-30 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 requested review of this revision. jansvoboda11 added a comment. I investigated this a bit more. What previously lead me to believe that `SourceLoc::ID` is being modified from the outside was the way it's declared right after some `friend`s: class SourceLocation { friend clas

[PATCH] D107155: [clang][deps] Substitute clang-scan-deps executable in lit tests

2021-07-30 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, arphaman, lxfind. jansvoboda11 added a project: clang. jansvoboda11 requested review of this revision. The lit tests for `clang-scan-deps` invoke the tool without going through the substitution system. While

[PATCH] D106864: [clang][cli] Expose -fno-cxx-modules in cc1

2021-07-30 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 363071. jansvoboda11 added a comment. Add negative test, check error messages. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D106864/new/ https://reviews.llvm.org/D106864 Files: clang/include/clang/Driver/Options.td clang/lib/Frontend/Compi

[PATCH] D106864: [clang][cli] Expose -fno-cxx-modules in cc1

2021-07-30 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/test/Modules/cxx20-disable.cpp:2 +// RUN: rm -rf %t && mkdir %t +// RUN: not %clang_cc1 -x objective-c++ -std=c++20 -fno-cxx-modules -I %t %s + arphaman wrote: > jansvoboda11 wrote: > > I'm not sure how to bes

[PATCH] D107155: [clang][deps] Substitute clang-scan-deps executable in lit tests

2021-08-02 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 363411. jansvoboda11 added a comment. Move substitution to `clang/test/lit.cfg.py`, revert `%` prefixes. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D107155/new/ https://reviews.llvm.org/D107155 Files: clang/test/lit.cfg.py Index: clang/t

[PATCH] D107155: [clang][deps] Substitute clang-scan-deps executable in lit tests

2021-08-02 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D107155#2916664 , @dblaikie wrote: > Hmm, don't we have some other substitution feature that avoids the need to > add the %? (like, I think LLVM's tests don't usually use the % for many tool > names - but they still make

[PATCH] D105881: [flang][driver] Switch to `BoolFOption` for boolean options

2021-08-02 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D105881#2906955 , @awarzynski wrote: > OK, that's fair enough. But what about the output from `clang --help` and > `clang -cc1 --help`? Let's look at -feliminate-unused-debug-types >

[PATCH] D106864: [clang][cli] Expose -fno-cxx-modules in cc1

2021-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG0556138624ed: [clang][cli] Expose -fno-cxx-modules in cc1 (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D106864/new/ https://revi

[PATCH] D107155: [clang][deps] Substitute clang-scan-deps executable in lit tests

2021-08-04 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG2718ae397b29: [clang][deps] Substitute clang-scan-deps executable in lit tests (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D1071

[PATCH] D105881: [flang][driver] Refactor boolean options

2021-08-05 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 accepted this revision. jansvoboda11 added a comment. This revision is now accepted and ready to land. In D105881#2926523 , @awarzynski wrote: > Yes. Updating printHelp >

[PATCH] D106862: [clang] Remove misleading assertion in FullSourceLoc

2021-08-05 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D106862/new/ https://reviews.llvm.org/D106862 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D104351: [HeaderSearch] Use `isImport` only for imported headers and not for `#pragma once`.

2021-08-06 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 accepted this revision. jansvoboda11 added a comment. This revision is now accepted and ready to land. Ok, this makes sense. LGTM. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D104351/new/ https://reviews.llvm.org/D104351

[PATCH] D106862: [clang] Remove misleading assertion in FullSourceLoc

2021-08-06 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG4aafd5f00c2a: [clang] Remove misleading assertion in FullSourceLoc (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D106862/new/ htt

[PATCH] D108215: [clang][deps] NFC: Move `ResourceDirectoryCache`

2021-08-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, arphaman. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. The `ResourceDirectoryCache` is useful not only in the `clang-scan-deps` CLI to

[PATCH] D108366: [clang][deps] Deduce resource directory from the compiler path

2021-08-19 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, arphaman, kousikk. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. After [[libclang][deps] Accept only driver invocations, don't modify t

[PATCH] D108366: [clang][deps] Deduce resource directory from the compiler path

2021-08-19 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Tagging @kousikk, since this is related to D69122 that introduced `ResourceDirectoryCache` to `clang-scan-deps`. When the compilation command doesn't have a `-resource-dir` argument, `ResourceDirectoryCache` invokes the specified c

[PATCH] D108215: [clang][deps] NFC: Move `ResourceDirectoryCache`

2021-08-19 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 abandoned this revision. jansvoboda11 added a comment. Fair points. Abandoning in favor of D108366 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D108215/new/ https://reviews.llvm.org/D108215

[PATCH] D108366: [clang][deps] Deduce resource directory from the compiler path

2021-08-19 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 367478. jansvoboda11 added a comment. Account for Windows backslashes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D108366/new/ https://reviews.llvm.org/D108366 Files: clang/include/clang/Tooling/Toolin

[PATCH] D103461: [clang][deps] NFC: Preserve the original frontend action

2021-07-07 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D103461#2841918 , @bmahjour wrote: > @jansvoboda11 This change is causing the following LIT tests to fail on AIX: > > Clang :: ClangScanDeps/headerwithdirname.cpp > Clang :: ClangScanDeps/headerwithdirnamefollowedbyinc

[PATCH] D105695: [clang][tooling] Accept Clang invocations with "-fno-integrated-as"

2021-07-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, bmahjour. jansvoboda11 added a project: clang. jansvoboda11 requested review of this revision. When "-fno-integrated-as" is passed to the Clang driver (or set by default by a specific toolchain), it will cons

[PATCH] D103461: [clang][deps] NFC: Preserve the original frontend action

2021-07-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D103461#2862067 , @jansvoboda11 wrote: > In D103461#2841918 , @bmahjour > wrote: > >> @jansvoboda11 This change is causing the following LIT tests to fail on AIX: >> >> Clang :

[PATCH] D104536: WIP: [clang][deps] Avoid minimizing PCH input files

2021-07-12 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 357862. jansvoboda11 added reviewers: Bigcheese, dexonsmith, arphaman. jansvoboda11 added a comment. Handle system input files. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D104536/new/ https://reviews.llv

[PATCH] D104536: WIP: [clang][deps] Avoid minimizing PCH input files

2021-07-12 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. I run a quick benchmark where an empty TU is configured with an explicitly built PCH that imports Cocoa. Dependency scanning without minimization takes 226 ms, with this patch 303 ms and 325 ms when padding minimized files to the original size. Since we'll eventual

[PATCH] D105881: [flang][driver] Switch to `BoolFOption` for boolean options

2021-07-13 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/include/clang/Driver/Options.td:246 +class EmptyKPM : KeyPathAndMacro<"", "", ""> {} class DiagnosticOpts awarzynski wrote: > @jansvoboda11 , is this the right approach here? I'd like use `BoolFOption` > i

[PATCH] D105881: [flang][driver] Switch to `BoolFOption` for boolean options

2021-07-13 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/include/clang/Driver/Options.td:246 +class EmptyKPM : KeyPathAndMacro<"", "", ""> {} class DiagnosticOpts awarzynski wrote: > jansvoboda11 wrote: > > awarzynski wrote: > > > @jansvoboda11 , is this the righ

[PATCH] D105695: [clang][tooling] Accept Clang invocations with multiple cc1 jobs

2021-07-14 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 358724. jansvoboda11 retitled this revision from "[clang][tooling] Accept Clang invocations with "-fno-integrated-as"" to "[clang][tooling] Accept Clang invocations with multiple cc1 jobs". jansvoboda11 edited the summary of this revision. jansvoboda11 a

[PATCH] D104536: WIP: [clang][deps] Avoid minimizing PCH input files

2021-07-14 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 358726. jansvoboda11 added a comment. Entirely disable `DepFS` when scanning PCHs. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D104536/new/ https://reviews.llvm.org/D104536 Files: clang/lib/Tooling/DependencyScanning/DependencyScanningWorke

[PATCH] D109506: [clangd] Print current request context along with the stack trace

2021-10-26 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Here's another test failure: https://green.lab.llvm.org/green/job/clang-stage1-RA/24998 Can you revert if the fix is not trivial? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109506/new/ https://reviews.llvm.org/D109

[PATCH] D112088: [clang][deps] Keep #pragma push_macro, pop_macro and include_alias when minimizing source code.

2021-11-01 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 accepted this revision. jansvoboda11 added a comment. This revision is now accepted and ready to land. LGTM, thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112088/new/ https://reviews.llvm.org/D112088 __

[PATCH] D112915: WIP: [clang][modules] Granular tracking of includes

2021-11-01 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, vsapsai, rsmith. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. When building a module consisting of submodules, the preprocessor keeps a

[PATCH] D112915: WIP: [clang][modules] Granular tracking of includes

2021-11-01 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. I'm interested in hearing some feedback whether the direction I'm taking here makes sense. There are a couple of TODOs (mostly on optimizing away unnecessary maps) and a few modules-ts tests are failing. @rsmith left a suggestion on D104344

[PATCH] D112923: [clang][deps] Reset some benign codegen options

2021-11-01 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Some command-line codegen arguments are likely to differ between identical modules discov

[PATCH] D112915: WIP: [clang][modules] Granular tracking of includes

2021-11-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 384484. jansvoboda11 added a comment. Avoid copying data between submodules Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112915/new/ https://reviews.llvm.org/D112915 Files: clang/include/clang/Lex/Head

[PATCH] D112915: WIP: [clang][modules] Granular tracking of includes

2021-11-03 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D112915#3104873 , @vsapsai wrote: > There can be other reasons to keep `IncludeMap` out of `SubmoduleState` but > I'm not sure the local submodule visibility is the right reason. I might be > reading the code incorrectly

[PATCH] D112915: WIP: [clang][modules] Granular tracking of includes

2021-11-04 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 384791. jansvoboda11 added a comment. Call `getFileInfo` in `Preprocessor::EnterMainSourceFile`. This ensures deserialization of `HeaderFileInfo`, which seems to be necessary with modules-ts enabled. Repository: rG LLVM Github Monorepo CHANGES SINC

[PATCH] D112915: WIP: [clang][modules] Granular tracking of includes

2021-11-08 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 385434. jansvoboda11 added a comment. Herald added a subscriber: mgrang. Fix deserialization, improve (sub)module state tracking Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112915/new/ https://reviews.ll

[PATCH] D112915: WIP: [clang][modules] Granular tracking of includes

2021-11-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 385730. jansvoboda11 added a comment. Make loading of (sub)module includes lazy Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112915/new/ https://reviews.llvm.org/D112915 Files: clang/include/clang/Lex/

[PATCH] D112915: [clang][modules] Track number of includes per submodule

2021-11-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 marked 2 inline comments as done. jansvoboda11 added a comment. Thanks for your feedback @dexonsmith. I reworked the patch to use more sensible data structures as suggested, and made the AST deserialization lazy (on (sub)module import). I think the only thing to figure out is the e

[PATCH] D113473: [clang][deps] Don't emit `-fmodule-map-file=`

2021-11-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, vsapsai, bnbarham. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. During explicit modules build, when all modules are provided via `-fmo

[PATCH] D112915: [clang][modules] Track number of includes per submodule

2021-11-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 385751. jansvoboda11 marked an inline comment as done. jansvoboda11 added a comment. Make clang-format happy. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112915/new/ https://reviews.llvm.org/D112915 Fil

[PATCH] D113391: [Modules] Don't support clang module and c++20 module at the same time

2021-11-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/test/ClangScanDeps/Inputs/header-search-pruning/cdb.json:1 -[ - { -"directory": "DIR", -"command": "clang -E DIR/header-search-pruning.cpp -Ibegin -I1 -Ia -I3 -I4 -I5 -I6 -Ib -I8 -Iend DEFINES -fmodules -fcxx-modules

[PATCH] D113391: [Modules] Don't support clang module and c++20 module at the same time

2021-11-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/test/ClangScanDeps/Inputs/header-search-pruning/cdb.json:1 -[ - { -"directory": "DIR", -"command": "clang -E DIR/header-search-pruning.cpp -Ibegin -I1 -Ia -I3 -I4 -I5 -I6 -Ib -I8 -Iend DEFINES -fmodules -fcxx-modules

[PATCH] D113391: [Modules] Don't support clang module and c++20 module at the same time

2021-11-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/test/ClangScanDeps/Inputs/header-search-pruning/cdb.json:3 + "directory" : "DIR", + "command" : "clang -E DIR/header-search-pruning.cpp -Ibegin -I1 -Ia -I3 -I4 -I5 -I6 -Ib -I8 -Iend DEFINES -fmodules -fmodules-cache-path=DI

[PATCH] D112915: [clang][modules] Track number of includes per submodule

2021-11-10 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 386139. jansvoboda11 added a comment. Store only direct includes in the PCM (compared to transitive stored previously), use InputFile ID (instead of full filesystem path). Also: add test of transitive includes, fix bug in `VisibleModuleSet::setVisible`

[PATCH] D113676: WIP: [clang][lex] Fix search path usage remark with modules

2021-11-11 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added a reviewer: ahoppen. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. When looking for module, `HeaderSearch::lookupModule` iterates through search paths, parses modulemaps

[PATCH] D113676: WIP: [clang][lex] Fix search path usage remark with modules

2021-11-11 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/lib/Lex/HeaderSearch.cpp:264 + if (Module || !AllowSearch || !HSOpts->ImplicitModuleMaps) { +noteModuleLookupUsage(Module, ImportLoc); return Module; This is the important change. Repository: rG

[PATCH] D113676: WIP: [clang][lex] Fix search path usage remark with modules

2021-11-11 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 386541. jansvoboda11 added a comment. Apply clang-format. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113676/new/ https://reviews.llvm.org/D113676 Files: clang/include/clang/Lex/HeaderSearch.h clang

[PATCH] D113676: WIP: [clang][lex] Fix search path usage remark with modules

2021-11-11 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 386749. jansvoboda11 added a comment. Add extra test case Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113676/new/ https://reviews.llvm.org/D113676 Files: clang/include/clang/Lex/HeaderSearch.h clang

[PATCH] D113676: WIP: [clang][lex] Fix search path usage remark with modules

2021-11-12 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. Thanks for the feedback, I'll try to clean this up a bit. Comment at: clang/lib/Lex/HeaderSearch.cpp:94 + // Module map parsing initiated by header search. + if (HS.CurrentSearchPathIdx != ~0U) +HS.ModuleToSearchDirIdx[M] = HS.Cur

[PATCH] D113761: [clang][modules] NFC: Factor out path-based submodule lookup

2021-11-12 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, vsapsai. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This is a prep patch for Dxx that factors out the path-based submodule looku

[PATCH] D113775: [clang][modules] Umbrella with missing submodule: unify implicit & explicit

2021-11-12 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, vsapsai. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Submodules not covered by existing umbrella header are being imported as textual

[PATCH] D113775: [clang][modules] Umbrella with missing submodule: unify implicit & explicit

2021-11-12 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 386847. jansvoboda11 added a comment. Re-run CI Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113775/new/ https://reviews.llvm.org/D113775 Files: clang/include/clang/Frontend/CompilerInstance.h clang/

[PATCH] D113676: WIP: [clang][lex] Fix search path usage remark with modules

2021-11-12 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/lib/Lex/HeaderSearch.cpp:94 + // Module map parsing initiated by header search. + if (HS.CurrentSearchPathIdx != ~0U) +HS.ModuleToSearchDirIdx[M] = HS.CurrentSearchPathIdx; ahoppen wrote: > j

[PATCH] D96280: [clang][cli] Round-trip the whole CompilerInvocation

2021-02-26 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:666 + // semantics as the original. + SmallVector GeneratedArgs1; + Generate(DummyInvocation, GeneratedArgs1, SA); scui wrote: > This is failing our build, This line and

[PATCH] D97461: [clang][cli] Implement '-cuid=' marshalling

2021-02-26 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGcb81135f94e5: [clang][cli] Implement '-cuid=' marshalling (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97461/new/ https://revie

[PATCH] D97552: [clang][cli] Fix generation of '-fvisibility' with regards to '-mignore-xcoff-visibility'

2021-02-26 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, DiggerLin. Herald added a subscriber: dang. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch fixes failure of the `CodeGen/aix-i

[PATCH] D97462: [clang][cli] Round-trip cc1 arguments in assert builds

2021-02-26 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 326677. jansvoboda11 added a comment. Rebase on top of D97552 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97462/new/ https://reviews.llvm.org/D97462 Files: clang/CMak

[PATCH] D93031: Enable fexec-charset option

2021-03-01 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/include/clang/Driver/Options.td:3583 +def fexec_charset : Separate<["-"], "fexec-charset">, MetaVarName<"">, + HelpText<"Set the execution for string and character literals. " Could you switch to the optio

[PATCH] D97702: [clang][modules] Use extensible RTTI for ModuleFileExtension

2021-03-01 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Clang exposes an interface for extending the PCM/PCH file format: `ModuleFileExtension`.

[PATCH] D97552: [clang][cli] Fix generation of '-fvisibility' with regards to '-mignore-xcoff-visibility'

2021-03-05 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGfcf75ae6ce20: [clang][cli] Fix generation of '-fvisibility' with regards to '-mignore-xcoff… (authored by jansvoboda11). Changed prior to commit: https://reviews.llvm.org/D97552?vs=326676&id=328448#toc

[PATCH] D97702: [clang][modules] Use extensible RTTI for ModuleFileExtension

2021-03-05 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG4295ae96cdf2: [clang][modules] Use extensible RTTI for ModuleFileExtension (authored by jansvoboda11). Changed prior to commit: https://reviews.llvm.org/D97702?vs=327163&id=328453#toc Repository: rG

[PATCH] D89986: [AIX] do not emit visibility attribute into IR when there is -mignore-xcoff-visibility

2021-03-05 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. FYI, this might need rebasing on top of D97552 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89986/new/ https://reviews.llvm.org/D89986 _

[PATCH] D97462: [clang][cli] Round-trip cc1 arguments in assert builds

2021-03-05 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 328460. jansvoboda11 added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97462/new/ https://reviews.llvm.org/D97462 Files: clang/CMakeLists.txt Index: clang/CMakeLists.txt ==

[PATCH] D89986: [AIX] do not emit visibility attribute into IR when there is -mignore-xcoff-visibility

2021-03-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D89986#2612021 , @DiggerLin wrote: > Gentle ping . @jansvoboda11 . Do you have any comment on it the last update > on "added -round-trip-args functionality for the lang opt > "-mignore-xcoff-visibility" ? I'd slightly

[PATCH] D97743: Define __GCC_HAVE_DWARF2_CFI_ASM if applicable

2021-03-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 accepted this revision. jansvoboda11 added a comment. This revision is now accepted and ready to land. Could the logic be implemented in the driver? LGTM regardless. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97743/new/ https://rev

[PATCH] D97552: [clang][cli] Fix generation of '-fvisibility' with regards to '-mignore-xcoff-visibility'

2021-03-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D97552#2607842 , @DiggerLin wrote: > 1. in your summary , it looks clang will emit "-fvisibility default" to cc1 > even if there is no -fvisibility in the clang command ? I compiled the clang > with your patch, it look

[PATCH] D93769: [clang] Add support for option -ffp-eval-method and extend #pragma float_control similarly

2021-03-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:2884 + } + Opts.setFPEvalMethod(FEM); + Can you please use the marshalling infrastructure for this? https://clang.llvm.org/docs/InternalsManual.html#adding-new-command-li

[PATCH] D97743: Define __GCC_HAVE_DWARF2_CFI_ASM if applicable

2021-03-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D97743#2614480 , @MaskRay wrote: > In D97743#2613629 , @jansvoboda11 > wrote: > >> Could the logic be implemented in the driver? >> >> LGTM regardless. > > No. `Res` is a `clang::Co

[PATCH] D97743: Define __GCC_HAVE_DWARF2_CFI_ASM if applicable

2021-03-09 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D97743#2614899 , @MaskRay wrote: > Move to driver Thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97743/new/ https://reviews.llvm.org/D97743

[PATCH] D98438: Clang: Allow selecting the hash algorithm for file checksums in debug info.

2021-03-11 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/include/clang/Driver/Options.td:2775 def gno_split_dwarf : Flag<["-"], "gno-split-dwarf">, Group; +def gsrc_hash_algorithm_EQ : Joined<["-"], "gsrc-hash-algorithm=">, Group, Flags<[CC1Option]>, + HelpText<"Hashing algorithm

[PATCH] D97717: [SYCL] Rework the SYCL driver options

2021-03-15 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 requested changes to this revision. jansvoboda11 added a comment. This revision now requires changes to proceed. I like the simplification of the command line interface. I have concerns about changing the tests just to make them pass though. Comment at: clang/unit

[PATCH] D94950: [clang][lex] Speculative fix for buffer overrun on raw string parse

2021-03-15 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/lib/Lex/LiteralSupport.cpp:1639 const char *Prefix = ThisTokBuf; - while (ThisTokBuf[0] != '(') + while (ThisTokBuf - Prefix < 16 && ThisTokBuf[0] != '(') ++ThisTokBuf; beccadax wrote

[PATCH] D94950: [clang][lex] Speculative fix for buffer overrun on raw string parse

2021-03-15 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 330647. jansvoboda11 added a comment. Implement suggested improvements Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94950/new/ https://reviews.llvm.org/D94950 Files: clang/lib/Lex/LiteralSupport.cpp

[PATCH] D94950: [clang][lex] Speculative fix for buffer overrun on raw string parse

2021-03-15 Thread Jan Svoboda 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 rG23cc8ebf59c6: [clang][lex] Speculative fix for buffer overrun on raw string parse (authored by jansvoboda11). Changed prior to commit: https://rev

[PATCH] D113880: [clang][modules] Infer framework modules in explicit builds

2021-11-15 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, vsapsai. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. When the dependency scanner discovers dependency on an inferred module, it corre

[PATCH] D113775: [clang][modules] Umbrella with missing submodule: unify implicit & explicit

2021-11-15 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/test/Modules/missing-submodule.m:3 // RUN: %clang_cc1 -fmodules -fimplicit-module-maps -fmodules-cache-path=%t -F %S/Inputs %s -verify +// RUN: %clang_cc1 -fmodules -fimplicit-module-maps -F %S/Input

[PATCH] D113775: [clang][modules] Umbrella with missing submodule: unify implicit & explicit

2021-11-15 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 387199. jansvoboda11 added a comment. Add `-fno-implicit-modules` to test case to make it more obvious. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113775/new/ https://reviews.llvm.org/D113775 Files:

[PATCH] D106876: Remove non-affecting module maps from PCM files.

2021-11-16 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added a comment. In D106876#3066924 , @ilyakuteev wrote: > Hello everyone, can somebody please help me commit this patch to trunk? Hi, I'm happy to commit this for you. What author name and email would you like to be associated with the co

[PATCH] D114092: [clang][lex] NFC: Remove unused HeaderFileInfo member

2021-11-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, vsapsai. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch removes `HeaderFileInfo::isNonDefault`, which is not being used anywh

[PATCH] D114093: [clang][lex] Refactor check for the first file include

2021-11-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, vsapsai. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch refactors the code that checks whether a file has just been included

[PATCH] D114095: [clang][lex][modules] Move number of includes from HeaderFileInfo to Preprocessor

2021-11-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, vsapsai. Herald added a subscriber: mgrang. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch moves the number of times a file wa

[PATCH] D114096: [clang][lex][modules] Stop tracking number of includes

2021-11-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 created this revision. jansvoboda11 added reviewers: Bigcheese, dexonsmith, vsapsai. Herald added a subscriber: mgrang. jansvoboda11 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch stops tracking the number of includ

[PATCH] D112915: [clang][modules] Track number of includes per submodule

2021-11-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 updated this revision to Diff 387952. jansvoboda11 added a comment. Rebase on top of extracted patches. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112915/new/ https://reviews.llvm.org/D112915 Files: clang/include/clang/Lex/Extern

[PATCH] D112915: [clang][modules] Track number of includes per submodule

2021-11-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 marked 5 inline comments as done. jansvoboda11 added a comment. In D112915#3122340 , @dexonsmith wrote: > Implementation looks a lot cleaner! > > I'd still like to drop NumIncludes first if possible because I think it'll be > easier to reas

[PATCH] D112915: [clang][modules] Track number of includes per submodule

2021-11-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 marked 4 inline comments as done. jansvoboda11 added a comment. In D112915#3136492 , @vsapsai wrote: > Didn't go in-depth for serialization/deserialization. When we add tracking > `isImport` on per-submodule basis, do you think AST reading/w

[PATCH] D114120: [clang] Remove CLANG_ROUND_TRIP_CC1_ARGS and always roundtrip in +assert builds

2021-11-17 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 accepted this revision. jansvoboda11 added a comment. This revision is now accepted and ready to land. LGTM, thanks! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114120/new/ https://reviews.llvm.org/D114120 ___ cfe-commits maili

[PATCH] D114120: [clang] Remove CLANG_ROUND_TRIP_CC1_ARGS and always roundtrip in +assert builds

2021-11-18 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 added inline comments. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:615 // May perform round-trip of command line arguments. By default, the round-trip // is enabled if CLANG_ROUND_TRIP_CC1_ARGS was defined during build. This can be // overwritten at run

[PATCH] D106876: Remove non-affecting module maps from PCM files.

2021-11-18 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG8a4fcfc242a0: Remove non-affecting module maps from PCM files. (authored by ilyakuteev, committed by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.

[PATCH] D113473: [clang][deps] Don't emit `-fmodule-map-file=`

2021-11-18 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG17ec9d1f6bc1: [clang][deps] Don't emit `-fmodule-map-file=` (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113473/new/ https://re

[PATCH] D114092: [clang][lex] NFC: Remove unused HeaderFileInfo member

2021-11-18 Thread Jan Svoboda via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG7b6790850968: [clang][lex] NFC: Remove unused HeaderFileInfo member (authored by jansvoboda11). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114092/new/ ht

[PATCH] D114093: [clang][lex] Refactor check for the first file include

2021-11-18 Thread Jan Svoboda via Phabricator via cfe-commits
jansvoboda11 marked 3 inline comments as done. jansvoboda11 added inline comments. Comment at: clang/include/clang/Lex/HeaderSearch.h:445-447 + bool ShouldEnterIncludeFile(bool &IsFirstIncludeOfFile, Preprocessor &PP, + const FileEntry *File, bool is

<    3   4   5   6   7   8   9   10   11   12   >