[PATCH] D43671: [clangd] Address FIXME and fix comment

2018-02-24 Thread Kirill Bobyrev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL326051: [clangd] Address FIXME and fix comment (authored by omtcyfz, committed by ). Herald added subscribers: llvm-commits, klimek. Changed prior to commit:

[clang-tools-extra] r326051 - [clangd] Address FIXME and fix comment

2018-02-24 Thread Kirill Bobyrev via cfe-commits
Author: omtcyfz Date: Sat Feb 24 23:21:16 2018 New Revision: 326051 URL: http://llvm.org/viewvc/llvm-project?rev=326051=rev Log: [clangd] Address FIXME and fix comment * Address a FIXME by warning the user that both -run-synchronously and -j X are passed. * Fix a comment to suppress clang-tidy

[PATCH] D43671: [clangd] Address FIXME and fix comment

2018-02-24 Thread Kirill Bobyrev via Phabricator via cfe-commits
omtcyfz updated this revision to Diff 135815. omtcyfz marked an inline comment as done. omtcyfz added a comment. Address Eric's nit: make warning message shorter so that it would fit into one line in order to omit braces for a single statement for compliance with the clang-tools-extra

[PATCH] D43734: [RecordLayout] Don't align to non-power-of-2 sizes when using -mms-bitfields

2018-02-24 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added inline comments. Comment at: lib/AST/RecordLayoutBuilder.cpp:1755 CharUnits TypeSize = Context.getTypeSizeInChars(BTy); -if (TypeSize > FieldAlign) +if (TypeSize > FieldAlign && +llvm::isPowerOf2_64(TypeSize.getQuantity()))

[PATCH] D43734: [RecordLayout] Don't align to non-power-of-2 sizes when using -mms-bitfields

2018-02-24 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo updated this revision to Diff 135813. mstorsjo added a comment. Asserting that non power of 2 only occurs in gnu mode. https://reviews.llvm.org/D43734 Files: lib/AST/RecordLayoutBuilder.cpp test/CodeGen/mingw-long-double.c Index: test/CodeGen/mingw-long-double.c

[PATCH] D43581: [clang-tidy/google] Improve the Objective-C global variable declaration check 

2018-02-24 Thread Yan Zhang via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL326046: [clang-tidy/google] Improve the Objective-C global variable declaration check  (authored by Wizard, committed by ). Herald added subscribers: llvm-commits, klimek. Changed prior to commit:

[PATCH] D43737: Improve -Winfinite-recursion

2018-02-24 Thread Robert Widmann via Phabricator via cfe-commits
CodaFi created this revision. CodaFi added a reviewer: rsmith. Herald added a subscriber: cfe-commits. Rewrites -Winfinite-recursion to remove the state dictionary and explore paths in loops - especially infinite loops. The new check now detects recursion in loop bodies dominated by a

[PATCH] D43105: [RISCV] Enable __int128_t and __uint128_t through clang flag

2018-02-24 Thread Mandeep Singh Grang via Phabricator via cfe-commits
mgrang added a comment. After addressing comments, I have now committed this patch. Thanks for all the reviews! Repository: rC Clang https://reviews.llvm.org/D43105 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D43105: [RISCV] Enable __int128_t and __uint128_t through clang flag

