[clang] aca23d8 - [clang] Fix assertion failure using -MJ with -fsyntax-only

2023-08-30 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-08-30T10:04:34-07:00 New Revision: aca23d8ac30d773c1513d1708bdda8149acc075a URL: https://github.com/llvm/llvm-project/commit/aca23d8ac30d773c1513d1708bdda8149acc075a DIFF: https://github.com/llvm/llvm-project/commit/aca23d8ac30d773c1513d1708bdda8149acc075a.diff

[clang] [clang][deps] Optimize command line generation (PR #65412)

2023-09-05 Thread Ben Langmuir via cfe-commits
benlangmuir wrote: I haven't dug into this in depth yet, but did you consider keeping the normal function names for the `const` versions and only rename the mutating ones? My thinking is you could use `CowCompilerInvocation` as a drop-in replacement for `CompilerInvocation` in immutable settin

[clang] [clang][deps] Optimize command line generation (PR #65412)

2023-09-05 Thread Ben Langmuir via cfe-commits
benlangmuir wrote: > There are places in Clang where we store the result of the const function in > some kind of long-lived data structure, and someplace else modify the result > of the non-const function, expecting the change to be reflected. I would be comfortable with this, because you woul

[clang] cc3fddb - [pch] Honour -fallow-pch-with-compiler-errors for overall compilation status

2020-03-31 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2020-03-31T13:50:12-07:00 New Revision: cc3fddb411d55d4d0902a772a9f3db11fc4f002e URL: https://github.com/llvm/llvm-project/commit/cc3fddb411d55d4d0902a772a9f3db11fc4f002e DIFF: https://github.com/llvm/llvm-project/commit/cc3fddb411d55d4d0902a772a9f3db11fc4f002e.diff

[clang] c322d32 - Forward WrapperFrontendAction::shouldEraseOutputFiles()

2020-03-31 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2020-03-31T16:20:23-07:00 New Revision: c322d328aa331639f647711aee44c5dddfadd337 URL: https://github.com/llvm/llvm-project/commit/c322d328aa331639f647711aee44c5dddfadd337 DIFF: https://github.com/llvm/llvm-project/commit/c322d328aa331639f647711aee44c5dddfadd337.diff

Re: [clang] dd870f6 - Fix warning about unused std::unique result, erase shifted elements

2019-11-18 Thread Ben Langmuir via cfe-commits
Nice find. The change LGTM, and is clearly what I always intended it to do. I was confused how this ever worked at all, but I see that (at least in libc++) we move the values into place rather than swap them, so the values at the end are still the largest values for types with a trivial move c

[clang] 2ac0c4b - [DirectoryWatcher] Fix misuse of FSEvents API and data race

2020-02-11 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2020-02-11T09:25:38-08:00 New Revision: 2ac0c4b46ee2a3c22b85b4483f2fd4d0fb916720 URL: https://github.com/llvm/llvm-project/commit/2ac0c4b46ee2a3c22b85b4483f2fd4d0fb916720 DIFF: https://github.com/llvm/llvm-project/commit/2ac0c4b46ee2a3c22b85b4483f2fd4d0fb916720.diff

r328337 - [vfs] Don't bail out after a missing -ivfsoverlay file

2018-03-23 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Fri Mar 23 10:37:27 2018 New Revision: 328337 URL: http://llvm.org/viewvc/llvm-project?rev=328337&view=rev Log: [vfs] Don't bail out after a missing -ivfsoverlay file This make -ivfsoverlay behave more like other fatal errors (e.g. missing -include file) by skipping the

[clang] 296ba5b - [clang][deps] Split lookupModuleOutput out of DependencyConsumer NFC

2023-03-10 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-03-10T13:14:49-08:00 New Revision: 296ba5bbd387e7f3edb0131054183fa7913a091e URL: https://github.com/llvm/llvm-project/commit/296ba5bbd387e7f3edb0131054183fa7913a091e DIFF: https://github.com/llvm/llvm-project/commit/296ba5bbd387e7f3edb0131054183fa7913a091e.diff

[clang] fcab930 - [clang][deps] Handle response files in dep scanner

2023-03-13 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-03-13T15:47:35-07:00 New Revision: fcab930cd32e6d977816fa7094a0de0bc0d7dd1f URL: https://github.com/llvm/llvm-project/commit/fcab930cd32e6d977816fa7094a0de0bc0d7dd1f DIFF: https://github.com/llvm/llvm-project/commit/fcab930cd32e6d977816fa7094a0de0bc0d7dd1f.diff

[clang] 1ede7b4 - [clang][modules] Avoid serializing all diag mappings in non-deterministic order

2023-06-29 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-06-29T13:17:24-07:00 New Revision: 1ede7b47493f8d8548202e5f4e4a150c11e070fd URL: https://github.com/llvm/llvm-project/commit/1ede7b47493f8d8548202e5f4e4a150c11e070fd DIFF: https://github.com/llvm/llvm-project/commit/1ede7b47493f8d8548202e5f4e4a150c11e070fd.diff

[clang] 758bca6 - [clang][deps] Remove -coverage-data-file and -coverage-notes-file from modules

2023-03-31 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-03-31T09:43:22-07:00 New Revision: 758bca6483853a743297b68bd88a5dba9d5247f2 URL: https://github.com/llvm/llvm-project/commit/758bca6483853a743297b68bd88a5dba9d5247f2 DIFF: https://github.com/llvm/llvm-project/commit/758bca6483853a743297b68bd88a5dba9d5247f2.diff

[clang] 8ec36e6 - [clang][modules] Handle explicit modules when checking for .Private -> _Private

2023-04-04 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-04-04T08:12:10-07:00 New Revision: 8ec36e6956cb03d80f3fee8e593808c43a8a1ec3 URL: https://github.com/llvm/llvm-project/commit/8ec36e6956cb03d80f3fee8e593808c43a8a1ec3 DIFF: https://github.com/llvm/llvm-project/commit/8ec36e6956cb03d80f3fee8e593808c43a8a1ec3.diff

[clang] cf73d3f - [clang][deps] Ensure module invocation can be serialized

2023-02-08 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-02-08T14:23:39-08:00 New Revision: cf73d3f07b5b0ff83a852dfdf8857500e86f9952 URL: https://github.com/llvm/llvm-project/commit/cf73d3f07b5b0ff83a852dfdf8857500e86f9952 DIFF: https://github.com/llvm/llvm-project/commit/cf73d3f07b5b0ff83a852dfdf8857500e86f9952.diff

[clang] 8711120 - [clang][deps] Migrate ModuleDepCollector to LexedFileChanged NFCI

2023-02-09 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-02-09T11:42:03-08:00 New Revision: 8711120e8bcf891f3c316e20869493e93472f200 URL: https://github.com/llvm/llvm-project/commit/8711120e8bcf891f3c316e20869493e93472f200 DIFF: https://github.com/llvm/llvm-project/commit/8711120e8bcf891f3c316e20869493e93472f200.diff

[clang] ee8ed0b - [clang][deps] Teach dep directive scanner about _Pragma

2023-05-09 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-05-09T10:05:12-07:00 New Revision: ee8ed0b3099e63ba0a18cca42b9cfdf098bc6201 URL: https://github.com/llvm/llvm-project/commit/ee8ed0b3099e63ba0a18cca42b9cfdf098bc6201 DIFF: https://github.com/llvm/llvm-project/commit/ee8ed0b3099e63ba0a18cca42b9cfdf098bc6201.diff

[clang] 5984ea2 - [clang] Prevent creation of new submodules in ASTWriter

2023-05-09 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-05-09T13:02:36-07:00 New Revision: 5984ea216d2acbe5613b0af06ea27ef395ca9904 URL: https://github.com/llvm/llvm-project/commit/5984ea216d2acbe5613b0af06ea27ef395ca9904 DIFF: https://github.com/llvm/llvm-project/commit/5984ea216d2acbe5613b0af06ea27ef395ca9904.diff

[clang] e06a91c - [clang][modules] Avoid re-exporting PCH imports on every later module import

2023-04-20 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-04-20T11:29:23-07:00 New Revision: e06a91c5996b039cacd55e6ead0baf14424c740c URL: https://github.com/llvm/llvm-project/commit/e06a91c5996b039cacd55e6ead0baf14424c740c DIFF: https://github.com/llvm/llvm-project/commit/e06a91c5996b039cacd55e6ead0baf14424c740c.diff

[clang-tools-extra] 8fe8d69 - [clang][deps] Make clang-scan-deps write modules in raw format

2023-05-03 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-05-03T12:07:46-07:00 New Revision: 8fe8d69ddf881db70cb8df31e614a06e633e2c5f URL: https://github.com/llvm/llvm-project/commit/8fe8d69ddf881db70cb8df31e614a06e633e2c5f DIFF: https://github.com/llvm/llvm-project/commit/8fe8d69ddf881db70cb8df31e614a06e633e2c5f.diff

[clang] 7b492d1 - [clang][deps] Teach dep directive scanner about #pragma clang system_header

2023-05-03 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-05-03T13:53:21-07:00 New Revision: 7b492d1be0ea5b767cc567ca2792a291242f9973 URL: https://github.com/llvm/llvm-project/commit/7b492d1be0ea5b767cc567ca2792a291242f9973 DIFF: https://github.com/llvm/llvm-project/commit/7b492d1be0ea5b767cc567ca2792a291242f9973.diff

Re: [PATCH] D23858: Don't diagnose non-modular includes when we are not compiling a module

2016-08-25 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. LGTM, but @rsmith should glance at this too. https://reviews.llvm.org/D23858 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r307855 - [index] Don't add relation to a NamedDecl with no name

2017-07-12 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Wed Jul 12 15:05:30 2017 New Revision: 307855 URL: http://llvm.org/viewvc/llvm-project?rev=307855&view=rev Log: [index] Don't add relation to a NamedDecl with no name Unless it's one of the special cases (tag, category) that we can handle. This syncs up the check between

r308800 - [index] Set SymbolSubKind::Accessor[GS]etter on class methods

2017-07-21 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Fri Jul 21 16:04:27 2017 New Revision: 308800 URL: http://llvm.org/viewvc/llvm-project?rev=308800&view=rev Log: [index] Set SymbolSubKind::Accessor[GS]etter on class methods We have the same relation between class properties and getter/setters that we have for instance p

[PATCH] D25916: Modules: emit an error instead of a random crash (or a misleading error) due to use-after-free.

2016-11-14 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. > Does it mean that a system module should only import system modules? If a > system module is allowed to import non-system modules, for a non-system > module, we will validate diagnostic options differently depending on whether > a system module or a non-system mod

[PATCH] D25916: Modules: emit an error instead of a random crash (or a misleading error) due to use-after-free.

2016-11-15 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. I'm inclined to suggest we break that behaviour with modules and treat a user module the same no matter where it was imported. @rsmith, what do you think? https://reviews.llvm.org/D25916 ___ cfe-commits mailing list c

[PATCH] D25948: [VFS] Replace TimeValue usage with std::chrono

2016-11-08 Thread Ben Langmuir via cfe-commits
benlangmuir accepted this revision. benlangmuir added a comment. This revision is now accepted and ready to land. LGTM, sorry for the delay. https://reviews.llvm.org/D25948 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.or

Re: [PATCH] D11403: [Modules] Add Darwin-specific compatibility module map parsing hacks

2015-08-12 Thread Ben Langmuir via cfe-commits
benlangmuir updated this revision to Diff 31947. benlangmuir added a comment. Changes per review. I still need to check performance of code-completing import statements to make sure the extra directory iteration isn't a big regression. Repository: rL LLVM http://reviews.llvm.org/D11403 Fi

r244912 - [Modules] Add Darwin-specific compatibility module map parsing hacks

2015-08-13 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Thu Aug 13 12:13:33 2015 New Revision: 244912 URL: http://llvm.org/viewvc/llvm-project?rev=244912&view=rev Log: [Modules] Add Darwin-specific compatibility module map parsing hacks This preserves backwards compatibility for two hacks in the Darwin system module map files

Re: [PATCH] D11403: [Modules] Add Darwin-specific compatibility module map parsing hacks

2015-08-13 Thread Ben Langmuir via cfe-commits
benlangmuir closed this revision. benlangmuir added a comment. Any regression to code completion was below the noise level in my testing. r244912 Comment at: include/clang/Basic/Module.h:363 @@ +362,3 @@ + /// This is more efficient than getFullModuleName(). + bool fullModule

r244917 - Attempt to fix build after r244912

2015-08-13 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Thu Aug 13 12:30:07 2015 New Revision: 244917 URL: http://llvm.org/viewvc/llvm-project?rev=244917&view=rev Log: Attempt to fix build after r244912 Some compilers were less happy about converting a lambda to a comparator function for array_pod_sort. Modified: cfe/tru

Re: r244912 - [Modules] Add Darwin-specific compatibility module map parsing hacks

2015-08-13 Thread Ben Langmuir via cfe-commits
Yep, that should be it! > On Aug 13, 2015, at 4:45 PM, Sean Silva wrote: > > This was the last thing blocking http://reviews.llvm.org/D10423 > <http://reviews.llvm.org/D10423> on your side, right? > > -- Sean Silva > > On Thu, Aug 13, 2015 at 10:13 AM

r250963 - Fix use-after-free in ModuleManager

2015-10-21 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Wed Oct 21 18:12:45 2015 New Revision: 250963 URL: http://llvm.org/viewvc/llvm-project?rev=250963&view=rev Log: Fix use-after-free in ModuleManager When removing out-of-date modules we might have left behind a VisitOrder that contains pointers to freed ModuleFiles. This

r251565 - Fix missing builtin identifier infos with PCH+modules

2015-10-28 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Wed Oct 28 17:25:37 2015 New Revision: 251565 URL: http://llvm.org/viewvc/llvm-project?rev=251565&view=rev Log: Fix missing builtin identifier infos with PCH+modules Use the *current* state of "is-moduleness" rather than the state at serialization time so that if we read

[PATCH] D11824: Make target feature 'arm' cover both 32 and 64 bit architecutres

2015-08-06 Thread Ben Langmuir via cfe-commits
benlangmuir created this revision. benlangmuir added a reviewer: rsmith. benlangmuir added a subscriber: cfe-commits. benlangmuir set the repository for this revision to rL LLVM. Herald added subscribers: rengolin, aemerson. ... and add aarch32 to specifically refer to the 32-bit ones.

Re: [PATCH] D11824: Make target feature 'arm' cover both 32 and 64 bit architecutres

2015-08-06 Thread Ben Langmuir via cfe-commits
benlangmuir added inline comments. Comment at: lib/Basic/Targets.cpp:4552 @@ -4551,2 +4551,3 @@ .Case("arm", true) +.Case("aarch32", true) .Case("softfloat", SoftFloat) rsmith wrote: > Should we also recognize "arm32" to better mirror the

r244306 - Make 'arm' cover both 32 and 64 bit architecutres

2015-08-06 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Thu Aug 6 20:59:56 2015 New Revision: 244306 URL: http://llvm.org/viewvc/llvm-project?rev=244306&view=rev Log: Make 'arm' cover both 32 and 64 bit architecutres ... and add aarch32 to specifically refer to the 32-bit ones. Previously, 'arm' meant only 32-bit architectu

Re: [PATCH] D11824: Make target feature 'arm' cover both 32 and 64 bit architecutres

2015-08-06 Thread Ben Langmuir via cfe-commits
benlangmuir closed this revision. benlangmuir added a comment. r244306 Repository: rL LLVM http://reviews.llvm.org/D11824 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: r202329 - Add a 'use-external-names' option to VFS overlay files

2016-07-20 Thread Ben Langmuir via cfe-commits
> On Jul 18, 2016, at 3:21 PM, Richard Smith wrote: > > On Wed, Feb 26, 2014 at 4:25 PM, Ben Langmuir > wrote: > Author: benlangmuir > Date: Wed Feb 26 18:25:12 2014 > New Revision: 202329 > > URL: http://llvm.org/viewvc/llvm-project?rev=202329&view=rev >

Re: [PATCH] D22636: Module: retry building modules that were just compiled by the same instance and are are out of date

2016-07-21 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. > B.pcm becomes out of date when we try to load module "A", because another > instance overwrites "B.pcm" How can this happen? We intentionally keep the file descriptors of modules open. If you just built A, then you will have B.pcm still open. When you read A,

Re: [PATCH] D22636: Module: retry building modules that were just compiled by the same instance and are are out of date

2016-07-22 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. > Can you point me to the source codes where we use rename to replace the file? > I am curious on how this all works out. This is the same as clang's handling of other output files. See {{CompilerInstance::createOutputFile}} and {{clearOutputFiles}}. When we are

Re: [PATCH] D22773: Modules: add command line option fmodules-disable-diagnostic-validation to disable validation of the diagnostic options when loading the module

2016-07-25 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. We need to add this option to the module hash (see getModuleHash - we already add a bunch of other HSOpts there). Otherwise the pcm could still be rewritten by a compilation that doesn't use a PCH, and then it would be out of date because of the timestamp instead o

Re: [PATCH] D22773: Modules: add command line option fmodules-disable-diagnostic-validation to disable validation of the diagnostic options when loading the module

2016-07-25 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. > the pcm could still be rewritten by a compilation that doesn't use a PCH, and > then it would be out of date because of the timestamp instead of the > diagnostic options > > "a compilation that doesn't use a PCH", is that a different project? And we > have two

Re: [PATCH] D22773: Modules: add command line option fmodules-disable-diagnostic-validation to disable validation of the diagnostic options when loading the module

2016-07-26 Thread Ben Langmuir via cfe-commits
benlangmuir accepted this revision. benlangmuir added a comment. This revision is now accepted and ready to land. LGTM https://reviews.llvm.org/D22773 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/list

Re: [PATCH] D23125: Modules: add command line option to support loading prebuilt modules on demand, without parsing any module map

2016-08-03 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. How about -fmodules-use-prebuilt-**module-cache** for the flag name? Saying "prebuilt-modules" is confusing to me, since -fmodule-file can also be used to load a prebuilt module, but doesn't use a cache. Comment at: lib/Driver/Tools.cpp:5416 @@ -5

Re: [PATCH] D23125: Modules: add command line option to support loading prebuilt modules on demand, without parsing any module map

2016-08-09 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. Sorry for the delay, I apparently forgot to hit submit. Replied inline. Comment at: lib/Frontend/CompilerInstance.cpp:1491 @@ +1490,3 @@ +false/*IsExplicit*/).first; +Module->IsSystem = true; +Module->IsFromModuleFile = tr

Re: [PATCH] D23125: Modules: add command line option to support loading prebuilt modules on demand, without parsing any module map

2016-08-09 Thread Ben Langmuir via cfe-commits
benlangmuir accepted this revision. benlangmuir added a comment. This revision is now accepted and ready to land. Still missing the change for `if (IsPrebuilt) {`, but otherwise LGTM. https://reviews.llvm.org/D23125 ___ cfe-commits mailing list cfe-

Re: [PATCH] D23422: [VFS] Add 'ignore-non-existent-contents' field to YAML

2016-08-11 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. This should have a test for the writer change. Otherwise LGTM. https://reviews.llvm.org/D23422 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r259624 - Make CF constant string decl visible to name lookup to fix module errors

2016-02-02 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Tue Feb 2 21:26:19 2016 New Revision: 259624 URL: http://llvm.org/viewvc/llvm-project?rev=259624&view=rev Log: Make CF constant string decl visible to name lookup to fix module errors The return type of the __builtin___*StringMakeConstantString functions is a pointer to

Re: r259624 - Make CF constant string decl visible to name lookup to fix module errors

2016-02-03 Thread Ben Langmuir via cfe-commits
> On Feb 3, 2016, at 11:45 AM, Douglas Gregor wrote: > >> >> On Feb 2, 2016, at 7:26 PM, Ben Langmuir via cfe-commits >> wrote: >> >> Author: benlangmuir >> Date: Tue Feb 2 21:26:19 2016 >> New Revision: 259624 >> >> URL: ht

r259734 - Fix predefine for __NSConstantString struct type

2016-02-03 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Wed Feb 3 18:55:24 2016 New Revision: 259734 URL: http://llvm.org/viewvc/llvm-project?rev=259734&view=rev Log: Fix predefine for __NSConstantString struct type Per review feedback the name was wrong and it can be used outside Objective-C. Unfortunately, making the inte

Re: r259624 - Make CF constant string decl visible to name lookup to fix module errors

2016-02-03 Thread Ben Langmuir via cfe-commits
Hey Doug, I fixed this in r259734; could you take a glance at that patch too? As I mentioned in person it required more changes than just moving this definition outside the if/fixing the name. Thanks, Ben > On Feb 3, 2016, at 11:50 AM, Ben Langmuir via cfe-commits > wrote: > >

r259859 - Don't synthesize an ImportDecl for a module named in -fmodule-implementation-of

2016-02-04 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Thu Feb 4 19:10:05 2016 New Revision: 259859 URL: http://llvm.org/viewvc/llvm-project?rev=259859&view=rev Log: Don't synthesize an ImportDecl for a module named in -fmodule-implementation-of When building a PCH with modules enabled this import would assert in the ASTWri

Re: [PATCH] D17104: [VFS] Drop path traversal assertion

2016-02-10 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. Please clarify what you mean here: > The rationale is that if source and destination paths in the YAML file > contain ".." this is enough > for the file manager to retrieve the right file, meaning that it doesn't > matter how we write it > since the FileManager

Re: [PATCH] D17104: [VFS] Drop path traversal assertion

2016-02-10 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. I don't think this is the right approach. If we don't canonicalize the source path then: - looking up the path *without* the .. won't work, which means anything that looks up a realpath will fail - directory iteration won't combine entries from foo/bar/.. and foo/

r260543 - [Modules] Don't infinite recurse on implicit import of circular modules in preamble

2016-02-11 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Thu Feb 11 11:04:42 2016 New Revision: 260543 URL: http://llvm.org/viewvc/llvm-project?rev=260543&view=rev Log: [Modules] Don't infinite recurse on implicit import of circular modules in preamble Update the Preprocessor's VisibleModuleSet when typo-correction creates a

Re: r260543 - [Modules] Don't infinite recurse on implicit import of circular modules in preamble

2016-02-11 Thread Ben Langmuir via cfe-commits
016, at 9:04 AM, Ben Langmuir via cfe-commits > wrote: > > Author: benlangmuir > Date: Thu Feb 11 11:04:42 2016 > New Revision: 260543 > > URL: http://llvm.org/viewvc/llvm-project?rev=260543&view=rev > Log: > [Modules] Don't infinite recurse on implicit im

r260563 - [Modules] Early-exit if ReadOptionsBlock fails to avoid crashing

2016-02-11 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Thu Feb 11 12:54:02 2016 New Revision: 260563 URL: http://llvm.org/viewvc/llvm-project?rev=260563&view=rev Log: [Modules] Early-exit if ReadOptionsBlock fails to avoid crashing If we didn't tell ReadOptionsBlock to allow failures then we can't assume that the stream is n

Re: r252114 - [modules] If we're given a module file, via -fmodule-file=, for a module, but

2016-02-11 Thread Ben Langmuir via cfe-commits
FYI I changed this to early-exit again in r260563 to fix implicit builds. It’s not safe to keep reading if we haven’t told ReadOptionsBlock to expect failures, since it will itself early-exit, leaving the stream in the middle of a block. It’s also a performance advantage to early exit when doi

Re: [PATCH] D17104: [VFS] Drop path traversal assertion

2016-02-11 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. > Now, we try to use the new YAML file + cache from a new clang invocation. > When the FileManager requests status in (2) for the path > "/install-dir/bin/../lib/clang/3.8.0/include/altivec.h" neither > "remove_dots()" nor "realpath()" would be able to resolve it to

Re: [PATCH] D17104: [VFS] Drop path traversal assertion

2016-02-12 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. > Given the two-path solution, another thing we could do in the first path, is > to default to the remove_dots() version for the source, i.e. > "/install-dir/lib/clang/3.8.0/include" instead of > "/install-dir/bin/../lib/clang/3.8.0/include". The path after remove_d

Re: [PATCH] D17104: [VFS] Drop path traversal assertion

2016-02-15 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. Okay, let's go with the two-path solution. Thanks! http://reviews.llvm.org/D17104 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D17104: [VFS] Drop path traversal assertion

2016-02-19 Thread Ben Langmuir via cfe-commits
benlangmuir accepted this revision. benlangmuir added a comment. This revision is now accepted and ready to land. LGTM if you fix 256->PATH_MAX. Comment at: lib/Frontend/ModuleDependencyCollector.cpp:66 @@ +65,3 @@ +#ifdef HAVE_REALPATH + char CanonicalPath[256]; +

Re: [PATCH] D17457: [VFS] Add 'overlay-relative' field to YAML files

2016-02-19 Thread Ben Langmuir via cfe-commits
benlangmuir accepted this revision. benlangmuir added a comment. This revision is now accepted and ready to land. LGTM! http://reviews.llvm.org/D17457 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/list

r261887 - Add FieldNames to __NSConstantString_tag

2016-02-25 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Thu Feb 25 10:36:26 2016 New Revision: 261887 URL: http://llvm.org/viewvc/llvm-project?rev=261887&view=rev Log: Add FieldNames to __NSConstantString_tag Since consumers of the AST may expect fields to be named. Patch by Brad King! Modified: cfe/trunk/lib/AST/ASTCon

Re: [PATCH] D17820: Clang Code Completion Filtering

2016-04-26 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. Overall approach seems good to me, but this needs tests. Other feedback inline. Comment at: include/clang/Sema/CodeCompleteConsumer.h:920 @@ +919,3 @@ +CodeCompletionResult Results) { +return true; + } --

