[PATCH] D68101: [MC][ELF] Prevent globals with an explicit section from being mergeable

2020-01-03 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D68101#1804006 , @bd1976llvm wrote: > I looked into these today. I think we can do the first of these. I have put a > WIP patch up here: https://reviews.llvm.org/D72194. Could you comment on the > approach taken? Thank you.

[PATCH] D71903: [Coroutines][6/6] Clang schedules new passes

2020-01-03 Thread Brian Gesiak via Phabricator via cfe-commits
modocache added a comment. I'm currently working on ensuring that CGSCC optimizations are rerun to optimize coroutine funclets -- the primary feedback I received on this and on D71899 -- but I just realized I didn't respond to one comment on this set of reviews

[PATCH] D68101: [MC][ELF] Prevent globals with an explicit section from being mergeable

2020-01-03 Thread ben via Phabricator via cfe-commits
bd1976llvm added a comment. In D68101#1802280 , @rjmccall wrote: > The solution described in that comment is not acceptable. We are not going > to tell users that they cannot assign symbols explicitly to sections because > LLVM is unable to promise not

[PATCH] D54943: [clang-tidy] implement const-transformation for cppcoreguidelines-const-correctness

2020-01-03 Thread Florin Iucha via Phabricator via cfe-commits
0x8000- added a comment. Indicated where the new test code should go. Comment at: clang-tools-extra/test/clang-tidy/checkers/cppcoreguidelines-const-correctness-values.cpp:608 +} + +template Please insert the this test code here: ``` struct IntWrapper {

[PATCH] D54943: [clang-tidy] implement const-transformation for cppcoreguidelines-const-correctness

2020-01-03 Thread Florin Iucha via Phabricator via cfe-commits
0x8000- added a comment. In D54943#1803448 , @JonasToth wrote: > In D54943#1800182 , @0x8000- > wrote: > > > F11163406: 0001-Add-extra-tests.patch > > shows a couple of

[PATCH] D72140: [clang-tools-extra] NFC: Fix trivial typos in comments

2020-01-03 Thread Kazuaki Ishizaki via Phabricator via cfe-commits
kiszk added a comment. I do not have commit rights to the repository. Could someone commit this change if it is OK? Kazuaki Ishizaki Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72140/new/ https://reviews.llvm.org/D72140 _

[PATCH] D72114: [MS] Overhaul how clang passes overaligned args on x86_32

2020-01-03 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/include/clang/CodeGen/CGFunctionInfo.h:91 bool InAllocaSRet : 1;// isInAlloca() + bool InAllocaIndirect : 1;// isInAlloca() bool IndirectByVal : 1; // isIndirect() rnk wrote: > rnk wrote: > > rjmccall

[PATCH] D72121: [clang-tidy] Fix readability-identifier-naming missing member variables

2020-01-03 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 236157. njames93 added a comment. addressed issues. Running the clang-tidy on the whole of lib clang just resulted in errors when compiling due to its dependancy on llvm, but I kind of knew that was going to happen CHANGES SINCE LAST ACTION https://revi

[PATCH] D71037: [Diagnostic] Add ftabstop to -Wmisleading-indentation

2020-01-03 Thread Tyker via Phabricator via cfe-commits
Tyker closed this revision. Tyker added a comment. In D71037#1803704 , @mstorsjo wrote: > In D71037#1803574 , @Tyker wrote: > > > In D71037#1803361 , @xbolva00 > > wrote: >

[clang] c4766ca - [Diagnostic] Add test for previous b4b904e19bb356724b2c6aea0199ce05c6f15cdb

2020-01-03 Thread via cfe-commits
Author: Tyker Date: 2020-01-04T01:41:21+01:00 New Revision: c4766cadcb38172c2843d65559060e0ae623b6eb URL: https://github.com/llvm/llvm-project/commit/c4766cadcb38172c2843d65559060e0ae623b6eb DIFF: https://github.com/llvm/llvm-project/commit/c4766cadcb38172c2843d65559060e0ae623b6eb.diff LOG: [D

[PATCH] D72097: [LifetimeAnalysis] Do not forbid void deref type in gsl::Pointer/gsl::Owner annotations

2020-01-03 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun marked 2 inline comments as done. xazax.hun added inline comments. Comment at: clang/include/clang/Basic/AttrDocs.td:4619 This attribute may be used by analysis tools and has no effect on code -generation. +generation. A ``void`` argument means that the pointer cna poi

[PATCH] D72097: [LifetimeAnalysis] Do not forbid void deref type in gsl::Pointer/gsl::Owner annotations

2020-01-03 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun updated this revision to Diff 236150. xazax.hun added a comment. - Fix typo. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72097/new/ https://reviews.llvm.org/D72097 Files: clang/include/clang/Basic/AttrDocs.td clang/include/clang/Basic/DiagnosticSemaKinds.td clang/lib/

[PATCH] D72097: [LifetimeAnalysis] Do not forbid void deref type in gsl::Pointer/gsl::Owner annotations

2020-01-03 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso added inline comments. Comment at: clang/include/clang/Basic/AttrDocs.td:4619 This attribute may be used by analysis tools and has no effect on code -generation. +generation. A ``void`` argument means that the pointer cna point to any type. `cna` typo

[PATCH] D72097: [LifetimeAnalysis] Do not forbid void deref type in gsl::Pointer/gsl::Owner annotations

2020-01-03 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun updated this revision to Diff 236148. xazax.hun added a comment. - Update the documentation. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72097/new/ https://reviews.llvm.org/D72097 Files: clang/include/clang/Basic/AttrDocs.td clang/include/clang/Basic/DiagnosticSemaKinds

[PATCH] D72188: [fuchsia] Enable Clang Static Analyzer

2020-01-03 Thread Gábor Horváth via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG0458e63d28a6: [fuchsia] Enable Clang Static Analyzer (authored by xazax.hun). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72188/new/ https://reviews.llvm.

[clang] 0458e63 - [fuchsia] Enable Clang Static Analyzer

2020-01-03 Thread Gabor Horvath via cfe-commits
Author: Gabor Horvath Date: 2020-01-03T15:49:32-08:00 New Revision: 0458e63d28a6685dae3d17cc210ef838be533612 URL: https://github.com/llvm/llvm-project/commit/0458e63d28a6685dae3d17cc210ef838be533612 DIFF: https://github.com/llvm/llvm-project/commit/0458e63d28a6685dae3d17cc210ef838be533612.diff

[PATCH] D72188: [fuchsia] Enable Clang Static Analyzer

2020-01-03 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun created this revision. xazax.hun added a reviewer: phosek. xazax.hun added a project: clang. Herald added subscribers: Charusso, gamesh411, dkrupp, donat.nagy, Szelethus, a.sidorin, rnkovacs, baloghadamsoftware, mgorny. phosek accepted this revision. phosek added a comment. This revision

[PATCH] D72188: [fuchsia] Enable Clang Static Analyzer

2020-01-03 Thread Petr Hosek via Phabricator via cfe-commits
phosek accepted this revision. phosek added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72188/new/ https://reviews.llvm.org/D72188 ___

[PATCH] D69868: Allow "callbr" to return non-void values

2020-01-03 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added subscribers: MaskRay, echristo. rnk added a comment. More reviewers: +@echristo @MaskRay Comment at: llvm/include/llvm/CodeGen/MachineBasicBlock.h:133 + /// Indicate that this basic block is the indirect dest of an INLINEASM_BR. + bool IsInlineAsmBrIndirectPad = fal

[PATCH] D72114: [MS] Overhaul how clang passes overaligned args on x86_32

2020-01-03 Thread Reid Kleckner via Phabricator via cfe-commits
rnk marked an inline comment as done. rnk added inline comments. Comment at: clang/include/clang/CodeGen/CGFunctionInfo.h:91 bool InAllocaSRet : 1;// isInAlloca() + bool InAllocaIndirect : 1;// isInAlloca() bool IndirectByVal : 1; // isIndirect() rnk

[PATCH] D72114: [MS] Overhaul how clang passes overaligned args on x86_32

2020-01-03 Thread Reid Kleckner via Phabricator via cfe-commits
rnk marked 2 inline comments as done. rnk added inline comments. Comment at: clang/include/clang/CodeGen/CGFunctionInfo.h:91 bool InAllocaSRet : 1;// isInAlloca() + bool InAllocaIndirect : 1;// isInAlloca() bool IndirectByVal : 1; // isIndirect() rjm

[PATCH] D71037: [Diagnostic] Add ftabstop to -Wmisleading-indentation

2020-01-03 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added a comment. In D71037#1803574 , @Tyker wrote: > In D71037#1803361 , @xbolva00 wrote: > > > Can you add a test case for that crash? Otherwise OK. > > > as i said. the bug can only occur for one line fil

[clang-tools-extra] 48ee040 - [clang-tidy] fix linkage with clangSema for FixitHintUtils, undo previous wrong fix

2020-01-03 Thread Jonas Toth via cfe-commits
Author: Jonas Toth Date: 2020-01-03T22:32:10+01:00 New Revision: 48ee04033cce2e085fd8909c6ebaa0de68ab65d0 URL: https://github.com/llvm/llvm-project/commit/48ee04033cce2e085fd8909c6ebaa0de68ab65d0 DIFF: https://github.com/llvm/llvm-project/commit/48ee04033cce2e085fd8909c6ebaa0de68ab65d0.diff LO

[PATCH] D71037: [Diagnostic] Add ftabstop to -Wmisleading-indentation

2020-01-03 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. Ah, true. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71037/new/ https://reviews.llvm.org/D71037 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D72110: [X86] ABI compat bugfix for MSVC vectorcall

2020-01-03 Thread pre-merge checks [bot] via Phabricator via cfe-commits
merge_guards_bot added a comment. {icon check-circle color=green} Unit tests: pass. 61177 tests passed, 0 failed and 729 were skipped. {icon times-circle color=red} clang-tidy: fail. Please fix clang-tidy findings

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

2020-01-03 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. In D54395#1803552 , @thakis wrote: > This breaks tests on Windows: http://45.33.8.238/win/5061/step_8.txt > > Please take a look, and if takes a while to investigate, please revert in the > meantime. (Probably needs the fno-dela

[clang-tools-extra] fed2a50 - [clang-tidy] quickfix: add -fno-delayed-template-parsing as default argument for runCheckOnCode unit-tests to unbreak windows

2020-01-03 Thread Jonas Toth via cfe-commits
Author: Jonas Toth Date: 2020-01-03T22:02:11+01:00 New Revision: fed2a5033af564af390faa8f8438018fe747126a URL: https://github.com/llvm/llvm-project/commit/fed2a5033af564af390faa8f8438018fe747126a DIFF: https://github.com/llvm/llvm-project/commit/fed2a5033af564af390faa8f8438018fe747126a.diff LO

[PATCH] D71037: [Diagnostic] Add ftabstop to -Wmisleading-indentation

2020-01-03 Thread Tyker via Phabricator via cfe-commits
Tyker added a comment. In D71037#1803361 , @xbolva00 wrote: > Can you add a test case for that crash? Otherwise OK. as i said. the bug can only occur for one line files. so we can't have a run line and a the crashing line. so i wasn't able to make a tes

[PATCH] D72110: [X86] ABI compat bugfix for MSVC vectorcall

2020-01-03 Thread Reid Kleckner via Phabricator via cfe-commits
rnk updated this revision to Diff 236115. rnk added a comment. - ZYXMM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72110/new/ https://reviews.llvm.org/D72110 Files: clang/include/clang/CodeGen/CGFunctionInfo.h clang/lib/CodeGen/TargetInfo.cp

[clang-tools-extra] 05ebaa6 - [clang-tidy] fix broken linking for AddConstTest with adding clangSema as dependency (DeclSpec)

2020-01-03 Thread Jonas Toth via cfe-commits
Author: Jonas Toth Date: 2020-01-03T21:55:51+01:00 New Revision: 05ebaa62e0db67d7a04d47b2f50eb2faa8597cc8 URL: https://github.com/llvm/llvm-project/commit/05ebaa62e0db67d7a04d47b2f50eb2faa8597cc8 DIFF: https://github.com/llvm/llvm-project/commit/05ebaa62e0db67d7a04d47b2f50eb2faa8597cc8.diff LO

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

2020-01-03 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. This breaks tests on Windows: http://45.33.8.238/win/5061/step_8.txt Please take a look, and if takes a while to investigate, please revert in the meantime. (Probably needs the fno-delayed-template-instantiation kludge that's in many other tests.) Repository: rG LLVM

[PATCH] D70764: build: reduce CMake handling for zlib

2020-01-03 Thread Khem Raj via Phabricator via cfe-commits
raj.khem added a comment. this is now in master, and I am seeing build failures in cross-building clang, e.g. when building clang for arm on a x86_64 host. its resorting to finding, libz from buildhost instead of target sysroot ( using --sysroot) and failing in link step. e.g. FAILED: bin/llvm

[clang] c0f1eac - [SystemZ] Don't allow CL option -mpacked-stack with -mbackchain.

2020-01-03 Thread Jonas Paulsson via cfe-commits
Author: Jonas Paulsson Date: 2020-01-03T12:26:54-08:00 New Revision: c0f1eac008e61e8345e3f41347cfd191e4ecb215 URL: https://github.com/llvm/llvm-project/commit/c0f1eac008e61e8345e3f41347cfd191e4ecb215 DIFF: https://github.com/llvm/llvm-project/commit/c0f1eac008e61e8345e3f41347cfd191e4ecb215.diff

[PATCH] D72114: [MS] Overhaul how clang passes overaligned args on x86_32

2020-01-03 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/test/CodeGen/x86_32-arguments-win32.c:77 +// CHECK-LABEL: define dso_local void @receive_vec_256(<8 x float> inreg %x, <8 x float> inreg %y, <8 x float> inreg %z, <8 x float>* %0, <8 x float>* %1) +// CHECK-LABEL: define dso_loca

[PATCH] D54943: [clang-tidy] implement const-transformation for cppcoreguidelines-const-correctness

2020-01-03 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth marked 2 inline comments as done. JonasToth added inline comments. Comment at: clang/include/clang/ASTMatchers/ASTMatchers.h:5224 +/// Matches QualType nodes that are of function pointer type. +/// I will remove those later. They are not used. Tidying

[PATCH] D54943: [clang-tidy] implement const-transformation for cppcoreguidelines-const-correctness

2020-01-03 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth updated this revision to Diff 236101. JonasToth added a comment. - ignore implicit casts in memberExpr(hasObjectExpression()) - implement functionality for function pointers Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54943/new/ https:/

[PATCH] D72114: [MS] Overhaul how clang passes overaligned args on x86_32

2020-01-03 Thread Reid Kleckner via Phabricator via cfe-commits
rnk marked 2 inline comments as done. rnk added inline comments. Comment at: clang/test/CodeGen/x86_32-arguments-win32.c:77 +// CHECK-LABEL: define dso_local void @receive_vec_256(<8 x float> inreg %x, <8 x float> inreg %y, <8 x float> inreg %z, <8 x float>* %0, <8 x float>* %1)

[PATCH] D54943: [clang-tidy] implement const-transformation for cppcoreguidelines-const-correctness

2020-01-03 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. In D54943#1800182 , @0x8000- wrote: > F11163406: 0001-Add-extra-tests.patch > shows a couple of false positives. I added your tests, but some did not show false positives anymore. I thi

[PATCH] D72110: [X86] ABI compat bugfix for MSVC vectorcall

2020-01-03 Thread Reid Kleckner via Phabricator via cfe-commits
rnk marked an inline comment as done. rnk added inline comments. Comment at: clang/lib/CodeGen/TargetInfo.cpp:1648 + // a bit different than the x64 version. First, all vector types (not HVAs) + // are assigned, with the first 6 ending up in the YMM0-5 or XMM0-5 registers. +

[PATCH] D36051: Move from a long list of checkers to tables

2020-01-03 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added a comment. This list used to be automatically updated by the clang-tools-extra/clang-tidy/add_new_check.py script. I suppose, this is broken now? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D36051/new/ https://reviews.llvm.org/D3605

[PATCH] D72167: Add support for __declspec(guard(nocf))

2020-01-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Can you please add some Sema tests that verify the attribute only appertains to functions, accepts the right number of arguments, etc? Also, some tests showing how this attribute works for things like redelcarations and virtual functions would help. e.g., void

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

2020-01-03 Thread Jonas Toth via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGcf48101200ee: [clang-tidy] implement utility-function to add 'const' to variables (authored by JonasToth). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D5439

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

2020-01-03 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. Thank you for all the review over the time this took to land! :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D54395/new/ https://reviews.llvm.org/D54395 ___ cfe-commits mail

[PATCH] D72114: [MS] Overhaul how clang passes overaligned args on x86_32

2020-01-03 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/include/clang/CodeGen/CGFunctionInfo.h:91 bool InAllocaSRet : 1;// isInAlloca() + bool InAllocaIndirect : 1;// isInAlloca() bool IndirectByVal : 1; // isIndirect() Would it be better to handle `inallo

