[PATCH] D39665: Support __has_c_attribute

2017-12-07 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman closed this revision. aaron.ballman added a comment. Commit in r320088. https://reviews.llvm.org/D39665 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r320091 - [Analysis] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC).

2017-12-07 Thread Eugene Zelenko via cfe-commits
Author: eugenezelenko Date: Thu Dec 7 13:55:09 2017 New Revision: 320091 URL: http://llvm.org/viewvc/llvm-project?rev=320091=rev Log: [Analysis] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). Modified: cfe/trunk/include/clang/Analysis/CFG.h

Re: r320089 - Add new language mode flags for C17.

2017-12-07 Thread Ahmed Bougacha via cfe-commits
On Thu, Dec 7, 2017 at 3:05 PM, Aaron Ballman wrote: > On Thu, Dec 7, 2017 at 6:00 PM, Aaron Ballman wrote: >> On Thu, Dec 7, 2017 at 5:59 PM, Ahmed Bougacha >> wrote: >>> On Thu, Dec 7, 2017 at 2:56 PM, Richard Smith

[PATCH] D40668: [Blocks] Inherit sanitizer options from parent decl

2017-12-07 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. Friendly ping. https://reviews.llvm.org/D40668 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: r315996 - [CMake][OpenMP] Customize default offloading arch

2017-12-07 Thread Jonas Hahnfeld via cfe-commits
Hi Ahmed, Am 2017-12-07 19:57, schrieb Ahmed Bougacha: Hi Jonas, On Tue, Oct 17, 2017 at 6:37 AM, Jonas Hahnfeld via cfe-commits wrote: Author: hahnfeld Date: Tue Oct 17 06:37:36 2017 New Revision: 315996 URL: http://llvm.org/viewvc/llvm-project?rev=315996=rev

Re: r315996 - [CMake][OpenMP] Customize default offloading arch

2017-12-07 Thread Jonas Hahnfeld via cfe-commits
Am 2017-12-07 20:34, schrieb Jonas Hahnfeld via cfe-commits: Hi Ahmed, Am 2017-12-07 19:57, schrieb Ahmed Bougacha: Hi Jonas, On Tue, Oct 17, 2017 at 6:37 AM, Jonas Hahnfeld via cfe-commits wrote: Author: hahnfeld Date: Tue Oct 17 06:37:36 2017 New Revision:

r320089 - Add new language mode flags for C17.

2017-12-07 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Thu Dec 7 13:46:26 2017 New Revision: 320089 URL: http://llvm.org/viewvc/llvm-project?rev=320089=rev Log: Add new language mode flags for C17. This adds -std=c17, -std=gnu17, and -std=iso9899:2017 as language mode flags for C17 and updates the value of

[PATCH] D40983: Generate Libclang invocation reproducers using a new -cc1gen-reproducer option

2017-12-07 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. Herald added a subscriber: mgorny. This patch is a follow up to the previous work that recorded Libclang invocations into temporary files: https://reviews.llvm.org/D40527. It adds a new -cc1 mode to clang: `-cc1gen-reproducer`. The goal of this mode is to

[PATCH] D40218: [Clang] Add __builtin_launder

2017-12-07 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: lib/CodeGen/CGBuiltin.cpp:1674 +Value *Ptr = EmitScalarExpr(E->getArg(0)); +Ptr = Builder.CreateInvariantGroupBarrier(Ptr); +return RValue::get(Ptr); It would be nice to avoid this for types that contain no

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-07 Thread Anton via Phabricator via cfe-commits
xgsa updated this revision to Diff 126058. xgsa added a comment. Documentation update https://reviews.llvm.org/D40671 Files: clang-tidy/ClangTidyDiagnosticConsumer.cpp docs/ReleaseNotes.rst docs/clang-tidy/index.rst test/clang-tidy/nolint.cpp test/clang-tidy/nolintnextline.cpp

r320122 - Unify implementation of our two different flavours of -Wtautological-compare.

2017-12-07 Thread Richard Smith via cfe-commits
Author: rsmith Date: Thu Dec 7 16:45:25 2017 New Revision: 320122 URL: http://llvm.org/viewvc/llvm-project?rev=320122=rev Log: Unify implementation of our two different flavours of -Wtautological-compare. In so doing, fix a handful of remaining bugs where we would report false positives or

[PATCH] D40225: Add -std=c17 as a flag

2017-12-07 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman closed this revision. aaron.ballman added a comment. Commit in r320089. https://reviews.llvm.org/D40225 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-07 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman requested changes to this revision. aaron.ballman added a comment. This revision now requires changes to proceed. In https://reviews.llvm.org/D40671#947762, @xgsa wrote: > So can this patch be submitted? Should I do something to make it happen? There are still some outstanding

Re: r320089 - Add new language mode flags for C17.

