[PATCH] D57532: [Index] Make sure c-index-test finds libc++ on Mac

2019-02-07 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 185772. ilya-biryukov added a comment. - Move the string to CIndexer. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57532/new/ https://reviews.llvm.org/D57532 Files:

[PATCH] D57883: [clang-tidy] refactor ExceptionAnalyzer further to give ternary answer

2019-02-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tidy/utils/ExceptionAnalyzer.h:31-192 +enum class ExceptionState : std::int8_t { + Throwing,///< The function can definitly throw given an AST. + NotThrowing, ///< This function can not throw, given an AST. + Unknown,

[PATCH] D57908: [SEMA]Generalize deferred diagnostic interface, NFC.

2019-02-07 Thread Alexey Bataev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL353456: [SEMA]Generalize deferred diagnostic interface, NFC. (authored by ABataev, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Repository: rL LLVM CHANGES

[PATCH] D57893: [analyzer] Fix function macro crash

2019-02-07 Thread Tibor Brunner via Phabricator via cfe-commits
bruntib created this revision. bruntib added reviewers: NoQ, george.karpenkov, Szelethus, xazax.hun. Herald added subscribers: cfe-commits, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware. Herald added a project: clang. When there is a functor-like macro

[PATCH] D57819: [clangd] Reduce number of threads used by BackgroundIndex to number of physical cores.

2019-02-07 Thread Kadir Cetinkaya via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE353422: [clangd] Reduce number of threads used by BackgroundIndex to number of physical… (authored by kadircet, committed by ). Changed prior to commit:

[PATCH] D57906: [CTU] Do not allow different CPP dialects in CTU

2019-02-07 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: xazax.hun, a_sidorin, r.stahl. Herald added subscribers: cfe-commits, gamesh411, Szelethus, dkrupp, rnkovacs. Herald added a project: clang. If CPP dialects are different then return with error. Consider this STL code: template

[PATCH] D55659: [Sema][ObjC] Disallow non-trivial C struct fields in unions

2019-02-07 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. Two minor tweaks, but otherwise LGTM. Comment at: lib/AST/Type.cpp:2273 +const RecordDecl *RD = QT->castAs()->getDecl(); +// C++ classes are ignored. +if

[PATCH] D57896: Variable names rule

2019-02-07 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. does the readability-identifier-naming check need to be changed to support multiple allowed case types? - key: readability-identifier-naming.VariableCase value:camelBack,CamelBack Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D57879: [clangd] Fix an assertion failure in Selection.

2019-02-07 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL353421: [clangd] Fix an assertion failure in Selection. (authored by hokein, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Repository: rL LLVM CHANGES SINCE

[PATCH] D55964: [clang-format][TableGen] Don't add spaces around items in square braces.

2019-02-07 Thread Jordan Rupprecht via Phabricator via cfe-commits
rupprecht updated this revision to Diff 185787. rupprecht added a comment. Herald added a subscriber: arphaman. Herald added a project: clang. - Rebased w/ D56943 patched in so we can override just TableGen in getLLVMStyle() Repository: rG LLVM Github

[PATCH] D57896: Variable names rule

2019-02-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Pretty sure this patch should have gone to llvm-commits, not cfe-commits. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57896/new/ https://reviews.llvm.org/D57896 ___

[PATCH] D57902: [AST] Fix structural inequivalence of operators

2019-02-07 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: shafik, a_sidorin, aaron.ballman. Herald added subscribers: cfe-commits, gamesh411, Szelethus, dkrupp, rnkovacs. Herald added a project: clang. Operators kind was not checked, so we reported e.g. op- to be equal with op+ Repository: rC

[PATCH] D57392: [clangd] Mention indexing in docs.

2019-02-07 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. Herald added a project: clang. Sorry about delaying this. Comment at: docs/clangd.rst:156 +- Passing experimental `-background-index` commandline argument, which will

[PATCH] D57824: [OpenCL][PR40603] In C++ preserve backwards compatibility with OpenCL C v2.0

2019-02-07 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia updated this revision to Diff 185774. Anastasia retitled this revision from "[OpenCL][PR40603] Align the use of extensions in C++ to be backwards compatible with OpenCL C v2.0" to "[OpenCL][PR40603] In C++ preserve backwards compatibility with OpenCL C v2.0". Anastasia edited the

[PATCH] D57893: [analyzer] Fix function macro crash

2019-02-07 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. This revision is now accepted and ready to land. Cheers! Let's wait for a couple days for feedback, and I'll commit on your behalf after that. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57893/new/

[PATCH] D57219: [Fixed Point Arithmetic] Fixed Point Comparisons

2019-02-07 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/lib/CodeGen/CGExprScalar.cpp:3444 case BO_NE: +return Builder.CreateICmpNE(FullLHS, FullRHS); + case BO_Mul: ebevhan wrote: > ebevhan wrote: > > rjmccall wrote: > > > leonardchan wrote: > > > > ebevhan

r353425 - [ASTImporter] Refactor unittests to be able to parameterize them in a more flexible way

2019-02-07 Thread Gabor Marton via cfe-commits
Author: martong Date: Thu Feb 7 08:52:48 2019 New Revision: 353425 URL: http://llvm.org/viewvc/llvm-project?rev=353425=rev Log: [ASTImporter] Refactor unittests to be able to parameterize them in a more flexible way Summary: Currently `TestImportBase` is derived from

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-07 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked an inline comment as done. jyu2 added inline comments. Comment at: lib/AST/Stmt.cpp:628 + DiagOffs = CurPtr-StrStart-1; + return diag::err_asm_invalid_operand_for_goto_labels; +} rsmith wrote: > jyu2 wrote: > > rsmith wrote:

[PATCH] D57896: Variable names rule

2019-02-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In D57896#1389046 , @michaelplatings wrote: > In D57896#1389042 , @lebedev.ri > wrote: > > > Pretty sure this patch should have gone to llvm-commits, not cfe-commits. > > > I just set

[PATCH] D54978: Move the SMT API to LLVM

2019-02-07 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. @mikhail.ramalho could you revert then? In general, we should not use Z3 unless it's explicitly requested. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54978/new/ https://reviews.llvm.org/D54978

[PATCH] D57829: [HIP] Disable emitting llvm.linker.options in device compilation

2019-02-07 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Also, why is this HIP-specific? I thought the toolchain was largely shared with CUDA and there were just a few runtime differences. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57829/new/ https://reviews.llvm.org/D57829

[PATCH] D57915: [COFF, ARM64] Remove definitions for _byteswap library functions

2019-02-07 Thread Tom Tan via Phabricator via cfe-commits
TomTan created this revision. TomTan added reviewers: mgrang, efriedma, mstorsjo. Herald added subscribers: cfe-commits, kristof.beyls, javed.absar. Herald added a project: clang. _byteswap_* functions are are implemented in below file as normal function from libucrt.lib and declared in stdlib.h.

[PATCH] D57914: [Driver] Allow enum SanitizerOrdinal to represent more than 64 different sanitizer checks, NFC.

2019-02-07 Thread pierre gousseau via Phabricator via cfe-commits
pgousseau created this revision. pgousseau added reviewers: rsmith, probinson, gbedwell, filcab, lebedev.ri, wristow. Herald added subscribers: cfe-commits, cryptoad. Herald added a project: clang. enum SanitizerOrdinal has reached maximum capacity, this change extends the capacity to 128

[PATCH] D57874: [WebAssembly] Set '-matomics' when '-pthread' is set

2019-02-07 Thread Dan Gohman via Phabricator via cfe-commits
sunfish added a comment. That sounds reasonable to me too. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57874/new/ https://reviews.llvm.org/D57874 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D57908: [SEMA]Generalize deferred diagnostic interface, NFC.

2019-02-07 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev created this revision. ABataev added reviewers: rjmccall, tra. Herald added a project: clang. Deferred diagnostic interface is going to be used for OpenMP device compilation. Generalized previously existed deferred diagnostic interface for CUDA to be used with OpenMP and, possibly, other

[PATCH] D57896: Variable names rule

2019-02-07 Thread Paul Robinson via Phabricator via cfe-commits
probinson added a comment. Herald added a project: LLVM. In D57896#1389067 , @lebedev.ri wrote: > 2. It might be best to give this more visibility, by submitting a mail to > llvm-dev, with a **noticeable** subject, like "RFC: changing variable naming >

[clang-tools-extra] r353421 - [clangd] Fix an assertion failure in Selection.

2019-02-07 Thread Haojian Wu via cfe-commits
Author: hokein Date: Thu Feb 7 08:00:44 2019 New Revision: 353421 URL: http://llvm.org/viewvc/llvm-project?rev=353421=rev Log: [clangd] Fix an assertion failure in Selection. Summary: The assertion is triggered when the Decl is null. Details for the assertion: F0207 09:55:09.069385 47308

[PATCH] D57891: [analyzer] Fix infinite recursion in printing macros

2019-02-07 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Is there a chance of obtaining a testcase for this? I would very strongly prefer one. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57891/new/ https://reviews.llvm.org/D57891 ___

[PATCH] D54978: Move the SMT API to LLVM

2019-02-07 Thread Brian Rzycki via Phabricator via cfe-commits
brzycki added a comment. This commit is causing a build-break for our nightly cross compilers of arm and aarch64. The immediately preceding commit of D54977 does not break with the exact same invocation. The problem is our build machine (Ubuntu 18.04 LTS)

[PATCH] D54978: Move the SMT API to LLVM

2019-02-07 Thread Shakeel Mahate via Phabricator via cfe-commits
shakeel.mahate added a comment. The ninja build also fails ninja -C out/gn ninja: Entering directory `out/gn' [1/3182] ACTION //clang/test:lit_site_cfg(//llvm/utils/gn/build/toolchain:unix) FAILED: gen/clang/test/lit.site.cfg.py python ../../llvm/utils/gn/build/write_cmake_config.py -o

[PATCH] D57908: [SEMA]Generalize deferred diagnostic interface, NFC.

2019-02-07 Thread Artem Belevich via Phabricator via cfe-commits
tra accepted this revision. tra added a comment. This revision is now accepted and ready to land. LGTM. I've added jlebar@ as he's originally written the code. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57908/new/ https://reviews.llvm.org/D57908

[clang-tools-extra] r353423 - [clangd] Mention indexing in docs.

2019-02-07 Thread Kadir Cetinkaya via cfe-commits
Author: kadircet Date: Thu Feb 7 08:10:39 2019 New Revision: 353423 URL: http://llvm.org/viewvc/llvm-project?rev=353423=rev Log: [clangd] Mention indexing in docs. Reviewers: sammccall Subscribers: ilya-biryukov, ioeric, MaskRay, jkorous, arphaman, cfe-commits Differential Revision:

[PATCH] D57905: [ASTImporter][ASTImporterSpecificLookup] Add test for different operators

2019-02-07 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: a_sidorin, shafik. Herald added subscribers: cfe-commits, gamesh411, Szelethus, dkrupp, rnkovacs. Herald added a reviewer: a.sidorin. Herald added a project: clang. This is to check that operators are handled properly in

[PATCH] D57874: [WebAssembly] Set '-matomics' when '-pthread' is set

2019-02-07 Thread Derek Schuff via Phabricator via cfe-commits
dschuff added a comment. So this CL has the effect that setting `-pthreads` will also set `-matomics`. Currently as you mentioned we have the problem that we can't make our current logic of "do we lower away the atomics" be controlled by the target features because it's done at pass config time

[PATCH] D43737: Improve -Winfinite-recursion

2019-02-07 Thread Steven Wu via Phabricator via cfe-commits
steven_wu added a comment. Herald added a project: LLVM. Sorry for following up late on the patch. Removing the reachability testing for the exit block causes false positive for infinite loop cases like this: void l() { static int count = 5; if (count >0) { count--; l();

[PATCH] D57819: [clangd] Reduce number of threads used by BackgroundIndex to number of physical cores.

2019-02-07 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov accepted this revision. ilya-biryukov added a comment. This revision is now accepted and ready to land. LGTM. NIT about a description: we can't be 100% certain that it's related to hyper-threading, so I'd avoid putting that to the description, maybe simply mention that this avoids

[clang-tools-extra] r353422 - [clangd] Reduce number of threads used by BackgroundIndex to number of physical cores.

2019-02-07 Thread Kadir Cetinkaya via cfe-commits
Author: kadircet Date: Thu Feb 7 08:04:30 2019 New Revision: 353422 URL: http://llvm.org/viewvc/llvm-project?rev=353422=rev Log: [clangd] Reduce number of threads used by BackgroundIndex to number of physical cores. Summary: clangd is using as many threads as logical cores for BackgroundIndex

[PATCH] D57532: [Index] Make sure c-index-test finds libc++ on Mac

2019-02-07 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 185775. ilya-biryukov added a comment. - Simplify code Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57532/new/ https://reviews.llvm.org/D57532 Files: clang/test/Index/record-completion-invocation.c

[PATCH] D57824: [OpenCL][PR40603] In C++ preserve backwards compatibility with OpenCL C v2.0

2019-02-07 Thread Sven van Haastregt via Phabricator via cfe-commits
svenvh accepted this revision. svenvh added a comment. This revision is now accepted and ready to land. Even nicer to have it only inside the extension logic indeed. LGTM. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57824/new/ https://reviews.llvm.org/D57824

[PATCH] D57392: [clangd] Mention indexing in docs.

2019-02-07 Thread Kadir Cetinkaya via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE353423: [clangd] Mention indexing in docs. (authored by kadircet, committed by ). Changed prior to commit: https://reviews.llvm.org/D57392?vs=185777=185781#toc Repository: rCTE Clang Tools Extra

[PATCH] D57322: [ASTImporter] Refactor unittests to be able to parameterize them in a more flexible way

2019-02-07 Thread Gabor Marton via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC353425: [ASTImporter] Refactor unittests to be able to parameterize them in a more… (authored by martong, committed by ). Changed prior to commit: https://reviews.llvm.org/D57322?vs=184694=185786#toc

[PATCH] D57768: [SYCL] Add SYCL device compilation flow.

2019-02-07 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D57768#1386862 , @Anastasia wrote: > - SYCL seem to require adding tight dependencies from the standard libraries > into the compiler because many language features are hidden behind library > classes. This is not common for

[PATCH] D57901: [ASTImporter] Add test RedeclChainShouldBeCorrectAmongstNamespaces

2019-02-07 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: a_sidorin, shafik. Herald added subscribers: cfe-commits, gamesh411, Szelethus, dkrupp, rnkovacs. Herald added a reviewer: a.sidorin. Herald added a project: clang. We add a new test to show that redecl chains are not handled properly

[PATCH] D57910: [ASTImporter] Find previous friend function template

2019-02-07 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added reviewers: a_sidorin, shafik. Herald added subscribers: cfe-commits, gamesh411, Szelethus, dkrupp, rnkovacs. Herald added a reviewer: a.sidorin. Herald added a project: clang. Repository: rC Clang https://reviews.llvm.org/D57910 Files:

[clang-tools-extra] r353415 - [ELF] Format lines inadvertently indented by rCTE353380

2019-02-07 Thread Fangrui Song via cfe-commits
Author: maskray Date: Thu Feb 7 07:38:14 2019 New Revision: 353415 URL: http://llvm.org/viewvc/llvm-project?rev=353415=rev Log: [ELF] Format lines inadvertently indented by rCTE353380 Modified: clang-tools-extra/trunk/clangd/SourceCode.h Modified:

[libunwind] r353414 - Creating release candidate rc2 from release_800 branch

2019-02-07 Thread Hans Wennborg via cfe-commits
Author: hans Date: Thu Feb 7 07:36:17 2019 New Revision: 353414 URL: http://llvm.org/viewvc/llvm-project?rev=353414=rev Log: Creating release candidate rc2 from release_800 branch Added: libunwind/tags/RELEASE_800/rc2/ - copied from r353413, libunwind/branches/release_80/

[libclc] r353414 - Creating release candidate rc2 from release_800 branch

2019-02-07 Thread Hans Wennborg via cfe-commits
Author: hans Date: Thu Feb 7 07:36:17 2019 New Revision: 353414 URL: http://llvm.org/viewvc/llvm-project?rev=353414=rev Log: Creating release candidate rc2 from release_800 branch Added: libclc/tags/RELEASE_800/rc2/ - copied from r353413, libclc/branches/release_80/

[PATCH] D57896: Variable names rule

2019-02-07 Thread Michael Platings via Phabricator via cfe-commits
michaelplatings created this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Following discussion and general agreement that the current naming rule for variables is not ideal, this patch

[PATCH] D57893: [analyzer] Fix function macro crash

2019-02-07 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus requested changes to this revision. Szelethus added a comment. This revision now requires changes to proceed. Actually, reproducing this with a testcase would be much preferred here too. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57893/new/

[PATCH] D57392: [clangd] Mention indexing in docs.

2019-02-07 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet updated this revision to Diff 185777. kadircet marked 2 inline comments as done. kadircet added a comment. Address comments Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57392/new/ https://reviews.llvm.org/D57392 Files: docs/clangd.rst

[PATCH] D57892: [analyzer] Fix macro printer crash when macro comes from another translation unit

2019-02-07 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a reviewer: martong. Szelethus added a comment. This revision is now accepted and ready to land. Yup, cheers! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57892/new/ https://reviews.llvm.org/D57892

[PATCH] D56943: [clang-format][NFC] Allow getLLVMStyle() to take a language

2019-02-07 Thread Jordan Rupprecht via Phabricator via cfe-commits
rupprecht added a comment. In D56943#1388985 , @rupprecht wrote: > In D56943#1388314 , @kristina wrote: > > > The patch itself looks sound. However given that you have a specific use > > case in mind (TableGen

[PATCH] D57896: Variable names rule

2019-02-07 Thread Michael Platings via Phabricator via cfe-commits
michaelplatings added a comment. In D57896#1389042 , @lebedev.ri wrote: > Pretty sure this patch should have gone to llvm-commits, not cfe-commits. I just set the repository, Phabricator did the rest - apparently the magic isn't working so well.

r353431 - [OpenCL][PR40603] In C++ preserve compatibility with OpenCL C v2.0

2019-02-07 Thread Anastasia Stulova via cfe-commits
Author: stulova Date: Thu Feb 7 09:32:37 2019 New Revision: 353431 URL: http://llvm.org/viewvc/llvm-project?rev=353431=rev Log: [OpenCL][PR40603] In C++ preserve compatibility with OpenCL C v2.0 Valid OpenCL C code should still compile in C++ mode. This change enables extensions and OpenCL

[PATCH] D57824: [OpenCL][PR40603] In C++ preserve backwards compatibility with OpenCL C v2.0

2019-02-07 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL353431: [OpenCL][PR40603] In C++ preserve compatibility with OpenCL C v2.0 (authored by stulova, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to

[PATCH] D57874: [WebAssembly] Set '-matomics' when '-pthread' is set

2019-02-07 Thread Derek Schuff via Phabricator via cfe-commits
dschuff added a comment. Oh I guess another option would just be to pin all 3 flags together here, but since `-pthread` sets a preprocessor define and may also affect linker behavior, I think it's fine to allow atomic codegen without setting `-pthread`. Repository: rC Clang CHANGES SINCE

r353456 - [SEMA]Generalize deferred diagnostic interface, NFC.

2019-02-07 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Thu Feb 7 11:46:42 2019 New Revision: 353456 URL: http://llvm.org/viewvc/llvm-project?rev=353456=rev Log: [SEMA]Generalize deferred diagnostic interface, NFC. Summary: Deferred diagnostic interface is going to be used for OpenMP device compilation. Generalized previously

[clang-tools-extra] r353413 - [clangd] Use Dex for dynamic index by default.

2019-02-07 Thread Eric Liu via cfe-commits
Author: ioeric Date: Thu Feb 7 07:34:37 2019 New Revision: 353413 URL: http://llvm.org/viewvc/llvm-project?rev=353413=rev Log: [clangd] Use Dex for dynamic index by default. Summary: Memory usage for a sample TU: Without Dex: 17.9M WithDex: 24.4M The memory increase is considerable but

[PATCH] D54395: [clang-tidy] implement utility-function to add 'const' to variables

2019-02-07 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. Herald added a project: clang. ping Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54395/new/ https://reviews.llvm.org/D54395 ___ cfe-commits mailing list

[PATCH] D57883: [clang-tidy] refactor ExceptionAnalyzer further to give ternary answer

2019-02-07 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth marked 2 inline comments as done. JonasToth added inline comments. Comment at: clang-tidy/utils/ExceptionAnalyzer.h:31-192 +enum class ExceptionState : std::int8_t { + Throwing,///< The function can definitly throw given an AST. + NotThrowing, ///< This function

[PATCH] D57878: [clangd] Use Dex for dynamic index by default.

2019-02-07 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 185762. ioeric added a comment. - Keep the option for now. Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57878/new/ https://reviews.llvm.org/D57878 Files: clangd/tool/ClangdMain.cpp Index:

[PATCH] D57878: [clangd] Use Dex for dynamic index by default.

2019-02-07 Thread Eric Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE353413: [clangd] Use Dex for dynamic index by default. (authored by ioeric, committed by ). Changed prior to commit: https://reviews.llvm.org/D57878?vs=185762=185763#toc Repository: rCTE Clang

[PATCH] D57879: [clangd] Fix an assertion failure in Selection.

2019-02-07 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 185771. hokein added a comment. Remove an unexpected change. Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57879/new/ https://reviews.llvm.org/D57879 Files: clangd/Selection.cpp

[PATCH] D57879: [clangd] Fix an assertion failure in Selection.

2019-02-07 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 185770. hokein added a comment. Add reproduce testcase. Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57879/new/ https://reviews.llvm.org/D57879 Files: clangd/Selection.cpp

[PATCH] D56943: [clang-format][NFC] Allow getLLVMStyle() to take a language

2019-02-07 Thread Jordan Rupprecht via Phabricator via cfe-commits
rupprecht added a comment. In D56943#1388314 , @kristina wrote: > The patch itself looks sound. However given that you have a specific use case > in mind (TableGen files) could you provide supplementary coverage for that > specific use case (unit tests

[PATCH] D57874: [WebAssembly] Set '-matomics' when '-pthread' is set

2019-02-07 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 added a comment. Yes it makes sense to me to set `-mthread-model=posix` when `-pthread` is passed on the commandline. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57874/new/ https://reviews.llvm.org/D57874

[PATCH] D57918: Add an attribute that causes clang to emit fortified calls to C stdlib functions

2019-02-07 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington created this revision. erik.pilkington added reviewers: aaron.ballman, rjmccall, eli.friedman. Herald added subscribers: dexonsmith, jkorous. Herald added a project: clang. This attribute applies to declarations of C stdlib functions (sprintf, memcpy...) that have known fortified

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-07 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added inline comments. Comment at: lib/AST/Stmt.cpp:628 + DiagOffs = CurPtr-StrStart-1; + return diag::err_asm_invalid_operand_for_goto_labels; +} efriedma wrote: > jyu2 wrote: > > rsmith wrote: > > > jyu2 wrote: > > > >

[PATCH] D57797: Variable auto-init: fix __block initialization

2019-02-07 Thread JF Bastien via Phabricator via cfe-commits
jfb updated this revision to Diff 185883. jfb added a comment. - Only initialize __block's storage. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57797/new/ https://reviews.llvm.org/D57797 Files: lib/CodeGen/CGDecl.cpp

[PATCH] D57874: [WebAssembly] Make thread-related options consistent

2019-02-07 Thread Dan Gohman via Phabricator via cfe-commits
sunfish added a comment. > - `-matomics` means `-mthread-model posix` The others sound reasonable, though this one seems a little surprising -- a user might have -matomics enabled because they're targeting a VM that has atomics, but still not want to use -mthread-model posix because their code

[PATCH] D57797: Variable auto-init: fix __block initialization

2019-02-07 Thread JF Bastien via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rC353495: Variable auto-init: fix __block initialization (authored by jfb, committed by ). Changed prior to commit:

r353495 - Variable auto-init: fix __block initialization

2019-02-07 Thread JF Bastien via cfe-commits
Author: jfb Date: Thu Feb 7 17:29:17 2019 New Revision: 353495 URL: http://llvm.org/viewvc/llvm-project?rev=353495=rev Log: Variable auto-init: fix __block initialization Summary: Automatic initialization [1] of __block variables was trampling over the block's headers after they'd been

[PATCH] D57935: [Sema] Make string literal init an rvalue.

2019-02-07 Thread Eli Friedman via Phabricator via cfe-commits
efriedma created this revision. efriedma added a reviewer: rsmith. Herald added a project: clang. This allows substantially simplifying the expression evaluation code, because we don't have to special-case lvalues which are actually string literal initialization. This currently throws away an

r353459 - [Sema][ObjC] Disallow non-trivial C struct fields in unions.

2019-02-07 Thread Akira Hatanaka via cfe-commits
Author: ahatanak Date: Thu Feb 7 12:21:46 2019 New Revision: 353459 URL: http://llvm.org/viewvc/llvm-project?rev=353459=rev Log: [Sema][ObjC] Disallow non-trivial C struct fields in unions. This patch fixes a bug where clang doesn’t reject union fields of non-trivial C struct types. For

[PATCH] D57855: [analyzer] Reimplement checker options

2019-02-07 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a reviewer: aaron.ballman. Szelethus added a comment. Aaron, you recently changed these file too, if you have the time, I'll happily listen to your feedback :) Also, I was thinking that maybe we could just `std::move` `CheckerRegisrty::Checkers` and `CheckerRegisrty::Packages`

[PATCH] D57230: [analyzer] Toning down invalidation a bit

2019-02-07 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. That's the one: typedef __typeof(sizeof(int)) size_t; void *malloc(size_t); void escape(int **); struct S { int *ptr; }; void foo() { struct S s1; s1.ptr = malloc(sizeof(int)); escape(); } After the patch the allocated symbol no longer

[PATCH] D57906: [CTU] Do not allow different CPP dialects in CTU

2019-02-07 Thread Aleksei Sidorin via Phabricator via cfe-commits
a_sidorin added a comment. Hi Gabor, Please find my comments inline. Comment at: lib/CrossTU/CrossTranslationUnit.cpp:232 + + // We do not support CTU across languages (C vs C++). if (LangTo.CPlusPlus != LangFrom.CPlusPlus) { The comment change looks

[PATCH] D57915: [COFF, ARM64] Remove definitions for _byteswap library functions

2019-02-07 Thread Eli Friedman via Phabricator via cfe-commits
efriedma accepted this revision. efriedma added a comment. This revision is now accepted and ready to land. I guess we can track inlining separately, if you want to merge this quickly to unblock the Chrome build. LGTM > the former provides global declaration which seems inherited by the >

[PATCH] D57797: Variable auto-init: fix __block initialization

2019-02-07 Thread JF Bastien via Phabricator via cfe-commits
jfb marked 3 inline comments as done. jfb added inline comments. Comment at: lib/CodeGen/CGDecl.cpp:1643 CharUnits Size = getContext().getTypeSizeInChars(type); if (!Size.isZero()) { switch (trivialAutoVarInit) { rjmccall wrote: > jfb wrote: > >

[PATCH] D57797: Variable auto-init: fix __block initialization

2019-02-07 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: lib/CodeGen/CGDecl.cpp:1726 +emitByrefStructureInit(emission); + } + jfb wrote: > Note that we still want this to be pulled out in this way because > `emitByrefStructureInit` emits the call to the initializer (in

[PATCH] D57874: [WebAssembly] Make thread-related options consistent

2019-02-07 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 added inline comments. Comment at: lib/Driver/ToolChains/WebAssembly.cpp:66 +if (Args.hasFlag(clang::driver::options::OPT_pthread, + clang::driver::options::OPT_no_pthread), +false) aheejin wrote: > This code is not

r353493 - [COFF, ARM64] Fix types for _ReadStatusReg, _WriteStatusReg

2019-02-07 Thread Eli Friedman via cfe-commits
Author: efriedma Date: Thu Feb 7 17:17:49 2019 New Revision: 353493 URL: http://llvm.org/viewvc/llvm-project?rev=353493=rev Log: [COFF, ARM64] Fix types for _ReadStatusReg, _WriteStatusReg r344765 added those intrinsics, but used the wrong types. Patch by Mike Hommey Differential Revision:

[PATCH] D57636: [COFF, ARM64] Fix types for _ReadStatusReg, _WriteStatusReg

2019-02-07 Thread Eli Friedman via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL353493: [COFF, ARM64] Fix types for _ReadStatusReg, _WriteStatusReg (authored by efriedma, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-02-07 Thread Rui Ueyama via Phabricator via cfe-commits
ruiu added a comment. Overall looks good. > Do you mean that of those three options, the last one specified should take > precedence? Yes. Comment at: ELF/Config.h:191 bool ZGlobal; + GnuStackKind ZGnustack; bool ZHazardplt; Members are (roughly)

[PATCH] D57797: Variable auto-init: fix __block initialization

2019-02-07 Thread JF Bastien via Phabricator via cfe-commits
jfb marked 2 inline comments as done. jfb added inline comments. Comment at: lib/CodeGen/CGDecl.cpp:1605 -emitByrefStructureInit(emission); - // Initialize the variable here if it doesn't have a initializer and it is a rjmccall wrote: > Are these changes

[PATCH] D57636: [COFF, ARM64] Fix types for _ReadStatusReg, _WriteStatusReg

2019-02-07 Thread Eli Friedman via Phabricator via cfe-commits
efriedma accepted this revision. efriedma added a comment. This revision is now accepted and ready to land. LGTM. Do you want me to commit this for you? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57636/new/ https://reviews.llvm.org/D57636

[PATCH] D57874: [WebAssembly] Make thread-related options consistent

2019-02-07 Thread Sam Clegg via Phabricator via cfe-commits
sbc100 added a comment. In D57874#1389981 , @sunfish wrote: > > - `-matomics` means `-mthread-model posix` > > The others sound reasonable, though this one seems a little surprising -- a > user might have -matomics enabled because they're targeting a VM

Buildbot numbers for the week of 01/27/2019 - 02/02/2019

2019-02-07 Thread Galina Kistanova via cfe-commits
Hello everyone, Below are some buildbot numbers for the last week of 01/27/2019 - 02/02/2019. Please see the same data in attached csv files: The longest time each builder was red during the week; "Status change ratio" by active builder (percent of builds that changed the builder status from

Buildbot numbers for the week of 01/20/2019 - 01/26/2019

2019-02-07 Thread Galina Kistanova via cfe-commits
Hello everyone, Below are some buildbot numbers for the week of 01/20/2019 - 01/26/2019. Please see the same data in attached csv files: The longest time each builder was red during the week; "Status change ratio" by active builder (percent of builds that changed the builder status from greed

[PATCH] D55659: [Sema][ObjC] Disallow non-trivial C struct fields in unions

2019-02-07 Thread Akira Hatanaka via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. ahatanak marked 2 inline comments as done. Closed by commit rL353459: [Sema][ObjC] Disallow non-trivial C struct fields in unions. (authored by ahatanak, committed by ). Herald added a project: LLVM. Herald added a

[PATCH] D57915: [COFF, ARM64] Remove definitions for _byteswap library functions

2019-02-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In D57915#1389549 , @TomTan wrote: > Added the tests back. Clang IR should not lower these to bswap calls because > they are global library functions. It might be slower to make the call to > library function than bswap, but

[PATCH] D57674: [clang-tidy] Add options to bugprone-argument-comment to add missing argument comments to literals

2019-02-07 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM aside from a testing nit. Comment at: clang-tidy/bugprone/ArgumentCommentCheck.cpp:231 +bool ArgumentCommentCheck::shouldAddComment(const Expr *Arg) const

[PATCH] D57915: [COFF, ARM64] Remove definitions for _byteswap library functions

2019-02-07 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In D57915#1389722 , @TomTan wrote: > In D57915#1389560 , @lebedev.ri > wrote: > > > In D57915#1389549 , @TomTan wrote: > > > > > Added the tests

[PATCH] D57902: [AST] Fix structural inequivalence of operators

2019-02-07 Thread Aleksei Sidorin via Phabricator via cfe-commits
a_sidorin accepted this revision. a_sidorin added a comment. This revision is now accepted and ready to land. Looks good, thanks! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57902/new/ https://reviews.llvm.org/D57902

[PATCH] D57636: [COFF, ARM64] Fix types for _ReadStatusReg, _WriteStatusReg

2019-02-07 Thread Mike Hommey via Phabricator via cfe-commits
glandium added a comment. @efriedma can you take another look? Ideally, this should be backported to the release_80 branch, so that would need to be landed asap. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57636/new/ https://reviews.llvm.org/D57636

[PATCH] D57874: [WebAssembly] Set '-matomics' when '-pthread' is set

2019-02-07 Thread Heejin Ahn via Phabricator via cfe-commits
aheejin updated this revision to Diff 185895. aheejin added a comment. Sorry nevermind my previous code. There was not hacky and much cleaner way to do everything in the driver layer. (Before I tried to do everything in the cc1 compilation layer :( ) Anyway, moved all logic to the driver layer

[PATCH] D57874: [WebAssembly] Set '-matomics' when '-pthread' is set

2019-02-07 Thread Heejin Ahn via Phabricator via cfe-commits
aheejin marked an inline comment as done. aheejin added inline comments. Comment at: lib/Driver/ToolChains/WebAssembly.cpp:66 +if (Args.hasFlag(clang::driver::options::OPT_pthread, + clang::driver::options::OPT_no_pthread), +false)

[PATCH] D57915: [COFF, ARM64] Remove definitions for _byteswap library functions

2019-02-07 Thread Tom Tan via Phabricator via cfe-commits
TomTan updated this revision to Diff 185849. TomTan added a comment. Added the tests back. Clang IR should not lower these to bswap calls because they are global library functions. It might be slower to make the call to library function than bswap, but this is the same for other architectures

[PATCH] D57855: [analyzer] Reimplement checker options

2019-02-07 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 185861. Szelethus edited the summary of this revision. Szelethus added a comment. Moved all `AnalyzerOptions` related changes to a separate revision. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57855/new/ https://reviews.llvm.org/D57855 Files:

[PATCH] D57896: Variable names rule

2019-02-07 Thread Hubert Tong via Phabricator via cfe-commits
hubert.reinterpretcast added a comment. I am generally in favour of this direction. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57896/new/ https://reviews.llvm.org/D57896 ___ cfe-commits mailing

  1   2   >