[clang-tools-extra] cf48101 - [clang-tidy] implement utility-function to add 'const' to variables

2020-01-03 Thread Jonas Toth via cfe-commits
Author: Jonas Toth Date: 2020-01-03T20:37:47+01:00 New Revision: cf48101200ee192dd82e6ed0512ae42e7b3162a9 URL: https://github.com/llvm/llvm-project/commit/cf48101200ee192dd82e6ed0512ae42e7b3162a9 DIFF: https://github.com/llvm/llvm-project/commit/cf48101200ee192dd82e6ed0512ae42e7b3162a9.diff LO

[PATCH] D72018: [attributes] [analyzer] Add an attribute to prevent checkers from modeling a function

2020-01-03 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D72018#1803144 , @xazax.hun wrote: > I expect not to have too many functions that need such exclusions. It was > more about making it easier to do some exclusions without touching the > analyzer. I will ask around what are the pre

[PATCH] D70638: [Diagnostic] add a warning which warns about misleading indentation

2020-01-03 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. (re-ping; I think this false positive for goto label case is important to be fixed before 10 release) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D70638/new/ https://reviews.llvm.org/D70638 ___

[PATCH] D71037: [Diagnostic] Add ftabstop to -Wmisleading-indentation

2020-01-03 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 reopened this revision. xbolva00 added a comment. This revision is now accepted and ready to land. Can you add a test case for that crash? Otherwise OK. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71037/new/ https://reviews.llvm.org/D71037 _