2017-12-07 Thread Ahmed Bougacha via cfe-commits
On Thu, Dec 7, 2017 at 2:56 PM, Richard Smith via cfe-commits wrote: > Looks like this might have messed up the line endings in a few files? Should be taken care of in r320112. -Ahmed > On 7 December 2017 at 13:46, Aaron Ballman via cfe-commits >

[PATCH] D40941: [ubsan] Use pass_object_size info in bounds checks (compiler-rt)

2017-12-07 Thread George Burgess IV via Phabricator via cfe-commits
george.burgess.iv added a comment. If the answer to my question is "no, it'll just work," LGTM. Thanks! Comment at: test/ubsan/TestCases/Misc/bounds.cpp:9 +int get_int(int *const p __attribute__((pass_object_size(0))), int i) { + // CHECK-A-2: bounds.cpp:[[@LINE+1]]:10:

[PATCH] D40940: [ubsan] Use pass_object_size info in bounds checks

2017-12-07 Thread George Burgess IV via Phabricator via cfe-commits
george.burgess.iv accepted this revision. george.burgess.iv added a comment. This revision is now accepted and ready to land. LGTM. Thanks again! https://reviews.llvm.org/D40940 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

r320128 - [ubsan] Use pass_object_size info in bounds checks

2017-12-07 Thread Vedant Kumar via cfe-commits
Author: vedantk Date: Thu Dec 7 17:51:47 2017 New Revision: 320128 URL: http://llvm.org/viewvc/llvm-project?rev=320128=rev Log: [ubsan] Use pass_object_size info in bounds checks Teach UBSan's bounds check to opportunistically use pass_object_size information to check array accesses.

r320112 - Remove line-endings added by r320089. NFC.

2017-12-07 Thread Ahmed Bougacha via cfe-commits
Author: ab Date: Thu Dec 7 14:58:02 2017 New Revision: 320112 URL: http://llvm.org/viewvc/llvm-project?rev=320112=rev Log: Remove line-endings added by r320089. NFC. Modified: cfe/trunk/include/clang/Basic/LangOptions.def Modified: cfe/trunk/include/clang/Basic/LangOptions.def URL:

[PATCH] D39451: P0620 follow-up: deducing `auto` from braced-init-list in new expr

2017-12-07 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. EDG and MSVC do not appear to treat this as a defect resolution; I suspect this is an oversight in GCC rather than an intentional extension. Let's convert the error to an (off by default) pedantic `Extension` (ISO C++11 does not allow ...), and suppress the extension

[PATCH] D40940: [ubsan] Use pass_object_size info in bounds checks

2017-12-07 Thread Vedant Kumar via Phabricator via cfe-commits
vsk updated this revision to Diff 126064. vsk added a comment. - Handle constant size modifiers while we're at it (e.g "int foo(int p[static 10])"). https://reviews.llvm.org/D40940 Files: lib/CodeGen/CGExpr.cpp lib/CodeGen/CodeGenFunction.h test/CodeGen/ubsan-pass-object-size.c Index:

r320115 - Correct line endings that got mixed up in r320088; NFC.

2017-12-07 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Thu Dec 7 15:10:09 2017 New Revision: 320115 URL: http://llvm.org/viewvc/llvm-project?rev=320115=rev Log: Correct line endings that got mixed up in r320088; NFC. Modified: cfe/trunk/test/Preprocessor/has_c_attribute.c Modified:

[PATCH] D40936: Hardware-assisted AddressSanitizer (clang part).

2017-12-07 Thread Evgenii Stepanov via Phabricator via cfe-commits
eugenis updated this revision to Diff 126060. eugenis added a comment. clang-format https://reviews.llvm.org/D40936 Files: clang/include/clang/Basic/Sanitizers.def clang/include/clang/Driver/SanitizerArgs.h clang/lib/CodeGen/BackendUtil.cpp clang/lib/CodeGen/CGDeclCXX.cpp

[PATCH] D39050: Add index-while-building support to Clang

2017-12-07 Thread Nathan Hawes via Phabricator via cfe-commits
nathawes added inline comments. Comment at: lib/FrontendTool/ExecuteCompilerInvocation.cpp:170 +Act = index::createIndexDataRecordingAction(FEOpts, std::move(Act)); +CI.setGenModuleActionWrapper(::createIndexDataRecordingAction); + } ioeric wrote: >

[PATCH] D40991: [libcxx] [test] Fix line endings, avoid unnecessary non-ASCII.

2017-12-07 Thread Stephan T. Lavavej via Phabricator via cfe-commits
STL_MSFT created this revision. [libcxx] [test] Fix line endings, avoid unnecessary non-ASCII. I recently wrote a tool to audit MSVC's codebase for inconsistent line endings and unnecessary non-ASCII characters, and I ran it over libcxx's codebase too. I don't need any of these changes to be

Re: r320089 - Add new language mode flags for C17.