r268471 - Fix CodeCompletion & TypoCorrection when combining a PCH with Modules

2016-05-03 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Tue May 3 19:53:13 2016 New Revision: 268471 URL: http://llvm.org/viewvc/llvm-project?rev=268471&view=rev Log: Fix CodeCompletion & TypoCorrection when combining a PCH with Modules This commit fixes the IdentifierIterator to actually include identifiers from a PCH or pr

Re: [PATCH] D17820: Clang Code Completion Filtering

2016-05-05 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. LGTM with one comment about the doxygen comments, but you should probably wait to hear from @akyrtzi too. Comment at: include/clang/Sema/CodeCompleteConsumer.h:916 @@ +915,3 @@ + /// \name Code-completion filtering + //@{ + /// \brief Check if th

Re: [PATCH] D20194: [ModuleMap][CrashReproducer] Collect headers from inner frameworks

2016-05-13 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. Let's move the code looks up the alternate name out of the ModuleMap parser, and into the dependency collector callbacks. This feels like an implementation detail of the dependency collector. We could add a new callback specifically for umbrella headers and handle

Re: [PATCH] D20194: [ModuleMap][CrashReproducer] Collect headers from inner frameworks

2016-05-13 Thread Ben Langmuir via cfe-commits
benlangmuir accepted this revision. benlangmuir added a comment. This revision is now accepted and ready to land. LGTM http://reviews.llvm.org/D20194 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listi

