Re: [clang-tools-extra] r278198 - [Documentation] Fix spelling mistakes in docs/clang-tidy/index.rst.

2016-08-09 Thread Alexander Kornienko via cfe-commits
Thanks! Could you fix one more nit below? On Aug 10, 2016 04:03, "Eugene Zelenko via cfe-commits" < cfe-commits@lists.llvm.org> wrote: Author: eugenezelenko Date: Tue Aug 9 20:55:51 2016 New Revision: 278198 URL: http://llvm.org/viewvc/llvm-project?rev=278198&view=rev Log: [Documentation] Fix s

Re: r266719 - Warn if function or variable cannot be implicitly instantiated

2016-08-09 Thread Sean Silva via cfe-commits
On Tue, Aug 9, 2016 at 9:18 AM, Serge Pavlov wrote: > Whether enable this warning or not should be determined by user feedback. > The warning was implemented to help users in complicated cases that arise > in module-enabled builds. It seems however that it makes troubles for other > users. Based

Re: [PATCH] D23167: emit_DW_AT_noreturn flag

2016-08-09 Thread Victor via cfe-commits
vleschuk added a comment. In https://reviews.llvm.org/D23167#510485, @aprantl wrote: > Did you forget to add the IR test before uploading the patch? Could you please clarify, what do you mean? All the IR tests are here now. https://reviews.llvm.org/D23167 __

Re: [PATCH] D23167: emit_DW_AT_noreturn flag

2016-08-09 Thread Victor via cfe-commits
vleschuk updated this revision to Diff 67462. vleschuk added a comment. Stripped more unnecessary code. And cosmetics: trailing spaces. https://reviews.llvm.org/D23167 Files: include/llvm/IR/DebugInfoFlags.def include/llvm/IR/DebugInfoMetadata.h include/llvm/Support/Dwarf.h lib/CodeGen/

Re: [PATCH] D23343: [clang-tidy] modernize-make-{smart_ptr} private ctor bugfix

2016-08-09 Thread Piotr Padlewski via cfe-commits
Prazek updated this revision to Diff 67460. Prazek added a comment. I hate it when arc do this thing. When origin/master is not the trunk... https://reviews.llvm.org/D23343 Files: clang-tidy/modernize/MakeSmartPtrCheck.cpp docs/ReleaseNotes.rst test/clang-tidy/modernize-make-shared.cpp

[PATCH] D23343: [clang-tidy] modernize-make-{smart_ptr} private ctor bugfix

2016-08-09 Thread Piotr Padlewski via cfe-commits
Prazek created this revision. Prazek added reviewers: alexfh, aaron.ballman, hokein. Prazek added a subscriber: cfe-commits. Bugfix for 27321. When the constructor of stored pointer type is private then it is invalid to change it to make_shared or make_unique. https://reviews.llvm.org/D23343 Fil

Re: [PATCH] D22227: [ubsan] Disable bounds-check for flexible array ivars

2016-08-09 Thread Vedant Kumar via cfe-commits
vsk added a comment. Ping. https://reviews.llvm.org/D7 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D21695: [clang] Version support for UBSan handlers

2016-08-09 Thread Vedant Kumar via cfe-commits
vsk added a subscriber: vsk. vsk added a comment. After reading through the discussion in https://reviews.llvm.org/D19668, I don't think I understood the pros/cons of using a single ABI check (like asan does) versus adding version numbers to each handler routine. With the latter approach, would

[clang-tools-extra] r278198 - [Documentation] Fix spelling mistakes in docs/clang-tidy/index.rst.

2016-08-09 Thread Eugene Zelenko via cfe-commits
Author: eugenezelenko Date: Tue Aug 9 20:55:51 2016 New Revision: 278198 URL: http://llvm.org/viewvc/llvm-project?rev=278198&view=rev Log: [Documentation] Fix spelling mistakes in docs/clang-tidy/index.rst. Modified: clang-tools-extra/trunk/docs/clang-tidy/index.rst Modified: clang-tools-ex

Re: [libcxx] r278191 - test/hard_link_count(): Fix test on darwin

2016-08-09 Thread Bruno Cardoso Lopes via cfe-commits
Thanks Matthias! On Tue, Aug 9, 2016 at 6:02 PM, Matthias Braun via cfe-commits wrote: > Author: matze > Date: Tue Aug 9 20:02:28 2016 > New Revision: 278191 > > URL: http://llvm.org/viewvc/llvm-project?rev=278191&view=rev > Log: > test/hard_link_count(): Fix test on darwin > > The hard link cou

Re: [PATCH] D23239: [CUDA] Add __device__ overloads for placement new and delete.

2016-08-09 Thread Justin Lebar via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278194: [CUDA] Add __device__ overloads for placement new and delete. (authored by jlebar). Changed prior to commit: https://reviews.llvm.org/D23239?vs=67282&id=67447#toc Repository: rL LLVM https:/

Re: [PATCH] D23240: [CUDA] Print a "previous-decl" note when calling an illegal member fn.

2016-08-09 Thread Justin Lebar via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278195: [CUDA] Print a "previous-decl" note when calling an illegal member fn. (authored by jlebar). Changed prior to commit: https://reviews.llvm.org/D23240?vs=67081&id=67448#toc Repository: rL LLVM