2017-12-07 Thread Ahmed Bougacha via cfe-commits
On Thu, Dec 7, 2017 at 3:00 PM, Aaron Ballman wrote: > On Thu, Dec 7, 2017 at 5:59 PM, Ahmed Bougacha > wrote: >> On Thu, Dec 7, 2017 at 2:56 PM, Richard Smith via cfe-commits >> wrote: >>> Looks like this might have

Re: r320089 - Add new language mode flags for C17.

2017-12-07 Thread Aaron Ballman via cfe-commits
On Thu, Dec 7, 2017 at 6:00 PM, Aaron Ballman wrote: > On Thu, Dec 7, 2017 at 5:59 PM, Ahmed Bougacha > wrote: >> On Thu, Dec 7, 2017 at 2:56 PM, Richard Smith via cfe-commits >> wrote: >>> Looks like this might have

r320113 - Correct line endings that got mixed up in r320089; NFC.

2017-12-07 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Thu Dec 7 15:04:11 2017 New Revision: 320113 URL: http://llvm.org/viewvc/llvm-project?rev=320113=rev Log: Correct line endings that got mixed up in r320089; NFC. Modified: cfe/trunk/include/clang/Frontend/LangStandard.h

[libcxx] r320096 - Creating release candidate rc3 from release_501 branch

2017-12-07 Thread Tom Stellard via cfe-commits
Author: tstellar Date: Thu Dec 7 14:10:39 2017 New Revision: 320096 URL: http://llvm.org/viewvc/llvm-project?rev=320096=rev Log: Creating release candidate rc3 from release_501 branch Added: libcxx/tags/RELEASE_501/rc3/ (props changed) - copied from r320095,

[libcxxabi] r320097 - Creating release candidate rc3 from release_501 branch

2017-12-07 Thread Tom Stellard via cfe-commits
Author: tstellar Date: Thu Dec 7 14:10:43 2017 New Revision: 320097 URL: http://llvm.org/viewvc/llvm-project?rev=320097=rev Log: Creating release candidate rc3 from release_501 branch Added: libcxxabi/tags/RELEASE_501/rc3/ - copied from r320096, libcxxabi/branches/release_50/

[PATCH] D40948: Switch Clang's default C++ language target to C++14

2017-12-07 Thread Tim Northover via Phabricator via cfe-commits
t.p.northover added a comment. Thanks Richard. I'll file the bugs tomorrow for the issues you suggest. Do you see either of them blocking the change to C++14 as a default? On a scale of "no", "no but I want a commitment to fix them" and "yes" sort of thing. Tonight I've just got one comment

Re: r320089 - Add new language mode flags for C17.

2017-12-07 Thread Aaron Ballman via cfe-commits
On Thu, Dec 7, 2017 at 5:59 PM, Ahmed Bougacha wrote: > On Thu, Dec 7, 2017 at 2:56 PM, Richard Smith via cfe-commits > wrote: >> Looks like this might have messed up the line endings in a few files? > > Should be taken care of in r320112.

[PATCH] D40671: [clang-tidy] Support specific checks for NOLINT directive

2017-12-07 Thread Anton via Phabricator via cfe-commits
xgsa marked an inline comment as done. xgsa added a comment. In https://reviews.llvm.org/D40671#948826, @aaron.ballman wrote: > There are still some outstanding concerns around the documentation wording, > but once those are resolved it should be ready to commit. If you don't have > commit

[PATCH] D39451: P0620 follow-up: deducing `auto` from braced-init-list in new expr

2017-12-07 Thread Zhihao Yuan via Phabricator via cfe-commits
lichray added a comment. Ping. Just accept this as a DR, like what GCC does, I guess? https://reviews.llvm.org/D39451 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r320082 - [OpenMP] NVPTX: Set default/minimum compute capability to sm_35

2017-12-07 Thread George Rokos via cfe-commits
Author: grokos Date: Thu Dec 7 12:27:31 2017 New Revision: 320082 URL: http://llvm.org/viewvc/llvm-project?rev=320082=rev Log: [OpenMP] NVPTX: Set default/minimum compute capability to sm_35 The current implementation of the nvptx runtime (to be upstreamed shortly) uses the atomicMax operation

[libunwind] r320103 - Creating release candidate rc3 from release_501 branch

2017-12-07 Thread Tom Stellard via cfe-commits
Author: tstellar Date: Thu Dec 7 14:11:09 2017 New Revision: 320103 URL: http://llvm.org/viewvc/llvm-project?rev=320103=rev Log: Creating release candidate rc3 from release_501 branch Added: libunwind/tags/RELEASE_501/rc3/ (props changed) - copied from r320102,

[PATCH] D35181: Defer addition of keywords to identifier table when loading AST

2017-12-07 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. LGTM, but I'd like the old `IdentifierTable` constructor to be removed if there are no callers left. Comment at: include/clang/Basic/IdentifierTable.h:473-476 /// \brief Create the identifier table, populating it with info about the /// language