Re: [PATCH] D20266: [Modules] Use vfs for (recursive) directory iteration

2016-05-16 Thread Ben Langmuir via cfe-commits
benlangmuir accepted this revision. benlangmuir added a comment. This revision is now accepted and ready to land. LGTM http://reviews.llvm.org/D20266 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listi

Re: [PATCH] D18585: [CrashReproducer] Add a module map callback for added headers

2016-03-30 Thread Ben Langmuir via cfe-commits
benlangmuir accepted this revision. benlangmuir added a comment. This revision is now accepted and ready to land. LGTM http://reviews.llvm.org/D18585 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listi

Re: r259734 - Fix predefine for __NSConstantString struct type

2016-04-03 Thread Ben Langmuir via cfe-commits
lock just before this. > > 2016-04-03 14:21 GMT+03:00 Vassil Vassilev via cfe-commits > mailto:cfe-commits@lists.llvm.org>>: > On 04/02/16 01:55, Ben Langmuir via cfe-commits wrote: > Author: benlangmuir > Date: Wed Feb 3 18:55:24 2016 > New Revision: 259734 > > UR

Re: r259734 - Fix predefine for __NSConstantString struct type

2016-04-11 Thread Ben Langmuir via cfe-commits
this. >> >> 2016-04-03 14:21 GMT+03:00 Vassil Vassilev via cfe-commits >> mailto:cfe-commits@lists.llvm.org>>: >> On 04/02/16 01:55, Ben Langmuir via cfe-commits wrote: >> Author: benlangmuir >> Date: Wed Feb 3 18:55:24 2016 >> New Revision: 259734

