[PATCH] D61446: Generalize the pass registration mechanism used by Polly to any third-party tool

2019-07-31 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 212509. serge-sans-paille added a comment. Herald added subscribers: dexonsmith, steven_wu. - Test extension point registration when extension is built-in - Correctly handle -DLLVM_LINK_LLVM_DYLIB=0 - Fix a few details Repository: rG LLVM Github

[PATCH] D62525: [Analyzer] Add new visitor to the iterator checkers

2019-07-31 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. I don't see obvious red flags here, @NoQ? In D62525#1523026 , @baloghadamsoftware wrote: > In D62525#1519868 , @NoQ wrote: > > > In D62525#1519475

[PATCH] D61446: Generalize the pass registration mechanism used by Polly to any third-party tool

2019-07-31 Thread serge via Phabricator via cfe-commits
serge-sans-paille added a comment. @Meinersbur I've updated the test case to test extension point if the extension is linked in, this is not so intrusive, I'm happy with the solution. Also fixed some linkage options when using llvm dynlib, validation looks nice on my side. Repository: rG LL

[PATCH] D65395: [clangd] Added a skeleton for a semantic highlighting feature to the vscode extension.

2019-07-31 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. The skeleton looks good, but apparently it does nothing (only enable the feature), do you have a small working prototype? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65395/new/ https://reviews.llvm.org/D65395 _

[PATCH] D65395: [clangd] Added a skeleton for a semantic highlighting feature to the vscode extension.

2019-07-31 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom updated this revision to Diff 212523. jvikstrom added a comment. Added check that clangd server actually supports semantic highlighting. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65395/new/ https://reviews.llvm.org/D65395 Files: cl

[PATCH] D64475: [clangd] Duplicate lines of semantic highlightings sent removed.

2019-07-31 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom updated this revision to Diff 212522. jvikstrom marked 2 inline comments as done. jvikstrom added a comment. Stopped using expensive getLineNumber function. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64475/new/ https://reviews.llvm.org

[PATCH] D64475: [clangd] Duplicate lines of semantic highlightings sent removed.

2019-07-31 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/ClangdLSPServer.cpp:1125 +Old = std::move(FileToHighlightings[File]); +FileToHighlightings[File] = Highlightings; + } NIT: avoid copying (from `Highlightings` into the map) under a

[PATCH] D64475: [clangd] Duplicate lines of semantic highlightings sent removed.

2019-07-31 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/unittests/SemanticHighlightingTests.cpp:408 +} + } // namespace ilya-biryukov wrote: > Could you also add a separate test that checks diffs when the number of lines > is getting smaller (

[PATCH] D59637: [analyzer] Use the custom propagation rules and sinks in GenericTaintChecker

2019-07-31 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In general, don't emit to stderr unless we either emit a warning/error about the incorrect configuration. As an experiment, what happens when you try to emit an error in the middle of the symbolic execution? You can retrieve a `DiagnosticsEngine` from any decl: `D->ge

[PATCH] D59516: [analyzer] Add custom filter functions for GenericTaintChecker

2019-07-31 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In general, the patch is looking alright, I'll take a second look later on. Don't mind my inlines too much, they are more directed towards the original code then your changes. Comment at: lib/StaticAnalyzer/Checkers/GenericTaintChecker.cpp:53-56 +

[PATCH] D62688: [Analyzer] Iterator Checkers - Model `empty()` method of containers

2019-07-31 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D62688#1606096 , @baloghadamsoftware wrote: > In D62688#1549574 , @Szelethus wrote: > > > Hmm, an idea just popped into my head. I'm not sure whether we have a > > single checker that

[PATCH] D65263: [clangd] a prototype for triggering rename after extracting.

2019-07-31 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In D65263#1606371 , @hokein wrote: > I agree that doing rename after extraction is not an ideal approach (both > correctness and latency), there should be other better ways to achieve this. > However as a LSP server, we ma

[PATCH] D65395: [clangd] Added a skeleton for a semantic highlighting feature to the vscode extension.

2019-07-31 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom added a comment. In D65395#1607889 , @hokein wrote: > The skeleton looks good, but apparently it does nothing (only enable the > feature), do you have a small working prototype? I've got a prototype that colors all the highlightings red, but i

[PATCH] D64475: [clangd] Duplicate lines of semantic highlightings sent removed.

2019-07-31 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom updated this revision to Diff 212528. jvikstrom marked an inline comment as done. jvikstrom added a comment. Copy outside lock. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64475/new/ https://reviews.llvm.org/D64475 Files: clang-tools

[PATCH] D64475: [clangd] Duplicate lines of semantic highlightings sent removed.

