[PATCH] D29001: [Modules] Fallback to building the module if a timeout occurs

2017-01-22 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno created this revision. Herald added a subscriber: fhahn. After https://reviews.llvm.org/D28299 gets in, clang will use PCMCache to manage memory buffers for pcm files. This means the lock file manager isn't needed for correctness anymore, but only as an optimization: clang waits for

[PATCH] D27257: [CodeCompletion] Ensure that ObjC root class completes instance methods from protocols and categories as well

2017-01-23 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. Ok. Thanks Alex, LGTM Repository: rL LLVM https://reviews.llvm.org/D27257 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D27257: [CodeCompletion] Ensure that ObjC root class completes instance methods from protocols and categories as well

2017-01-20 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. How does this interact (if at all) with classes annotated with `__attribute__((objc_root_class))`? Comment at: lib/Sema/SemaCodeComplete.cpp:5259 SelIdents, CurContext, Selectors, AllowSameLength, Results,

[PATCH] D28299: Module: use PCMCache to manage memory buffers for pcm files.

2017-01-24 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: lib/Serialization/ASTReader.cpp:3692 +ValidationConflicts); +for (auto N : ValidationConflicts) + Diag(diag::err_module_ancestor_conflict) << N; This should honor `ARR_OutOfDate`, so

[PATCH] D29753: [PCH] Avoid early VarDecl emission attempt if no owning module avaiable

2017-02-09 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno created this revision. This fixes PR31863, a regression introduced in r276159. Consider this snippet: struct FVector; struct FVector {}; struct FBox { FVector Min; FBox(int); }; namespace { FBox InvalidBoundingBox(0); } While parsing the DECL_VAR for 'struct FBox', clang

[PATCH] D28832: Improve redefinition errors pointing to the same header.

2017-01-17 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno created this revision. Diagnostics related to redefinition errors that point to the same header file do not provide much information that helps fixing the issue. In modules context it usually happens because of a non modular include, in non-module context it might happen because of the

[PATCH] D25213: Fix PR28181: Prevent operator overloading related assertion failure crash that happens in C only

2017-01-18 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. LGTM! Comment at: lib/Sema/SemaExpr.cpp:11523 // being assigned to. if (Opc == BO_Assign && pty->getKind() == BuiltinType::Overload) { + if

[PATCH] D28832: Improve redefinition errors pointing to the same header.

2017-01-20 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Thanks Vassil. @rsmith is this ok for you? https://reviews.llvm.org/D28832 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D26955: Fix bitwidth for x87 extended-precision floating-point type