2018-02-24 Thread Mandeep Singh Grang via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL326045: [RISCV] Enable __int128_t and __uint128_t through clang flag (authored by mgrang, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit:

r326045 - [RISCV] Enable __int128_t and __uint128_t through clang flag

2018-02-24 Thread Mandeep Singh Grang via cfe-commits
Author: mgrang Date: Sat Feb 24 19:58:23 2018 New Revision: 326045 URL: http://llvm.org/viewvc/llvm-project?rev=326045=rev Log: [RISCV] Enable __int128_t and __uint128_t through clang flag Summary: If the flag -fforce-enable-int128 is passed, it will enable support for __int128_t and

[PATCH] D43581: [clang-tidy/google] Improve the Objective-C global variable declaration check 

2018-02-24 Thread Yan Zhang via Phabricator via cfe-commits
Wizard added a comment. In https://reviews.llvm.org/D43581#1018584, @stephanemoore wrote: > In https://reviews.llvm.org/D43581#1018499, @aaron.ballman wrote: > > > This LGTM! Do you need someone to commit on your behalf? > > > I would be happy to commit assuming that I am able to and can meet

[PATCH] D43581: [clang-tidy/google] Improve the Objective-C global variable declaration check 

2018-02-24 Thread Stephane Moore via Phabricator via cfe-commits
stephanemoore marked an inline comment as done. stephanemoore added a comment. In https://reviews.llvm.org/D43581#1018499, @aaron.ballman wrote: > This LGTM! Do you need someone to commit on your behalf? I would be happy to commit assuming that I am able to and can meet submission

Re: [libcxx] r323971 - Remove ; use instead. See https://libcxx.llvm.org/TS_deprecation.html

2018-02-24 Thread Marshall Clow via cfe-commits
On Thu, Feb 22, 2018 at 7:58 AM, Nico Weber wrote: > I have a small personal project where I used to use this. I tried > switching to instead, but that apparently requires -std=c++17. > With that, things build fine with my locally-built clang, but latest Xcode > clang

[PATCH] D43281: [AMDGPU] fixes for lds f32 builtins

2018-02-24 Thread Daniil Fukalov via Phabricator via cfe-commits
dfukalov marked an inline comment as done. dfukalov added a comment. ping... https://reviews.llvm.org/D43281 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D43734: [RecordLayout] Don't align to non-power-of-2 sizes when using -mms-bitfields

2018-02-24 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd added inline comments. Comment at: lib/AST/RecordLayoutBuilder.cpp:1755 CharUnits TypeSize = Context.getTypeSizeInChars(BTy); -if (TypeSize > FieldAlign) +if (TypeSize > FieldAlign && +llvm::isPowerOf2_64(TypeSize.getQuantity()))

[PATCH] D43734: [RecordLayout] Don't align to non-power-of-2 sizes when using -mms-bitfields

2018-02-24 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo created this revision. mstorsjo added reviewers: compnerd, rnk, majnemer. When targeting GNU/MinGW for i386, the size of the "long double" data type is 12 bytes (while it is 8 bytes in MSVC). When building with -mms-bitfields to have struct layouts match MSVC, data types are laid out

[PATCH] D43689: [analyzer] Disable constructor inlining when lifetime extension through fields occurs.

2018-02-24 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: lib/StaticAnalyzer/Core/ExprEngineCXX.cpp:177 + assert(VD->getType()->isReferenceType()); + if (VD->getType()->getPointeeType().getCanonicalType() != + MTE->GetTemporaryExpr()->getType().getCanonicalType()) {

[PATCH] D43671: [clangd] Address FIXME and fix comment

2018-02-24 Thread Eric Liu via Phabricator via cfe-commits
ioeric accepted this revision. ioeric added a comment. This revision is now accepted and ready to land. Oops, just realized I forgot to push the "send" button! Comment at: clangd/tool/ClangdMain.cpp:153 + if (RunSynchronously) { +if

[PATCH] D43714: [analyzer] Don't do anything when trivial-copying an empty class object.

2018-02-24 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin accepted this revision. dcoughlin added a comment. This revision is now accepted and ready to land. LGTM. https://reviews.llvm.org/D43714 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D43689: [analyzer] Disable constructor inlining when lifetime extension through fields occurs.

2018-02-24 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin accepted this revision. dcoughlin added inline comments. This revision is now accepted and ready to land. Comment at: include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h:70 +/// by binding a smaller object within it to a reference. +bool

r326039 - [X86] Remove some masked cvt builtins that can be replaced with legacy sse/avx buiiltins and a select.

2018-02-24 Thread Craig Topper via cfe-commits
Author: ctopper Date: Sat Feb 24 10:55:13 2018 New Revision: 326039 URL: http://llvm.org/viewvc/llvm-project?rev=326039=rev Log: [X86] Remove some masked cvt builtins that can be replaced with legacy sse/avx buiiltins and a select. Modified: cfe/trunk/include/clang/Basic/BuiltinsX86.def

[PATCH] D43666: [analyzer] When constructing a temporary without construction context, track it for destruction anyway.

2018-02-24 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin added inline comments. Comment at: lib/StaticAnalyzer/Core/ExprEngine.cpp:2234 + // should go away, but the assertion should remain, without the + // "DidCacheOutOnCleanup" part, of course. + bool DidCacheOutOnCleanup = false; Can you add a comment

[PATCH] D43430: Omit nullptr check for sufficiently simple delete-expressions

2018-02-24 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. That is an extremely Google-specific analysis, actually; AFAIK almost nobody else uses static linking all the way down to and including the C and C++ standard libraries unless they're literally building an executable for a fully-static environment, like the kernel.

r326038 - Add a C++11 and C2x spelling for the objc_bridge_related attribute in the clang vendor namespace.

2018-02-24 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Sat Feb 24 09:37:37 2018 New Revision: 326038 URL: http://llvm.org/viewvc/llvm-project?rev=326038=rev Log: Add a C++11 and C2x spelling for the objc_bridge_related attribute in the clang vendor namespace. This attribute has custom parsing rules that previously

[PATCH] D41228: [ObjC] Enable __strong pointers in structs under ARC

2018-02-24 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. Thanks! This looks ready; thank you for your patience in working this out. Comment at: include/clang/AST/Type.h:1108 +PCK_ARCStrong, // objc strong pointer. +

r326036 - Add a C++11 and C2x spelling for the availability attribute in the clang vendor namespace.

2018-02-24 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Sat Feb 24 09:16:42 2018 New Revision: 326036 URL: http://llvm.org/viewvc/llvm-project?rev=326036=rev Log: Add a C++11 and C2x spelling for the availability attribute in the clang vendor namespace. This attribute has custom parsing rules that previously prevented it

[PATCH] D43273: [libcxx] [test] Fix MSVC warnings and errors.

2018-02-24 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists accepted this revision. mclow.lists added a comment. This revision is now accepted and ready to land. LGTM - thanks! https://reviews.llvm.org/D43273 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

Re: [libcxx] r324290 - Remove ; use instead. See https://libcxx.llvm.org/TS_deprecation.html

2018-02-24 Thread Marshall Clow via cfe-commits
On Thu, Feb 22, 2018 at 7:06 AM, Nico Weber wrote: > Out of interest, do you know why the non-experimental version doesn't have > to_string()? What are folks supposed to use instead? > std::string has an (explicit) constructor from string_view. -- Marshall

[PATCH] D43700: Emit proper CodeView even when not using the cl driver.

2018-02-24 Thread Reid Kleckner via Phabricator via cfe-commits
rnk accepted this revision. rnk added a comment. This revision is now accepted and ready to land. Lgtm We should go farther, IMO. `clang -g` should default to emitting codeview in an MSVC environment. https://reviews.llvm.org/D43700 ___

[PATCH] D41384: [analyzer] Suppress false positive warnings form security.insecureAPI.strcpy

2018-02-24 Thread András Leitereg via Phabricator via cfe-commits
leanil updated this revision to Diff 135795. leanil marked an inline comment as done. leanil added a comment. Use `getTypeSizeInChars` to get array size. https://reviews.llvm.org/D41384 Files: lib/StaticAnalyzer/Checkers/CheckSecuritySyntaxOnly.cpp test/Analysis/security-syntax-checks.m

[PATCH] D43581: [clang-tidy/google] Improve the Objective-C global variable declaration check 

2018-02-24 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This LGTM! Do you need someone to commit on your behalf? Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D43581 ___ cfe-commits mailing list

r325996 - bpf: Hook target feature "alu32" with LLVM

2018-02-24 Thread Yonghong Song via cfe-commits
Author: yhs Date: Fri Feb 23 15:55:29 2018 New Revision: 325996 URL: http://llvm.org/viewvc/llvm-project?rev=325996=rev Log: bpf: Hook target feature "alu32" with LLVM LLVM has supported a new target feature "alu32" which could be enabled or disabled by "-mattr=[+|-]alu32" when using llc. This

[PATCH] D41102: Setup clang-doc frontend framework

2018-02-24 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Thank you for working on this! Some more thoughts. Comment at: clang-doc/BitcodeWriter.cpp:191 + Record.clear(); + for (const char C : BlockIdNameMap[ID]) Record.push_back(C); + Stream.EmitRecord(llvm::bitc::BLOCKINFO_CODE_BLOCKNAME, Record);

[PATCH] D43590: [clang-format] Fix regression when getStyle() called with empty filename

2018-02-24 Thread Bjorn Pettersson via Phabricator via cfe-commits
bjope added inline comments. Comment at: unittests/Format/FormatTest.cpp:11727 +TEST(FormatStyle, GetStyleWithEmptyFileName) { + auto Style1 = getStyle("file", "", "Google"); + ASSERT_TRUE((bool)Style1); bjope wrote: > Do you really want to try to find a

[PATCH] D43732: Resolve build bot problems in unittests/Format/FormatTest.cpp

2018-02-24 Thread Bjorn Pettersson via Phabricator via cfe-commits
bjope added a comment. This is an attempt to fix problems seen after https://reviews.llvm.org/D43590 Repository: rC Clang https://reviews.llvm.org/D43732 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D43732: Resolve build bot problems in unittests/Format/FormatTest.cpp

2018-02-24 Thread Bjorn Pettersson via Phabricator via cfe-commits
bjope created this revision. Herald added a subscriber: klimek. Make the new GetStyleWithEmptyFileName test case independent of the file system used when running the test. Since the test is supposed to use the fallback "Google" style we now use a InMemoryFileSystem to make sure that we do not

[PATCH] D43731: Fix documentation for SpaceAfterCStyleCast option

2018-02-24 Thread Eric Marti via Phabricator via cfe-commits
EricMarti created this revision. EricMarti added a project: clang-tools-extra. Herald added a subscriber: cfe-commits. I noticed that the example for SpaceAfterCStyleCast does not match its description. I fixed the example after testing it out. Repository: rCTE Clang Tools Extra

[PATCH] D43696: Reduce hash collisions for reference and pointer types

2018-02-24 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev added inline comments. Comment at: lib/AST/ODRHash.cpp:581 + void VisitType(const Type *T) { +ID.AddInteger(T->getTypeClass()); + } rtrieu wrote: > rsmith wrote: > > This looks redundant, the above `Visit(const Type*)` function seems to > >

[libcxx] r326027 - Cleanup __config indention NFC

2018-02-24 Thread Logan Chien via cfe-commits
Author: logan Date: Fri Feb 23 23:57:32 2018 New Revision: 326027 URL: http://llvm.org/viewvc/llvm-project?rev=326027=rev Log: Cleanup __config indention NFC This commit indents each level by two space characters, e.g. #if defined(CONDITION) # define _LIBCPP_NAME VALUE #else # define