Re: r259734 - Fix predefine for __NSConstantString struct type

2016-04-11 Thread Ben Langmuir via cfe-commits
en >> <mailto:yaron.ke...@gmail.com>> wrote: >>> >>> +1, if possible. There is a if (getLangOpts().ObjC1) block just before this. >>> >>> 2016-04-03 14:21 GMT+03:00 Vassil Vassilev via cfe-commits >>> mailto:cfe-commits@lists.llvm.org>

Re: [PATCH] D18849: [modules] Avoid module relocation error when building modules from VFS

2016-04-11 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. This doesn't appear to be a safe change. We can't assume that `RootName` wouldn't ever be legitimately found somewhere in a path (even without a VFS) and changing the path prefix could give a completely different location. I would also be concerned about the perfo

Re: [PATCH] D18849: [modules] Avoid module relocation error when building modules from VFS

2016-04-12 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. > From what I understand from > http://lists.llvm.org/pipermail/cfe-dev/2014-July/038273.html, changing the > behavior of the cached result has side-effects and demands a non trivial > change, am I assuming the right thing? Yes. Threading through the Filename see

Re: [PATCH] D18849: [modules] Avoid module relocation error when building modules from VFS

2016-04-12 Thread Ben Langmuir via cfe-commits
benlangmuir added inline comments. Comment at: lib/Basic/FileManager.cpp:221-223 @@ -220,2 +220,5 @@ // See if there is already an entry in the map. + // FIXME: Note that when first requested, the returned file name equals to the + // requested path. This is not true when re