[PATCH] D40988: Clang-format: add finer-grained options for putting all arguments on one line

2017-12-07 Thread Russell McClellan via Phabricator via cfe-commits
russellmcc created this revision. Herald added a subscriber: klimek. Add two new options, AllowAllArgumentsOnNextLine and AllowAllConstructorInitializersOnNextLine. These mirror the existing AllowAllParametersOfDeclarationOnNextLine and allow me to support an internal style guide where I work.

Re: r315996 - [CMake][OpenMP] Customize default offloading arch

2017-12-07 Thread Ahmed Bougacha via cfe-commits
Hi Jonas, On Tue, Oct 17, 2017 at 6:37 AM, Jonas Hahnfeld via cfe-commits wrote: > Author: hahnfeld > Date: Tue Oct 17 06:37:36 2017 > New Revision: 315996 > > URL: http://llvm.org/viewvc/llvm-project?rev=315996=rev > Log: > [CMake][OpenMP] Customize default

[PATCH] D39694: [VerifyDiagnosticConsumer] support -verify=

2017-12-07 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. I've not done a detailed review of the string manipulation here, but this looks like a great feature, thanks! Comment at: include/clang/Basic/DiagnosticDriverKinds.td:342 + +def note_drv_verify_prefix_spelling : Note<"-verify prefixes must start with a

[PATCH] D40940: [ubsan] Use pass_object_size info in bounds checks

2017-12-07 Thread Vedant Kumar via Phabricator via cfe-commits
vsk updated this revision to Diff 126037. vsk added a comment. Thanks for your feedback. - Give up on 0-sized types. - Give up on pass_object_size(2 | 3). https://reviews.llvm.org/D40940 Files: lib/CodeGen/CGExpr.cpp lib/CodeGen/CodeGenFunction.h test/CodeGen/ubsan-pass-object-size.c

[PATCH] D35181: Defer addition of keywords to identifier table when loading AST

2017-12-07 Thread Johann Klähn via Phabricator via cfe-commits
jklaehn added a comment. Ping, can you take another look? https://reviews.llvm.org/D35181 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D40937: [clang-tidy] Infinite loop checker

2017-12-07 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a reviewer: dcoughlin. aaron.ballman added a subscriber: dcoughlin. aaron.ballman added a comment. I share the concerns that @Eugene.Zelenko brought up regarding this not being in the analyzer. This is a path sensitive problem that I'm not certain clang-tidy is the best home

[PATCH] D40948: Switch Clang's default C++ language target to C++14

2017-12-07 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. In https://reviews.llvm.org/D40948#948843, @t.p.northover wrote: > Thanks Richard. I'll file the bugs tomorrow for the issues you suggest. Do > you see either of them blocking the change to C++14 as a default? On a scale > of "no", "no but I want a commitment to fix

[PATCH] D39050: Add index-while-building support to Clang

2017-12-07 Thread Nathan Hawes via Phabricator via cfe-commits
nathawes updated this revision to Diff 126065. nathawes added a comment. Herald added a subscriber: mgrang. Worked through the comments from @ioeric and split the code for writing out the collected indexing data into a separate patch. https://reviews.llvm.org/D39050 Files:

[PATCH] D40941: [ubsan] Use pass_object_size info in bounds checks (compiler-rt)

