[PATCH] D53417: [Clang][Sema][PowerPC] Choose a better candidate in overload function call if there is a compatible vector conversion instead of ambiguous call error

2018-11-08 Thread Zixuan Wu via Phabricator via cfe-commits
wuzish marked 2 inline comments as done. wuzish added a comment. The updated patch now extended the scope and can include the case. https://reviews.llvm.org/D53417 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D53417: [Clang][Sema][PowerPC] Choose a better candidate in overload function call if there is a compatible vector conversion instead of ambiguous call error

2018-11-08 Thread Zixuan Wu via Phabricator via cfe-commits
wuzish updated this revision to Diff 173276. wuzish added a comment. Extend the scope to all vector type as one comment suggested. > a conversion sequence that bitcasts a vector should be ranked worse than one > that does not, regardless of the kind of vector in use. Which is also made code

Re: [clang-tools-extra] r346461 - Ignore implicit things like ConstantExpr.

2018-11-08 Thread Roman Lebedev via cfe-commits
Test? On Fri, Nov 9, 2018 at 4:34 AM Bill Wendling via cfe-commits wrote: > > Author: void > Date: Thu Nov 8 17:32:30 2018 > New Revision: 346461 > > URL: http://llvm.org/viewvc/llvm-project?rev=346461=rev > Log: > Ignore implicit things like ConstantExpr. > > Modified: > >

[PATCH] D53417: [Clang][Sema][PowerPC] Choose a better candidate in overload function call if there is a compatible vector conversion instead of ambiguous call error

2018-11-08 Thread Zixuan Wu via Phabricator via cfe-commits
wuzish added a comment. In https://reviews.llvm.org/D53417#1292404, @rsmith wrote: > I like the direction here, and I'd like to see this applied generally: a > conversion sequence that bitcasts a vector should be ranked worse than one > that does not, regardless of the kind of vector in use.

[PATCH] D53417: [Clang][Sema][PowerPC] Choose a better candidate in overload function call if there is a compatible vector conversion instead of ambiguous call error

2018-11-08 Thread Hubert Tong via Phabricator via cfe-commits
hubert.reinterpretcast added a comment. > some test points check the error report for ambiguous call because of too > many implicit cast choices from ext_vector_type to vector type. It appears the answer is to update these tests and remove the restriction on the type class.

r346471 - [PowerPC] [Clang] [AltiVec] The second parameter of vec_sr function should be modulo the number of bits in the element

2018-11-08 Thread Zi Xuan Wu via cfe-commits
Author: wuzish Date: Thu Nov 8 19:35:32 2018 New Revision: 346471 URL: http://llvm.org/viewvc/llvm-project?rev=346471=rev Log: [PowerPC] [Clang] [AltiVec] The second parameter of vec_sr function should be modulo the number of bits in the element The second parameter of vec_sr function is

[PATCH] D53417: [Clang][Sema][PowerPC] Choose a better candidate in overload function call if there is a compatible vector conversion instead of ambiguous call error

2018-11-08 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. I like the direction here, and I'd like to see this applied generally: a conversion sequence that bitcasts a vector should be ranked worse than one that does not, regardless of the kind of vector in use. https://reviews.llvm.org/D53417

[PATCH] D54087: [PowerPC] [Clang] [AltiVec] The second parameter of vec_sr function should be modulo the number of bits in the element