Re: [PATCH] D20383: PCH + Module: make sure we write out macros associated with builtin identifiers

2016-05-23 Thread Ben Langmuir via cfe-commits
benlangmuir added a subscriber: doug.gregor. benlangmuir added a comment. I'd like to see Doug and/or Richard review this. It seems reasonable to me to first blush, but I assume there was a good reason we weren't doing this already... http://reviews.llvm.org/D20383

Re: [PATCH] D20942: [LockFileManager] Improve error output by adding error messages

2016-06-02 Thread Ben Langmuir via cfe-commits
benlangmuir accepted this revision. benlangmuir added a comment. This revision is now accepted and ready to land. LGTM. Some minor suggestions. Comment at: include/llvm/Support/LockFileManager.h:87 @@ +86,3 @@ + + /// \brief Get error message + std::string getErrorMessage() c

Re: [PATCH] D21111: Avoid accessing an invalid PresumedLoc

2016-06-27 Thread Ben Langmuir via cfe-commits
benlangmuir added a subscriber: benlangmuir. benlangmuir added a comment. LGTM Repository: rL LLVM http://reviews.llvm.org/D2 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r275454 - [index] Index system ImportDecls even when there is a DeclarationsOnly filter

2016-07-14 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Thu Jul 14 13:51:55 2016 New Revision: 275454 URL: http://llvm.org/viewvc/llvm-project?rev=275454&view=rev Log: [index] Index system ImportDecls even when there is a DeclarationsOnly filter Whether we call an ImportDecl a decl or a reference symbol role is somewhat acade