[PATCH] D72140: [clang-tools-extra] NFC: Fix trivial typos in comments

2020-01-03 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. This is fantastic, thank you for much for all the typo fixes! This LGTM. Do you need someone to commit on your behalf? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D72018: [attributes] [analyzer] Add an attribute to prevent checkers from modeling a function

2020-01-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D72018#1803144 , @xazax.hun wrote: > In D72018#1803012 , @aaron.ballman > wrote: > > > In D72018#1802636 , @NoQ wrote: > > > > > Would chan

[PATCH] D72057: [docs] Remove outdated svn/git information from hacking page

2020-01-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman closed this revision. aaron.ballman added a comment. Thank you for the patch! I've commit on your behalf in e5a56f2d50ce1939eba4fddbeb9c8e032db4fc95 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72057/n

[clang] e5a56f2 - Remove outdated svn/git information from hacking page

2020-01-03 Thread Aaron Ballman via cfe-commits
Author: Alexander Lanin Date: 2020-01-03T14:13:40-05:00 New Revision: e5a56f2d50ce1939eba4fddbeb9c8e032db4fc95 URL: https://github.com/llvm/llvm-project/commit/e5a56f2d50ce1939eba4fddbeb9c8e032db4fc95 DIFF: https://github.com/llvm/llvm-project/commit/e5a56f2d50ce1939eba4fddbeb9c8e032db4fc95.dif