2018-11-08 Thread Zixuan Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL346471: [PowerPC] [Clang] [AltiVec] The second parameter of vec_sr function should be… (authored by wuzish, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D54087: [PowerPC] [Clang] [AltiVec] The second parameter of vec_sr function should be modulo the number of bits in the element

2018-11-08 Thread Zixuan Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC346471: [PowerPC] [Clang] [AltiVec] The second parameter of vec_sr function should be… (authored by wuzish, committed by ). Changed prior to commit: https://reviews.llvm.org/D54087?vs=172538=173262#toc

[PATCH] D53263: Fix places where the return type of a FunctionDecl was being used in place of the function type

2018-11-08 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall added a comment. This revision is now accepted and ready to land. LGTM. https://reviews.llvm.org/D53263 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D54288: Fix ClangFormat issue of recognizing ObjC subscript as C++ attributes when message target is a result of a C-style method.

2018-11-08 Thread Yan Zhang via Phabricator via cfe-commits
Wizard updated this revision to Diff 173258. Wizard added a comment. remove blank lines Repository: rC Clang https://reviews.llvm.org/D54288 Files: lib/Format/TokenAnnotator.cpp unittests/Format/FormatTest.cpp Index: unittests/Format/FormatTest.cpp

r346468 - Fix test from r346439 to also work on Windows due to path separator differences.

2018-11-08 Thread Douglas Yung via cfe-commits
Author: dyung Date: Thu Nov 8 18:44:07 2018 New Revision: 346468 URL: http://llvm.org/viewvc/llvm-project?rev=346468=rev Log: Fix test from r346439 to also work on Windows due to path separator differences. Modified: cfe/trunk/test/Modules/mismatch-diagnostics.cpp Modified:

[PATCH] D51554: [CUDA][OPENMP][NVPTX]Improve logic of the debug info support.

2018-11-08 Thread Eric Christopher via Phabricator via cfe-commits
echristo added a comment. The llvm backend patch here has discussion around debug info kinds that we should iron out first. Comment at: lib/Driver/ToolChains/Cuda.cpp:292 + bool IsDebugEnabled = !A || A->getOption().matches(options::OPT_O0) || +

[PATCH] D54288: Fix ClangFormat issue of recognizing ObjC subscription as C++ attributes when message target is a result of a C-style method.

2018-11-08 Thread Yan Zhang via Phabricator via cfe-commits
Wizard created this revision. Herald added a subscriber: cfe-commits. Repository: rC Clang https://reviews.llvm.org/D54288 Files: lib/Format/TokenAnnotator.cpp unittests/Format/FormatTest.cpp Index: unittests/Format/FormatTest.cpp

[clang-tools-extra] r346467 - Remove unused c'tor.

2018-11-08 Thread Bill Wendling via cfe-commits
Author: void Date: Thu Nov 8 18:03:24 2018 New Revision: 346467 URL: http://llvm.org/viewvc/llvm-project?rev=346467=rev Log: Remove unused c'tor. Modified: clang-tools-extra/trunk/modularize/ModuleAssistant.cpp Modified: clang-tools-extra/trunk/modularize/ModuleAssistant.cpp URL:

[PATCH] D53675: [WebAssembly] Lower select for vectors

2018-11-08 Thread Thomas Lively via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL346462: [WebAssembly] Lower select for vectors (authored by tlively, committed by ). Repository: rL LLVM https://reviews.llvm.org/D53675 Files:

[clang-tools-extra] r346461 - Ignore implicit things like ConstantExpr.

2018-11-08 Thread Bill Wendling via cfe-commits
Author: void Date: Thu Nov 8 17:32:30 2018 New Revision: 346461 URL: http://llvm.org/viewvc/llvm-project?rev=346461=rev Log: Ignore implicit things like ConstantExpr. Modified: clang-tools-extra/trunk/clang-tidy/performance/NoexceptMoveConstructorCheck.cpp Modified:

r346458 - Use correct parameter name in comment.

2018-11-08 Thread Bill Wendling via cfe-commits
Author: void Date: Thu Nov 8 17:04:05 2018 New Revision: 346458 URL: http://llvm.org/viewvc/llvm-project?rev=346458=rev Log: Use correct parameter name in comment. Modified: cfe/trunk/include/clang/StaticAnalyzer/Core/AnalyzerOptions.h Modified:

[PATCH] D54243: DebugInfo: Add a driver flag for DWARF debug_ranges base address specifier use.

2018-11-08 Thread Eric Christopher via Phabricator via cfe-commits
echristo added a comment. I have no other bikeshed colors here. :) Repository: rC Clang https://reviews.llvm.org/D54243 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D53921: Compound literals, enums, et al require const expr

2018-11-08 Thread Bill Wendling via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC346455: Compound literals, enums, et al require const expr (authored by void, committed by ). Changed prior to commit: https://reviews.llvm.org/D53921?vs=172313=173248#toc Repository: rC Clang

[PATCH] D53921: Compound literals, enums, et al require const expr