r275464 - Attempt to workaround Windows bots after my previous commit

2016-07-14 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Thu Jul 14 15:08:43 2016 New Revision: 275464 URL: http://llvm.org/viewvc/llvm-project?rev=275464&view=rev Log: Attempt to workaround Windows bots after my previous commit For some reason it seems the second invocation is getting DMOD_OTHER_H set to a path with/forward/s

r275496 - Remove the new module cache from the index-module test

2016-07-14 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Thu Jul 14 17:53:23 2016 New Revision: 275496 URL: http://llvm.org/viewvc/llvm-project?rev=275496&view=rev Log: Remove the new module cache from the index-module test Forgot to add the new cache to the `rm -rf` line. This broke some bots when trying to load a module buil

Re: r275464 - Attempt to workaround Windows bots after my previous commit

2016-07-14 Thread Ben Langmuir via cfe-commits
builds/14659/steps/check-clang%20msan/logs/stdio > > <http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/14659/steps/check-clang%20msan/logs/stdio> > On Thu, Jul 14, 2016 at 1:16 PM Ben Langmuir via cfe-commits > mailto:cfe-commits@lists.llvm.org>> wrote: >

Re: r275600 - [objcmt] Fix a buffer overflow crash than can occur while modernizing enums.

2016-07-15 Thread Ben Langmuir via cfe-commits
> On Jul 15, 2016, at 12:22 PM, Argyrios Kyrtzidis via cfe-commits > wrote: > > Author: akirtzidis > Date: Fri Jul 15 14:22:34 2016 > New Revision: 275600 > > URL: http://llvm.org/viewvc/llvm-project?rev=275600&view=rev > Log: > [objcmt] Fix a buffer overflow crash than can occur while moderni