2016-11-28 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: lib/Basic/TargetInfo.cpp:229 switch (BitWidth) { - case 96: + case 80: if (() == ::APFloat::x87DoubleExtended) The change makes sense but I believe there's some historical reason why this is 96 instead of 80?

[PATCH] D26916: [ObjC] Avoid a @try/@finally/@autoreleasepool fixit when parsing an expression

2016-11-28 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hi Alex, thanks for working on this Comment at: lib/Parse/ParseObjc.cpp:2877 +if (GetLookAheadToken(1).is(tok::l_brace) && +ExprStatementTokLoc == AtLoc) { char ch = Tok.getIdentifierInfo()->getNameStart()[0];

[PATCH] D25866: [Sema] Support implicit scalar to vector conversions

2016-11-28 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: lib/Sema/SemaExpr.cpp:8064 + ScalarCast = CK_FloatingCast; +} else if (ScalarTy->isIntegralType(S.Context)) { + // Determine if the integer constant can be expressed as a floating point sdardis wrote: >

[PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2016-11-28 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. @rsmith ping! https://reviews.llvm.org/D26267 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D27546: [ASTReader] Sort RawComments before merging

2016-12-07 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno created this revision. bruno added reviewers: manmanren, akyrtzi, rsmith. bruno added a subscriber: cfe-commits. `RawComments` are sorted by comparing underlying `SourceLocation`'s. This is done by comparing `FileID` and `Offset`; when the `FileID` is the same it means the locations are

[PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2016-12-08 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Any thoughts on this @rsmith ? https://reviews.llvm.org/D26267 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D27604: [Driver] Add compiler option to generate a reproducer

2016-12-09 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno updated this revision to Diff 80981. bruno added a comment. Update after Mehdi's review! https://reviews.llvm.org/D27604 Files: docs/UsersManual.rst include/clang/Basic/DiagnosticDriverKinds.td include/clang/Driver/Driver.h include/clang/Driver/Options.td lib/Driver/Driver.cpp

[PATCH] D27604: [Driver] Add compiler option to generate a reproducer

2016-12-09 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > I am wondering if there is clearer name than `-gen-reproducer`. Probably, I'm open to suggestions :-) > IIUC, the goal is to extract all environment (system) dependent pieces, > copying them to a folder where the compiler can be chroot-ed (via > `-isysroot`). It

[PATCH] D27604: [Driver] Add compiler option to generate a reproducer

2016-12-09 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno created this revision. bruno added reviewers: rsmith, v.g.vassilev. bruno added subscribers: cfe-commits, mehdi_amini. One way to currently test the reproducers is to setup "FORCE_CLANG_DIAGNOSTICS_CRASH=1" before invoking clang. This simulates a crash and produces the same contents needed

[PATCH] D27796: Fix printf specifier handling: invalid specifier should not be marked as "consuming data arguments"

2016-12-15 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. LGTM https://reviews.llvm.org/D27796 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D27546: [ASTReader] Sort RawComments before merging

2016-12-12 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Ping! https://reviews.llvm.org/D27546 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D16533: Bug 20796 - GCC's -Wstrict-prototypes warning not implemented in Clang

2016-12-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. LGTM Repository: rL LLVM https://reviews.llvm.org/D16533 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2016-12-14 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno updated this revision to Diff 81478. bruno added a comment. Here is the Decl dump in the end of `ReadDeclRecord` for each Decl before it fails: - ParmVarDecl 0x7ffe23053b20 col:12 in libc.math hidden 'int' -- FunctionDecl 0x7ffe23053a48 col:5 in libc.math hidden abs 'int (int)'

[PATCH] D24933: Enable configuration files in clang

2016-12-12 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: include/clang/Driver/Driver.h:287 + const std::string () const { return ConfigFile; } + void setConfigFile(StringRef x, unsigned N) { +ConfigFile = x; x -> FileName Comment at:

[PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2017-01-09 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. @rsmith ping! https://reviews.llvm.org/D26267 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2017-01-10 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno closed this revision. bruno added a comment. Thanks for the review Richard. Committed 291644 Comment at: lib/Lex/HeaderSearch.cpp:1082 + auto TryEnterImported = [&](void) -> bool { +if (!ModulesEnabled) rsmith wrote: > Maybe add a FIXME here

[PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2016-11-30 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: lib/Frontend/FrontendActions.cpp:227 +IsBuiltin = true; + addHeaderInclude(H.NameAsWritten, Includes, LangOpts, Module->IsExternC, + IsBuiltin /*AlwaysInclude*/); rsmith wrote: > I don't

[PATCH] D27298: [Frontend] Fix an issue where a quoted search path is incorrectly removed as a duplicate header search path

2016-12-01 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. LGTM! Repository: rL LLVM https://reviews.llvm.org/D27298 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D26916: [ObjC] Avoid a @try/@finally/@autoreleasepool fixit when parsing an expression

2016-11-29 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. Thanks for the explanation, LGTM Repository: rL LLVM https://reviews.llvm.org/D26916 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D27429: [Chrono][Darwin] On Darwin use CLOCK_UPTIME_RAW instead of CLOCK_MONOTONIC

2016-12-05 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno created this revision. bruno added reviewers: mclow.lists, dexonsmith, EricWF. bruno added a subscriber: cfe-commits. CLOCK_MONOTONIC is only defined on Darwin on libc versions >= 1133 and its behaviour differs from Linux. CLOCK_UPTIME on Darwin actually matches CLOCK_MONOTONIC on Linux,

[PATCH] D16533: Bug 20796 - GCC's -Wstrict-prototypes warning not implemented in Clang

2016-12-02 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hi Alex, thanks for following up with this! Comment at: lib/Sema/SemaDecl.cpp:11819 + // Warn if K function is defined without previous declaration + // declaration. This warning is issued only if the difinition itself + // does not

[PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2016-12-02 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > The right thing to do would be to track the set of headers whose #import / > #include-with-#pragma-once is > visible, and only skip inclusions if there is a *visible* #import / > #include-with-#pragma-once of that header. This makes sense, but the situation is a bit

[PATCH] D27429: [Chrono][Darwin] On Darwin use CLOCK_UPTIME_RAW instead of CLOCK_MONOTONIC

2017-01-05 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. @EricWF ok to commit? https://reviews.llvm.org/D27429 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D27429: [Chrono][Darwin] On Darwin use CLOCK_UPTIME_RAW instead of CLOCK_MONOTONIC

2017-01-04 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno updated this revision to Diff 83158. bruno added a comment. Thanks for the reviews. @howard.hinnant thanks for the great explanation & examples. Attached a new version of the patch, addressing all suggestions. The logic became a bit simpler after Saleem's r290804, which already moved the

[PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2017-01-03 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Ping! https://reviews.llvm.org/D26267 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D27852: [modules] Handle modules with nonstandard names in module.private.modulemaps

2016-12-20 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hi, Thanks for working on this. Comment at: include/clang/Basic/DiagnosticLexKinds.td:647 + "top-level module '%0' in private module map, expected a submodule of '%1'">, + InGroup>; It would be nice if we

[PATCH] D27852: [modules] Handle modules with nonstandard names in module.private.modulemaps

2016-12-20 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a reviewer: bruno. bruno added inline comments. Comment at: test/Modules/implicit-private-with-different-name.m:13 +// expected-warning@Inputs/implicit-private-with-different-name/A.framework/Modules/module.private.modulemap:1{{top-level module 'APrivate' in

[PATCH] D27604: [Driver] Add compiler option to generate a reproducer

2016-12-20 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Ping! https://reviews.llvm.org/D27604 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D27852: [modules] Handle modules with nonstandard names in module.private.modulemaps

2016-12-20 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. Right, I missed it, LGTM https://reviews.llvm.org/D27852 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2016-12-20 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno updated this revision to Diff 82067. bruno marked 3 inline comments as done. bruno added a comment. Uploaded new patch with another approach to fix the issue. https://reviews.llvm.org/D26267 Files: include/clang/Lex/HeaderSearch.h include/clang/Lex/ModuleMap.h

[PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2016-12-20 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno marked 3 inline comments as done. bruno added a comment. > Do we need to perfectly preserve the functionality of `#pragma once` / > `#import`? That is, would it be acceptable to > you if we spuriously enter files that have been imported in that way, while > building a module?

[PATCH] D27832: Add -plugin-opt=sample-profile for thinLTO build.

2016-12-19 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: lib/Driver/Tools.cpp:2211 + if (Arg *A = Args.getLastArg(options::OPT_fprofile_sample_use_EQ)) { +StringRef fname = A->getValue(); +if (!llvm::sys::fs::exists(fname)) "fname" -> "FName", "FileName", etc, or any

[PATCH] D30810: Preserve vec3 type.

2017-03-23 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > I would like to see this patch committed. I see clear evidence of it > improving existing GPU targets in the master repo as well as outside of the > main tree implementations. Bruno, do you have any more concerns? I believe the argument lacks numbers (or at least you

[PATCH] D31134: [Serialization] Serialize DependentSizedExtVectorType

2017-03-21 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. LGTM Alex, thanks! Repository: rL LLVM https://reviews.llvm.org/D31134 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D25866: [Sema] Support implicit scalar to vector conversions

2017-03-27 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: test/Sema/vector-gcc-compat.c:61 + //match. + v2i64_r = v2i64_a == 1; // expected-warning {{incompatible vector types assigning to 'v2i64' (vector of 2 'long long' values) from 'long __attribute__((ext_vector_type(2)))'

[PATCH] D29923: PPCallbacks::MacroUndefined, change signature and add test.

2017-03-27 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. LGTM! https://reviews.llvm.org/D29923 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

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

2017-03-27 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Ping! https://reviews.llvm.org/D31269 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2017-03-22 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno created this revision. When modules come from module map files explicitly specified by -fmodule-map-file= arguments, allow those to override/shadow modules with the same name that are found implicitly by header search. If such a module is looked up by name (e.g. @import), we will always

[PATCH] D31378: [PCH] Attach instance's dependency collectors to PCH external AST sources.

2017-03-29 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. Thanks for working on this! LGTM too https://reviews.llvm.org/D31378 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D31241: [Modules][PCH] Serialize #pragma pack

2017-03-29 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. Thanks Alex. LGTM Repository: rL LLVM https://reviews.llvm.org/D31241 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D30810: Preserve vec3 type.

2017-03-15 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > As you can see, the type legalizer handle vec3 load/store properly. It does > not write 4th element. The vec3 load/store generates more instructions but it > has correct behavior. I am not 100% sure the vec3 --> vec4 load/store is > correct or not because no one has

[PATCH] D30810: Preserve vec3 type.

2017-03-14 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > Thanks for your comment. We have a pass to undo the vec4 to vec3. I wondered > why clang generates the vec4 for vec3 load/store. As you can see the comment > on clang's code, they are generated for better performance. I had a questions > at this point. clang should

[PATCH] D25866: [Sema] Support implicit scalar to vector conversions

2017-04-10 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: lib/Sema/SemaExpr.cpp:10024 + // FIXME: The check for C++ here is for GCC compatibility. GCC rejects the + //usage of logical operators with vectors in C. This check could be + //notionally dropped.

[PATCH] D31667: [Sema] Extend GetSignedVectorType to deal with non ExtVector types

2017-04-04 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Great! Thanks for improving this. Comment at: include/clang/Sema/Sema.h:9287 bool AllowBothBool, bool AllowBoolConversion); - QualType GetSignedVectorType(QualType V); + QualType GetSignedVectorType(QualType V, bool

[PATCH] D25866: [Sema] Support implicit scalar to vector conversions

2017-04-04 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: lib/Sema/SemaExpr.cpp:8032 + + return InvalidOperands(Loc, LHS, RHS); +} Double checking here: are there tests for the `InvalidOperands` case above? Comment at: lib/Sema/SemaExpr.cpp:8163 +/// type

[PATCH] D31778: [Modules] Implement ODR-like semantics for tag types in C/ObjC

2017-04-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno created this revision. Allow ODR for ObjC/C in the sense that we won't keep more that one definition around (merge them). However, ensure the decl pass the structural compatibility check in C11 6.2.7/1, for that, reuse the structural equivalence checks used by the ASTImporter. Few other

[PATCH] D31781: [Modules] Allow local submodule visibility without c++

2017-04-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno created this revision. Removing this restriction will make it handy to explore local submodule visibility without c++ being turned on. We're currently testing it out with C/ObjC. https://reviews.llvm.org/D31781 Files: lib/Frontend/CompilerInvocation.cpp Index:

[PATCH] D25866: [Sema] Support implicit scalar to vector conversions

2017-04-05 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: lib/Sema/SemaExpr.cpp:8188 + //type and then perform the rest of the checks here. GCC as of + //pre-release 7.0 does not accept this though. + if (VectorEltTy->isIntegralType(S.Context) && sdardis

[PATCH] D31667: [Sema] Extend GetSignedVectorType to deal with non ExtVector types

2017-04-05 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. Thanks Simon! LGTM https://reviews.llvm.org/D31667 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D31781: [Modules] Allow local submodule visibility without c++

2017-04-12 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL300108: [Modules] Enable local submodule visibility for ObjC/C (authored by bruno). Changed prior to commit: https://reviews.llvm.org/D31781?vs=94407=95034#toc Repository: rL LLVM

[PATCH] D27604: [Driver] Add compiler option to generate a reproducer

2017-04-12 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL300109: [Driver] Add compiler option to generate a reproducer (authored by bruno). Changed prior to commit: https://reviews.llvm.org/D27604?vs=80981=95035#toc Repository: rL LLVM

[PATCH] D28670: [ObjC] Disallow vector parameters and return values in Objective-C methods on older X86 targets

2017-04-12 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: lib/Sema/SemaDeclObjC.cpp:4309 + const ObjCMethodDecl *Method) { + SourceLocation Loc; + QualType T; Maybe add an assert for `Triple.getArch() == llvm::Triple::x86)` here?

[PATCH] D28832: Improve redefinition errors pointing to the same header.

2017-04-14 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno updated this revision to Diff 95369. bruno marked 2 inline comments as done. bruno added a comment. Updated the patch after Richard's comments: Before -- In file included from x.c:2: Inputs4/C.h:3:5: error: redefinition of 'c' int c = 1; ^ In module 'X' imported from

[PATCH] D28832: Improve redefinition errors pointing to the same header.

2017-04-14 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. @v.g.vassilev your testcase is interesting but it's unrelated to this specific improvement. The error message it's triggered by (a) the decl name not being found because `kROOTD_OPEN` is hidden, (b) type transforms looks for an alternative (c)

[PATCH] D28832: Improve redefinition errors pointing to the same header.

2017-04-14 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno marked 5 inline comments as done. bruno added inline comments. Comment at: include/clang/Basic/DiagnosticSemaKinds.td:8708 +def note_redefinition_modules_same_file : Note< + "'%0' included multiple times, additional (likely non-modular) include site in module

[PATCH] D25383: [libcxx][modules] Add a submodule for math.h

2017-04-13 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno abandoned this revision. bruno added a comment. This isn't needed anymore. https://reviews.llvm.org/D25383 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D27546: [ASTReader] Sort RawComments before merging

2017-04-13 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno closed this revision. bruno added a comment. Done in r290134 https://reviews.llvm.org/D27546 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D31778: [Modules] Implement ODR-like semantics for tag types in C/ObjC

2017-04-13 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. @rsmith ping! https://reviews.llvm.org/D31778 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D31778: [Modules] Implement ODR-like semantics for tag types in C/ObjC

2017-04-20 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno marked 6 inline comments as done. bruno added inline comments. Comment at: lib/Parse/ParseDecl.cpp:4236-4237 Sema::SkipBodyInfo SkipBody; + Sema::CheckCompatTagInfo CheckCompatTag; if (!Name && TUK == Sema::TUK_Definition && Tok.is(tok::l_brace) &&

[PATCH] D31778: [Modules] Implement ODR-like semantics for tag types in C/ObjC

2017-04-20 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno updated this revision to Diff 96080. bruno marked 2 inline comments as done. bruno added a comment. Update the patch after Richard's suggestions https://reviews.llvm.org/D31778 Files: include/clang/AST/ASTStructuralEquivalence.h include/clang/Basic/DiagnosticASTKinds.td

[PATCH] D13117: [DarwinDriver] Use -lto_library to specify the path for libLTO.dylib

2017-04-13 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno closed this revision. bruno added a comment. Done way back in r248932 Repository: rL LLVM https://reviews.llvm.org/D13117 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D27429: [Chrono][Darwin] On Darwin use CLOCK_UPTIME_RAW instead of CLOCK_MONOTONIC

2017-04-13 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno closed this revision. bruno added a comment. r291466 & r291517 https://reviews.llvm.org/D27429 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D29001: [Modules] Fallback to building the module if a timeout occurs

2017-04-13 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno closed this revision. bruno added a comment. Updating: already done in r298175 https://reviews.llvm.org/D29001 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D30768: [PATCH][VFS] Ignore broken symlinks in the directory iterator.

2017-03-09 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hi Juergen, Thanks for working on this. Comment at: include/clang/Basic/VirtualFileSystem.h:164 EC = Impl->increment(); -if (EC || !Impl->CurrentEntry.isStatusKnown()) +if (!Impl->CurrentEntry.isStatusKnown()) Impl.reset(); //

[PATCH] D27810: FileManager: mark virtual file entries as valid entries

2017-03-09 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Please attach a testcase! https://reviews.llvm.org/D27810 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D30183: Add -iframeworkwithsysroot compiler option

2017-03-10 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. Hi Alex, Thanks for taking a look a this. LGTM Repository: rL LLVM https://reviews.llvm.org/D30183 ___ cfe-commits mailing list

[PATCH] D30768: [PATCH][VFS] Ignore broken symlinks in the directory iterator.

2017-03-10 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added inline comments. This revision is now accepted and ready to land. Comment at: lib/Basic/VirtualFileSystem.cpp:1873 vfs::directory_iterator I = FS->dir_begin(State->top()->getName(), EC); -if (EC) +if (EC && EC !=

[PATCH] D30915: Canonicalize the path provided by -fmodules-cache-path

2017-03-13 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. LGTM Comment at: lib/Frontend/CompilerInvocation.cpp:1434 + + // Canonicalize -fmodules-cache-path before storing it. + SmallString<128>

[PATCH] D30810: Preserve vec3 type.

2017-03-13 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a reviewer: bruno. bruno added a comment. Hi JinGu, I just read the discussion on cfe-dev, some comments: > My colleague and I are implementing a transformation pass between LLVM IR and > another IR and we want to keep the 3-component vector types in our target IR Why can't you go

[PATCH] D30882: Add a callback for __has_include and use it for dependency scanning

2017-03-13 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. Hi Pete, thanks for working on this! LGTM with the minor comments below. Comment at: include/clang/Lex/PPCallbacks.h:264 + virtual void HasInclude(SourceLocation Loc, const

[PATCH] D30881: Track skipped files in dependency scanning

2017-03-13 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hi Pete, Comment at: lib/Frontend/DependencyFile.cpp:191 + const Token , + SrcMgr::CharacteristicKind FileType) override; + Is there any `FileSkipped` callback invocation that might trigger an unwanted

[PATCH] D29117: SPARC: allow usage of floating-point registers in inline ASM

2017-03-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hi, Thanks for working on this. Few questions: - What happens with the validation if +soft-float is used? - What about the 'e' mode, can you double check if the sparc backend support these instructions? If so it might be interesting to add it here. Also, please attach

[PATCH] D25866: [Sema] Support implicit scalar to vector conversions

2017-03-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hey, really sorry for the delay here. Comment at: lib/Sema/SemaExpr.cpp:8007 +static bool canConvertIntToOtherIntTy(Sema , ExprResult *Int, + QualType OtherIntTy) { + QualType IntTy =

[PATCH] D28218: Small optimizations for SourceManager::getFileID()

2017-03-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hi Daniel, This seems pretty nice. Can you share how much performance improvements you got by this / how did you test it? https://reviews.llvm.org/D28218 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D28670: [ObjC] Disallow vector parameters and return values in Objective-C methods on older X86 targets

2017-03-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hi Alex, Comment at: lib/Sema/SemaDeclObjC.cpp:4312 + for (const ParmVarDecl *P : Method->parameters()) { +if (P->getType()->isVectorType()) { + Loc = P->getLocStart(); Assuming objc/c++ can pass/return these, the current check

[PATCH] D29753: [PCH] Avoid early VarDecl emission attempt if no owning module avaiable

2017-02-28 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > It seems to me that the problem here is that `DeclMustBeEmitted` is not safe > to call in the middle of deserialization if anything partially-deserialized > might be reachable from the declaration we're querying, and yet we're > currently calling it in that case.

[PATCH] D29753: [PCH] Avoid early VarDecl emission attempt if no owning module avaiable

2017-02-28 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > What do folks think? IMO we should do it. https://reviews.llvm.org/D29753 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D29753: [PCH] Avoid early VarDecl emission attempt if no owning module avaiable

2017-03-01 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL296656: [PCH] Avoid VarDecl emission attempt if no owning module avaiable (authored by bruno). Changed prior to commit: https://reviews.llvm.org/D29753?vs=87774=90212#toc Repository: rL LLVM

[PATCH] D31778: [Modules] Implement ODR-like semantics for tag types in C/ObjC

2017-04-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: include/clang/AST/ASTStructuralEquivalence.h:52 + /// \brief Whether warn or error on tag type mismatches. + bool ErrorOnTagTypeMismatch; aprantl wrote: > No need to use \brief in new code any more. We are compiling

[PATCH] D31778: [Modules] Implement ODR-like semantics for tag types in C/ObjC

2017-04-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno updated this revision to Diff 94471. bruno added a comment. Update patch on top of Adrian comments https://reviews.llvm.org/D31778 Files: include/clang/AST/ASTStructuralEquivalence.h include/clang/Basic/DiagnosticASTKinds.td include/clang/Parse/Parser.h include/clang/Sema/Sema.h

[PATCH] D27546: [ASTReader] Sort RawComments before merging

2017-04-14 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > Does this cause us to deserialize the SLocEntry for every FileID referenced > by a RawComment? That would seem pretty bad. I don't recall because It's been a while, but I'm gonna take a look and get back to you. Thanks https://reviews.llvm.org/D27546

[PATCH] D31778: [Modules] Implement ODR-like semantics for tag types in C/ObjC

2017-04-17 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Ping! https://reviews.llvm.org/D31778 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2017-04-24 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Ping! https://reviews.llvm.org/D31269 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D28832: Improve redefinition errors pointing to the same header.

2017-04-24 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Ping https://reviews.llvm.org/D28832 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D34588: Check for _MSC_VER before define _LIBCPP_MSVCRT

2017-07-09 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > Thinking more about this, on Windows, is there a strong reason to default to > a different libc by default on Windows? I'm mostly concerned with `-fms-extensions` + darwin, which doesn't apply to this scenario, maybe someone else knows a better answer here. > @bruno

[PATCH] D34985: Do not read the file to determine its name.

2017-07-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. @v.g.vassilev will this also benefit from `ContentCache::getBuffer` improvements from https://reviews.llvm.org/D33275? I guess if `getBuffer` transparently handles pointing to right buffer we won't need this change? Repository: rL LLVM https://reviews.llvm.org/D34985

[PATCH] D33275: Keep into account if files were virtual.

2017-07-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. We're hitting a very similar problem to this one, which I think this patch will likely fix. I can't come up with a reproducible testcase either. If you can write one better yet, but I'm ok with

[PATCH] D33275: Keep into account if files were virtual.

2017-07-06 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. That sounds even better. Thanks @v.g.vassilev https://reviews.llvm.org/D33275 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D34588: Check for _MSC_VER before define _LIBCPP_MSVCRT

2017-07-17 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL308225: Check for _MSC_VER before defining _LIBCPP_MSVCRT (authored by bruno). Changed prior to commit: https://reviews.llvm.org/D34588?vs=103975=106960#toc Repository: rL LLVM

[PATCH] D34588: Check for _MSC_VER before define _LIBCPP_MSVCRT

2017-07-17 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. > Could something like _WIN32 && _MSC_VER make this better? That would allow > us to differentiate between the various environments. It's kinda icky, but, > does make sense in a round about way. The check in the patch was already under a `#if defined(_WIN32)`, having

[PATCH] D34878: [ARM] Option for reading thread pointer from coprocessor register

2017-07-25 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. If there's a precedence for a flag name there, it's nice to be compatible here. You don't necessarily need to use the same name as the backend. https://reviews.llvm.org/D34878 ___ cfe-commits mailing list

[PATCH] D34030: Fix the postorder visting of the ClassTemplateSpecializationDecl nodes in the RecursiveASTVisitor.

2017-07-25 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. In https://reviews.llvm.org/D34030#819699, @MontyKutyi wrote: > As I can see the `clang/test` contains a lot of different simple tests, but > for testing this I think it is not enough to run the clang with some > arguments on a specific input. So I should create a new

  1   2   3   4   5   >