[PATCH] D70073: [ConstExprPreter] Implemented function calls and if statements

2020-01-03 Thread Nandor Licker via Phabricator via cfe-commits
nand added a comment. ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D70073/new/ https://reviews.llvm.org/D70073 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bi

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

2020-01-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tools-extra/unittests/clang-tidy/AddConstTest.cpp:1055 + EXPECT_NE(runCheckOnCode(Cat(S), nullptr, "input.m"), +Cat("Object const*target;")); + EXPECT_NE(runCheckOnCode(Cat(S), nullptr, "input.m"),

[PATCH] D72114: [MS] Overhaul how clang passes overaligned args on x86_32

2020-01-03 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added inline comments. Comment at: clang/test/CodeGen/x86_32-arguments-win32.c:77 +// CHECK-LABEL: define dso_local void @receive_vec_256(<8 x float> inreg %x, <8 x float> inreg %y, <8 x float> inreg %z, <8 x float>* %0, <8 x float>* %1) +// CHECK-LABEL: define dso_

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

2020-01-03 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth marked an inline comment as done. JonasToth added inline comments. Comment at: clang-tools-extra/unittests/clang-tidy/AddConstTest.cpp:1055 + EXPECT_NE(runCheckOnCode(Cat(S), nullptr, "input.m"), +Cat("Object const*target;")); + EXPECT_NE(runCheckOnCode(C

[PATCH] D72167: Add support for __declspec(guard(nocf))

2020-01-03 Thread dmajor via Phabricator via cfe-commits
dmajor added a comment. Thanks for doing this! When I applied this patch and added `__declspec(guard(nocf))` to the function that was giving us trouble , I still crash

[PATCH] D72121: [clang-tidy] Fix readability-identifier-naming missing member variables

2020-01-03 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. In D72121#1803242 , @njames93 wrote: > Ahh clang format script must have run, I'll undo that. I've not tried running > it against the whole of llvm as I don't know what the easy way to do that is, > especially given that llvm d

[PATCH] D72057: [docs] Remove outdated svn/git information from hacking page

2020-01-03 Thread Alexander Lanin via Phabricator via cfe-commits
AlexanderLanin added a comment. In D72057#1802982 , @aaron.ballman wrote: > LGTM with a small typo fix. Do you need someone to commit this on your behalf? Yes, please. I cannot commit myself. Alexander Lanin CHANGES SINCE LAST ACTION https://review

[PATCH] D72057: [docs] Remove outdated svn/git information from hacking page

2020-01-03 Thread Alexander Lanin via Phabricator via cfe-commits
AlexanderLanin updated this revision to Diff 236088. AlexanderLanin marked an inline comment as done. AlexanderLanin added a comment. `Getting Started` since it's `Getting Started with the LLVM System` CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72057/new/ https://reviews.llvm.org/D72

[PATCH] D72110: [X86] ABI compat bugfix for MSVC vectorcall

2020-01-03 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added inline comments. Comment at: clang/lib/CodeGen/TargetInfo.cpp:1648 + // a bit different than the x64 version. First, all vector types (not HVAs) + // are assigned, with the first 6 ending up in the YMM0-5 or XMM0-5 registers. + // This differs from the x64

[PATCH] D65761: Add Windows Control Flow Guard checks (/guard:cf).

2020-01-03 Thread Andrew Paverd via Phabricator via cfe-commits
ajpaverd added a comment. In D65761#1772076 , @dmajor wrote: > Well, this patch specifically has code (even a test) that `nocf_check` > prevents CFG, so it looks like the intent was there, it's just that there > isn't a way to get that attribute onto fun

[PATCH] D72121: [clang-tidy] Fix readability-identifier-naming missing member variables

2020-01-03 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Ahh clang format script must have run, I'll undo that. I've not tried running it against the whole of llvm as I don't know what the easy way to do that is, especially given that llvm disregards it's standard naming convention for old projects and stl like containers. T

[PATCH] D72163: [clangd] targetDecl() returns only NamedDecls.

2020-01-03 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGf06f439fadf7: [clangd] targetDecl() returns only NamedDecls. (authored by sammccall). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72163/new/ https://revie

[PATCH] D71644: [clangd] Heuristically resolve dependent call through smart pointer type

2020-01-03 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. This is great! Thank you! Comment at: clang-tools-extra/clangd/FindTarget.cpp:116 + // smart pointer type. + ASTContext *Ctx = hackyFindASTContext(T); + if (!Ctx) --

[clang-tools-extra] f06f439 - [clangd] targetDecl() returns only NamedDecls.

2020-01-03 Thread Sam McCall via cfe-commits
Author: Sam McCall Date: 2020-01-03T18:18:40+01:00 New Revision: f06f439fadf740ea9019f2eb7f26ff88198ed375 URL: https://github.com/llvm/llvm-project/commit/f06f439fadf740ea9019f2eb7f26ff88198ed375 DIFF: https://github.com/llvm/llvm-project/commit/f06f439fadf740ea9019f2eb7f26ff88198ed375.diff LO

[PATCH] D72167: Add support for __declspec(guard(nocf))

2020-01-03 Thread Andrew Paverd via Phabricator via cfe-commits
ajpaverd created this revision. ajpaverd added reviewers: rnk, dmajor, pcc, hans. Herald added subscribers: llvm-commits, cfe-commits, hiraditya. Herald added projects: clang, LLVM. Avoid using the `nocf_check` attribute with Control Flow Guard. Instead, use a new `"guard_nocf"` function attribut

[PATCH] D71499: Add builtins for aligning and checking alignment of pointers and integers

2020-01-03 Thread Nuno Lopes via Phabricator via cfe-commits
nlopes added a comment. @lebedev.ri I agree with you that the semantics of these alignment builtins should only return a pointer that is of the same object as the one given as input. Otherwise, these builtins would be even worst that ptr2int/int2ptr, since their result could alias with any othe

[clang] add743b - [OPENMP]Fix crash on error message for declare reduction.

2020-01-03 Thread Alexey Bataev via cfe-commits
Author: Alexey Bataev Date: 2020-01-03T12:13:03-05:00 New Revision: add743b4348095c0d2e407c7a2b8a87a5f8194b0 URL: https://github.com/llvm/llvm-project/commit/add743b4348095c0d2e407c7a2b8a87a5f8194b0 DIFF: https://github.com/llvm/llvm-project/commit/add743b4348095c0d2e407c7a2b8a87a5f8194b0.diff

[clang] ba3484c - [clang-format/java] format multiple qualified annotations on one declaration better

2020-01-03 Thread Nico Weber via cfe-commits
Author: Nico Weber Date: 2020-01-03T12:11:44-05:00 New Revision: ba3484c051b62a662c555200f4a03b2e8df8e094 URL: https://github.com/llvm/llvm-project/commit/ba3484c051b62a662c555200f4a03b2e8df8e094 DIFF: https://github.com/llvm/llvm-project/commit/ba3484c051b62a662c555200f4a03b2e8df8e094.diff LO

[PATCH] D71969: [OpenMP] diagnose zero-length array section in the depend clause

2020-01-03 Thread Kelvin Li via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG427ffa2cdbbc: [OpenMP] diagnose zero-length array section in the depend clause (authored by kkwli0). Herald added a project: clang. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https

[PATCH] D71596: [clangd] Improve documentation for auto and implicit specs

2020-01-03 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/FindTarget.h:194 +llvm::SmallVector +explicitReferenceTargets(ast_type_traits::DynTypedNode N, + DeclRelationSet Mask = {}); sammccall wrote: > ilya-biryukov wrote:

[PATCH] D71596: [clangd] Improve documentation for auto and implicit specs

2020-01-03 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/FindTarget.h:194 +llvm::SmallVector +explicitReferenceTargets(ast_type_traits::DynTypedNode N, + DeclRelationSet Mask = {}); ilya-biryukov wrote: > sammccall wrote:

[clang] 427ffa2 - [OpenMP] diagnose zero-length array section in the depend clause

2020-01-03 Thread Kelvin Li via cfe-commits
Author: Kelvin Li Date: 2020-01-03T11:55:37-05:00 New Revision: 427ffa2cdbbc7337d903ba71823a7830fa92568d URL: https://github.com/llvm/llvm-project/commit/427ffa2cdbbc7337d903ba71823a7830fa92568d DIFF: https://github.com/llvm/llvm-project/commit/427ffa2cdbbc7337d903ba71823a7830fa92568d.diff LOG

[PATCH] D72163: [clangd] targetDecl() returns only NamedDecls.

2020-01-03 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 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72163/new/ https://reviews.llvm.org/D72163 _

[PATCH] D72018: [attributes] [analyzer] Add an attribute to prevent checkers from modeling a function

2020-01-03 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. In D72018#1803012 , @aaron.ballman wrote: > In D72018#1802636 , @NoQ wrote: > > > Would changing the literal in the attribute have the same effect? I.e., > > `acquire_handle("Fuchsia_But

[PATCH] D72163: [clangd] targetDecl() returns only NamedDecls.

2020-01-03 Thread pre-merge checks [bot] via Phabricator via cfe-commits
merge_guards_bot added a comment. {icon check-circle color=green} Unit tests: pass. 61180 tests passed, 0 failed and 729 were skipped. {icon check-circle color=green} clang-tidy: pass. {icon check-circle color=green} clang-format: pass. Build artifacts

[PATCH] D72140: [clang-tools-extra] NFC: Fix trivial typos in comments

2020-01-03 Thread pre-merge checks [bot] via Phabricator via cfe-commits
merge_guards_bot added a comment. {icon check-circle color=green} Unit tests: pass. 61180 tests passed, 0 failed and 729 were skipped. {icon times-circle color=red} clang-tidy: fail. Please fix clang-tidy findings

[PATCH] D72163: [clangd] targetDecl() returns only NamedDecls.

2020-01-03 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added reviewers: kadircet, ilya-biryukov. Herald added subscribers: cfe-commits, usaxena95, arphaman, jkorous, MaskRay. Herald added a project: clang. While it's perfectly reasonable for non-named decls such as static_assert to resolve to themselves: - n

[PATCH] D71510: [clang][checkers] Added new checker 'error-return-checker'. (WIP)

2020-01-03 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. Works relatively good now but not perfect. The tests are sometimes too strict so there are some false positives, for example this case: unsigned long X = strtoul("345", NULL, 10); if (X > 100) { // handle error } The result is not checked for `ULONG_MAX` but s

[clang] b4b904e - [Diagnostic] Fixed add ftabstop to -Wmisleading-indentation

2020-01-03 Thread via cfe-commits
Author: Tyker Date: 2020-01-03T17:22:24+01:00 New Revision: b4b904e19bb356724b2c6aea0199ce05c6f15cdb URL: https://github.com/llvm/llvm-project/commit/b4b904e19bb356724b2c6aea0199ce05c6f15cdb DIFF: https://github.com/llvm/llvm-project/commit/b4b904e19bb356724b2c6aea0199ce05c6f15cdb.diff LOG: [D

[PATCH] D71510: [clang][checkers] Added new checker 'error-return-checker'. (WIP)

2020-01-03 Thread Balázs Kéri via Phabricator via cfe-commits
balazske updated this revision to Diff 236070. balazske added a comment. - Implemented all (now possible) functions. - Moved ParmVal value to own state map. - Improved state data and bug reporting. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71510

[PATCH] D72140: [clang-tools-extra] NFC: Fix trivial typos in comments

2020-01-03 Thread Kazuaki Ishizaki via Phabricator via cfe-commits
kiszk updated this revision to Diff 236069. kiszk added a comment. Rebase with master Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72140/new/ https://reviews.llvm.org/D72140 Files: clang-tools-extra/clang-apply-replacements/lib/Tooling/ApplyRep

[PATCH] D72018: [attributes] [analyzer] Add an attribute to prevent checkers from modeling a function

2020-01-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D72018#1802636 , @NoQ wrote: > Would changing the literal in the attribute have the same effect? I.e., > `acquire_handle("Fuchsia_But_Please_Ignore_Me")`. It should, but doesn't currently because we don't have any check

[PATCH] D71037: [Diagnostic] Add ftabstop to -Wmisleading-indentation

2020-01-03 Thread Tyker via Phabricator via cfe-commits
Tyker updated this revision to Diff 236058. Tyker added a comment. This update should fixes the issue. the assert was incorrect. because file offsets are 0-based where as column numbers are 1-based. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71037/new/ https://reviews.llvm.org/D7103

[PATCH] D72057: [docs] Remove outdated svn/git information from hacking page

2020-01-03 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 with a small typo fix. Do you need someone to commit this on your behalf? Comment at: clang/www/hacking.html:279 + To contribute changes to Clang see +

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

2020-01-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Still LG with a small nit in one of the FIXME tests. Comment at: clang-tools-extra/unittests/clang-tidy/AddConstTest.cpp:1006 +} + +} // namespace test JonasToth wrote: > aaron.ballman wrote: > > JonasToth wrote: > > > aaron.ballm

[PATCH] D71499: Add builtins for aligning and checking alignment of pointers and integers

2020-01-03 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In D71499#1802134 , @lebedev.ri wrote: > For future reference, if anyone needs here's the C versions of these builtins: > https://godbolt.org/z/oHeAh- > > ^ looks like we are missing some backend-level folds for round-down vari

[PATCH] D72153: [libTooling] Add function to determine associated text of a declaration.

2020-01-03 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 236057. ymandel added a comment. clang-format Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72153/new/ https://reviews.llvm.org/D72153 Files: clang/include/clang/Tooling/Transformer/SourceCode.h clang/lib/

[PATCH] D72153: [libTooling] Add function to determine associated text of a declaration.

2020-01-03 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel created this revision. ymandel added a reviewer: gribozavr. Herald added a project: clang. This patch adds `getAssociatedRange` which, for a given decl, computes preceding and trailing text that would conceptually be associated with the decl by the reader. This includes comments, whitespac

[PATCH] D72110: [X86] ABI compat bugfix for MSVC vectorcall

2020-01-03 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. I don't see anything I have a problem with, but still want @ctopper to have a bit of time to take a look. Ping me monday on both if he doesn't respond. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72110/new/ https://r

[PATCH] D72114: [MS] Overhaul how clang passes overaligned args on x86_32

2020-01-03 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. I think this is alright, I want @ctopper to take a look before I approve it though. Additionally, do you know if this modifies the regcall calling convention at all? Should it? Comment at: clang/test/CodeGenCXX/inalloca-vector.cpp:71 +// CHECK-LA

[PATCH] D71406: [clangd] Add xref for macros to FileIndex.

2020-01-03 Thread pre-merge checks [bot] via Phabricator via cfe-commits
merge_guards_bot added a comment. {icon check-circle color=green} Unit tests: pass. 60496 tests passed, 0 failed and 726 were skipped. {icon check-circle color=green} clang-tidy: pass. {icon check-circle color=green} clang-format: pass. Build artifacts

[PATCH] D72150: Allow space after C-style cast in C# code

2020-01-03 Thread Jonathan B Coe via Phabricator via cfe-commits
jbcoe created this revision. jbcoe added a reviewer: klimek. jbcoe added a project: clang-format. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D72150 Files: clang/lib/Format/TokenAnnotator.cpp clang/unit

[PATCH] D71596: [clangd] Improve documentation for auto and implicit specs

2020-01-03 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: clang-tools-extra/clangd/FindTarget.h:194 +llvm::SmallVector +explicitReferenceTargets(ast_type_traits::DynTypedNode N, + DeclRelationSet Mask = {}); ilya-biryukov wrote: > sammccall wrote: > >

[PATCH] D71406: [clangd] Add xref for macros to FileIndex.

2020-01-03 Thread UTKARSH SAXENA via Phabricator via cfe-commits
usaxena95 updated this revision to Diff 236037. usaxena95 marked 5 inline comments as done. usaxena95 added a comment. Added another version of `handleMacroOccurence` to handle MacroReferences from main file. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llv

[PATCH] D71406: [clangd] Add xref for macros to FileIndex.

2020-01-03 Thread UTKARSH SAXENA via Phabricator via cfe-commits
usaxena95 added inline comments. Comment at: clang-tools-extra/clangd/index/FileIndex.cpp:86 +// Add macro references. +for (const auto &IDToRefs : MacroRefsToIndex->MacroRefs) { + for (const auto &Range : IDToRefs.second) { ilya-biryukov wrote: > ho

[PATCH] D72144: Treat C# `using` as a control statement

2020-01-03 Thread Jonathan B Coe via Phabricator via cfe-commits
jbcoe updated this revision to Diff 236035. jbcoe added a reviewer: klimek. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72144/new/ https://reviews.llvm.org/D72144 Files: clang/lib/Format/TokenAnnotator.cpp clang/unittests/Format/FormatTestCSharp.cpp Index: clang/unittests/Format/

[PATCH] D72144: Treat C# `using` as a control statement

2020-01-03 Thread Jonathan B Coe via Phabricator via cfe-commits
jbcoe created this revision. jbcoe added a project: clang-format. Herald added a project: clang. Herald added a subscriber: cfe-commits. Unless SpaceBeforeParensOptions is set to SBPO_Never, a space will be put between `using` and `(` in C# code. Repository: rG LLVM Github Monorepo https://r

[PATCH] D71596: [clangd] Improve documentation for auto and implicit specs

2020-01-03 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clang-tools-extra/clangd/FindTarget.h:194 +llvm::SmallVector +explicitReferenceTargets(ast_type_traits::DynTypedNode N, + DeclRelationSet Mask = {}); sammccall wrote: > ilya-biryukov wrote:

  1   2   >