Re: [PATCH] D23335: [CUDA] Reject calls to __device__ functions from host variable global initializers.

2016-08-09 Thread Justin Lebar via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278196: [CUDA] Reject calls to __device__ functions from host variable global… (authored by jlebar). Changed prior to commit: https://reviews.llvm.org/D23335?vs=67435&id=67449#toc Repository: rL LLVM

r278196 - [CUDA] Reject calls to __device__ functions from host variable global initializers.

2016-08-09 Thread Justin Lebar via cfe-commits
Author: jlebar Date: Tue Aug 9 20:09:21 2016 New Revision: 278196 URL: http://llvm.org/viewvc/llvm-project?rev=278196&view=rev Log: [CUDA] Reject calls to __device__ functions from host variable global initializers. Reviewers: tra Subscribers: cfe-commits Differential Revision: https://review

r278193 - [CUDA] Rename CheckCUDATarget to IsAllowedCUDACall. NFC

2016-08-09 Thread Justin Lebar via cfe-commits
Author: jlebar Date: Tue Aug 9 20:09:11 2016 New Revision: 278193 URL: http://llvm.org/viewvc/llvm-project?rev=278193&view=rev Log: [CUDA] Rename CheckCUDATarget to IsAllowedCUDACall. NFC Summary: I want to reuse "CheckCUDAFoo" in a later patch. Also, I think IsAllowedCUDACall gets the point ac

r278192 - [Diag] Fix idiom in comment: "on the lam", not "on the lamb".

2016-08-09 Thread Justin Lebar via cfe-commits
Author: jlebar Date: Tue Aug 9 20:09:07 2016 New Revision: 278192 URL: http://llvm.org/viewvc/llvm-project?rev=278192&view=rev Log: [Diag] Fix idiom in comment: "on the lam", not "on the lamb". Modified: cfe/trunk/lib/Basic/Diagnostic.cpp Modified: cfe/trunk/lib/Basic/Diagnostic.cpp URL: h

r278194 - [CUDA] Add __device__ overloads for placement new and delete.

2016-08-09 Thread Justin Lebar via cfe-commits
Author: jlebar Date: Tue Aug 9 20:09:14 2016 New Revision: 278194 URL: http://llvm.org/viewvc/llvm-project?rev=278194&view=rev Log: [CUDA] Add __device__ overloads for placement new and delete. Summary: Previously these sort of worked because they didn't end up resulting in calls at the ptx laye

r278195 - [CUDA] Print a "previous-decl" note when calling an illegal member fn.

2016-08-09 Thread Justin Lebar via cfe-commits
Author: jlebar Date: Tue Aug 9 20:09:18 2016 New Revision: 278195 URL: http://llvm.org/viewvc/llvm-project?rev=278195&view=rev Log: [CUDA] Print a "previous-decl" note when calling an illegal member fn. Summary: When we emit err_ref_bad_target, we should emit a "'method' declared here" note. We

Re: [PATCH] D23238: [CUDA] Rename CheckCUDATarget to IsAllowedCUDACall. NFC

2016-08-09 Thread Justin Lebar via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278193: [CUDA] Rename CheckCUDATarget to IsAllowedCUDACall. NFC (authored by jlebar). Changed prior to commit: https://reviews.llvm.org/D23238?vs=67079&id=67446#toc Repository: rL LLVM https://revie

[libcxx] r278191 - test/hard_link_count(): Fix test on darwin

2016-08-09 Thread Matthias Braun via cfe-commits
Author: matze Date: Tue Aug 9 20:02:28 2016 New Revision: 278191 URL: http://llvm.org/viewvc/llvm-project?rev=278191&view=rev Log: test/hard_link_count(): Fix test on darwin The hard link count that stat reports are different between normal hfs and the case sensitive variant. Accept both. Modif

r278183 - [CUDA] Minor comment nits.

2016-08-09 Thread Justin Lebar via cfe-commits
Author: jlebar Date: Tue Aug 9 19:40:43 2016 New Revision: 278183 URL: http://llvm.org/viewvc/llvm-project?rev=278183&view=rev Log: [CUDA] Minor comment nits. Modified: cfe/trunk/lib/Sema/SemaOverload.cpp Modified: cfe/trunk/lib/Sema/SemaOverload.cpp URL: http://llvm.org/viewvc/llvm-projec

r278184 - [CUDA] Fix out-of-date comment.

2016-08-09 Thread Justin Lebar via cfe-commits
Author: jlebar Date: Tue Aug 9 19:40:46 2016 New Revision: 278184 URL: http://llvm.org/viewvc/llvm-project?rev=278184&view=rev Log: [CUDA] Fix out-of-date comment. LangOpts.CUDADisableTargetCallChecks no longer exists (it's effectively always true now). Modified: cfe/trunk/include/clang/Sem

Re: [PATCH] D22476: [AST] Make MemberExpr non-dependent according to core issue 224