2018-11-08 Thread Bill Wendling via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL346455: Compound literals, enums, et al require const expr (authored by void, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit:

r346455 - Compound literals, enums, et al require const expr

2018-11-08 Thread Bill Wendling via cfe-commits
Author: void Date: Thu Nov 8 16:41:36 2018 New Revision: 346455 URL: http://llvm.org/viewvc/llvm-project?rev=346455=rev Log: Compound literals, enums, et al require const expr Summary: Compound literals, enums, file-scoped arrays, etc. require their initializers and size specifiers to be

[PATCH] D45616: [X86] Lower _mm[256|512]_cmp[.]_mask intrinsics to native llvm IR

2018-11-08 Thread Nikita Astafev via Phabricator via cfe-commits
nastafev added a comment. Thanks, I agree with @andrew.w.kaylor and his interpretation. I was trying to convey the message that the programmer operating with intrinsics relies on the semantics they carry because there's no other way to express that semantics. Re-optimizing what's already

r346454 - Fix a use-after-free introduced by r344915.

2018-11-08 Thread Adrian Prantl via cfe-commits
Author: adrian Date: Thu Nov 8 16:26:15 2018 New Revision: 346454 URL: http://llvm.org/viewvc/llvm-project?rev=346454=rev Log: Fix a use-after-free introduced by r344915. r344915 added a call to ApplyDebugLocation to the sanitizer check function emitter. Some of the sanitizers are emitted in

[PATCH] D53921: Compound literals, enums, et al require const expr

2018-11-08 Thread Bill Wendling via Phabricator via cfe-commits
void marked an inline comment as done. void added a comment. I'm using "arcanist" for the first time, and I don't want to mess things up. I'll address the comments here in the next patch. Repository: rC Clang https://reviews.llvm.org/D53921 ___

[PATCH] D51575: [clang-tidy/checks] Implement a clang-tidy check to verify Google Objective-C function naming conventions 

2018-11-08 Thread Stephane Moore via Phabricator via cfe-commits
stephanemoore added inline comments. Comment at: docs/clang-tidy/checks/google-objc-function-naming.rst:20 + static bool is_positive(int i) { return i > 0; } + bool IsNegative(int i) { return i < 0; } + benhamilton wrote: > This is not actually handled by the

[PATCH] D53700: Support _Clang as a scoped attribute identifier

2018-11-08 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. Let's do it. The diagnostic and fix-it is awesome ;) https://reviews.llvm.org/D53700 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D51575: [clang-tidy/checks] Implement a clang-tidy check to verify Google Objective-C function naming conventions 

2018-11-08 Thread Stephane Moore via Phabricator via cfe-commits
stephanemoore updated this revision to Diff 173244. stephanemoore marked an inline comment as done. stephanemoore added a comment. Added a test case for an extern function without an appropriate prefix (`IsPrime`). Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D51575 Files:

[PATCH] D54281: [clang-tidy] fix PR39583 - ignoring ParenCast for string-literals in pro-bounds-array-to-pointer-decay

2018-11-08 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/cppcoreguidelines/ProBoundsArrayToPointerDecayCheck.cpp:65 + unless(isInsideOfRangeBeginEndStmt()), + unless(hasSourceExpression(ignoringParenCasts(stringLiteral() .bind("cast"),

[PATCH] D54269: Introduce shard storage to auto-index.

2018-11-08 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clangd/index/Background.cpp:29 #include +#include +#include Please run Clang-format. Headers in sections should be in alphabetical order. Repository: rCTE Clang Tools Extra

[PATCH] D54281: [clang-tidy] fix PR39583 - ignoring ParenCast for string-literals in pro-bounds-array-to-pointer-decay

2018-11-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: clang-tidy/cppcoreguidelines/ProBoundsArrayToPointerDecayCheck.cpp:65 + unless(isInsideOfRangeBeginEndStmt()), + unless(hasSourceExpression(ignoringParenCasts(stringLiteral() .bind("cast"),

[PATCH] D45616: [X86] Lower _mm[256|512]_cmp[.]_mask intrinsics to native llvm IR

2018-11-08 Thread Andy Kaylor via Phabricator via cfe-commits
andrew.w.kaylor added a comment. Agreed. Reverting this patch wouldn't move us forward on constrained FP handling. What I'm saying (and what I think @nastafev is saying) is that this patch is taking a built-in that allows the user to express specific signalling behavior and throwing away that

[PATCH] D54281: [clang-tidy] fix PR39583 - ignoring ParenCast for string-literals in pro-bounds-array-to-pointer-decay

2018-11-08 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/cppcoreguidelines/ProBoundsArrayToPointerDecayCheck.cpp:65 + unless(isInsideOfRangeBeginEndStmt()), + unless(hasSourceExpression(ignoringParenCasts(stringLiteral() .bind("cast"),

[PATCH] D53700: Support _Clang as a scoped attribute identifier

2018-11-08 Thread Louis Dionne via Phabricator via cfe-commits
ldionne accepted this revision. ldionne added a comment. This revision is now accepted and ready to land. I'm fine with `_Clang` or anything else too. Thanks for doing this! Comment at: lib/Basic/Attributes.cpp:18 if (ScopeName == "__gnu__") -ScopeName =

[PATCH] D54281: [clang-tidy] fix PR39583 - ignoring ParenCast for string-literals in pro-bounds-array-to-pointer-decay

2018-11-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth created this revision. JonasToth added reviewers: aaron.ballman, alexfh, hokein. Herald added subscribers: cfe-commits, kbarton, xazax.hun, nemanjai. The fix to the issue that `const char* p = ("foo")` is diagnosed as decay is to ignored the ParenCast. Resolves PR39583 Repository:

[PATCH] D54222: [clang-tidy] Add a check to detect returning static locals in public headers

2018-11-08 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: docs/clang-tidy/checks/llvm-problematic-statics.rst:7 + +Looks for functions defined in "public" headers that return the address of a static local. These are not guaranteed to have the addresss across shared libraries and could

[PATCH] D53921: Compound literals, enums, et al require const expr

2018-11-08 Thread Bill Wendling via Phabricator via cfe-commits
void marked 2 inline comments as done. void added inline comments. Comment at: include/clang/AST/Expr.h:3073-3074 + e = ice->getSubExpr(); +else if (ConstantExpr *ce = dyn_cast(e)) + e = ce->getSubExpr(); +else rsmith wrote: > Should we skip an

[PATCH] D54222: [clang-tidy] Add a check to detect returning static locals in public headers

2018-11-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: clang-tidy/llvm/ProblematicStaticsCheck.cpp:33 + const auto *VD = Result.Nodes.getNodeAs("var"); + const auto *Return = Result.Nodes.getNodeAs("return"); + diag(Return->getBeginLoc(), "address of static local variable %0 may not "

[PATCH] D54257: [clang-tidy] **Prototype** use AllTUsExecutors

2018-11-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. Very interesting. As I am not very familiar with all the internals I do have a few questions :) Right now notes seem not be closely attached to their related warning. But within the there is a check, that a note is emitted after an error. Would it make sense to

[PATCH] D53263: Fix places where the return type of a FunctionDecl was being used in place of the function type

2018-11-08 Thread Ben via Phabricator via cfe-commits
bobsayshilol added a reviewer: rjmccall. bobsayshilol added a comment. Ping. https://reviews.llvm.org/D53263 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D53921: Compound literals, enums, et al require const expr

2018-11-08 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. This revision is now accepted and ready to land. Thanks, other than the compound literal part I think this is all fine. I'm happy for you to go ahead with this as-is; we can rearrange how we handle compound literals as a later change if you

[PATCH] D54222: [clang-tidy] Add a check to detect returning static locals in public headers

2018-11-08 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/llvm/ProblematicStaticsCheck.cpp:33 + const auto *VD = Result.Nodes.getNodeAs("var"); + const auto *Return = Result.Nodes.getNodeAs("return"); + diag(Return->getBeginLoc(), "address of static local variable %0 may

[PATCH] D45616: [X86] Lower _mm[256|512]_cmp[.]_mask intrinsics to native llvm IR

2018-11-08 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. Yes, in constrained-fp mode we might need intrinsics, at least short-term. I assume you'll probably add target-independent constrained masked fp vector operations at some point, but that's probably not a priority. But that still leaves two problems. One, clang

[PATCH] D54222: [clang-tidy] Add a check to detect returning static locals in public headers

2018-11-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: clang-tidy/llvm/ProblematicStaticsCheck.cpp:33 + const auto *VD = Result.Nodes.getNodeAs("var"); + const auto *Return = Result.Nodes.getNodeAs("return"); + diag(Return->getBeginLoc(), "address of static local variable %0 may not "

[PATCH] D53488: [clang-tidy] Improving narrowing conversions

2018-11-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: clang-tidy/cppcoreguidelines/NarrowingConversionsCheck.cpp:178 + return; +// Conversions to unsigned integer are well defined and follow modulo 2 +// arithmetic. gchatelet wrote: > JonasToth wrote: > > I

[PATCH] D54258: [Clang] Fix pretty printing of CUDA address spaces

2018-11-08 Thread Richard Membarth via Phabricator via cfe-commits
richardmembarth added a comment. I think it's not so easy to provide such tests for CUDA. CUDA memory space specifiers are implemented via attributes, e.g. `#define __shared__ __attribute__((shared))`. As a result of this, they are pretty-printed via a different code path. In my example, I call

[PATCH] D53974: [clang-tidy] new check: bugprone-too-small-loop-variable

2018-11-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. LG from my side. Please wait for feedback from @aaron.ballman or @alexfh before committing. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D53974 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D45616: [X86] Lower _mm[256|512]_cmp[.]_mask intrinsics to native llvm IR

2018-11-08 Thread Andy Kaylor via Phabricator via cfe-commits
andrew.w.kaylor added a comment. In https://reviews.llvm.org/D45616#1290897, @nastafev wrote: > > can trigger arbitrary floating-point exceptions anywhere in your code > > I believe this statement reflects the current state of many compilers on the > market, I guess I just don't see the

[PATCH] D54275: [HIP] Remove useless sections in linked files

2018-11-08 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl created this revision. yaxunl added a reviewer: tra. clang-offload-bundler creates `__CLANG_OFFLOAD_BUNDLE__*` sections in the bundles, which get into the linked files. These sections are useless after linking. They waste disk space and cause confusion for clang when directly linked with

r346439 - [Frontend/Modules] Show diagnostics on prebuilt module configuration mismatch too

2018-11-08 Thread David Blaikie via cfe-commits
Author: dblaikie Date: Thu Nov 8 12:47:30 2018 New Revision: 346439 URL: http://llvm.org/viewvc/llvm-project?rev=346439=rev Log: [Frontend/Modules] Show diagnostics on prebuilt module configuration mismatch too The current version only emits the below error for a module (attempted to be

[PATCH] D53334: [Frontend/Modules] Show diagnostics on prebuilt module configuration mismatch too

2018-11-08 Thread David Blaikie via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL346439: [Frontend/Modules] Show diagnostics on prebuilt module configuration mismatch… (authored by dblaikie, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D54195: Fix linker option for -fprofile-arcs -ftest-coverage

2018-11-08 Thread Jessica Han via Phabricator via cfe-commits
jessicah updated this revision to Diff 173209. jessicah added a comment. Updated diff with additional context upon review comments. Repository: rC Clang https://reviews.llvm.org/D54195 Files: lib/Driver/ToolChains/Linux.cpp test/Driver/clang_f_opts.c Index: test/Driver/clang_f_opts.c

[PATCH] D54245: [VFS] Implement `RedirectingFileSystem::getRealPath`.

2018-11-08 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. In https://reviews.llvm.org/D54245#1292008, @bruno wrote: > Hi Volodymyr. Does this behavior changed after your VFS fallback change? https://reviews.llvm.org/D50539 didn't change `RedirectingFileSystem` behavior regarding real paths. But for `-ivfsoverlay` it started

[PATCH] D54245: [VFS] Implement `RedirectingFileSystem::getRealPath`.

2018-11-08 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hi Volodymyr. Does this behavior changed after your VFS fallback change? https://reviews.llvm.org/D54245 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D54195: Fix linker option for -fprofile-arcs -ftest-coverage

2018-11-08 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. Thanks for the patch. Would you mind uploading a diff with additional context (e.g. git diff -U1)? Phab doesn't render it. Repository: rC Clang https://reviews.llvm.org/D54195 ___ cfe-commits mailing list

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2018-11-08 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. In https://reviews.llvm.org/D53157#1291978, @cameron.mcinally wrote: > In https://reviews.llvm.org/D53157#1291964, @kpn wrote: > > > I don't expect anyone would need to switch between constrained and regular > > floating point at an instruction level of granularity. > > >

[PATCH] D52296: [Clang] - Add -fdwarf-fission=split,single option.

2018-11-08 Thread Paul Robinson via Phabricator via cfe-commits
probinson added inline comments. Comment at: lib/Driver/ToolChains/Clang.cpp:5889 const llvm::Triple = getToolChain().getTriple(); - if (Args.hasArg(options::OPT_gsplit_dwarf) && + if ((getDebugFissionKind(D, Args) == DwarfFissionKind::Split) && (T.isOSLinux() ||

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2018-11-08 Thread Cameron McInally via Phabricator via cfe-commits
cameron.mcinally added a comment. In https://reviews.llvm.org/D53157#1291964, @kpn wrote: > I don't expect anyone would need to switch between constrained and regular > floating point at an instruction level of granularity. The Standard allows for this (to some degree). E.g. FENV_ACCESS can

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2018-11-08 Thread Andy Kaylor via Phabricator via cfe-commits
andrew.w.kaylor added a comment. Craig Topper also raised some concerns with me (in person, his desk is right by mine) about the potential effect this might have on code size. He tells me that IRBuilder calls are intended to always be inlined and if we grow the implementation of these

[PATCH] D53417: [Clang][Sema][PowerPC] Choose a better candidate in overload function call if there is a compatible vector conversion instead of ambiguous call error

2018-11-08 Thread Hubert Tong via Phabricator via cfe-commits
hubert.reinterpretcast added inline comments. Comment at: clang/lib/Sema/SemaOverload.cpp:3913 +for (auto Type : Types) { + if (S.Context.getCanonicalType(Type)->getTypeClass() != Type::Vector) +return false; wuzish wrote: >

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2018-11-08 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. In https://reviews.llvm.org/D53157#1290364, @andrew.w.kaylor wrote: > Rather than having separate methods to create the constrained versions of the > intrinsics, why not have a way to set the constrained state in the IR builder > and have the regular CreateFAdd et. al.

[PATCH] D49863: [istream] Fix error flags and exceptions propagated from input stream operations

2018-11-08 Thread Zhihao Yuan via Phabricator via cfe-commits
lichray accepted this revision. lichray added inline comments. This revision is now accepted and ready to land. Herald added a subscriber: libcxx-commits. Comment at: libcxx/include/istream:365 __input_arithmetic(basic_istream<_CharT, _Traits>& __is, _Tp& __n) { -#ifndef

[PATCH] D54262: [clang-tidy] Add `delete this` bugprone check (PR38741)

2018-11-08 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/bugprone/DeleteThisCheck.cpp:23 + cxxDeleteExpr( + has(ignoringParenImpCasts(cxxThisExpr( + .bind("DeleteThis"), Will this catch too much? e.g., ``` struct S { int *Foo;

[PATCH] D53488: [clang-tidy] Improving narrowing conversions

2018-11-08 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/cppcoreguidelines/NarrowingConversionsCheck.cpp:17 +#include "llvm/ADT/SmallVector.h" +#include "llvm/Support/Mutex.h" + Is this include needed? Comment at:

[PATCH] D54262: [clang-tidy] Add `delete this` bugprone check (PR38741)

2018-11-08 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Please also add regression test case. Is should also cover standalone function with this variable. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D54262 ___ cfe-commits mailing list

[PATCH] D54262: [clang-tidy] Add `delete this` bugprone check (PR38741)

2018-11-08 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Please mention this check in docs/ReleaseNotes.rst (in alphabetical order). Comment at: docs/clang-tidy/checks/bugprone-delete-this.rst:8 + +Said statement generates multiple problems, such as enforcing allocating the object via ``new``, or not

[PATCH] D53900: [CodeComplete] Penalize inherited ObjC properties for auto-completion

2018-11-08 Thread David Goldman via Phabricator via cfe-commits
dgoldman added a comment. Since I don't have commit access, sammccall will land this Repository: rC Clang https://reviews.llvm.org/D53900 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D54246: [clang-tidy] Add the abseil-duration-factory-scale check

2018-11-08 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/abseil/DurationFactoryScaleCheck.cpp:36 +GetScaleForFactory(llvm::StringRef FactoryName) { + static const auto *ScaleMap = + new std::unordered_map( hwright wrote: > Eugene.Zelenko wrote: > > This

[PATCH] D54246: [clang-tidy] Add the abseil-duration-factory-scale check

2018-11-08 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: docs/ReleaseNotes.rst:88 + Checks for cases where arguments to ``absl::Duration`` factory functions are + scaled internally and could be changed to a different factory function. This + check also looks for arguements with a

[PATCH] D54258: [Clang] Fix pretty printing of CUDA address spaces

2018-11-08 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Can you add tests for this change? We typically have these in Misc by passing `-ast-print`. Repository: rC Clang https://reviews.llvm.org/D54258 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D54033: [clang-tidy] Untangle layering in ClangTidyDiagnosticConsumer somewhat. NFC

2018-11-08 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE346418: [clang-tidy] Untangle layering in ClangTidyDiagnosticConsumer somewhat. NFC (authored by sammccall, committed by ). Changed prior to commit:

[PATCH] D54269: Introduce shard storage to auto-index.

2018-11-08 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet created this revision. kadircet added reviewers: sammccall, ioeric. Herald added subscribers: cfe-commits, arphaman, jkorous, ilya-biryukov. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D54269 Files: clangd/index/Background.cpp clangd/index/Background.h

[clang-tools-extra] r346418 - [clang-tidy] Untangle layering in ClangTidyDiagnosticConsumer somewhat. NFC

2018-11-08 Thread Sam McCall via cfe-commits
Author: sammccall Date: Thu Nov 8 09:42:16 2018 New Revision: 346418 URL: http://llvm.org/viewvc/llvm-project?rev=346418=rev Log: [clang-tidy] Untangle layering in ClangTidyDiagnosticConsumer somewhat. NFC Summary: Clang's hierarchy is CompilerInstance -> DiagnosticsEngine ->

[PATCH] D53850: Declares __cpu_model as dso local

2018-11-08 Thread Haibo Huang via Phabricator via cfe-commits
hhb added a comment. Ping.. Repository: rC Clang https://reviews.llvm.org/D53850 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] r346415 - [clang-tidy] fix test after r346414

2018-11-08 Thread Sam McCall via cfe-commits
Author: sammccall Date: Thu Nov 8 09:10:31 2018 New Revision: 346415 URL: http://llvm.org/viewvc/llvm-project?rev=346415=rev Log: [clang-tidy] fix test after r346414 Modified: clang-tools-extra/trunk/test/clang-tidy/diagnostic.cpp Modified:

[PATCH] D53958: [Tooling] Produce diagnostics for missing input files.

2018-11-08 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC346414: [Tooling] Produce diagnostics for missing input files. (authored by sammccall, committed by ). Changed prior to commit: https://reviews.llvm.org/D53958?vs=172052=173180#toc Repository: rC

r346414 - [Tooling] Produce diagnostics for missing input files.

2018-11-08 Thread Sam McCall via cfe-commits
Author: sammccall Date: Thu Nov 8 08:57:01 2018 New Revision: 346414 URL: http://llvm.org/viewvc/llvm-project?rev=346414=rev Log: [Tooling] Produce diagnostics for missing input files. Summary: This was disabled way back in 2011, in the dark times before Driver was VFS-aware. Also, make

[PATCH] D53780: Fix bitcast to address space cast for coerced load/stores

2018-11-08 Thread Yaxun Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC346413: Fix bitcast to address space cast for coerced load/stores (authored by yaxunl, committed by ). Changed prior to commit: https://reviews.llvm.org/D53780?vs=172673=173179#toc Repository: rC

r346413 - Fix bitcast to address space cast for coerced load/stores

2018-11-08 Thread Yaxun Liu via cfe-commits
Author: yaxunl Date: Thu Nov 8 08:55:46 2018 New Revision: 346413 URL: http://llvm.org/viewvc/llvm-project?rev=346413=rev Log: Fix bitcast to address space cast for coerced load/stores Coerced load/stores through memory do not take into account potential address space differences when it

[PATCH] D53417: [Clang][Sema][PowerPC] Choose a better candidate in overload function call if there is a compatible vector conversion instead of ambiguous call error

2018-11-08 Thread Nemanja Ivanovic via Phabricator via cfe-commits
nemanjai added a comment. @hubert.reinterpretcast Have your comments been addressed adequately in the latest version of the patch? Do you have an opinion on adding the test case I proposed? Comment at: clang/test/Sema/altivec-generic-overload.c:1 +// RUN: %clang_cc1 %s

[PATCH] D53488: [clang-tidy] Catching narrowing from double to float.

2018-11-08 Thread Guillaume Chatelet via Phabricator via cfe-commits
gchatelet added a comment. Is this good enough to go? @JonasToth Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D53488 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D54087: [PowerPC] [Clang] [AltiVec] The second parameter of vec_sr function should be modulo the number of bits in the element

2018-11-08 Thread Nemanja Ivanovic via Phabricator via cfe-commits
nemanjai accepted this revision. nemanjai added a comment. This revision is now accepted and ready to land. Just for clarification (and please add the text to the commit message), this is actually required by the ABI: Each element of the result vector is the result of logically right shifting

[PATCH] D46403: [CFI] Force LLVM to die if the implicit blacklist files cannot be found.

2018-11-08 Thread Filipe Cabecinhas via Phabricator via cfe-commits
filcab added a comment. Sorry to ressurect this review, but I have a few questions: - What kind of functions fail? - Are there bugzillas to track these? - How can a compiler expect to have blacklists for "all" its CFI clients? (I'm ok with having a default for "most-used, well-known,

r346408 - [OPENMP]Make lambda mapping follow reqs for PTR_AND_OBJ mapping.

2018-11-08 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Thu Nov 8 07:47:39 2018 New Revision: 346408 URL: http://llvm.org/viewvc/llvm-project?rev=346408=rev Log: [OPENMP]Make lambda mapping follow reqs for PTR_AND_OBJ mapping. The base pointer for the lambda mapping must point to the lambda capture placement and pointer must

[PATCH] D54262: [clang-tidy] Add `delete this` bugprone check (PR38741)

2018-11-08 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. It's best to use `clang-tidy/add_new_check.py` tool. You also need tests, and a note in releasenotes. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D54262 ___ cfe-commits mailing list

[PATCH] D54246: [clang-tidy] Add the abseil-duration-factory-scale check

2018-11-08 Thread Hyrum Wright via Phabricator via cfe-commits
hwright added inline comments. Comment at: clang-tidy/abseil/DurationFactoryScaleCheck.cpp:36 +GetScaleForFactory(llvm::StringRef FactoryName) { + static const auto *ScaleMap = + new std::unordered_map( Eugene.Zelenko wrote: > This will cause memory leaks,

[PATCH] D54246: [clang-tidy] Add the abseil-duration-factory-scale check

2018-11-08 Thread Hyrum Wright via Phabricator via cfe-commits
hwright updated this revision to Diff 173166. hwright marked 4 inline comments as done. hwright added a comment. Address reviewer comments https://reviews.llvm.org/D54246 Files: clang-tidy/abseil/AbseilTidyModule.cpp clang-tidy/abseil/CMakeLists.txt

[PATCH] D54262: [clang-tidy] Add `delete this` bugprone check (PR38741)

2018-11-08 Thread Mateusz Maćkowski via Phabricator via cfe-commits
m4tx created this revision. m4tx added reviewers: alexfh, hokein. Herald added subscribers: cfe-commits, xazax.hun, mgorny. Add a bugprone check to clang-tidy that detects the usages of `delete this`. The warning is shown even when `delete this` is the last line in the method (as there is no

[PATCH] D54261: [clangd] proof-of-concept: clang-tidy only runs over main-file

2018-11-08 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous, MaskRay, ioeric, ilya-biryukov, kbarton, nemanjai. based on https://reviews.llvm.org/D54259, with API updates to make everything build again. Not ready for review, probably won't become ready

[PATCH] D54258: [Clang] Fix pretty printing of CUDA address spaces

2018-11-08 Thread Richard Membarth via Phabricator via cfe-commits
richardmembarth created this revision. richardmembarth added reviewers: Anastasia, aaron.ballman. Herald added a subscriber: cfe-commits. The current pretty-printer emits OpenCL-style memory spaces specifiers: __device, __constant, and __shared. The correct CUDA memory space specifiers are:

[PATCH] D54257: [clang-tidy] **Prototype** use AllTUsExecutors

2018-11-08 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. Herald added subscribers: cfe-commits, mgrang, xazax.hun. Only works on StandaloneToolExecutor, crashes happen when running AllTUsExecutors with multithreads (I believe it is because ClangTidyContext is not threadsafe). // Restrict thread to 1. ./bin/clang-tidy

[PATCH] D53934: [clangd] Improve code completion for ObjC methods

2018-11-08 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. Thanks for fixing this! Comment at: unittests/clangd/CodeCompleteTests.cpp:2195 +TEST(CompletionTest, ObjectiveCMethodNoArguments) { + std::string Context = R"objc( +

[PATCH] D54141: [clang-tidy] add deduplication support for run-clang-tidy.py

2018-11-08 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. > Could you please explain your motivation of catching clang-tidy stdout? > `--export-fixes` emits everything of `diagnostic` to YAML even the > `diagnostic` doesn't have fixes. I guess the reason is that you want code > snippets that you could show to users? If so,

[PATCH] D51484: [OpenCL] Add support of cl_intel_device_side_avc_motion_estimation extension

2018-11-08 Thread Andrew Savonichev via Phabricator via cfe-commits
asavonic added a comment. Committed in r346392. Repository: rC Clang https://reviews.llvm.org/D51484 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D53457: clang-cl: Add "/clang:" pass-through arg support.

2018-11-08 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC346393: clang-cl: Add /clang: pass-through arg support. (authored by hans, committed by ). Repository: rC Clang https://reviews.llvm.org/D53457 Files: docs/UsersManual.rst

r346393 - clang-cl: Add "/clang:" pass-through arg support.

2018-11-08 Thread Hans Wennborg via cfe-commits
Author: hans Date: Thu Nov 8 03:27:04 2018 New Revision: 346393 URL: http://llvm.org/viewvc/llvm-project?rev=346393=rev Log: clang-cl: Add "/clang:" pass-through arg support. The clang-cl driver disables access to command line options outside of the "Core" and "CLOption" sets of command line

r346392 - [OpenCL] Add support of cl_intel_device_side_avc_motion_estimation extension

2018-11-08 Thread Andrew Savonichev via cfe-commits
Author: asavonic Date: Thu Nov 8 03:25:41 2018 New Revision: 346392 URL: http://llvm.org/viewvc/llvm-project?rev=346392=rev Log: [OpenCL] Add support of cl_intel_device_side_avc_motion_estimation extension Summary: Documentation can be found at

[PATCH] D53457: clang-cl: Add "/clang:" pass-through arg support.

2018-11-08 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In https://reviews.llvm.org/D53457#1291020, @neerajksingh wrote: > Reid, Hans, or someone else with commit access. If the revision looks good, > could you please submit to SVN? > > Any particular testing I should run beforehand? I ran the clang tests locally > on Windows.

[PATCH] D54253: [OpenCL][NFC] Improve test coverage of test/Index/opencl-types.cl

2018-11-08 Thread Andrew Savonichev via Phabricator via cfe-commits
asavonic added a comment. LGTM. Repository: rC Clang https://reviews.llvm.org/D54253 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D54253: [OpenCL][NFC] Improve test coverage of test/Index/opencl-types.cl

2018-11-08 Thread Alexey Sachkov via Phabricator via cfe-commits
AlexeySachkov created this revision. AlexeySachkov added reviewers: Anastasia, asavonic. Herald added subscribers: arphaman, yaxunl. The problem here is that test only checks default target. I recently introduced regression which wasn't detected by local testing: I missed that some declarations

  1   2   >