[PATCH] D85736: [Sema][AArch64] Support arm_sve_vector_bits attribute

2020-08-11 Thread Cullen Rhodes via Phabricator via cfe-commits
c-rhodes created this revision. c-rhodes added reviewers: efriedma, sdesmalen, rsandifo-arm, aaron.ballman, paulwalker-arm. Herald added subscribers: danielkiss, kristof.beyls, tschuett. Herald added a reviewer: rengolin. Herald added a project: clang. c-rhodes requested review of this revision.

[clang] f4dccf1 - [clang] Add a matcher for template template parameters.

2020-08-11 Thread Bruno Ricci via cfe-commits
Author: Bruno Ricci Date: 2020-08-11T16:01:36+01:00 New Revision: f4dccf115cc198e552b520fda0ee623457015db7 URL: https://github.com/llvm/llvm-project/commit/f4dccf115cc198e552b520fda0ee623457015db7 DIFF: https://github.com/llvm/llvm-project/commit/f4dccf115cc198e552b520fda0ee623457015db7.diff L

[PATCH] D85536: [clang] Add a matcher for template template parameters.

2020-08-11 Thread Bruno Ricci via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGf4dccf115cc1: [clang] Add a matcher for template template parameters. (authored by riccibruno). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85536/new/ htt

[PATCH] D84844: [OpenMP] Ensure testing for versions 4.5 and default - Part 1

2020-08-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev accepted this revision. ABataev added a comment. This revision is now accepted and ready to land. LG Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D84844/new/ https://reviews.llvm.org/D84844 ___ c

[PATCH] D80791: [AArch64] Generate .note.gnu.property based on module flags.

2020-08-11 Thread Momchil Velikov via Phabricator via cfe-commits
chill added a comment. In D80791#2210124 , @danielkiss wrote: >>> it is not useful to have a bti annotated function unless everything else is >>> bti compatible too: it is all or nothing per elf module. >> >> This is false. Some functions in an elf module

[PATCH] D80791: [AArch64] Generate .note.gnu.property based on module flags.

2020-08-11 Thread Szabolcs Nagy via Phabricator via cfe-commits
nsz added a comment. In D80791#2210207 , @chill wrote: > In D80791#2210124 , @danielkiss > wrote: > it is not useful to have a bti annotated function unless everything else is bti compatible too: it is a

[PATCH] D85319: [analyzer][RFC] Get info from the LLVM IR for precision

2020-08-11 Thread Gabor Marton via Phabricator via cfe-commits
martong updated this revision to Diff 284738. martong added a comment. - Use custom, CSA specific pipeline - Rename runOptimizerPipeline to runPipeline - Add unittest for IRContext - Add BuildCodeGen to CSA's FrontendAction.h Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION h

[PATCH] D72705: [analyzer] Added new checker 'alpha.unix.ErrorReturn'.

2020-08-11 Thread Balázs Kéri via Phabricator via cfe-commits
balazske updated this revision to Diff 284741. balazske marked 2 inline comments as done. balazske added a comment. - Rebase - Changed `testBinOpForCheckStatement` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72705/new/ https://reviews.llvm.org/D7

[PATCH] D85716: [AST][RecoveryExpr] Fix a bogus unused diagnostic when the type is preserved.

2020-08-11 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 284742. hokein added a comment. address review comment: a dependent-kind cast expr should not be warned about the unused result. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85716/new/ https://reviews.llvm.org/

[PATCH] D85716: [AST][RecoveryExpr] Fix a bogus unused diagnostic when the type is preserved.