2017-12-07 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added inline comments. Comment at: test/ubsan/TestCases/Misc/bounds.cpp:9 +int get_int(int *const p __attribute__((pass_object_size(0))), int i) { + // CHECK-A-2: bounds.cpp:[[@LINE+1]]:10: runtime error: index 2 out of bounds for type 'int *' + return p[i];

r320124 - Fold together the in-range and out-of-range portions of -Wtautological-compare.

2017-12-07 Thread Richard Smith via cfe-commits
Author: rsmith Date: Thu Dec 7 17:00:27 2017 New Revision: 320124 URL: http://llvm.org/viewvc/llvm-project?rev=320124=rev Log: Fold together the in-range and out-of-range portions of -Wtautological-compare. Modified: cfe/trunk/lib/Sema/SemaChecking.cpp Modified:

[PATCH] D40548: [clangd] Symbol index interfaces and index-based code completion.

2017-12-07 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added a comment. As a follow-up, here's the interface for querying the index that I am using right now. It's meant to be able to retrieve from any kind of "backend", i.e. in-memory, ClangdIndexDataStore, libIndexStore, etc. I was able to implement "Open Workspace Symbol" (which is

r320131 - Add a test that the __STDC_VERSION__ macro reports the correct value for -std=c17.

2017-12-07 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Thu Dec 7 18:39:26 2017 New Revision: 320131 URL: http://llvm.org/viewvc/llvm-project?rev=320131=rev Log: Add a test that the __STDC_VERSION__ macro reports the correct value for -std=c17. Added: cfe/trunk/test/Preprocessor/c17.c Added:

[PATCH] D40995: [TextDiagnosticBuffer] Fix diagnostic note emission order.

2017-12-07 Thread Joel E. Denny via Phabricator via cfe-commits
jdenny created this revision. The frontend currently groups diagnostics from the command line according to diagnostic level, but that places all notes last. Fix that by emitting such diagnostics in the order they were generated. https://reviews.llvm.org/D40995 Files:

[PATCH] D39050: Add index-while-building support to Clang

2017-12-07 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added a comment. In https://reviews.llvm.org/D39050#948500, @akyrtzi wrote: > @malaperle, to clarify we are not suggesting that you write your own parser, > the suggestion is to use clang in 'fast-scan' mode to get the structure of > the declarations of a single file, see

[PATCH] D39694: [VerifyDiagnosticConsumer] support -verify=

2017-12-07 Thread Joel E. Denny via Phabricator via cfe-commits
jdenny marked 13 inline comments as done. jdenny added a comment. I marked the comments related to Hal's suggestions as done to avoid confusion for future reviews. I'm not used to using this sort of tool for reviews. Hopefully it's appropriate for the author to do that rather than the

[PATCH] D39694: [VerifyDiagnosticConsumer] support -verify=

2017-12-07 Thread Joel E. Denny via Phabricator via cfe-commits
jdenny added a comment. In https://reviews.llvm.org/D39694#949066, @rsmith wrote: > I've not done a detailed review of the string manipulation here, but this > looks like a great feature, thanks! Hi Richard. Thanks for your feedback. I'll fix the line wrapping you pointed out.

[PATCH] D40997: [driver] Take target

2017-12-07 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman abandoned this revision. arphaman added a comment. Sorry, accidental Return. Will close and reopen. Repository: rC Clang https://reviews.llvm.org/D40997 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D40997: [driver] Take target

2017-12-07 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. Herald added a subscriber: javed.absar. Repository: rC Clang https://reviews.llvm.org/D40997 Files: lib/Driver/ToolChains/Darwin.cpp test/Driver/appletvos-version-min.c test/Driver/darwin-multiarch-arm.c test/Driver/darwin-stdlib.cpp

Re: r320124 - Fold together the in-range and out-of-range portions of -Wtautological-compare.

2017-12-07 Thread Hans Wennborg via cfe-commits
I've reverted in r320133 since it caused new warnings in Chromium that I'm not sure were intentional. See comment on the revert. On Thu, Dec 7, 2017 at 5:00 PM, Richard Smith via cfe-commits wrote: > Author: rsmith > Date: Thu Dec 7 17:00:27 2017 > New Revision:

[PATCH] D39694: [VerifyDiagnosticConsumer] support -verify=

2017-12-07 Thread Joel E. Denny via Phabricator via cfe-commits
jdenny updated this revision to Diff 126086. jdenny added a comment. This update does the following: 1. Fixes the line wrapping that Richard pointed out. 2. Converts from std::vector to std::set for more efficient prefix lookup. 3. Grows a dependence on https://reviews.llvm.org/D40995 (which

r320132 - [Blocks] Inherit sanitizer options from parent decl

2017-12-07 Thread Vedant Kumar via cfe-commits
Author: vedantk Date: Thu Dec 7 18:47:58 2017 New Revision: 320132 URL: http://llvm.org/viewvc/llvm-project?rev=320132=rev Log: [Blocks] Inherit sanitizer options from parent decl There is no way to apply sanitizer suppressions to ObjC blocks. A reasonable default is to have blocks inherit

[PATCH] D40668: [Blocks] Inherit sanitizer options from parent decl

2017-12-07 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC320132: [Blocks] Inherit sanitizer options from parent decl (authored by vedantk). Repository: rC Clang https://reviews.llvm.org/D40668 Files: lib/CodeGen/CGBlocks.cpp

[PATCH] D40668: [Blocks] Inherit sanitizer options from parent decl

2017-12-07 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. In https://reviews.llvm.org/D40668#949096, @zaks.anna wrote: > LGTM. > > Thanks! > > I was wondering if there are other places where this propagation needs to be > added, for example, other calls to GenerateBlockFunction. Thanks for the review :). Yes there is one other

[PATCH] D40998: [driver][darwin] Take the OS version specified in "-target" as the target OS instead of inferring it from SDK / environment

2017-12-07 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith requested changes to this revision. dexonsmith added inline comments. This revision now requires changes to proceed. Comment at: lib/Driver/ToolChains/Darwin.cpp:1234-1276 +// The -target option specifies the deployment target when +// -m-version-min is not

[PATCH] D40998: [driver][darwin] Take the OS version specified in "-target" as the target OS instead of inferring it from SDK / environment

2017-12-07 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. Herald added a subscriber: javed.absar. The OS version is specified in `-target` should be used instead of the one in an environment variable / SDK name. rdar://35813850 Repository: rC Clang https://reviews.llvm.org/D40998 Files:

[PATCH] D39451: P0620 follow-up: deducing `auto` from braced-init-list in new expr

2017-12-07 Thread Zhihao Yuan via Phabricator via cfe-commits
lichray updated this revision to Diff 126092. lichray added a comment. Keep a pedantic Extension warning. Repository: rC Clang https://reviews.llvm.org/D39451 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/SemaExprCXX.cpp test/CXX/expr/expr.unary/expr.new/p2-cxx0x.cpp

[PATCH] D40668: [Blocks] Inherit sanitizer options from parent decl

2017-12-07 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna accepted this revision. zaks.anna added a comment. This revision is now accepted and ready to land. LGTM. Thanks! I was wondering if there are other places where this propagation needs to be added, for example, other calls to GenerateBlockFunction. https://reviews.llvm.org/D40668

[PATCH] D40996: Add --no-cuda-version-check in unknown-std.cpp

2017-12-07 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 created this revision. This unit test fails on the system that has CUDA Toolkit 9.0 installed. And CUDA 9 does not support GPU arch sm_20. It results in the following error. clang-6.0: error: GPU arch sm_20 is supported by CUDA versions between 7.0 and 8.0 (inclusive), but

[PATCH] D40897: [clangd] Introduce a "Symbol" class.

2017-12-07 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added inline comments. Comment at: clangd/Symbol.h:23 + // The path of the source file where a symbol occurs. + std::string FilePath; + // The offset to the first character of the symbol from the beginning of the malaperle wrote: > sammccall wrote:

r320133 - Revert r320124 "Fold together the in-range and out-of-range portions of -Wtautological-compare."

2017-12-07 Thread Hans Wennborg via cfe-commits
Author: hans Date: Thu Dec 7 21:19:12 2017 New Revision: 320133 URL: http://llvm.org/viewvc/llvm-project?rev=320133=rev Log: Revert r320124 "Fold together the in-range and out-of-range portions of -Wtautological-compare." This broke Chromium: ../../base/trace_event/trace_log.cc:1545:29:

[PATCH] D40968: [OpenMP] Diagnose function name on the link clause

2017-12-07 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 updated this revision to Diff 126025. kkwli0 marked an inline comment as done. https://reviews.llvm.org/D40968 Files: include/clang/Basic/DiagnosticSemaKinds.td include/clang/Sema/Sema.h lib/Sema/SemaOpenMP.cpp test/OpenMP/declare_target_ast_print.cpp

[PATCH] D40968: [OpenMP] Diagnose function name on the link clause

2017-12-07 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 marked an inline comment as done. kkwli0 added inline comments. Comment at: lib/Sema/SemaOpenMP.cpp:12576 +if (MT == OMPDeclareTargetDeclAttr::MT_Link && isa(ND)) { + Diag(Id.getLoc(), diag::err_omp_function_in_link_clause); ABataev wrote: > I

[PATCH] D40948: Switch Clang's default C++ language target to C++14

2017-12-07 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: clang/test/CodeGenCXX/new-overflow.cpp:88 // CHECK: [[N:%.*]] = sext i16 {{%.*}} to i32 - // CHECK-NEXT: [[T0:%.*]] = icmp slt i32 [[N]], 0 - // CHECK-NEXT: [[T1:%.*]] = select i1 [[T0]], i32 -1, i32 [[N]] - // CHECK-NEXT:

[PATCH] D39363: [clang-tidy] Correctly classify constant arrays and constant strings as constants when checking identifiers naming

2017-12-07 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added a comment. Sorry for the delay. I missed this revision somehow. Please add cfe-commits to the subscribers list so that others can chime in. https://reviews.llvm.org/D39363 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D40956: [AMDGPU] Switch to the new addr space mapping by default for clang

2017-12-07 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl created this revision. Herald added subscribers: t-tye, tpr, dstuttard, nhaehnle, wdng, kzhuravl. Will clean up the old addr space mapping in separate patch. https://reviews.llvm.org/D40956 Files: lib/Basic/Targets/AMDGPU.cpp lib/Basic/Targets/AMDGPU.h test/CodeGen/address-space.c

[PATCH] D40548: [clangd] Symbol index interfaces and index-based code completion.

2017-12-07 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 125962. ioeric added a comment. Diff on https://reviews.llvm.org/D40897 instead origin/master! Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D40548 Files: clangd/CMakeLists.txt clangd/ClangdIndex.cpp clangd/ClangdIndex.h

[PATCH] D40548: [clangd] Symbol index interfaces and index-based code completion.

2017-12-07 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 125960. ioeric added a comment. - Use IncludeNamespaceLevelDecls option; fix some broken tests. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D40548 Files: clangd/CMakeLists.txt clangd/ClangdIndex.cpp clangd/ClangdIndex.h

[PATCH] D30946: [ScopePrinting] Added support to print full scopes of types and declarations.

2017-12-07 Thread Simon Schroeder via Phabricator via cfe-commits
schroedersi added a comment. Ping https://reviews.llvm.org/D30946 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D39363: [clang-tidy] Correctly classify constant arrays and constant strings as constants when checking identifiers naming

2017-12-07 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added a comment. One nit. Otherwise seems fine. Comment at: clang-tidy/readability/IdentifierNamingCheck.cpp:502 -if (!Type.isNull() && Type.isLocalConstQualified() && +if (!Type.isNull() && Type.isConstQualified() && Decl->isStaticDataMember() &&

[PATCH] D40939: [analyzer] Avoid element regions of void type.

2017-12-07 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. I like the idea of adding those assertions but a bit worried about the other changes. Basically (if I get this right), we are masking the issues here and I am a bit afraid that they will get forgotten. I think it would be nice to at least add a FIXME that this path

[PATCH] D40489: [clangd] Changed tracing interfaces

2017-12-07 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clangd/Trace.cpp:138 return; - if (!Args) -Args = llvm::make_unique(); - T->event(Ctx, "E", - Args ? json::obj{{"args", std::move(*Args)}} : json::obj{}); + assert(Args && "Args can't be null at this point"); +

[PATCH] D40897: [clangd] Introduce a "Symbol" class.

2017-12-07 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Thanks for putting this together! Have a bit of a braindump here, happy to discuss further either here or offline. Comment at: clangd/Symbol.h:1 +//===--- Symbol.h ---*- C++-*-===// +// I

[PATCH] D40548: [clangd] Prototyping index support and naive index-based global code completion. WIP

2017-12-07 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 125928. ioeric added a comment. - More cleanups and merged with https://reviews.llvm.org/D40897 Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D40548 Files: clangd/CMakeLists.txt clangd/ClangdIndex.cpp clangd/ClangdIndex.h

r320017 - Ignore pointers to incomplete types when diagnosing misaligned addresses

2017-12-07 Thread Roger Ferrer Ibanez via cfe-commits
Author: rogfer01 Date: Thu Dec 7 01:23:50 2017 New Revision: 320017 URL: http://llvm.org/viewvc/llvm-project?rev=320017=rev Log: Ignore pointers to incomplete types when diagnosing misaligned addresses This is a fix for PR35509 in which we crash because we attempt to compute the alignment of an

[PATCH] D40895: Ignore pointers to incomplete types when diagnosing misaligned addresses

2017-12-07 Thread Roger Ferrer Ibanez via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL320017: Ignore pointers to incomplete types when diagnosing misaligned addresses (authored by rogfer01). Changed prior to commit: https://reviews.llvm.org/D40895?vs=125718=125901#toc Repository: rL

[PATCH] D40884: [Index] Add setPreprocessor member to IndexDataConsumer.

2017-12-07 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 125913. ioeric marked an inline comment as done. ioeric added a comment. - Removed a redundant #include Repository: rC Clang https://reviews.llvm.org/D40884 Files: include/clang/Index/IndexDataConsumer.h lib/Index/IndexingAction.cpp

[PATCH] D40888: [ARM] ACLE parallel arithmetic and DSP style multiplications

2017-12-07 Thread Sjoerd Meijer via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL320019: [ARM] ACLE parallel arithmetic and DSP style multiplications (authored by SjoerdMeijer). Changed prior to commit: https://reviews.llvm.org/D40888?vs=125705=125909#toc Repository: rL LLVM

r320019 - [ARM] ACLE parallel arithmetic and DSP style multiplications

2017-12-07 Thread Sjoerd Meijer via cfe-commits
Author: sjoerdmeijer Date: Thu Dec 7 01:54:39 2017 New Revision: 320019 URL: http://llvm.org/viewvc/llvm-project?rev=320019=rev Log: [ARM] ACLE parallel arithmetic and DSP style multiplications This is a follow up of r302131, in which we forgot to add SemaChecking tests. Adding these tests

[PATCH] D40888: [ARM] ACLE parallel arithmetic and DSP style multiplications

2017-12-07 Thread Sjoerd Meijer via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC320019: [ARM] ACLE parallel arithmetic and DSP style multiplications (authored by SjoerdMeijer). Repository: rC Clang https://reviews.llvm.org/D40888 Files: include/clang/Basic/BuiltinsARM.def

[PATCH] D40909: [clang-format] Reorganize raw string delimiters

2017-12-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 125915. krasimir added a comment. - Added unsafe canonical delimiter update handling Repository: rC Clang https://reviews.llvm.org/D40909 Files: include/clang/Format/Format.h lib/Format/ContinuationIndenter.cpp lib/Format/ContinuationIndenter.h

[PATCH] D40909: [clang-format] Reorganize raw string delimiters

2017-12-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 125921. krasimir added a comment. - Added support for enclosing function names Repository: rC Clang https://reviews.llvm.org/D40909 Files: include/clang/Format/Format.h lib/Format/ContinuationIndenter.cpp lib/Format/ContinuationIndenter.h

Re: [PATCH] D40948: Switch Clang's default C++ language target to C++14

2017-12-07 Thread Tim Northover via cfe-commits
Here's the test-suite diff. It's really just a few ancient code-bases that don't compile with C++14, no runtime issues I noticed. Tim. commit a52b065052bfefaac17e7096fd2c911aac62e9da Author: Tim Northover Date: Thu Dec 7 09:16:34 2017 + Support C++14 as a

[PATCH] D40909: [clang-format] Reorganize raw string delimiters

2017-12-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 125927. krasimir added a comment. - Updated documentation Repository: rC Clang https://reviews.llvm.org/D40909 Files: docs/ClangFormatStyleOptions.rst include/clang/Format/Format.h lib/Format/ContinuationIndenter.cpp

[PATCH] D40486: [clangd] Implemented logging using Context

2017-12-07 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clangd/JSONRPCDispatcher.cpp:23 +namespace { +static Key TracerKey; +static Key IDKey; sammccall wrote: > RequestTracer? actually, RequestSpan I think - "tracer" is pretty confusing at global scope

[PATCH] D40897: [clangd] Introduce a "Symbol" class.

2017-12-07 Thread Eric Liu via Phabricator via cfe-commits
ioeric added inline comments. Comment at: clangd/Symbol.h:23 + // The path of the source file where a symbol occurs. + std::string FilePath; + // The offset to the first character of the symbol from the beginning of the Is this relative or absolute?

[PATCH] D40884: [Index] Add setPreprocessor member to IndexDataConsumer.

2017-12-07 Thread Eric Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL320030: [Index] Add setPreprocessor member to IndexDataConsumer. (authored by ioeric). Repository: rL LLVM https://reviews.llvm.org/D40884 Files: cfe/trunk/include/clang/Index/IndexDataConsumer.h

[PATCH] D40884: [Index] Add setPreprocessor member to IndexDataConsumer.

2017-12-07 Thread Eric Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC320030: [Index] Add setPreprocessor member to IndexDataConsumer. (authored by ioeric). Changed prior to commit: https://reviews.llvm.org/D40884?vs=125913=125920#toc Repository: rC Clang

r320030 - [Index] Add setPreprocessor member to IndexDataConsumer.

2017-12-07 Thread Eric Liu via cfe-commits
Author: ioeric Date: Thu Dec 7 03:04:24 2017 New Revision: 320030 URL: http://llvm.org/viewvc/llvm-project?rev=320030=rev Log: [Index] Add setPreprocessor member to IndexDataConsumer. Summary: This enables us to use information in Preprocessor when handling symbol occurrences. Reviewers:

[PATCH] D40948: Switch Clang's default C++ language target to C++14

2017-12-07 Thread Tim Northover via Phabricator via cfe-commits
t.p.northover created this revision. Herald added a subscriber: mcrosier. Hi all, So, I've finally managed to run all the tests I wanted and get this out for review. Sorry it's taken so long. This patch switches Clang's default C++ target to C++14 across all platforms and updates the

[PATCH] D40909: [clang-format] Reorganize raw string delimiters

2017-12-07 Thread Daniel Jasper via Phabricator via cfe-commits
djasper added inline comments. Comment at: include/clang/Format/Format.h:1216 +LK_TextProto, +/// Do not use. Keep at last position. +LK_End, Lets find a way to implement without this in the public header file. Comment at:

[PATCH] D40909: [clang-format] Reorganize raw string delimiters

2017-12-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: include/clang/Format/Format.h:1375 +std::vector EnclosingFunctionNames; +/// \brief The canonical delimiter for this language. +std::string CanonicalDelimiter; djasper wrote: > Can you pull apart this

[PATCH] D40909: [clang-format] Reorganize raw string delimiters

2017-12-07 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 125939. krasimir edited the summary of this revision. krasimir added a comment. - Address review comments Repository: rC Clang https://reviews.llvm.org/D40909 Files: docs/ClangFormatStyleOptions.rst include/clang/Format/Format.h

[PATCH] D39375: [clang] Add PPCallbacks list to preprocessor when building a preacompiled preamble.

2017-12-07 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov requested changes to this revision. ilya-biryukov added inline comments. This revision now requires changes to proceed. Comment at: lib/Frontend/PrecompiledPreamble.cpp:242 std::shared_ptr PCHContainerOps, bool StoreInMemory, -PreambleCallbacks ) { +

[PATCH] D40485: [clangd] Introduced a Context that stores implicit data

2017-12-07 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clangd/Context.h:25 + +class ContextData { +public: sammccall wrote: > IIUC, the only reason we expose separate `Context` and `ContextData` types is > to give things like Span a stable reference to hold onto

  1   2   >