Re: [PATCH] D17299: [ASTReader] Report error when accessing corrupt record data

2016-03-02 Thread Ben Langmuir via cfe-commits
benlangmuir added a comment. This LGTM, but I would like Richard to take a look too. http://reviews.llvm.org/D17299 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: r262984 - [index] Fix assertion hit when indexing re-declarations of built-in functions.

2016-03-08 Thread Ben Langmuir via cfe-commits
> On Mar 8, 2016, at 6:12 PM, Argyrios Kyrtzidis via cfe-commits > wrote: > > Author: akirtzidis > Date: Tue Mar 8 20:12:40 2016 > New Revision: 262984 > > URL: http://llvm.org/viewvc/llvm-project?rev=262984&view=rev > Log: > [index] Fix assertion hit when indexing re-declarations of built-in

Re: r262984 - [index] Fix assertion hit when indexing re-declarations of built-in functions.

2016-03-08 Thread Ben Langmuir via cfe-commits
Thanks! > On Mar 8, 2016, at 7:00 PM, Argyrios Kyrtzidis wrote: > >> >> On Mar 8, 2016, at 6:28 PM, Ben Langmuir > > wrote: >> >>> >>> On Mar 8, 2016, at 6:12 PM, Argyrios Kyrtzidis via cfe-commits >>> mailto:cfe-commits@lists.llvm.org>> wrote: >>> >>> Author: ak

r263076 - [Modules] Add stdatomic to the list of builtin headers

2016-03-09 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Wed Mar 9 17:31:34 2016 New Revision: 263076 URL: http://llvm.org/viewvc/llvm-project?rev=263076&view=rev Log: [Modules] Add stdatomic to the list of builtin headers Since it's provided by the compiler. This allows a system module map file to declare a module for it. N