2019-07-31 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom added inline comments. Comment at: clang-tools-extra/clangd/unittests/SemanticHighlightingTests.cpp:408 +} + } // namespace ilya-biryukov wrote: > ilya-biryukov wrote: > > Could you also add a separate test that checks diffs when the number of > > lin

[PATCH] D64475: [clangd] Duplicate lines of semantic highlightings sent removed.

2019-07-31 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tools-extra/clangd/ClangdLSPServer.cpp:1125 +Old = std::move(FileToHighlightings[File]); +FileToHighlightings[File] = Highlightings; + } ilya-biryukov wrote: > NIT: avoid copying (from `Highlightings` into

[PATCH] D62893: [Analyzer] Iterator Checkers - Make range errors and invalidated access fatal

2019-07-31 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. This revision is now accepted and ready to land. Makes sense! But, does any of the test cases actually test *this* particular change? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62893/new/ https://re

[PATCH] D65486: [clangd] Ignore semicolons, whitespace, and comments in SelectionTree.

2019-07-31 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 212536. sammccall added a comment. Improve comments in SelectedTokens. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65486/new/ https://reviews.llvm.org/D65486 Files: clang-tools-extra/clangd/Selection.cpp

[PATCH] D62895: [Analyzer] Iterator Checkers - Check and simulate `std::advance`, `std::prev` and `std::next`

2019-07-31 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Again, this a place where a debugging functionality would be awesome to precisely observe the change being made. I also noticed that `IteratorChecker` and related classes don't have any dump methods, maybe that is worth investing into as well? Repository: rC Clang

r367399 - [RISCV] Add support for floating point registers in inlineasm

2019-07-31 Thread Simon Cook via cfe-commits
Author: simoncook Date: Wed Jul 31 02:12:00 2019 New Revision: 367399 URL: http://llvm.org/viewvc/llvm-project?rev=367399&view=rev Log: [RISCV] Add support for floating point registers in inlineasm This adds support for parsing/emitting in IR the floating-point RISC-V registers in inline assembly

[PATCH] D64737: RISCV: Add support for floating point registers in inlineasm

2019-07-31 Thread Simon Cook via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367399: [RISCV] Add support for floating point registers in inlineasm (authored by simoncook, committed by ). Herald added subscribers: llvm-commits, s.egerton. Herald added a project: LLVM. Changed prior

[PATCH] D59637: [analyzer] Use the custom propagation rules and sinks in GenericTaintChecker

2019-07-31 Thread Borsik Gábor via Phabricator via cfe-commits
boga95 marked 2 inline comments as done. boga95 added a comment. I think it shouldn't give compile error in case of incorrect configuration now (maybe warning) because: - Without qualified names, I can create a code which cannot be configured properly. - It can throw an error without configu

r367403 - [RISCV] Support 'f' Inline Assembly Constraint

2019-07-31 Thread Sam Elliott via cfe-commits
Author: lenary Date: Wed Jul 31 02:45:55 2019 New Revision: 367403 URL: http://llvm.org/viewvc/llvm-project?rev=367403&view=rev Log: [RISCV] Support 'f' Inline Assembly Constraint Summary: This adds the 'f' inline assembly constraint, as supported by GCC. An 'f'-constrained operand is passed in a

[clang-tools-extra] r367406 - [Clangd] NFC: Added FIXME in ExtractVariable tests

2019-07-31 Thread Shaurya Gupta via cfe-commits
Author: sureyeaah Date: Wed Jul 31 03:08:29 2019 New Revision: 367406 URL: http://llvm.org/viewvc/llvm-project?rev=367406&view=rev Log: [Clangd] NFC: Added FIXME in ExtractVariable tests Modified: clang-tools-extra/trunk/clangd/unittests/TweakTests.cpp Modified: clang-tools-extra/trunk/clang

[PATCH] D64799: [Sema] Emit diagnostics for uncorrected delayed typos at the end of TU

2019-07-31 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. An experiment with popping on expression evaluation context failed, I couldn't find a good way to fix the problems described above. Typo correction can and will run after the evaluation context where expression created is popped and the diagnostic we produce depend

[PATCH] D65500: [RISCV] Support 'f' Inline Assembly Constraint

2019-07-31 Thread Sam Elliott via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367403: [RISCV] Support 'f' Inline Assembly Constraint (authored by lenary, committed by ). Changed prior to commit: https://reviews.llvm.org/D65500?vs=212513&id=212543#toc Repository: rL LLVM CHANG

[PATCH] D65500: [RISCV] Support 'f' Inline Assembly Constraint

2019-07-31 Thread Sam Elliott via Phabricator via cfe-commits
lenary created this revision. lenary added reviewers: asb, lewis-revill. Herald added subscribers: llvm-commits, cfe-commits, s.egerton, Jim, benna, psnobl, jocewei, PkmX, rkruppe, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, MaskRay, jrtc27, shiva0217, kito-cheng, niosHD, sa

[PATCH] D65500: [RISCV] Support 'f' Inline Assembly Constraint

2019-07-31 Thread Alex Bradbury via Phabricator via cfe-commits
asb accepted this revision. asb 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/D65500/new/ https://reviews.llvm.org/D65500

[PATCH] D65500: [RISCV] Support 'f' Inline Assembly Constraint

2019-07-31 Thread Sam Elliott via Phabricator via cfe-commits
lenary updated this revision to Diff 212513. lenary added a comment. - Simplify inline-asm-invalid.ll test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65500/new/ https://reviews.llvm.org/D65500 Files: clang/lib/Basic/Targets/RISCV.cpp clang/

[PATCH] D65300: [clang] [CodeGen] clang-misexpect prototype for compiler warnings

2019-07-31 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri requested changes to this revision. lebedev.ri added a comment. This revision now requires changes to proceed. Thank you for working on this! I'm guessing this doesn't have a `-Werror=` mode? I still believe this should output a remark. It will still be visible in the compiler console

[PATCH] D62525: [Analyzer] Add new visitor to the iterator checkers

2019-07-31 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware marked 2 inline comments as done. baloghadamsoftware added inline comments. Comment at: lib/StaticAnalyzer/Checkers/IteratorChecker.cpp:281-282 + + // `FoundChange` becomes true when we find the statement the results in the + // current state of the iterator.

[PATCH] D65445: [CrossTU] Handle case when no USR could be generated during Decl search.

2019-07-31 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. In D65445#1607803 , @balazske wrote: > It looks like that the problem can happen when the anonymous union is in any > `DeclContext` and for CTU import the import of a variable is requested and > that variable is in a related `Dec

[PATCH] D64753: [CrossTU][NFCI] Refactor loadExternalAST function

2019-07-31 Thread Gabor Marton via Phabricator via cfe-commits
martong added inline comments. Comment at: clang/lib/CrossTU/CrossTranslationUnit.cpp:489 + if (DisplayCTUProgress) { +if (llvm::Expected FileName = +ASTStorage.getFileForFunction(LookupName, CrossTUDir, IndexName)) ` LoadOperation` should not be

[PATCH] D63932: [GlobalDCE] Dead Virtual Function Elimination

2019-07-31 Thread Oliver Stannard (Linaro) via Phabricator via cfe-commits
ostannard added a comment. > - Take the example from my earlier message, give the "main executable" and > "DSO" hidden visibility, build the "main executable" with LTO and the "DSO" > without LTO, and statically link them both into the same executable. We run > into the same problem where the P

r367428 - [AArch64] Add support for Transactional Memory Extension (TME)

2019-07-31 Thread Momchil Velikov via cfe-commits
Author: chill Date: Wed Jul 31 05:52:17 2019 New Revision: 367428 URL: http://llvm.org/viewvc/llvm-project?rev=367428&view=rev Log: [AArch64] Add support for Transactional Memory Extension (TME) Re-commit r366322 after some fixes TME is a future architecture technology, documented in https:/

[PATCH] D64416: [AArch64] Add support for Transactional Memory Extension (TME)

2019-07-31 Thread Momchil Velikov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367428: [AArch64] Add support for Transactional Memory Extension (TME) (authored by chill, committed by ). Changed prior to commit: https://reviews.llvm.org/D64416?vs=212332&id=212559#toc Repository:

[PATCH] D65486: [clangd] Ignore semicolons, whitespace, and comments in SelectionTree.

2019-07-31 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet accepted this revision. kadircet added a comment. This revision is now accepted and ready to land. Thanks for the comments, LGTM! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65486/new/ https://reviews.llvm.org/D65486 _

[PATCH] D65445: [CrossTU] Handle case when no USR could be generated during Decl search.

2019-07-31 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. Probably this is a problem case too but only if the `f` or `i` has an initializer expression and really no USR is generated for `f` or `i`. But what I have found is that there is a `VarDecl` for a "invisible" variable whose type is the anonymous union and it has a (def

[PATCH] D61446: Generalize the pass registration mechanism used by Polly to any third-party tool

2019-07-31 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 212567. serge-sans-paille added a comment. Make validation more resilient depending on shared/static build. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61446/new/ https://reviews.llvm.org/D61446 Files: clang/lib/CodeGen/BackendUtil.cp

[PATCH] D65510: [clangd] Fix implicit template instatiations appearing as topLevelDecls.

2019-07-31 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom created this revision. jvikstrom added reviewers: hokein, ilya-biryukov. Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous, MaskRay. Herald added a project: clang. The parser gives implicit template instantiations to the action's HandleTopLevelDecls callback. This makes

[PATCH] D65511: Delay emitting dllexport explicitly defaulted members until the class is fully parsed (PR40006)

2019-07-31 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. hans added reviewers: rnk, rsmith. This is similar to r245139, but that only addressed dllexported classes. It was still possible to run into the same problem with dllexported members in an otherwise normal class (see bug). This uses the same strategy to fix: delay d

r367431 - AMDGPU: Add missing builtin declarations

2019-07-31 Thread Matt Arsenault via cfe-commits
Author: arsenm Date: Wed Jul 31 07:03:05 2019 New Revision: 367431 URL: http://llvm.org/viewvc/llvm-project?rev=367431&view=rev Log: AMDGPU: Add missing builtin declarations Modified: cfe/trunk/include/clang/Basic/BuiltinsAMDGPU.def cfe/trunk/test/CodeGenOpenCL/builtins-amdgcn.cl Modifie

[PATCH] D65454: AMDGPU: Add missing builtin declarations

2019-07-31 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm closed this revision. arsenm added a comment. r367431 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65454/new/ https://reviews.llvm.org/D65454 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mai

[PATCH] D65486: [clangd] Ignore semicolons, whitespace, and comments in SelectionTree.

2019-07-31 Thread Shaurya Gupta via Phabricator via cfe-commits
SureYeaah added inline comments. Comment at: clang-tools-extra/clangd/Selection.cpp:50 + S.StartOffset = SM.getFileOffset(Tok.location()); + S.EndOffset = S.StartOffset + Tok.length(); + if (S.StartOffset >= SelBegin && S.EndOffset <= SelEnd) Would

[PATCH] D65517: [Preprocessor] Always discard body of #define if we failed to parse it

2019-07-31 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. ilya-biryukov added a reviewer: sammccall. Herald added a project: clang. Preivously we would only discard it if we failed to parse parameter lists. If we do not consume the body, parser sees tokens inside directive. In turns, this leads to spurious diagnostics

[PATCH] D65382: [analyzer][NFC] Refactoring BugReporter.cpp P4.: If it can be const, make it const

2019-07-31 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D65382#1605769 , @baloghadamsoftware wrote: > Most managers are stateful because they also store the elements they manage > (e.g. `ProgramStateManager` stores states, `SValBuilder` owns other managers > such as `SymbolManager` th

[PATCH] D65387: [clangd] Add a callback mechanism for handling responses from client.

2019-07-31 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 212586. hokein marked 11 inline comments as done. hokein added a comment. address comments: - move the reply callback handling code to MessageHandler; - prevent memory leakage when LSP clients don't send back the reply; - use the new machanism for applyTweak a

[PATCH] D64475: [clangd] Duplicate lines of semantic highlightings sent removed.

2019-07-31 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom marked an inline comment as done. jvikstrom added inline comments. Comment at: clang-tools-extra/clangd/ClangdLSPServer.cpp:1125 +Old = std::move(FileToHighlightings[File]); +FileToHighlightings[File] = Highlightings; + } hokein wrote: > ilya-b

[PATCH] D63325: [Support][Time profiler] Make FE codegen blocks to be inside frontend blocks

2019-07-31 Thread Anton Afanasyev via Phabricator via cfe-commits
anton-afanasyev added a comment. Ping! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63325/new/ https://reviews.llvm.org/D63325 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llv

[PATCH] D64907: [AST] Traverse attributes inside DEF_TRAVERSE_DECL macro

2019-07-31 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 212591. ilya-biryukov added a comment. Herald added a subscriber: mgorny. - Add a test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64907/new/ https://reviews.llvm.org/D64907 Files: clang/include/clan

[PATCH] D64907: [AST] Traverse attributes inside DEF_TRAVERSE_DECL macro

2019-07-31 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 212592. ilya-biryukov added a comment. - Reformat Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64907/new/ https://reviews.llvm.org/D64907 Files: clang/include/clang/AST/RecursiveASTVisitor.h clang/u

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-07-31 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: test/Sema/warn-int-in-bool-context.c:26 + r = a << 7; // expected-warning {{'<<' in boolean context; did you mean '<'?}} + r = ONE << b; // expected-warning {{'<<' in boolean context; did you mean '<'?}} + jf

[PATCH] D64475: [clangd] Duplicate lines of semantic highlightings sent removed.

2019-07-31 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov accepted this revision. ilya-biryukov marked an inline comment as done. ilya-biryukov added a comment. LGTM from my side Comment at: clang-tools-extra/clangd/ClangdLSPServer.cpp:1125 +Old = std::move(FileToHighlightings[File]); +FileToHighlightings[File] =

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-07-31 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 marked an inline comment as done. xbolva00 added inline comments. Comment at: test/SemaCXX/warn-int-in-bool-context.cpp:96 + + if (f == apple || orange) // expected-warning {{enum constant in boolean context}} +return a; aaron.ballman wrote: > xbol

[PATCH] D61446: Generalize the pass registration mechanism used by Polly to any third-party tool

2019-07-31 Thread Michael Kruse via Phabricator via cfe-commits
Meinersbur added a comment. Did you resolve the conflicting `llvmGetPassPluginInfo` symbols for windows? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61446/new/ https://reviews.llvm.org/D61446 ___ cfe-commits mailing list cfe-commits@lists

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-07-31 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. C FE: -IfStmt 0x55a225bc4dc8 | |-BinaryOperator 0x55a225bc4d48 'int' '||' | | |-BinaryOperator 0x55a225bc4d08 'int' '==' | | | |-ImplicitCastExpr 0x55a225bc4cf0 'int' | | | | `-ImplicitCastExpr 0x55a225bc4cd8 'enum fruit':'enum fruit' | | | | `-DeclR

r367447 - [InstCombine] canonicalize fneg before fmul/fdiv

2019-07-31 Thread Sanjay Patel via cfe-commits
Author: spatel Date: Wed Jul 31 09:53:22 2019 New Revision: 367447 URL: http://llvm.org/viewvc/llvm-project?rev=367447&view=rev Log: [InstCombine] canonicalize fneg before fmul/fdiv Reverse the canonicalization of fneg relative to fmul/fdiv. That makes it easier to implement the transforms (and p

[PATCH] D65510: [clangd] Fix implicit template instatiations appearing as topLevelDecls.

2019-07-31 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/ClangdUnit.cpp:68 + if (const auto *TD = dyn_cast(D)) +return TD->getTemplateSpecializationKind() == TSK_ImplicitInstantiation; + return false; We also want to skip `TSK_ExplicitInsta

[PATCH] D65511: Delay emitting dllexport explicitly defaulted members until the class is fully parsed (PR40006)

2019-07-31 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: clang/lib/Sema/SemaDeclCXX.cpp:11545 +for (CXXMethodDecl *M : WorkList) { + DefineImplicitSpecialMember(*this, M, M->getLocation()); + ActOnFinishInlineFunctionDef(M); Do we need to do this until fixpoint? Supp

[PATCH] D65511: Delay emitting dllexport explicitly defaulted members until the class is fully parsed (PR40006)

2019-07-31 Thread Hans Wennborg via Phabricator via cfe-commits
hans marked an inline comment as done. hans added inline comments. Comment at: clang/lib/Sema/SemaDeclCXX.cpp:11545 +for (CXXMethodDecl *M : WorkList) { + DefineImplicitSpecialMember(*this, M, M->getLocation()); + ActOnFinishInlineFunctionDef(M); rn

[PATCH] D61446: Generalize the pass registration mechanism used by Polly to any third-party tool

2019-07-31 Thread serge via Phabricator via cfe-commits
serge-sans-paille added a comment. @Meinersbur nop, forgot that one, I'll have a look, thanks for pointing that out. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61446/new/ https://reviews.llvm.org/D61446 ___ cfe-commits mailing list cfe-

[PATCH] D65050: [SemaTemplate] Mark a function type as dependent when its parameter list contains pack expansion

2019-07-31 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. I think this is reasonable, but I'd like @rsmith to weigh in -- this looks like it could be a Core Issue. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65050/new/ https://reviews.llvm.org/D65050 ___ cfe-commi

[PATCH] D65525: [clangd] Add new helpers to make tweak tests scale better. Convert most tests. NFC

2019-07-31 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added a reviewer: ilya-biryukov. Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous, MaskRay, mgorny. Herald added a project: clang. TweakTests.cpp has some pretty good helpers added for the first few tweaks, but they have some limitation

[PATCH] D65517: [Preprocessor] Always discard body of #define if we failed to parse it

2019-07-31 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. LG, though I'm obviously not an expert here. Thanks for tracking this down! Comment at: clang/lib/Lex/PPDirectives.cpp:2405 + auto _ = llvm::make_scope_exit([&]() { +

[PATCH] D65526: [Clangd] Initial prototype version of ExtractFunction

2019-07-31 Thread Shaurya Gupta via Phabricator via cfe-commits
SureYeaah created this revision. SureYeaah added reviewers: kadircet, sammccall. Herald added subscribers: cfe-commits, arphaman, jkorous, MaskRay, ilya-biryukov, mgorny. Herald added a project: clang. - Prototype version; Only looking for a high level review. - Only works for extraction from fre

[PATCH] D65050: [SemaTemplate] Mark a function type as dependent when its parameter list contains pack expansion

2019-07-31 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. > this looks like it could be a Core Issue I think the issue is clang-specific. clang splits the standard notion of a dependent type into two separate bits, for the sake of diagnostics: `isDependentType()`, and `isInstantiationDependentType()`. `isInstantiationDepend

[PATCH] D65486: [clangd] Ignore semicolons, whitespace, and comments in SelectionTree.

2019-07-31 Thread Sam McCall via Phabricator via cfe-commits
sammccall marked 2 inline comments as done. sammccall added inline comments. Comment at: clang-tools-extra/clangd/Selection.cpp:50 + S.StartOffset = SM.getFileOffset(Tok.location()); + S.EndOffset = S.StartOffset + Tok.length(); + if (S.StartOffset >= SelBegin && S

[PATCH] D65511: Delay emitting dllexport explicitly defaulted members until the class is fully parsed (PR40006)

2019-07-31 Thread Reid Kleckner via Phabricator via cfe-commits
rnk accepted this revision. rnk added a comment. This revision is now accepted and ready to land. lgtm Comment at: clang/lib/Sema/SemaDeclCXX.cpp:11545 +for (CXXMethodDecl *M : WorkList) { + DefineImplicitSpecialMember(*this, M, M->getLocation()); + ActOnFinishInl

[clang-tools-extra] r367453 - [clangd] Ignore semicolons, whitespace, and comments in SelectionTree.

2019-07-31 Thread Sam McCall via cfe-commits
Author: sammccall Date: Wed Jul 31 10:52:40 2019 New Revision: 367453 URL: http://llvm.org/viewvc/llvm-project?rev=367453&view=rev Log: [clangd] Ignore semicolons, whitespace, and comments in SelectionTree. Summary: Whitespace and comments are a clear bugfix: selecting some comments/space near a

[PATCH] D65486: [clangd] Ignore semicolons, whitespace, and comments in SelectionTree.

2019-07-31 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. sammccall marked an inline comment as done. Closed by commit rL367453: [clangd] Ignore semicolons, whitespace, and comments in SelectionTree. (authored by sammccall, committed by ). Herald added a project: LLVM. Herald added

[PATCH] D63932: [GlobalDCE] Dead Virtual Function Elimination

2019-07-31 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc added a comment. In D63932#1608235 , @ostannard wrote: > > - Take the example from my earlier message, give the "main executable" and > > "DSO" hidden visibility, build the "main executable" with LTO and the "DSO" > > without LTO, and statically link

[PATCH] D65527: Avoid assemble step in verbose-output-quoting.c

2019-07-31 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen created this revision. ychen added a reviewer: hans. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D65527 Files: clang/test/Driver/verbose-output-quoting.c Index: clang/test/Driver/verbose-output-qu

[PATCH] D65511: Delay emitting dllexport explicitly defaulted members until the class is fully parsed (PR40006)

2019-07-31 Thread Alexandre Ganea via Phabricator via cfe-commits
aganea added inline comments. Comment at: clang/lib/Sema/SemaDeclCXX.cpp:11545 +for (CXXMethodDecl *M : WorkList) { + DefineImplicitSpecialMember(*this, M, M->getLocation()); + ActOnFinishInlineFunctionDef(M); rnk wrote: > hans wrote: > > rnk wrote:

[PATCH] D65308: [NFC][clang] Refactor getCompilationPhases()+Types.def step 3.

2019-07-31 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi updated this revision to Diff 212634. plotfi added a comment. trying to re-land, changing TY_ObjCXXHeader to TY_PP_ObjCXXHeader, Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65308/new/ https://reviews.llvm.org/D65308 Files: clang/includ

[PATCH] D64811: Warn when NumParams overflows

2019-07-31 Thread Mark de Wever via Phabricator via cfe-commits
Mordante marked an inline comment as done. Mordante added inline comments. Comment at: clang/lib/Parse/ParseDecl.cpp:6673 + // Avoid exceeding the maximum function parameters + // See https://bugs.llvm.org/show_bug.cgi?id=19607 + if (ParamInfo.size() > Type::getMaxNumParams())

[PATCH] D65534: [clang] Change FileManager to use llvm::ErrorOr instead of null on failure

2019-07-31 Thread Harlan Haskins via Phabricator via cfe-commits
harlanhaskins created this revision. harlanhaskins added reviewers: arphaman, bruno. Herald added subscribers: lldb-commits, cfe-commits, jsji, kadircet, dexonsmith, jkorous, MaskRay, kbarton, nemanjai. Herald added a reviewer: martong. Herald added a reviewer: shafik. Herald added projects: clang

[PATCH] D65510: [clangd] Fix implicit template instatiations appearing as topLevelDecls.

2019-07-31 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tools-extra/clangd/ClangdUnit.cpp:68 + if (const auto *TD = dyn_cast(D)) +return TD->getTemplateSpecializationKind() == TSK_ImplicitInstantiation; + return false; ilya-biryukov wrote: > We also want to skip `T

r367478 - [NFC][clang] Refactor getCompilationPhases()+Types.def step 3.

2019-07-31 Thread Puyan Lotfi via cfe-commits
Author: zer0 Date: Wed Jul 31 13:40:08 2019 New Revision: 367478 URL: http://llvm.org/viewvc/llvm-project?rev=367478&view=rev Log: [NFC][clang] Refactor getCompilationPhases()+Types.def step 3. Second landing attempt: Changed TY_ObjCXXHeader to TY_PP_ObjCXXHeader to fix -x

r367479 - [clang][ARM] Fix msvc arm{64} builtins to use int on LP64 systems.

2019-07-31 Thread Michael J. Spencer via cfe-commits
Author: mspencer Date: Wed Jul 31 13:42:28 2019 New Revision: 367479 URL: http://llvm.org/viewvc/llvm-project?rev=367479&view=rev Log: [clang][ARM] Fix msvc arm{64} builtins to use int on LP64 systems. The `InterlockedX_{acq,nf,rel}` functions deal with 32 bits which is long on MSVC, but int on m

[PATCH] D64164: [clang][ARM] Fix msvc arm{64} builtins to use int on LP64 systems.

2019-07-31 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367479: [clang][ARM] Fix msvc arm{64} builtins to use int on LP64 systems. (authored by mspencer, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to co

[PATCH] D65534: [clang] Change FileManager to use llvm::ErrorOr instead of null on failure

2019-07-31 Thread Davide Italiano via Phabricator via cfe-commits
davide added a comment. Really on the lldb side, Jonas is the right person to review this patch. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65534/new/ https://reviews.llvm.org/D65534 ___ cfe-commits

[PATCH] D65534: [clang] Change FileManager to use llvm::ErrorOr instead of null on failure

2019-07-31 Thread Davide Italiano via Phabricator via cfe-commits
davide added a comment. [and Raphael for the clang vendor bits] Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65534/new/ https://reviews.llvm.org/D65534 ___ cfe-commits mailing list cfe-commits@lists.l

[PATCH] D64671: [clang-tidy] New check: misc-init-local-variables

2019-07-31 Thread Jussi Pakkanen via Phabricator via cfe-commits
jpakkane updated this revision to Diff 212664. jpakkane added a comment. Herald added subscribers: kbarton, nemanjai. Renamed to cppcoreguidelines-init-variables. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64671/new/ https://reviews.llvm.org/D64671 Files: clang-tools-extra/clang-t

[PATCH] D64146: [ConstExprPreter][WIP] Initial patch for the constexpr interpreter

2019-07-31 Thread Nandor Licker via Phabricator via cfe-commits
nand marked 40 inline comments as done. nand added a comment. I have applied most of the changes you suggested to my HEAD which had significantly more functionality, including a replacement of Opcodes.in with TableGen. Quite a few of your concerns are answered by the features I have added betwee

[PATCH] D58418: [clang][DirectoryWatcher] Upstream DirectoryWatcher

2019-07-31 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi added a comment. @jkorous DirectoryWatcherTests causes ninja check-clang to hang on my Ubuntu 18.04 computer. check-clang will not finish and I am forced to killall -9 DirectoryWatcherTests. My system has 40 threads and this repros on ext4 and btrfs. Repository: rL LLVM CHANGES SINC

[PATCH] D65534: [clang] Change FileManager to use llvm::ErrorOr instead of null on failure

2019-07-31 Thread Jan Korous via Phabricator via cfe-commits
jkorous added inline comments. Comment at: clang/include/clang/Basic/FileManager.h:143 /// - llvm::StringMap SeenDirEntries; + llvm::StringMap, llvm::BumpPtrAllocator> + SeenDirEntries; Maybe we could replace this with some type that has hard-to-use-incorre

[PATCH] D60943: Delay diagnosing asm constraints that require immediates until after inlining

2019-07-31 Thread Bill Wendling via Phabricator via cfe-commits
void added a comment. Friendly ping. :-) Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60943/new/ https://reviews.llvm.org/D60943 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin

[PATCH] D58418: [clang][DirectoryWatcher] Upstream DirectoryWatcher

2019-07-31 Thread Jan Korous via Phabricator via cfe-commits
jkorous added a comment. In D58418#1609138 , @plotfi wrote: > @jkorous DirectoryWatcherTests causes ninja check-clang to hang on my Ubuntu > 18.04 computer. check-clang will not finish and I am forced to killall -9 > DirectoryWatcherTests. My system has

[PATCH] D65543: Use library basenames when autolinking on Windows

2019-07-31 Thread Reid Kleckner via Phabricator via cfe-commits
rnk created this revision. rnk added reviewers: russell.gallop, thakis, pcc. Herald added a subscriber: srhines. Herald added a project: clang. Otherwise we embed a potentially absolute and potentially relative path to clang's resource directory into the object file. Object files with paths embedd

[PATCH] D65543: Use library basenames when autolinking on Windows

2019-07-31 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc added a comment. The idea behind embedding the path was that these objects are usually not distributed, so things usually just work. Is there some other way that we could arrange for the linker to search the sanitizer library directory automatically? Maybe we could add the path to one of t

[PATCH] D65545: Handle some fs::remove failures

2019-07-31 Thread JF Bastien via Phabricator via cfe-commits
jfb created this revision. jfb added reviewers: Bigcheese, bruno, arphaman, vsapsai. Herald added subscribers: llvm-commits, cfe-commits, dexonsmith, jkorous, hiraditya. Herald added projects: clang, LLVM. We have data showing that some modules builds fail in rare cases. We're therefore interest

[PATCH] D65534: [clang] Change FileManager to use llvm::ErrorOr instead of null on failure

2019-07-31 Thread Harlan Haskins via Phabricator via cfe-commits
harlanhaskins marked 2 inline comments as done. harlanhaskins added inline comments. Comment at: clang/include/clang/Basic/FileManager.h:143 /// - llvm::StringMap SeenDirEntries; + llvm::StringMap, llvm::BumpPtrAllocator> + SeenDirEntries; jkorous wrote: >

[PATCH] D62525: [Analyzer] Add new visitor to the iterator checkers

2019-07-31 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D62525#1607813 , @Szelethus wrote: > In D62525#1523026 , > @baloghadamsoftware wrote: > > > The problem is that the transition is added in the top level function but > > iterator position a

[PATCH] D65534: [clang] Change FileManager to use llvm::ErrorOr instead of null on failure

2019-07-31 Thread Jonas Devlieghere via Phabricator via cfe-commits
JDevlieghere added inline comments. Comment at: clang/include/clang/Basic/FileManager.h:217 /// - /// This returns NULL if the file doesn't exist. + /// This returns a \c std::error_code if there was an error loading the file. /// harlanhaskins wrote: > j

[PATCH] D65534: [clang] Change FileManager to use llvm::ErrorOr instead of null on failure

2019-07-31 Thread Harlan Haskins via Phabricator via cfe-commits
harlanhaskins added inline comments. Comment at: clang/include/clang/Basic/FileManager.h:217 /// - /// This returns NULL if the file doesn't exist. + /// This returns a \c std::error_code if there was an error loading the file. /// JDevlieghere wrote: > h

[PATCH] D65534: [clang] Change FileManager to use llvm::ErrorOr instead of null on failure

2019-07-31 Thread Harlan Haskins via Phabricator via cfe-commits
harlanhaskins updated this revision to Diff 212701. harlanhaskins added a comment. Store references instead of raw pointers in FileManger's cache Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65534/new/ https://reviews.llvm.org/D65534 Files: cla

[PATCH] D65549: [Sema] Prevent -Wunused-lambda-capture from generating false positive warnings on templated member function

2019-07-31 Thread Ziang Wan via Phabricator via cfe-commits
ziangwan created this revision. ziangwan added reviewers: rsmith, nickdesaulniers, kongyi, pirama, stephenkelly. Herald added a project: clang. Herald added a subscriber: cfe-commits. This is a continuation of https://reviews.llvm.org/D44844 and a potential fix for https://bugs.llvm.org/show_bug.

r367497 - [Sema] Enable -Wimplicit-float-conversion for integral to floating point precision loss

2019-07-31 Thread Ziang Wan via cfe-commits
Author: ziangwan725 Date: Wed Jul 31 17:16:43 2019 New Revision: 367497 URL: http://llvm.org/viewvc/llvm-project?rev=367497&view=rev Log: [Sema] Enable -Wimplicit-float-conversion for integral to floating point precision loss Issue an warning when the code tries to do an implicit int -> float co

[PATCH] D64666: [Sema] Enable -Wimplicit-float-conversion for integral to floating point precision loss

2019-07-31 Thread Phabricator via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rL367497: [Sema] Enable -Wimplicit-float-conversion for integral to floating point… (authored by ziangwan725, committed by )

[PATCH] D64666: [Sema] Enable -Wimplicit-float-conversion for integral to floating point precision loss

2019-07-31 Thread Ziang Wan via Phabricator via cfe-commits
ziangwan added a comment. I have committed this patch. I will stay diligent in case anything fails. Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64666/new/ https://reviews.llvm.org/D64666 ___ cfe-commits mailing list

  1   2   >