2020-08-11 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang/test/SemaCXX/recovery-expr-type.cpp:88 +void func() { + // verify that no -Wunused-variable diagnostic on the inner Derived expression. + (Derived(Derived())); // expected-error {{call to implicitly-deleted default constructor}}

[PATCH] D72705: [analyzer] Added new checker 'alpha.unix.ErrorReturn'.

2020-08-11 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. More results in CodeChecker: emacs_errorreturn

[PATCH] D83325: [Sema] Iteratively strip sugar when removing address spaces.

2020-08-11 Thread Bevin Hansson via Phabricator via cfe-commits
ebevhan added a comment. In D83325#2209589 , @svenvh wrote: > LGTM, but just wondering if the test actually belongs to this patch, as it > doesn't demonstrate the problem without one of your other patches? Mm, that is true, but then I'd be submitting the

[clang] 956582a - [Sema] Iteratively strip sugar when removing address spaces.

2020-08-11 Thread Bevin Hansson via cfe-commits
Author: Bevin Hansson Date: 2020-08-11T17:26:19+02:00 New Revision: 956582aa165804dd8335879c3a7f833901e5424c URL: https://github.com/llvm/llvm-project/commit/956582aa165804dd8335879c3a7f833901e5424c DIFF: https://github.com/llvm/llvm-project/commit/956582aa165804dd8335879c3a7f833901e5424c.diff

[PATCH] D83325: [Sema] Iteratively strip sugar when removing address spaces.

2020-08-11 Thread Bevin Hansson via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG956582aa1658: [Sema] Iteratively strip sugar when removing address spaces. (authored by ebevhan). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83325/new/ h

[PATCH] D81904: [clang] Do not crash for unsupported fixed point to floating point conversion

2020-08-11 Thread Bevin Hansson via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGd4408fe17f33: [clang] Do not crash for unsupported fixed point to floating point conversion (authored by gousemoodhin, committed by ebevhan). Herald added a project: clang. Herald added a subscriber: cfe-

[clang] d4408fe - [clang] Do not crash for unsupported fixed point to floating point conversion

2020-08-11 Thread Bevin Hansson via cfe-commits
Author: Gousemoodhin Nadaf Date: 2020-08-11T17:26:19+02:00 New Revision: d4408fe17f33bcd664ec8f468abfd1094e84a7c1 URL: https://github.com/llvm/llvm-project/commit/d4408fe17f33bcd664ec8f468abfd1094e84a7c1 DIFF: https://github.com/llvm/llvm-project/commit/d4408fe17f33bcd664ec8f468abfd1094e84a7c1.

[PATCH] D85319: [analyzer][RFC] Get info from the LLVM IR for precision

2020-08-11 Thread Gabor Marton via Phabricator via cfe-commits
martong marked 3 inline comments as done. martong added inline comments. Comment at: clang/lib/StaticAnalyzer/Frontend/FrontendActions.cpp:30 + // markers which are used by some LLVM analysis (e.g. AliasAnalysis). + CGO.OptimizationLevel = 2; // -O2 + xazax.hun

[PATCH] D85319: [analyzer][RFC] Get info from the LLVM IR for precision

2020-08-11 Thread Gabor Marton via Phabricator via cfe-commits
martong updated this revision to Diff 284760. martong added a comment. - Use /// comments in IRContext.h - Conjure the return value even if the funciton is pure - Set all CodeGen options to the default (except the opt level) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION http

[PATCH] D85666: [clang-tidy] IncludeInserter: allow <> in header name

2020-08-11 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang-tools-extra/clang-tidy/utils/IncludeInserter.cpp:98-103 + assert(SourceMgr && "SourceMgr shouldn't be null; did you remember to call " + "registerPreprocessor()?"); + bool IsAngled = Header.consume_front("<"

[PATCH] D62574: Add support for target-configurable address spaces.

2020-08-11 Thread Bevin Hansson via Phabricator via cfe-commits
ebevhan updated this revision to Diff 284765. ebevhan retitled this revision from "Initial draft of target-configurable address spaces." to "Add support for target-configurable address spaces.". ebevhan edited the summary of this revision. ebevhan added a comment. Rebased and updated summary. R

[PATCH] D85031: [builtins] Unify the softfloat division implementation

2020-08-11 Thread Anatoly Trosinenko via Phabricator via cfe-commits
atrosinenko updated this revision to Diff 284777. atrosinenko added a comment. Re-upload after D85731: [builtins] Make softfloat-related errors less noisy to get rid of "error: unknown type name 'fp_t'" and similar clang-tidy diagnostics for `fp_div_impl.inc`.

[PATCH] D62574: Add support for target-configurable address spaces.

2020-08-11 Thread Bevin Hansson via Phabricator via cfe-commits
ebevhan added a comment. I think this works now. It should probably be given a few more reviewers to have a look. Do you have some suggestions, @Anastasia ? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62574/new/ https://reviews.llvm.org/D62574

[PATCH] D85032: [builtins] Make divXf3 handle denormal results

2020-08-11 Thread Anatoly Trosinenko via Phabricator via cfe-commits
atrosinenko updated this revision to Diff 284779. atrosinenko added a comment. Re-upload after D85731: [builtins] Make softfloat-related errors less noisy to get rid of "error: unknown type name 'fp_t'" and similar clang-tidy diagnostics for `fp_div_impl.inc`.

[PATCH] D85733: [libTooling] Cleanup and reorder `RewriteRule.h`.

2020-08-11 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr2 accepted this revision. gribozavr2 added inline comments. This revision is now accepted and ready to land. Comment at: clang/include/clang/Tooling/Transformer/RewriteRule.h:147 +// Every rewrite rules is triggered by a match against some AST node. +// Transformer gua

[PATCH] D85734: [libTooling] Move RewriteRule include edits to ASTEdit granularity.

2020-08-11 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 284781. ymandel added a comment. Updated clang-tidy transformer interpreter correspondingly. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85734/new/ https://reviews.llvm.org/D85734 Files: clang-tools-extra/

[PATCH] D85734: [libTooling] Move RewriteRule include edits to ASTEdit granularity.

2020-08-11 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 284783. ymandel added a comment. fixed typo Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85734/new/ https://reviews.llvm.org/D85734 Files: clang-tools-extra/clang-tidy/utils/TransformerClangTidyCheck.cpp

[PATCH] D85733: [libTooling] Cleanup and reorder `RewriteRule.h`.

2020-08-11 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 284785. ymandel added a comment. fixed typo Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85733/new/ https://reviews.llvm.org/D85733 Files: clang/include/clang/Tooling/Transformer/RewriteRule.h clang/lib/T

[PATCH] D81272: [clang-tidy] New check `misc-redundant-condition`

2020-08-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tools-extra/clang-tidy/misc/MiscTidyModule.cpp:46 +CheckFactories.registerCheck( +"misc-redundant-condition"); CheckFactories.registerCheck( I think this check should probably live in the `bu

[PATCH] D85734: [libTooling] Move RewriteRule include edits to ASTEdit granularity.

2020-08-11 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr2 accepted this revision. gribozavr2 added inline comments. Comment at: clang/include/clang/Tooling/Transformer/RewriteRule.h:39 + // Inserts an include in the file. The `Replacement` field is the name of the + // file for which to add an include. + AddInclude, --

[PATCH] D83501: [clangd][ObjC] Improve xrefs for protocols and classes

2020-08-11 Thread David Goldman via Phabricator via cfe-commits
dgoldman added inline comments. Comment at: clang-tools-extra/clangd/unittests/SymbolCollectorTests.cpp:614 + +TEST_F(SymbolCollectorTest, ObjCClassExtensions) { + Annotations Header(R"( sammccall wrote: > dgoldman wrote: > > sammccall wrote: > > > dgoldman wrot

[PATCH] D83501: [clangd][ObjC] Improve xrefs for protocols and classes

2020-08-11 Thread David Goldman via Phabricator via cfe-commits
dgoldman updated this revision to Diff 284788. dgoldman marked 3 inline comments as done. dgoldman added a comment. - Final touches Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83501/new/ https://reviews.llvm.org/D83501 Files: clang-tools-extra

[PATCH] D85734: [libTooling] Move RewriteRule include edits to ASTEdit granularity.

2020-08-11 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 284789. ymandel added a comment. reword comment per suggestion. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85734/new/ https://reviews.llvm.org/D85734 Files: clang-tools-extra/clang-tidy/utils/TransformerC

[clang] 645dd1b - [libTooling] Cleanup and reorder `RewriteRule.h`.

2020-08-11 Thread Yitzhak Mandelbaum via cfe-commits
Author: Yitzhak Mandelbaum Date: 2020-08-11T16:35:36Z New Revision: 645dd1b3bf8d976683c72b9faf501d6f0b16326e URL: https://github.com/llvm/llvm-project/commit/645dd1b3bf8d976683c72b9faf501d6f0b16326e DIFF: https://github.com/llvm/llvm-project/commit/645dd1b3bf8d976683c72b9faf501d6f0b16326e.diff

[PATCH] D85750: [SyntaxTree] Unbox operators into tokens for nodes generated from `CXXOperatorCallExpr`

2020-08-11 Thread Eduardo Caldas via Phabricator via cfe-commits
eduucaldas created this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. eduucaldas requested review of this revision. For an user define `<`, `x < y` would yield the syntax tree: BinaryOperatorExpression |-IdExpression | `-UnqualifiedId | `-x |-IdExpre

[PATCH] D85733: [libTooling] Cleanup and reorder `RewriteRule.h`.

2020-08-11 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG645dd1b3bf8d: [libTooling] Cleanup and reorder `RewriteRule.h`. (authored by ymandel). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACT

[clang-tools-extra] cb29c33 - [clangd][ObjC] Improve xrefs for protocols and classes

2020-08-11 Thread David Goldman via cfe-commits
Author: David Goldman Date: 2020-08-11T12:36:31-04:00 New Revision: cb29c33984bf40beebd22edf80a5034cf8849307 URL: https://github.com/llvm/llvm-project/commit/cb29c33984bf40beebd22edf80a5034cf8849307 DIFF: https://github.com/llvm/llvm-project/commit/cb29c33984bf40beebd22edf80a5034cf8849307.diff

[PATCH] D83501: [clangd][ObjC] Improve xrefs for protocols and classes

2020-08-11 Thread David Goldman via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGcb29c33984bf: [clangd][ObjC] Improve xrefs for protocols and classes (authored by dgoldman). Repository: rG LLVM Github Monorepo CHANGES SINCE LA

[PATCH] D85193: [clang] Do not use an invalid expression to update the initializer.

2020-08-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/Sema/SemaInit.cpp:3088 // No structured initializer list to update if (!StructuredList) return; I would move the check up to here as the only time we should get a null expression is if somethi

[PATCH] D85750: [SyntaxTree] Unbox operators into tokens for nodes generated from `CXXOperatorCallExpr`

2020-08-11 Thread Eduardo Caldas via Phabricator via cfe-commits
eduucaldas updated this revision to Diff 284794. eduucaldas added a comment. Add explanation comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85750/new/ https://reviews.llvm.org/D85750 Files: clang/lib/Tooling/Syntax/BuildTree.cpp clang/

[PATCH] D83360: [InstSimplify] Remove select ?, undef, X -> X and select ?, X, undef -> X

2020-08-11 Thread Nikita Popov via Phabricator via cfe-commits
nikic added a comment. D85684 has landed, so we can try reapplying this change. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83360/new/ https://reviews.llvm.org/D83360 ___

[PATCH] D85750: [SyntaxTree] Unbox operators into tokens for nodes generated from `CXXOperatorCallExpr`

2020-08-11 Thread Eduardo Caldas via Phabricator via cfe-commits
eduucaldas added a reviewer: gribozavr2. eduucaldas added inline comments. Comment at: clang/lib/Tooling/Syntax/BuildTree.cpp:1024 + // representation of built-in and user-defined operators. + if (child->getBeginLoc() == S->getOperatorLoc()) +continue; -

[PATCH] D85734: [libTooling] Move RewriteRule include edits to ASTEdit granularity.

2020-08-11 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGd8c1f43dcc94: [libTooling] Move RewriteRule include edits to ASTEdit granularity. (authored by ymandel). Repository: rG LLVM Github Monorepo CHAN

[clang-tools-extra] d8c1f43 - [libTooling] Move RewriteRule include edits to ASTEdit granularity.

2020-08-11 Thread Yitzhak Mandelbaum via cfe-commits
Author: Yitzhak Mandelbaum Date: 2020-08-11T16:47:14Z New Revision: d8c1f43dcc949fda5ce37a122d1a0d92975de82c URL: https://github.com/llvm/llvm-project/commit/d8c1f43dcc949fda5ce37a122d1a0d92975de82c DIFF: https://github.com/llvm/llvm-project/commit/d8c1f43dcc949fda5ce37a122d1a0d92975de82c.diff

[PATCH] D85193: [clang] Do not use an invalid expression to update the initializer.

2020-08-11 Thread Aleksandr Platonov via Phabricator via cfe-commits
ArcsinX added inline comments. Comment at: clang/lib/Sema/SemaInit.cpp:3088 // No structured initializer list to update if (!StructuredList) return; aaron.ballman wrote: > I would move the check up to here as the only time we should get a null > expre

[PATCH] D85735: [OpenMP] Context selector extensions for template functions

2020-08-11 Thread Jon Chesterfield via Phabricator via cfe-commits
JonChesterfield added a comment. Nice. What makes it an extension? 5.0 / 2.3.5 claims "and where variant-func-id is the name of a function variant that is either a base language identifier or, for C++, a template-id." which suggests this could be always-on Comment at: clang/l

[PATCH] D85752: [Analyzer] Store the pointed/referenced type for dynamic casts

2020-08-11 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware created this revision. baloghadamsoftware added reviewers: NoQ, Charusso. baloghadamsoftware added a project: clang. Herald added subscribers: ASDenysPetrov, martong, steakhal, gamesh411, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, rnkovacs, szepet, kristof.beyls

[PATCH] D85753: [clangd] Discard diagnostics from another SourceManager.

2020-08-11 Thread Adam Czachorowski via Phabricator via cfe-commits
adamcz created this revision. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous. Herald added a project: clang. adamcz requested review of this revision. Herald added subscribers: MaskRay, ilya-biryukov. This can happen when building implicit modules, as demonstrated in

[PATCH] D85728: [Analyzer] Support for the new variadic isa<> and isa_and_not_null<> in CastValueChecker

2020-08-11 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 284801. baloghadamsoftware retitled this revision from "[Analyzer][WIP] Support for the new variadic isa<> and isa_and_not_null<> in CastValueChecker" to "[Analyzer] Support for the new variadic isa<> and isa_and_not_null<> in CastValueChecker". ba

[PATCH] D85613: [clang] Look through bindings when checking whether a default argument references a local entity.

2020-08-11 Thread Bruno Ricci via Phabricator via cfe-commits
riccibruno updated this revision to Diff 284803. riccibruno added a comment. Remove the now-unused `const VarDecl *` parameter to `DiagnoseIfOdrUse`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85613/new/ https://reviews.llvm.org/D85613 Files:

[PATCH] D85193: [clang] Do not use an invalid expression to update the initializer.

2020-08-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM! Comment at: clang/lib/Sema/SemaInit.cpp:3088 // No structured initializer list to update if (!StructuredList) return; ArcsinX

[PATCH] D85755: [OPENMP]Do not add TGT_OMP_TARGET_PARAM flag to non-captured mapped arguments.

2020-08-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: jdoerfert. Herald added subscribers: guansong, yaxunl. Herald added a project: clang. ABataev requested review of this revision. If the arguments are mapped, but are actually not used in the target region, the compiler still adds attribute T

[PATCH] D85750: [SyntaxTree] Unbox operators into tokens for nodes generated from `CXXOperatorCallExpr`

2020-08-11 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr2 accepted this revision. gribozavr2 added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Tooling/Syntax/BuildTree.cpp:1016 // operand because it does not correspond to anything written in source // code + if (c

[clang] b9aaf32 - Fix MSVC "not all control paths return a value" warning. NFC.

2020-08-11 Thread Simon Pilgrim via cfe-commits
Author: Simon Pilgrim Date: 2020-08-11T18:13:03+01:00 New Revision: b9aaf32f46494695d1b20c08730c536e17f8 URL: https://github.com/llvm/llvm-project/commit/b9aaf32f46494695d1b20c08730c536e17f8 DIFF: https://github.com/llvm/llvm-project/commit/b9aaf32f46494695d1b20c08730c536e17f8.diff

[PATCH] D85750: [SyntaxTree] Unbox operators into tokens for nodes generated from `CXXOperatorCallExpr`

2020-08-11 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr2 added inline comments. Comment at: clang/lib/Tooling/Syntax/BuildTree.cpp:1024 + // representation of built-in and user-defined operators. + if (child->getBeginLoc() == S->getOperatorLoc()) +continue; eduucaldas wrote: > Here we want

[PATCH] D85753: [clangd] Discard diagnostics from another SourceManager.

2020-08-11 Thread Adam Czachorowski via Phabricator via cfe-commits
adamcz updated this revision to Diff 284811. adamcz added a comment. log dropped dianostic Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85753/new/ https://reviews.llvm.org/D85753 Files: clang-tools-extra/clangd/Diagnostics.cpp clang-tools-ext

[PATCH] D85753: [clangd] Discard diagnostics from another SourceManager.

2020-08-11 Thread Adam Czachorowski via Phabricator via cfe-commits
adamcz added a reviewer: sammccall. adamcz added a comment. Hey Sam. What's your opinion on this? The options we have are: 1. Drop the diagnostics, like this change is doing 2. Relocate the diagnostic to the beginning of the "real" main file, like we do with SourceManager-less diagnostics 3. Tr

[PATCH] D84887: [OPENMP]Fix codegen for is_device_ptr component, captured by reference.

2020-08-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 284815. ABataev added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D84887/new/ https://reviews.llvm.org/D84887 Files: clang/lib/CodeGen/CGOpenMPRuntime.cpp clang/test/OpenMP/target_is_dev

[PATCH] D85545: [Diagnostics] Diagnose missing comma in string array initialization

2020-08-11 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks added a comment. Actually sorry, it does still seem like there are false positives on structs. Reduced: $ cat /tmp/a.cpp struct A { const char* a; const char* b; const char* c; }; static constexpr A foo2 = A{"", ""

[PATCH] D84068: AMDGPU/clang: Search resource directory for device libraries

2020-08-11 Thread Eric Christopher via Phabricator via cfe-commits
echristo added a comment. Hi All, I'd really like to avoid depending on any program other than clang installing something into clang's working directory. I think this needs to be written from the perspective of specifying another directory to look for things. -eric CHANGES SINCE LAST ACTION

[PATCH] D85762: [OPENMP]Do not allow threadprivates as base for array-like reduction.

2020-08-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added a reviewer: jdoerfert. Herald added subscribers: guansong, yaxunl. Herald added a project: clang. ABataev requested review of this revision. Herald added a subscriber: sstefan1. The base must be shared between the threads, threadprivates are not allowed

[PATCH] D85431: [analyzer] Implement a new checker ThreadPrimitivesChecker

2020-08-11 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. You're on the right track but your checker repeats `PthreadLockChecker` word-by-word. Like, you can find answers to all your questions (eg., "how to use `isLiveRegion`?") by reading that checker. C++ functions aren't any different from C functions; that's an extremely minor

[PATCH] D85752: [Analyzer] Store the pointed/referenced type for dynamic casts

2020-08-11 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Yes, i completely agree that this is the right decision, thanks! Comment at: clang/lib/StaticAnalyzer/Core/DynamicType.cpp:71-72 +Ty = Ty.getNonReferenceType(); + if (const auto *STTPTy = dyn_cast(Ty.getTypePtr())) +Ty = STTPTy->getReplacementType

[PATCH] D84886: Create LoopNestPass

2020-08-11 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. Hello, sorry for the late reply. I have some high-level questions - What are existing and future loop passes/analyses that could benefit from using LoopNestPass? - I'd feel more comfortable if existing loop pass/analysis managers could be extended to handle LoopNestPass,

[PATCH] D85752: [Analyzer] Store the pointed/referenced type for dynamic casts

2020-08-11 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/StaticAnalyzer/Core/DynamicType.cpp:73 +Ty = STTPTy->getReplacementType(); + if (Ty->isPointerType()) +Ty = Ty->getPointeeType(); Is this doing what you intended? What about a reference to a pointer?

[PATCH] D79279: Add overloaded versions of builtin mem* functions

2020-08-11 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. In D79279#2201484 , @rsmith wrote: > I think it would be reasonable in general to guarantee that our `__builtin_` > functions have contracts at least as wide as the underlying C function, but > allow them to have extensions, and to k

[PATCH] D85728: [Analyzer] Support for the new variadic isa<> and isa_and_not_null<> in CastValueChecker

2020-08-11 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Thanks!! Could you also unforget the diff context? >.< Comment at: clang/lib/StaticAnalyzer/Checkers/CastValueChecker.cpp:270-272 +default: + llvm_unreachable("Invalid template argument for isa<> or " + "isa_and_nonnull<>");

[PATCH] D85431: [analyzer] Implement a new checker ThreadPrimitivesChecker

2020-08-11 Thread Denys Petrov via Phabricator via cfe-commits
ASDenysPetrov added a comment. @NoQ > You're on the right track but your checker repeats `PthreadLockChecker` > word-by-word. Like, you can find answers to all your questions (eg., "how to > use `isLiveRegion`?") by reading that checker. C++ functions aren't any > different from C functions; t

[PATCH] D84457: [OPENMP]Fix PR37671: Privatize local(private) variables in untied tasks.

2020-08-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 284830. ABataev added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D84457/new/ https://reviews.llvm.org/D84457 Files: clang/lib/CodeGen/CGOpenMPRuntime.cpp clang/lib/CodeGen/CGOpenMPRunti

[PATCH] D83360: [InstSimplify] Remove select ?, undef, X -> X and select ?, X, undef -> X

2020-08-11 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added a comment. In D83360#2210630 , @nikic wrote: > D85684 has landed, so we can try reapplying > this change. I've put up D85765 with this patch and the follow ups re-ena

Re: [PATCH] D85545: [Diagnostics] Diagnose missing comma in string array initialization

2020-08-11 Thread Dávid Bolvanský via cfe-commits
I check if all elements of init list are strings, so this is not exactly true "struct checker" (I have no such info in that part of code..) but I consider it good enough. Your test case is based on real code? Does not seem so - well sure, we could construct many examples where warning fires useless

[PATCH] D85321: [OPENMP]Do not capture base pointer by reference if it is used as a base for array-like reduction.

2020-08-11 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev updated this revision to Diff 284836. ABataev added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85321/new/ https://reviews.llvm.org/D85321 Files: clang/lib/Sema/SemaOpenMP.cpp clang/test/OpenMP/distribute_parallel_f

[PATCH] D85545: [Diagnostics] Diagnose missing comma in string array initialization

2020-08-11 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks added a comment. In D85545#2211070 , @xbolva00 wrote: > I check if all elements of init list are strings, so this is not > exactly true "struct checker" (I have no such info in that part of > code..) but I consider it good enough. Your test case i

[PATCH] D85695: [OpenMP] split execution of a long test into smaller parts.

2020-08-11 Thread Artem Belevich via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGec5f793996f4: [OpenMP] split execution of a long test into smaller parts. (authored by tra). Repository: rG LLVM Github Monorepo CHANGES SINCE LA

[clang] ec5f793 - [OpenMP] split execution of a long test into smaller parts.

2020-08-11 Thread Artem Belevich via cfe-commits
Author: Artem Belevich Date: 2020-08-11T11:52:40-07:00 New Revision: ec5f793996f4dc86d339db88c0836e0cf4e8abea URL: https://github.com/llvm/llvm-project/commit/ec5f793996f4dc86d339db88c0836e0cf4e8abea DIFF: https://github.com/llvm/llvm-project/commit/ec5f793996f4dc86d339db88c0836e0cf4e8abea.diff

Re: [PATCH] D85545: [Diagnostics] Diagnose missing comma in string array initialization

2020-08-11 Thread Dávid Bolvanský via cfe-commits
Ok, I will bump that limit + 1. ut 11. 8. 2020 o 20:52 Arthur Eubanks via Phabricator napísal(a): > > aeubanks added a comment. > > In D85545#2211070 , @xbolva00 wrote: > > > I check if all elements of init list are strings, so this is not > > exactly true

[PATCH] D85256: Add -Wtautological-value-range-compare warning.

2020-08-11 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. In D85256#2209211 , @sberg wrote: > I think this generates a false positive with `test.cc` > > enum E { E1 = 1, E2 = 2 }; > bool f(E e) { return ((e & E1) ? 1 : 0) + ((e & E2) ? 1 : 0) > 1; } > > and `clang++ -fsyntax-only -Wtau

[PATCH] D85753: [clangd] Discard diagnostics from another SourceManager.

2020-08-11 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added inline comments. Comment at: clang-tools-extra/clangd/Diagnostics.cpp:209 // Update diag to point at include inside main file. D.File = SM.getFileEntryForID(SM.getMainFileID())->getName().str(); D.Range = std::move(R); can't we rather reco

[libunwind] e8dac8b - [libunwind][NFC] Fix typo in comment

2020-08-11 Thread Louis Dionne via cfe-commits
Author: Louis Dionne Date: 2020-08-11T15:24:52-04:00 New Revision: e8dac8b3dbe7a31af291032f1f3e95e789200590 URL: https://github.com/llvm/llvm-project/commit/e8dac8b3dbe7a31af291032f1f3e95e789200590 DIFF: https://github.com/llvm/llvm-project/commit/e8dac8b3dbe7a31af291032f1f3e95e789200590.diff

[PATCH] D84068: AMDGPU/clang: Search resource directory for device libraries

2020-08-11 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added a comment. In D84068#2210872 , @echristo wrote: > Hi All, > > I'd really like to avoid depending on any program other than clang installing > something into clang's working directory. I think this needs to be written > from the perspective o

[PATCH] D85735: [OpenMP] Context selector extensions for template functions

2020-08-11 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. In D85735#2210662 , @JonChesterfield wrote: > Nice. What makes it an extension? 5.0 / 2.3.5 claims "and where > variant-func-id is the name of a function variant that is either a base > language identifier or, for C++, a templ

[libunwind] 9b211a5 - [libunwind] Fix incorrect check for out-of-boundedness

2020-08-11 Thread Louis Dionne via cfe-commits
Author: Louis Dionne Date: 2020-08-11T15:37:57-04:00 New Revision: 9b211a5076310f14081dd257b0cbac6857534bc3 URL: https://github.com/llvm/llvm-project/commit/9b211a5076310f14081dd257b0cbac6857534bc3 DIFF: https://github.com/llvm/llvm-project/commit/9b211a5076310f14081dd257b0cbac6857534bc3.diff

[PATCH] D85176: [Coverage] Enable emitting gap area between macros

2020-08-11 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu updated this revision to Diff 284858. zequanwu added a comment. Address comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85176/new/ https://reviews.llvm.org/D85176 Files: clang/lib/CodeGen/CoverageMappingGen.cpp clang/test/Cove

[PATCH] D85773: [Driver][XRay][test] Update the macOS support check

2020-08-11 Thread Azharuddin Mohammed via Phabricator via cfe-commits
azharudd created this revision. azharudd added a reviewer: arphaman. Herald added subscribers: cfe-commits, dexonsmith, dberris. Herald added a project: clang. azharudd requested review of this revision. For macOS, the code says, the XRay flag is only supported on x86_64. Updating the test and mak

Re: [PATCH] D85545: [Diagnostics] Diagnose missing comma in string array initialization

2020-08-11 Thread Arthur O'Dwyer via cfe-commits
Dávid: Please just disable it for initializers of structs. That seems to be the common denominator in all the false positives I've observed on this thread. On Tue, Aug 11, 2020 at 3:07 PM Dávid Bolvanský wrote: > Ok, I will bump that limit + 1. > > ut 11. 8. 2020 o 20:52 Arthur Eubanks via Phab

[PATCH] D85457: [NewPM][optnone] Mark various passes as required

2020-08-11 Thread Arthur Eubanks via Phabricator via cfe-commits
aeubanks updated this revision to Diff 284875. aeubanks added a comment. Specify target Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85457/new/ https://reviews.llvm.org/D85457 Files: clang/test/CodeGen/O0-no-skipped-passes.c llvm/include/llvm

[PATCH] D85777: [OpenMP] Support std::complex math functions in target regions

2020-08-11 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert created this revision. jdoerfert added reviewers: JonChesterfield, jhuber6, ABataev. Herald added subscribers: guansong, bollu, yaxunl, mgorny. Herald added a project: clang. jdoerfert requested review of this revision. Herald added a subscriber: sstefan1. The last (big) missing piece to

[PATCH] D85778: More accurately compute the ranges of possible values for +, -, *, &, %.

2020-08-11 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith created this revision. rsmith added reviewers: sberg, rtrieu. Herald added a project: clang. Herald added a subscriber: cfe-commits. rsmith requested review of this revision. Continue to heuristically pick the wider of the two operands for narrowing conversion warnings so that some_char + 1

[PATCH] D60620: [HIP] Support target id by --offload-arch

2020-08-11 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 284882. yaxunl added a comment. rebase to ToT and minor bug fixes CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60620/new/ https://reviews.llvm.org/D60620 Files: clang/include/clang/Basic/DiagnosticDriverKinds.td clang/include/clang/Basic/Target

[PATCH] D85256: Add -Wtautological-value-range-compare warning.

2020-08-11 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. In D85256#2211129 , @rsmith wrote: > This appears to be a general problem: the `GetExprRange` mechanism in > SemaChecking miscomputes the ranges for `+`, `*`, and `-` expressions, and > we'll get them wrong for all warnings that u

[PATCH] D85777: [OpenMP] Support std::complex math functions in target regions

2020-08-11 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert updated this revision to Diff 284898. jdoerfert added a comment. Update test and include mock `type_traits` header Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85777/new/ https://reviews.llvm.org/D85777 Files: clang/lib/Headers/CMakeL

[clang] 06d100a - [Analyzer] Support note tags for smart ptr checker

2020-08-11 Thread Nithin Vadukkumchery Rajendrakumar via cfe-commits
Author: Nithin Vadukkumchery Rajendrakumar Date: 2020-08-11T23:27:16+02:00 New Revision: 06d100a69a08632e6a553a7fb4d3750b55145946 URL: https://github.com/llvm/llvm-project/commit/06d100a69a08632e6a553a7fb4d3750b55145946 DIFF: https://github.com/llvm/llvm-project/commit/06d100a69a08632e6a553a7fb

[PATCH] D84600: [Analyzer] Support note tags for smart ptr checker

2020-08-11 Thread Nithin VR via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG06d100a69a08: [Analyzer] Support note tags for smart ptr checker (authored by vrnithinkumar). Repository: rG LLVM Github Monorepo CHANGES SINCE L

[PATCH] D82317: [Clang/Test]: Update tests where `noundef` attribute is necessary

2020-08-11 Thread Gui Andrade via Phabricator via cfe-commits
guiand added a comment. After discussing with @eugenis, for the meantime it might be best to do the following: - Change the masking attribute to be `-fdisable-noundef-analysis` (name notwithstanding), and have it completely turn off all `noundef`s - Change the llvm-lit configuration to use the

[PATCH] D81678: Introduce noundef attribute at call sites for stricter poison analysis

2020-08-11 Thread Gui Andrade via Phabricator via cfe-commits
guiand updated this revision to Diff 284907. guiand added a comment. Herald added a subscriber: delcypher. To try to alleviate the tests issue, @eugenis and I discussed that it might be best to take it slow. So now this patch will mask off emitting the attribute on clang tests by default. Repo

[PATCH] D85789: [Parser] Suppress -Wempty-translation-unit if this is a header file

2020-08-11 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added a reviewer: kadircet. Herald added subscribers: cfe-commits, usaxena95. Herald added a project: clang. sammccall requested review of this revision. Herald added a subscriber: ilya-biryukov. This is motivated by tooling (clangd, libclang etc) - heade

[PATCH] D81678: Introduce noundef attribute at call sites for stricter poison analysis

2020-08-11 Thread Gui Andrade via Phabricator via cfe-commits
guiand requested review of this revision. guiand added a comment. I think I'd like someone to take a look at the `llvm-lit` changes to see if this makes sense as an approach Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D81678/new/ https://reviews.

[PATCH] D85573: [CGAtomic] Mark atomic libcall functions `nounwind`

2020-08-11 Thread Gui Andrade via Phabricator via cfe-commits
guiand updated this revision to Diff 284922. guiand added a comment. Added `willreturn`. I think `nocapture` is probably best left to a future change since it's more invasive -- it would require keeping tabs of which arguments to each function is a pointer arg. Repository: rG LLVM Github Mon

[PATCH] D85722: [SystemZ][z/OS] enable trigraphs by default on z/OS

2020-08-11 Thread Hubert Tong via Phabricator via cfe-commits
hubert.reinterpretcast added inline comments. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:2787-2789 // Mimicking gcc's behavior, trigraphs are only enabled if -trigraphs - // is specified, or -std is set to a conforming mode. + // is specified, -std is set to a con

[PATCH] D82582: [SVE] Remove calls to VectorType::getNumElements from clang

2020-08-11 Thread Christopher Tetreault via Phabricator via cfe-commits
ctetreau updated this revision to Diff 284926. ctetreau added a comment. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82582/new/ https://reviews.llvm.org/D82582 Files: clang/lib/CodeGen/CGAtomic.cpp clang/lib/CodeGen/CGBuiltin.cpp cl

[PATCH] D74051: Move update_cc_test_checks.py tests to clang

2020-08-11 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added a comment. In D74051#2017115 , @mgorny wrote: > Nevermind, I figured out good enough workaround. What was the workaround? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74051/new/ https://rev

<    1   2   3   >