r264423 - [index] Remove redundancy between symbol kind and language

2016-03-25 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Fri Mar 25 12:01:59 2016 New Revision: 264423 URL: http://llvm.org/viewvc/llvm-project?rev=264423&view=rev Log: [index] Remove redundancy between symbol kind and language Condense the ObjCKIND and CXXKIND options into just KIND, since the language was already specified o

Re: [PATCH] Allow "redefinition" of typedef of anon tag from unimported submodule

2015-11-13 Thread Ben Langmuir via cfe-commits
This time sending to the right list address. > On Nov 13, 2015, at 4:00 PM, Ben Langmuir wrote: > > Hey Richard, > > After your commit r233345 we started diagnosing “redefinition” errors for > typedefs of anonymous tags that are *not visible* in case like this: > > module that isn’t imported:

Re: [PATCH] Allow "redefinition" of typedef of anon tag from unimported submodule

2015-11-13 Thread Ben Langmuir via cfe-commits
> On Nov 13, 2015, at 4:20 PM, Richard Smith wrote: > > On Fri, Nov 13, 2015 at 4:03 PM, Ben Langmuir via cfe-commits > mailto:cfe-commits@lists.llvm.org>> wrote: > This time sending to the right list address. > > Likewise =) > > > On Nov 13, 2015, at 4:0

r253123 - [modules] Allow "redefinition" of typedef of anon tag from unimported submodule

2015-11-13 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Fri Nov 13 21:26:14 2015 New Revision: 253123 URL: http://llvm.org/viewvc/llvm-project?rev=253123&view=rev Log: [modules] Allow "redefinition" of typedef of anon tag from unimported submodule r233345 started being stricter about typedef names for linkage purposes in non-

Re: [PATCH] Allow "redefinition" of typedef of anon tag from unimported submodule

2015-11-13 Thread Ben Langmuir via cfe-commits
> On Nov 13, 2015, at 5:32 PM, Ben Langmuir via cfe-commits > wrote: > > >> On Nov 13, 2015, at 4:20 PM, Richard Smith > <mailto:rich...@metafoo.co.uk>> wrote: >> >> On Fri, Nov 13, 2015 at 4:03 PM, Ben Langmuir via cfe-commits >> mailto:

[PATCH] Allow modules specified by -fmodule-map-file to shadow implicitly found ones

2015-11-18 Thread Ben Langmuir via cfe-commits
Hi Richard, This is an updated patch for allowing -fmodule-map-file to shadow implicitly found modules. I’ve tried to simplify things by just using the explicitness of the module rather than the original more-general approach. I’ll make a separate patch for -fmodule-file, which is turning out

Re: r252960 - [modules] Simplify and generalize the existing rule for finding hidden

2015-12-09 Thread Ben Langmuir via cfe-commits
Hey Richard, This caused a new error for the following code: @import Foo.X; // declaration of ‘struct foo’ from Foo.Y is not visible yet, but the pcm is loaded. struct foo *bar; // declares ‘struct foo’ @import Foo.Y; // also declares ‘struct foo’ void useFoo(struct foo *x); //

Re: r252960 - [modules] Simplify and generalize the existing rule for finding hidden

2015-12-09 Thread Ben Langmuir via cfe-commits
> On Dec 9, 2015, at 11:07 AM, Ben Langmuir wrote: > > Hey Richard, > > This caused a new error for the following code: > >@import Foo.X; // declaration of ‘struct foo’ from Foo.Y is not visible > yet, but the pcm is loaded. >struct foo *bar; // declares ‘struct foo’ >@import Foo.

Re: r252960 - [modules] Simplify and generalize the existing rule for finding hidden

2015-12-09 Thread Ben Langmuir via cfe-commits
> On Dec 9, 2015, at 1:36 PM, Richard Smith wrote: > > On Wed, Dec 9, 2015 at 11:55 AM, Ben Langmuir via cfe-commits > mailto:cfe-commits@lists.llvm.org>> wrote: > > On Dec 9, 2015, at 11:07 AM, Ben Langmuir > <mailto:blangm...@apple.com>> wrote: > >

r255267 - [Modules] Fix regression when an elaborated-type-specifier mentions a hidden tag

2015-12-10 Thread Ben Langmuir via cfe-commits
Author: benlangmuir Date: Thu Dec 10 11:28:51 2015 New Revision: 255267 URL: http://llvm.org/viewvc/llvm-project?rev=255267&view=rev Log: [Modules] Fix regression when an elaborated-type-specifier mentions a hidden tag This makes non-C++ languages find the same decl as C++ does to workaround a re

Re: r252960 - [modules] Simplify and generalize the existing rule for finding hidden

2015-12-10 Thread Ben Langmuir via cfe-commits
> On Dec 9, 2015, at 2:49 PM, Richard Smith wrote: > > On Wed, Dec 9, 2015 at 2:00 PM, Ben Langmuir <mailto:blangm...@apple.com>> wrote: > >> On Dec 9, 2015, at 1:36 PM, Richard Smith > <mailto:rich...@metafoo.co.uk>> wrote: >> >> On Wed, De

<    1   2   3   4   5   >