2016-08-09 Thread Richard Smith via cfe-commits
rsmith added inline comments. Comment at: lib/AST/Expr.cpp:1413 @@ +1412,3 @@ +for (auto *EnableIf : Method->specific_attrs()) { + if (EnableIf->getCond()->isTypeDependent()) +return false; You should presumably be checking `isValueDependent` here

[PATCH] D23341: [CUDA] Include CUDA headers before anything else.

2016-08-09 Thread Justin Lebar via cfe-commits
jlebar created this revision. jlebar added a reviewer: tra. jlebar added subscribers: Prazek, cfe-commits. There's no point to --cuda-path if we then go and include /usr/include first. And if you install the right packages, Ubuntu will install (very old) CUDA headers there. https://reviews.llvm.

[PATCH] D23340: [CUDA] Fix CUDA install version parsing.

2016-08-09 Thread Justin Lebar via cfe-commits
jlebar created this revision. jlebar added a reviewer: tra. jlebar added subscribers: Prazek, cfe-commits. getAsInteger returns true on error. Oops. No test because the behavior at the moment is identical with or without this change. https://reviews.llvm.org/D23340 Files: clang/lib/Driver/To

Modify MallocChecker.cpp to recognize kfree( )

2016-08-09 Thread Andrew Wells via cfe-commits
This is my first commit, so my apologies if I did anything wrong. It adds kfree( ) to MallocChecker.cpp and changes the kmalloc-linuxs.c to test this change appropriately. Index: MallocChecker.cpp === --- MallocChecker.cpp (revision 2

Re: [PATCH] D22587: [ASTContext] Fix part of DR224 for nontype template arguments

2016-08-09 Thread Richard Smith via cfe-commits
rsmith added a comment. Discussion on the core reflector suggests that we should use odr-style equivalence when identifying the current instantiation, and not look through static const member initializers as the example in the standard suggests. Let's hold off on this until CWG has a chance to

Re: [PATCH] D23335: [CUDA] Reject calls to __device__ functions from host variable global initializers.

2016-08-09 Thread Justin Lebar via cfe-commits
jlebar updated this revision to Diff 67435. jlebar marked an inline comment as done. jlebar added a comment. Test tweak per review. https://reviews.llvm.org/D23335 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/lib/Sema/SemaDecl.cpp clang/test/SemaCUDA/global-initializers-h

Re: [PATCH] D23335: [CUDA] Reject calls to __device__ functions from host variable global initializers.

2016-08-09 Thread Justin Lebar via cfe-commits
jlebar added inline comments. Comment at: clang/test/SemaCUDA/global-initializers-host.cu:2 @@ +1,3 @@ +// RUN: %clang_cc1 %s --std=c++11 -triple x86_64-linux-unknown -emit-llvm -o - -verify + +#include "Inputs/cuda.h" tra wrote: > I'd add the same comment as in

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

2016-08-09 Thread Richard Smith via cfe-commits
rsmith added inline comments. Comment at: lib/Frontend/CompilerInstance.cpp:1483 @@ +1482,3 @@ + HSOpts.ModulesUsePrebuiltModules ? + ASTReader::ARR_ConfigurationMismatch : + ARRF

Re: [PATCH] D22725: [clang-tidy] Add check 'modernize-use-algorithm'

2016-08-09 Thread Piotr Padlewski via cfe-commits
2016-08-09 5:49 GMT-07:00 Aaron Ballman : > > I think this boils down to personal preference, which is why I'm > concerned about the check. Either mechanism is correct, so this is > purely a stylistic check in many regards. > > About warnings - well, if someone choose this check to be run, then he

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

2016-08-09 Thread Richard Smith via cfe-commits
rsmith added a subscriber: rsmith. rsmith added a comment. This doesn't seem like quite the right user interface for this feature. The module cache is volatile, and it's not really reasonable for people to assume they know what is and isn't within it. Instead, it seems like what we want to prov

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

2016-08-09 Thread Manman Ren via cfe-commits
manmanren added a comment. In https://reviews.llvm.org/D23125#504942, @benlangmuir wrote: > How about -fmodules-use-prebuilt-**module-cache** for the flag name? Saying > "prebuilt-modules" is confusing to me, since -fmodule-file can also be used > to load a prebuilt module, but doesn't use a

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

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

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

2016-08-09 Thread Manman Ren via cfe-commits
manmanren updated this revision to Diff 67431. manmanren added a comment. Add comments for setting IsSystem to true. https://reviews.llvm.org/D23125 Files: include/clang/Basic/DiagnosticDriverKinds.td include/clang/Driver/Options.td include/clang/Lex/HeaderSearchOptions.h lib/Driver/Too

Re: [PATCH] D23335: [CUDA] Reject calls to __device__ functions from host variable global initializers.

2016-08-09 Thread Artem Belevich via cfe-commits
tra accepted this revision. tra added a comment. This revision is now accepted and ready to land. LGTM. Comment at: clang/test/SemaCUDA/global-initializers-host.cu:2 @@ +1,3 @@ +// RUN: %clang_cc1 %s --std=c++11 -triple x86_64-linux-unknown -emit-llvm -o - -verify + +#include "

[PATCH] D23335: [CUDA] Reject calls to __device__ functions from host variable global initializers.

2016-08-09 Thread Justin Lebar via cfe-commits
jlebar created this revision. jlebar added a reviewer: tra. jlebar added a subscriber: cfe-commits. https://reviews.llvm.org/D23335 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/lib/Sema/SemaDecl.cpp clang/test/SemaCUDA/call-device-fn-from-host.cu clang/test/SemaCUDA/globa

Re: [PATCH] D23242: [CUDA] Raise an error if a wrong-side call is codegen'ed.

2016-08-09 Thread Justin Lebar via cfe-commits
jlebar added a comment. > Hm, these seem completely broken, before and after this patch. I'll handle it > separately if that's OK. https://reviews.llvm.org/D23335. The device side equivalent works afaict (and is very well-tested). https://reviews.llvm.org/D23242 _

Re: [PATCH] D23167: emit_DW_AT_noreturn flag

2016-08-09 Thread Adrian Prantl via cfe-commits
aprantl added a comment. Did you forget to add the IR test before uploading the patch? https://reviews.llvm.org/D23167 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libcxxabi] r278169 - Depend directly on unwind when not building standalone

2016-08-09 Thread Petr Hosek via cfe-commits
Author: phosek Date: Tue Aug 9 16:28:52 2016 New Revision: 278169 URL: http://llvm.org/viewvc/llvm-project?rev=278169&view=rev Log: Depend directly on unwind when not building standalone When using libunwind and not building as standalone project, we can directly depend on the unwind library tar

Re: [PATCH] D23167: emit_DW_AT_noreturn flag

2016-08-09 Thread Victor via cfe-commits
vleschuk added a comment. Could somebody commit this, please? I do not have the commit permissions yet. https://reviews.llvm.org/D23167 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

Re: [PATCH] D23167: emit_DW_AT_noreturn flag

2016-08-09 Thread Victor via cfe-commits
vleschuk added a comment. In https://reviews.llvm.org/D23167#510379, @aprantl wrote: > Found one more. Done Comment at: include/llvm/IR/DebugInfoMetadata.h:1424 @@ +1423,3 @@ + /// + /// Return true if this subprogram is C++11 noreturn or C11 _Noreturn + unsigned isNoRetur

Re: [PATCH] D23167: emit_DW_AT_noreturn flag

2016-08-09 Thread Victor via cfe-commits
vleschuk updated this revision to Diff 67410. vleschuk added a comment. Added more tests https://reviews.llvm.org/D23167 Files: include/llvm/IR/DebugInfoFlags.def include/llvm/IR/DebugInfoMetadata.h include/llvm/Support/Dwarf.h lib/CodeGen/AsmPrinter/DwarfUnit.cpp lib/Support/Dwarf.cp

Re: [PATCH] D23316: [analyzer] Fixed the false-positives caused by macro generated code.

2016-08-09 Thread Vassil Vassilev via cfe-commits
v.g.vassilev added inline comments. Comment at: lib/Analysis/CloneDetection.cpp:431 @@ +430,3 @@ +// level of it's containing clone. This prevents false-positives caused by +// complex macros. For example 'assert(false)' could be reported as a clone +// if the assert m

Re: [PATCH] D23218: [ADT] Change iterator_adaptor_base's default template arguments to forward more underlying typedefs

2016-08-09 Thread Tim Shen via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278156: [ADT] Change iterator_adaptor_base's default template arguments to forward… (authored by timshen). Changed prior to commit: https://reviews.llvm.org/D23218?vs=66984&id=67408#toc Repository: r

r278156 - [ADT] Change iterator_adaptor_base's default template arguments to forward more underlying typedefs

2016-08-09 Thread Tim Shen via cfe-commits
Author: timshen Date: Tue Aug 9 15:22:55 2016 New Revision: 278156 URL: http://llvm.org/viewvc/llvm-project?rev=278156&view=rev Log: [ADT] Change iterator_adaptor_base's default template arguments to forward more underlying typedefs Summary: The corresponding LLVM change: D23217. LazyVector::i

Re: [PATCH] D22587: [ASTContext] Fix part of DR224 for nontype template arguments

2016-08-09 Thread Matthias Gehre via cfe-commits
mgehre added a comment. ping https://reviews.llvm.org/D22587 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D22476: [AST] Make MemberExpr non-dependent according to core issue 224

2016-08-09 Thread Matthias Gehre via cfe-commits
mgehre added a comment. ping https://reviews.llvm.org/D22476 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D23314: [analyzer] CloneDetector allows comparing clones for suspicious variable pattern errors.

2016-08-09 Thread Vassil Vassilev via cfe-commits
v.g.vassilev requested changes to this revision. This revision now requires changes to proceed. Comment at: lib/StaticAnalyzer/Checkers/CloneChecker.cpp:83 @@ +82,3 @@ +auto WarnID = DiagEngine.getCustomDiagID( +DiagnosticsEngine::Warning, "Maybe you wanted to use %0 h

Re: [PATCH] D22940: [OpenCL] Handle -cl-fp32-correctly-rounded-divide-sqrt

2016-08-09 Thread Yaxun Liu via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278155: [OpenCL] Handle -cl-fp32-correctly-rounded-divide-sqrt (authored by yaxunl). Changed prior to commit: https://reviews.llvm.org/D22940?vs=66002&id=67406#toc Repository: rL LLVM https://review

r278155 - [OpenCL] Handle -cl-fp32-correctly-rounded-divide-sqrt

2016-08-09 Thread Yaxun Liu via cfe-commits
Author: yaxunl Date: Tue Aug 9 15:10:18 2016 New Revision: 278155 URL: http://llvm.org/viewvc/llvm-project?rev=278155&view=rev Log: [OpenCL] Handle -cl-fp32-correctly-rounded-divide-sqrt Let the driver pass the option to frontend. Do not set precision metadata for division instructions when thi

Re: [PATCH] D23167: emit_DW_AT_noreturn flag

2016-08-09 Thread Adrian Prantl via cfe-commits
aprantl added a comment. Found one more. Comment at: test/DebugInfo/noreturn_c11.ll:10 @@ +9,3 @@ +; CHECK: DW_TAG_subprogram +; CHECK: DW_AT_noreturn + One more thing: please rewrite this (and the other testcases) as ``` ; CHECK: DW_TAG_subprogram ; CHECK-NOT

Re: [PATCH] D23167: emit_DW_AT_noreturn flag

2016-08-09 Thread Adrian Prantl via cfe-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. LGTM on the condition that the missing IR roundtrip test (e.g., by extending test/Assembler/disubprogram.ll) is added before committing. https://reviews.llvm.org/D23167 _

Re: [PATCH] D23167: emit_DW_AT_noreturn flag

2016-08-09 Thread Victor via cfe-commits
vleschuk updated this revision to Diff 67398. vleschuk marked 6 inline comments as done. vleschuk added a comment. Stripped unnecessary attributes, added more context to CHECK https://reviews.llvm.org/D23167 Files: include/llvm/IR/DebugInfoFlags.def include/llvm/IR/DebugInfoMetadata.h inc

Re: [PATCH] D22815: [OpenCL][AMDGPU] Add support for -cl-denorms-are-zero

2016-08-09 Thread Yaxun Liu via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278151: [OpenCL][AMDGPU] Add support for -cl-denorms-are-zero (authored by yaxunl). Changed prior to commit: https://reviews.llvm.org/D22815?vs=65533&id=67397#toc Repository: rL LLVM https://reviews

r278151 - [OpenCL][AMDGPU] Add support for -cl-denorms-are-zero

2016-08-09 Thread Yaxun Liu via cfe-commits
Author: yaxunl Date: Tue Aug 9 14:43:38 2016 New Revision: 278151 URL: http://llvm.org/viewvc/llvm-project?rev=278151&view=rev Log: [OpenCL][AMDGPU] Add support for -cl-denorms-are-zero Adjust target features for amdgcn target when -cl-denorms-are-zero is set. Denormal support is controlled by

[PATCH] D23331: Implement LWG 2148: Make non-enum default hash specialization well-formed

2016-08-09 Thread Eric Fiselier via cfe-commits
EricWF created this revision. EricWF added a reviewer: mclow.lists. EricWF added a subscriber: cfe-commits. This patch removes the static_assert for non-enum types in the primary hash template. Instead non-enum types create a hash specialization that is not constructible nor callable. See also:

r278148 - Add a missing -no-canonical-prefixes.

2016-08-09 Thread Benjamin Kramer via cfe-commits
Author: d0k Date: Tue Aug 9 14:20:25 2016 New Revision: 278148 URL: http://llvm.org/viewvc/llvm-project?rev=278148&view=rev Log: Add a missing -no-canonical-prefixes. Modified: cfe/trunk/test/Driver/cuda-detect.cu Modified: cfe/trunk/test/Driver/cuda-detect.cu URL: http://llvm.org/viewvc/l

Re: [libcxx] r278147 - Update in-tree Google Benchmark to current ToT.

2016-08-09 Thread Craig, Ben via cfe-commits
This is probably more of a comment on the compare_bench.py side of things, but here goes anyway... When comparing two results, both the percentage and absolute differences can be very important. It is very easy to be misled by percentages. It is harder to be misled with absolute differences.

Re: [PATCH] D22725: [clang-tidy] Add check 'modernize-use-algorithm'

2016-08-09 Thread Jonas Devlieghere via cfe-commits
JDevlieghere updated this revision to Diff 67391. JDevlieghere added a comment. Removed anonymous namespaces in test file. I was playing around with it but forgot to remove it before making my last diff. Repository: rL LLVM https://reviews.llvm.org/D22725 Files: clang-tidy/modernize/CMake

Re: [PATCH] D22725: [clang-tidy] Add check 'modernize-use-algorithm'

2016-08-09 Thread Jonas Devlieghere via cfe-commits
JDevlieghere updated this revision to Diff 67390. JDevlieghere marked 5 inline comments as done. JDevlieghere added a comment. Fixes issues raised by Alexander and Aaron Repository: rL LLVM https://reviews.llvm.org/D22725 Files: clang-tidy/modernize/CMakeLists.txt clang-tidy/modernize/Mo

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-09 Thread Alexander Kornienko via cfe-commits
alexfh added inline comments. Comment at: test/clang-tidy/readability-else-after-return.cpp:33 @@ -32,1 +32,3 @@ + // CHECK-MESSAGES: :[[@LINE-1]]:3: warning: do not use 'else' after 'return' + // CHECK-FIXES: // comment f(0); omtcyfz wrote: > alexfh wrote:

[libcxx] r278147 - Update in-tree Google Benchmark to current ToT.

2016-08-09 Thread Eric Fiselier via cfe-commits
Author: ericwf Date: Tue Aug 9 13:56:48 2016 New Revision: 278147 URL: http://llvm.org/viewvc/llvm-project?rev=278147&view=rev Log: Update in-tree Google Benchmark to current ToT. I've put some work into the Google Benchmark library in order to make it easier to benchmark libc++. These changes h

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-09 Thread Alexander Kornienko via cfe-commits
alexfh added inline comments. Comment at: clang-tidy/readability/ElseAfterReturnCheck.cpp:45 @@ +44,3 @@ + for (const auto &BindingName : + {"return", "continue", "break", "goto", "throw"}) { +if (Result.Nodes.getNodeAs(BindingName)) { omtcyfz wrote: >

Re: r277522 - [CFG] Fix crash finding destructor of lifetime-extended temporary.

2016-08-09 Thread Hans Wennborg via cfe-commits
For the record, this was for PR28666. Richard: what do you think about merging this to 3.9? On Tue, Aug 2, 2016 at 2:07 PM, Devin Coughlin via cfe-commits wrote: > Author: dcoughlin > Date: Tue Aug 2 16:07:23 2016 > New Revision: 277522 > > URL: http://llvm.org/viewvc/llvm-project?rev=277522&vi

Re: [PATCH] D23198: clang-rename rename-all: support reading old/newname pairs from a YAML file

2016-08-09 Thread Alexander Kornienko via cfe-commits
alexfh added a subscriber: alexfh. alexfh added a comment. A few late comments. Comment at: clang-tools-extra/trunk/clang-rename/tool/ClangRename.cpp:65 @@ +64,3 @@ + + RenameAllInfo() : Offset(0) {} +}; I'd use inline inititalizer instead. Co

Re: [PATCH] D23329: [NFC] Reducing allocations in AST attributes

2016-08-09 Thread Eugene via cfe-commits
kevgs added a comment. Btw, ConstAttrVec is never used. https://reviews.llvm.org/D23329 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D23329: [NFC] Reducing allocations in AST attributes

2016-08-09 Thread Eugene via cfe-commits
kevgs added a comment. My test case is: clang++ -std=c++14 -fsyntax-only test.cc #include #include #include int main() { std::vector v = {1, 2, 3}; std::for_each(v.begin(), v.end(), [](auto i) { std::cout << i; }); return 0; } https://reviews.llvm.org/D23329 _

[PATCH] D23329: [NFC] Reducing allocations in AST attributes

2016-08-09 Thread Eugene via cfe-commits
kevgs created this revision. kevgs added reviewers: rsmith, bkramer. kevgs added a subscriber: cfe-commits. In my test case max resident memory changed from 65760k to 64476k which is 1.9% improvement. Allocations in grow_pod changed from 8847 to 4872 according to tcmalloc heap profiler. Overa

Re: [PATCH] D23279: clang-reorder-fields

2016-08-09 Thread Alexander Shaposhnikov via cfe-commits
alexshap added a comment. > I do think that an automated tool will do a better job of changing field > orderings in a non-breaking way than most people would, mostly due to > initializer lists. yeah, that was the original motivation Repository: rL LLVM https://reviews.llvm.org/D23279 _

Re: [PATCH] D23198: clang-rename rename-all: support reading old/newname pairs from a YAML file

2016-08-09 Thread Miklos Vajna via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL278145: clang-rename rename-all: support reading old/newname pairs from a YAML file (authored by vmiklos). Changed prior to commit: https://reviews.llvm.org/D23198?vs=67215&id=67381#toc Repository: r

[clang-tools-extra] r278145 - clang-rename rename-all: support reading old/newname pairs from a YAML file

2016-08-09 Thread Miklos Vajna via cfe-commits
Author: vmiklos Date: Tue Aug 9 13:20:41 2016 New Revision: 278145 URL: http://llvm.org/viewvc/llvm-project?rev=278145&view=rev Log: clang-rename rename-all: support reading old/newname pairs from a YAML file This is handy in case by the time clang-rename is invoked, an external tool already gen

Re: [PATCH] D22900: Revert r244207 - Mark calls in thunk functions as tail-call optimization

2016-08-09 Thread Nick Lewycky via cfe-commits
nlewycky added a comment. For the IR level, I think this has got to be valid: declare void @bar(i32* byval %p) define void @foo(i32* byval %p) { tail call void @bar(i32* byval %p.tmp) ret void } The `tail` is an aliasing property which indicates that the callee doesn't touch any o

Re: [PATCH] D23284: Add -Rpass-with-hotness

2016-08-09 Thread Adam Nemet via cfe-commits
anemet added reviewers: dnovillo, rsmith. anemet marked an inline comment as done. anemet added subscribers: dnovillo, rsmith. anemet added a comment. Add more reviewers suggested by Aaron. @dnovillo, @rsmith, is my thinking correct that this new flag does not belong to the R_Group. https://re

Re: [PATCH] D23198: clang-rename rename-all: support reading old/newname pairs from a YAML file

2016-08-09 Thread Miklos Vajna via cfe-commits
vmiklos added inline comments. Comment at: clang-rename/tool/ClangRename.cpp:65 @@ +64,3 @@ + + RenameAllInfo() : Offset(0) {} +}; omtcyfz wrote: > omtcyfz wrote: > > vmiklos wrote: > > > omtcyfz wrote: > > > > AFAIK there's no need to do that, integer types are

Re: [PATCH] D23279: clang-reorder-fields

2016-08-09 Thread Ben Craig via cfe-commits
bcraig added a comment. In https://reviews.llvm.org/D23279#510178, @omtcyfz wrote: > In https://reviews.llvm.org/D23279#510167, @alexshap wrote: > > > my point is the following: this tool helps perform some operation (changing > > the order of fields), > > if smb decides to do it manually - th

Re: [PATCH] D23284: Add -Rpass-with-hotness

2016-08-09 Thread Adam Nemet via cfe-commits
anemet updated this revision to Diff 67379. anemet added a comment. Address Aaron's comment https://reviews.llvm.org/D23284 Files: include/clang/Basic/DiagnosticDriverKinds.td include/clang/Driver/Options.td include/clang/Frontend/CodeGenOptions.def lib/CodeGen/CodeGenAction.cpp lib/F

Re: [PATCH] D23242: [CUDA] Raise an error if a wrong-side call is codegen'ed.

2016-08-09 Thread Justin Lebar via cfe-commits
jlebar updated this revision to Diff 67378. jlebar added a comment. Address review comments. Also swap the two tests -- I had the wrong names on them. https://reviews.llvm.org/D23242 Files: clang/include/clang/Sema/Sema.h clang/lib/Sema/SemaCUDA.cpp clang/lib/Sema/SemaDeclCXX.cpp clang

Re: [PATCH] D23279: clang-reorder-fields

2016-08-09 Thread Kirill Bobyrev via cfe-commits
omtcyfz added a comment. In https://reviews.llvm.org/D23279#510167, @alexshap wrote: > my point is the following: this tool helps perform some operation (changing > the order of fields), > if smb decides to do it manually - the result will have exactly the same > issue. While creating tools

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-09 Thread Kirill Bobyrev via cfe-commits
omtcyfz added inline comments. Comment at: clang-tidy/readability/ElseAfterReturnCheck.cpp:45 @@ +44,3 @@ + for (const auto &BindingName : + {"return", "continue", "break", "goto", "throw"}) { +if (Result.Nodes.getNodeAs(BindingName)) { aaron.ballman wr

Re: [PATCH] D22130: Link static PIE programs against rcrt0.o on OpenBSD

2016-08-09 Thread Stefan Kempf via cfe-commits
sisnkemp added a comment. Ping? https://reviews.llvm.org/D22130 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-09 Thread Aaron Ballman via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/readability/ElseAfterReturnCheck.cpp:45 @@ +44,3 @@ + for (const auto &BindingName : + {"return", "continue", "break", "goto", "throw"}) { +if (Result.Nodes.getNodeAs(BindingName)) { omtcyfz wr

Re: [PATCH] D23279: clang-reorder-fields

2016-08-09 Thread Alexander Shaposhnikov via cfe-commits
alexshap added a comment. my point is the following: this tool helps perform some operation (changing the order of fields), if smb decides to do it manually - the result will have exactly the same issue. Repository: rL LLVM https://reviews.llvm.org/D23279

Re: [PATCH] D23279: clang-reorder-fields

2016-08-09 Thread Kirill Bobyrev via cfe-commits
omtcyfz added a comment. In https://reviews.llvm.org/D23279#510157, @alexshap wrote: > The difference is that if we reorder fields the new struct is not > binary-compatible with the old one. Exactly. If both libraries are in your project, it becomes broken. Repository: rL LLVM https://rev

Re: [PATCH] D23242: [CUDA] Raise an error if a wrong-side call is codegen'ed.

2016-08-09 Thread Justin Lebar via cfe-commits
jlebar marked 3 inline comments as done. jlebar added a comment. > Should be add few tests for calling device functions from host-side global > initializers? Perhaps for device->host, too, as there may be unexpected > interplay with constructor emptiness checks. Hm, these seem completely broke

Re: [PATCH] D23279: clang-reorder-fields

2016-08-09 Thread Alexander Shaposhnikov via cfe-commits
alexshap added a comment. The difference is that if we reorder fields the new struct is not binary-compatible with the old one. Repository: rL LLVM https://reviews.llvm.org/D23279 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://li

Re: [PATCH] D23279: clang-reorder-fields

2016-08-09 Thread Kirill Bobyrev via cfe-commits
omtcyfz added a comment. In https://reviews.llvm.org/D23279#510147, @alexshap wrote: > Suppose you have a struct Foo defined in LibA and you have used clang-rename > to rename Foo into Bar (or just a field of Foo say - you have renamed Foo::x > into Foo::y); LibA is linked to LibB and you have

Re: [PATCH] D23279: clang-reorder-fields

2016-08-09 Thread Alexander Shaposhnikov via cfe-commits
alexshap added a comment. Suppose you have a struct Foo defined in LibA and you have used clang-rename to rename Foo into Bar (or just a field of Foo say - you have renamed Foo::x into Foo::y); LibA is linked to LibB and you have Foo foo = { &x, 17, 1.29, 0 }; in LibB. Therefore LibA knows noth

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-09 Thread Kirill Bobyrev via cfe-commits
omtcyfz added inline comments. Comment at: clang-tidy/readability/ElseAfterReturnCheck.cpp:45 @@ +44,3 @@ + for (const auto &BindingName : + {"return", "continue", "break", "goto", "throw"}) { +if (Result.Nodes.getNodeAs(BindingName)) { aaron.ballman wr

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-09 Thread Aaron Ballman via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/readability/ElseAfterReturnCheck.cpp:45 @@ +44,3 @@ + for (const auto &BindingName : + {"return", "continue", "break", "goto", "throw"}) { +if (Result.Nodes.getNodeAs(BindingName)) { omtcyfz wr

Re: [PATCH] D23265: [clang-tidy] enhance readability-else-after-return

2016-08-09 Thread Kirill Bobyrev via cfe-commits
omtcyfz added inline comments. Comment at: clang-tidy/readability/ElseAfterReturnCheck.cpp:45 @@ +44,3 @@ + for (const auto &BindingName : + {"return", "continue", "break", "goto", "throw"}) { +if (Result.Nodes.getNodeAs(BindingName)) { alexfh wrote: >

Re: [PATCH] D23279: clang-reorder-fields

2016-08-09 Thread Kirill Bobyrev via cfe-commits
omtcyfz added a comment. In https://reviews.llvm.org/D23279#510129, @alexshap wrote: > Regarding TUs - i am aware of that - would be useful if you could provide a > test which doesn't work - that would help us avoid miscommunication. Thanks. Suppose you have a `struct Foo` defined in `LibA` an

r278140 - [CUDA] Regression test to make sure C++ include path are forwarded to host and device frontends.

2016-08-09 Thread Samuel Antao via cfe-commits
Author: sfantao Date: Tue Aug 9 12:27:24 2016 New Revision: 278140 URL: http://llvm.org/viewvc/llvm-project?rev=278140&view=rev Log: [CUDA] Regression test to make sure C++ include path are forwarded to host and device frontends. Summary: Add test to detect the C++ include paths are passed to b

Re: [PATCH] D23279: clang-reorder-fields

2016-08-09 Thread Alexander Shaposhnikov via cfe-commits
alexshap added a comment. Regarding TUs - i am aware of that - would be useful if you could provide a test which doesn't work - that would help us avoid miscommunication. Thanks. Repository: rL LLVM https://reviews.llvm.org/D23279 ___ cfe-commit

r278139 - [clang-cl] Make -gline-tables-only imply -gcodeview

2016-08-09 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Tue Aug 9 12:23:56 2016 New Revision: 278139 URL: http://llvm.org/viewvc/llvm-project?rev=278139&view=rev Log: [clang-cl] Make -gline-tables-only imply -gcodeview It's surprising that you have to pass /Z7 in addition to -gcodeview to get debug info. The sanitizer runtime, for e

Re: [PATCH] D22946: [CUDA] Regression test to make sure C++ include path are forwarded to host and device frontends.

2016-08-09 Thread Artem Belevich via cfe-commits
tra accepted this revision. tra added a comment. This revision is now accepted and ready to land. LGTM. https://reviews.llvm.org/D22946 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

Re: [PATCH] D23279: clang-reorder-fields

2016-08-09 Thread Kirill Bobyrev via cfe-commits
omtcyfz added a comment. In https://reviews.llvm.org/D23279#510061, @alexshap wrote: > First of all, many thanks for the comments & proposal of clang-refactor. > > 1. Regarding high-level project organization: clang-refactor - that can be a > good place for various refactoring techniques like th

Re: [PATCH] D23241: Add the notion of deferred diagnostics.

2016-08-09 Thread Justin Lebar via cfe-commits
jlebar added a comment. Reid, I'd still like you to have a look at this one if you don't mind, since it's outside my and Art's core competencies. Comment at: clang/lib/CodeGen/CodeGenModule.cpp:2886 @@ +2885,3 @@ + // Check if this function has diagnostics that should be emitt

Re: [PATCH] D23241: Add the notion of deferred diagnostics.

2016-08-09 Thread Justin Lebar via cfe-commits
jlebar updated this revision to Diff 67367. jlebar marked an inline comment as done. jlebar added a comment. Address review comments, and don't abort codegen'ing a function if it has only deferred warnings -- check specifically for errors. https://reviews.llvm.org/D23241 Files: clang/include/

Re: [PATCH] D22946: [CUDA] Regression test to make sure C++ include path are forwarded to host and device frontends.

2016-08-09 Thread Samuel Antao via cfe-commits
sfantao added inline comments. Comment at: test/Driver/cuda-detect.cu:75-77 @@ -74,1 +74,5 @@ +// Verify that compiler accepts CUDA syntax with "-x cuda-cpp-output". +// RUN: %clang -Werror -fsyntax-only -x cuda-cpp-output -c %s +// +// Verify that C++ include paths are passed f

  1   2   >