[PATCH] D59754: [Sema] Add c++2a designated initializer warnings

2019-06-14 Thread Dmitry Sokolov via Phabricator via cfe-commits
sokolovd added a comment. This looks like exactly what we need for my project. We're using Clang and Designated Initializers but would like to make sure that we use those in C++20 compatible manner. Is this blocked on something? Any way I can help? Repository: rG LLVM Github Monorepo CHANGE

[PATCH] D60883: [OpenMP] Avoid emitting maps for target link variables when unified memory is used

2019-06-14 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363435: [OpenMP] Avoid emitting maps for target link variables when unified memory is… (authored by gbercea, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Reposito

[PATCH] D63010: [OpenMP] Add task alloc function

2019-06-14 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. ping Repository: rOMP OpenMP CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63010/new/ https://reviews.llvm.org/D63010 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailma

[PATCH] D61790: [C++20] add Basic consteval specifier

2019-06-14 Thread Douglas Yung via Phabricator via cfe-commits
dyung added a comment. Hi, the test cxx2a-consteval.cpp that you added in this commit is failing on the PS4 Windows bot. http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast/builds/9/steps/test/logs/stdio FAIL: Clang :: SemaCXX/cxx2a-consteval.cpp (13131 of 50204

[PATCH] D59754: [Sema] Add c++2a designated initializer warnings

2019-06-14 Thread Don Hinton via Phabricator via cfe-commits
hintonda added a comment. In D59754#1543949 , @sokolovd wrote: > This looks like exactly what we need for my project. We're using Clang and > Designated Initializers but would like to make sure that we use those in > C++20 compatible manner. Is this bloc

[PATCH] D63335: [HIP] Change kernel stub name again

2019-06-14 Thread Michael Liao via Phabricator via cfe-commits
hliao added a comment. In D63335#1543854 , @tra wrote: > In D63335#1543845 , @hliao wrote: > > > it's requested from debugger people. they don't want to the host-side stub > > could match the device-side kernel fun

[PATCH] D63335: [HIP] Change kernel stub name again

2019-06-14 Thread Michael Liao via Phabricator via cfe-commits
hliao marked an inline comment as done. hliao added inline comments. Comment at: clang/lib/CodeGen/CGCUDANV.cpp:789 +return Name; + return std::move(("__device_stub__" + Name).str()); +} tra wrote: > I suspect `return "__device_stub__" + Name;` would do. Str

[PATCH] D63335: [HIP] Change kernel stub name again

2019-06-14 Thread Michael Liao via Phabricator via cfe-commits
hliao added a comment. In D63335#1543854 , @tra wrote: > In D63335#1543845 , @hliao wrote: > > > it's requested from debugger people. they don't want to the host-side stub > > could match the device-side kernel fun

[PATCH] D63335: [HIP] Change kernel stub name again

2019-06-14 Thread Michael Liao via Phabricator via cfe-commits
hliao added a comment. In D63335#1543854 , @tra wrote: > In D63335#1543845 , @hliao wrote: > > > it's requested from debugger people. they don't want to the host-side stub > > could match the device-side kernel fun

[PATCH] D63329: Allow static linking of libc++ on Linux, just like -static-libstdc++

2019-06-14 Thread Hal Finkel via Phabricator via cfe-commits
hfinkel added inline comments. Comment at: clang/lib/Driver/ToolChains/Gnu.cpp:570 + // FIXME: libc++ dynamically links against libpthread, so for static + // linking, we need to supply that dependency. Why does this say FIXME? Comm

[PATCH] D63009: [OpenMP] Add target task alloc function with device ID

2019-06-14 Thread Alexandre Eichenberger via Phabricator via cfe-commits
AlexEichenberger added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:5122 +NewTask = CGF.EmitRuntimeCall( + createRuntimeFunction(OMPRTL__kmpc_omp_target_task_alloc), AllocArgs); + } else { gtbercea wrote: > ABataev wrote: > > gtbercea wr

[PATCH] D63010: [OpenMP] Add task alloc function

2019-06-14 Thread Hansang Bae via Phabricator via cfe-commits
hbae accepted this revision. hbae added a comment. LGTM. Repository: rOMP OpenMP CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63010/new/ https://reviews.llvm.org/D63010 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lis

[PATCH] D63009: [OpenMP] Add target task alloc function with device ID

2019-06-14 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea marked an inline comment as done. gtbercea added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:5122 +NewTask = CGF.EmitRuntimeCall( + createRuntimeFunction(OMPRTL__kmpc_omp_target_task_alloc), AllocArgs); + } else { AlexEichenber

[PATCH] D63010: [OpenMP] Add task alloc function

2019-06-14 Thread Ravi Narayanaswamy via Phabricator via cfe-commits
RaviNarayanaswamy added a comment. LGTM Repository: rOMP OpenMP CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63010/new/ https://reviews.llvm.org/D63010 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-b

[PATCH] D63174: [clang][NewPM] Add RUNS for tests that produce slightly different IR under new PM

2019-06-14 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan added a comment. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63174/new/ https://reviews.llvm.org/D63174 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bi

r363446 - Use getOperatorSpelling to get the spelling of an overloaded operator

2019-06-14 Thread Richard Smith via cfe-commits
Author: rsmith Date: Fri Jun 14 13:01:51 2019 New Revision: 363446 URL: http://llvm.org/viewvc/llvm-project?rev=363446&view=rev Log: Use getOperatorSpelling to get the spelling of an overloaded operator rather than duplicating operator name tables in multiple places. Modified: cfe/trunk/lib/A

r363447 - PR42071: Reject weird names for non-type template parameters.

2019-06-14 Thread Richard Smith via cfe-commits
Author: rsmith Date: Fri Jun 14 13:01:54 2019 New Revision: 363447 URL: http://llvm.org/viewvc/llvm-project?rev=363447&view=rev Log: PR42071: Reject weird names for non-type template parameters. Also reject default arguments appearing in invalid locations. Modified: cfe/trunk/include/clang/B

[PATCH] D63010: [OpenMP] Add task alloc function

2019-06-14 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363449: [OpenMP] Add task alloc function (authored by gbercea, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Repository: rL LLVM CHANGES SINCE LAST ACTION htt

[PATCH] D63174: [clang][NewPM] Add RUNS for tests that produce slightly different IR under new PM

2019-06-14 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan added a comment. For the avx tests, I don't suppose you know a simple way to generate these tests? They're about 10k lines long and it's taking a while to go through it by hand to replace the current IR checks with codegen for `-O1`. (Perhaps something along the lines of `utils/upd

r363450 - Use unsigned for bitfields to avoid sign extension

2019-06-14 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Fri Jun 14 13:19:29 2019 New Revision: 363450 URL: http://llvm.org/viewvc/llvm-project?rev=363450&view=rev Log: Use unsigned for bitfields to avoid sign extension Modified: cfe/trunk/include/clang/Sema/DeclSpec.h cfe/trunk/lib/Sema/DeclSpec.cpp Modified: cfe/trunk/inclu

[PATCH] D61790: [C++20] add Basic consteval specifier

2019-06-14 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: cfe/trunk/include/clang/Sema/DeclSpec.h:366 // constexpr-specifier - unsigned Constexpr_specified : 1; + ConstexprSpecKind ConstexprSpecifier : 2; Please always use `unsigned` for bitfields to avoid sign extensions un

r363451 - [OpenMP] Add target task alloc function with device ID

2019-06-14 Thread Gheorghe-Teodor Bercea via cfe-commits
Author: gbercea Date: Fri Jun 14 13:19:54 2019 New Revision: 363451 URL: http://llvm.org/viewvc/llvm-project?rev=363451&view=rev Log: [OpenMP] Add target task alloc function with device ID Summary: Add a new call to Clang to perform task allocation for the target. Reviewers: ABataev, AlexEichenb

[PATCH] D63009: [OpenMP] Add target task alloc function with device ID

2019-06-14 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363451: [OpenMP] Add target task alloc function with device ID (authored by gbercea, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Repository: rL LLVM CHANGES S

[PATCH] D62883: [analyzer] Track conditions of terminator statements on which the reported node depends on

2019-06-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. > I am not sure about assuming operator bool being correct. I think we first > could think about other tricks to limit the tracking (see my idea above) and > if we fail I would only add such rules as a last resort. I think this depends greatly on the stack frame layout. I s

[PATCH] D62883: [analyzer] Track conditions of terminator statements on which the reported node depends on

2019-06-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D62883#1542802 , @Szelethus wrote: > Some conclusions: > > - Cases where the condition is also a variable initialization tend to expand > the bug path greatly. This isn't always bad, but should be noted. In general, > unless we ha

[PATCH] D62883: [analyzer] Track conditions of terminator statements on which the reported node depends on

2019-06-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/test/Analysis/track-control-dependency-conditions.cpp:80-81 + + if (bar) // expected-note {{Taking true branch}} + // expected-note@-1{{Assuming 'bar' is not equal to 0}} +if (flag) // expected-note {{Taking true bra

[PATCH] D63335: [HIP] Change kernel stub name again

2019-06-14 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D63335#1544019 , @hliao wrote: > In D63335#1543854 , @tra wrote: > > > In D63335#1543845 , @hliao wrote: > > > > > it's requested from debugger people

[PATCH] D62883: [analyzer] Track conditions of terminator statements on which the reported node depends on

2019-06-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. How about we track the condition value past its collapse point only if it involves an overwrite of a variable (or other region) from which the value is loaded? Like, if there are no overwrites, stop at the collapse point. If there are overwrites, stop at the oldest overwrit

[PATCH] D63335: [HIP] Change kernel stub name again

2019-06-14 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D63335#1544026 , @hliao wrote: > Is it OK for us to mangle `__device_stub __` as the nested name into the > original one, says, we prepend `_ZN15__device_stub__E`, so that we have > `_ZN15__device_stub__E10kernelfuncIiEvv` > > and

[PATCH] D63335: [HIP] Change kernel stub name again

2019-06-14 Thread Michael Liao via Phabricator via cfe-commits
hliao added a comment. In D63335#1544311 , @tra wrote: > In D63335#1544019 , @hliao wrote: > > > In D63335#1543854 , @tra wrote: > > > > > In D63335#1543845

[PATCH] D62761: [analyzer] exploded-graph-rewriter: Implement a --diff mode.

2019-06-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ marked an inline comment as done. NoQ added inline comments. Comment at: clang/utils/analyzer/exploded-graph-rewriter.py:170-171 super(Store, self).__init__() -self.clusters = [StoreCluster(c) for c in json_s] +self.clusters = collections.OrderedDict(

[PATCH] D63335: [HIP] Change kernel stub name again

2019-06-14 Thread Artem Belevich via Phabricator via cfe-commits
tra requested changes to this revision. tra added a comment. This revision now requires changes to proceed. In D63335#1544315 , @hliao wrote: > > Sorry, I still don't think I understand the reasons for this change. The > > stub and the kernel do have a di

r363463 - [Remarks][NFC] Improve testing and documentation of -foptimization-record-passes

2019-06-14 Thread Francis Visoiu Mistrih via cfe-commits
Author: thegameg Date: Fri Jun 14 14:38:57 2019 New Revision: 363463 URL: http://llvm.org/viewvc/llvm-project?rev=363463&view=rev Log: [Remarks][NFC] Improve testing and documentation of -foptimization-record-passes This adds: * documentation to the user manual * nicer error message * test for t

[PATCH] D63335: [HIP] Change kernel stub name again

2019-06-14 Thread Michael Liao via Phabricator via cfe-commits
hliao added a comment. In D63335#1544320 , @tra wrote: > In D63335#1544315 , @hliao wrote: > > > > Sorry, I still don't think I understand the reasons for this change. The > > > stub and the kernel do have a differ

[PATCH] D62883: [analyzer] Track conditions of terminator statements on which the reported node depends on

2019-06-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. (then, again, not sure what happens if more nested stack frames are around) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62883/new/ https://reviews.llvm.org/D62883 ___ cfe-commits mailing list cfe-commits@lists.llvm.or

[PATCH] D62761: [analyzer] exploded-graph-rewriter: Implement a --diff mode.

2019-06-14 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso marked an inline comment as done. Charusso added inline comments. Comment at: clang/utils/analyzer/exploded-graph-rewriter.py:170-171 super(Store, self).__init__() -self.clusters = [StoreCluster(c) for c in json_s] +self.clusters = collections.Or

[PATCH] D63361: Pretend NRVO variables are references so that CodeView can get their value

2019-06-14 Thread Amy Huang via Phabricator via cfe-commits
akhuang created this revision. Herald added subscribers: llvm-commits, cfe-commits, hiraditya. Herald added projects: clang, LLVM. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D63361 Files: clang/lib/CodeGen/CGDebugInfo.cpp clang/lib/CodeGen/CGDecl.cpp debuginfo-tests/nrv

[PATCH] D63161: Devirtualize destructor of final class.

2019-06-14 Thread Hiroshi Yamauchi via Phabricator via cfe-commits
yamauchi updated this revision to Diff 204852. yamauchi marked an inline comment as done. yamauchi added a comment. Addressed comment. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63161/new/ https://reviews.llvm.org/D63161 Files: lib/CodeGen/CGExprCXX.cpp t

[PATCH] D63335: [HIP] Change kernel stub name again

2019-06-14 Thread Michael Liao via Phabricator via cfe-commits
hliao updated this revision to Diff 204856. hliao added a comment. Just revise the interface for device kernel stubbing. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63335/new/ https://reviews.llvm.org/D63335 Files: clang/lib/CodeGen/CGCUDANV.c

[PATCH] D63161: Devirtualize destructor of final class.

2019-06-14 Thread Hiroshi Yamauchi via Phabricator via cfe-commits
yamauchi marked an inline comment as done. yamauchi added inline comments. Comment at: lib/CodeGen/CGExprCXX.cpp:1871 + CGF.CGM.getLangOpts().AppleKext))) + Dtor = DevirtualizedDtor; +else { rsmith wrot

[PATCH] D63362: [analyzer] Fix JSON dumps for store clusters.

2019-06-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added a reviewer: Charusso. Herald added subscribers: cfe-commits, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a project: clang. Include a unique pointer so that it was possible to figure out if it's

[PATCH] D63161: Devirtualize destructor of final class.

2019-06-14 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: lib/CodeGen/CGExprCXX.cpp:1867-1868 - if (Dtor->isVirtual()) { + if (Dtor->isVirtual() && + !(Dtor->hasAttr() || RD->hasAttr())) { CGF.CGM.getCXXABI().emitVirtualObjectDelete(CGF, DE, Ptr, ElementType, --

r363467 - [CodeGen][ObjC] Annotate retain-agnostic ObjC globals with attribute

2019-06-14 Thread Akira Hatanaka via cfe-commits
Author: ahatanak Date: Fri Jun 14 15:06:28 2019 New Revision: 363467 URL: http://llvm.org/viewvc/llvm-project?rev=363467&view=rev Log: [CodeGen][ObjC] Annotate retain-agnostic ObjC globals with attribute 'objc_arc_inert' The attribute enables the ARC optimizer to delete ObjC ARC runtime calls on

[PATCH] D63362: [analyzer] Fix JSON dumps for store clusters.

2019-06-14 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso accepted this revision. Charusso added a comment. This revision is now accepted and ready to land. Thanks you! Comment at: clang/lib/StaticAnalyzer/Core/RegionStore.cpp:215 + << "{ \"cluster\": \"" << I.getKey() << "\", \"pointer\": \"" + << ((const v

[PATCH] D62831: [CodeGen][ObjC] Add attribute "objc_arc_intert" to ObjC globals that are retain-agnostic

2019-06-14 Thread Akira Hatanaka 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 rL363467: [CodeGen][ObjC] Annotate retain-agnostic ObjC globals with attribute (authored by ahatanak, committed by ). Herald

[PATCH] D63335: [HIP] Add the interface deriving the stub name of device kernels.

2019-06-14 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D63335#1544324 , @hliao wrote: > > I think debugger does have sufficient information to deal with this and > > that would be the right place to deal with the issue. > > em, I did push the later as well, :(. OK, I will simplify the

[PATCH] D63335: [HIP] Add the interface deriving the stub name of device kernels.

2019-06-14 Thread Michael Liao via Phabricator via cfe-commits
hliao added a comment. In D63335#1544428 , @tra wrote: > In D63335#1544324 , @hliao wrote: > > > > I think debugger does have sufficient information to deal with this and > > > that would be the right place to deal

[PATCH] D63335: [HIP] Add the interface deriving the stub name of device kernels.

2019-06-14 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. This is a cleaner way to provide stub name tweaks. Comment at: clang/lib/CodeGen/CGCUDANV.cpp:223 + // Ensure either we have different ABIs between host and device compilati

[PATCH] D63366: AMDGPU: Add GWS instruction builtins

2019-06-14 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm created this revision. arsenm added reviewers: rampitec, b-sumner, yaxunl. Herald added subscribers: t-tye, tpr, dstuttard, nhaehnle, wdng, jvesely, kzhuravl. https://reviews.llvm.org/D63366 Files: include/clang/Basic/BuiltinsAMDGPU.def test/CodeGenOpenCL/builtins-amdgcn.cl Index: t

[PATCH] D63088: [clang-tidy] misc-unused-parameters: don't comment out parameter name for C code

2019-06-14 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri accepted this revision. lebedev.ri added a comment. This revision is now accepted and ready to land. Seems obviously correct, with the nit. Comment at: clang-tools-extra/clang-tidy/misc/UnusedParametersCheck.cpp:141-156 + // Cannot remove parameter for non-local fun

[PATCH] D63089: [clang] Warn on implicit boolean casts in more contexts (PR34180)

2019-06-14 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Please always upload all patches with full context (`-U9`) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63089/new/ https://reviews.llvm.org/D63089 ___ cfe-commits maili

[PATCH] D63367: [clang-doc] Add basic support for templates and typedef

2019-06-14 Thread Diego Astiazarán via Phabricator via cfe-commits
DiegoAstiazaran created this revision. DiegoAstiazaran added reviewers: juliehockett, jakehehrlich, lebedev.ri. DiegoAstiazaran added a project: clang-tools-extra. Herald added subscribers: kadircet, arphaman. In serialize::parseBases(...), when a base record is a template specialization, the spe

[PATCH] D63369: [AST] Fixed extraneous warnings for binary conditional operator

2019-06-14 Thread Nathan Huckleberry via Phabricator via cfe-commits
Nathan-Huckleberry created this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Binary conditional operator gave warnings where ternary operators did not. They have been fixed to warn similarly to ternary operators. Link: https://bugs.llvm.org/show_bug.cgi?id=4223

[PATCH] D63362: [analyzer] Fix JSON dumps for store clusters.

2019-06-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 204874. NoQ added a comment. Fair enough, they aren't really needed here. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63362/new/ https://reviews.llvm.org/D63362 Files: clang/lib/StaticAnalyzer/Core/RegionStore.cpp clang/test/Analysis/dump_egraph.

[PATCH] D63325: [Support][Time profiler] Make FE codegen blocks to be inside frontend blocks

2019-06-14 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang/lib/CodeGen/CodeGenAction.cpp:232 { +llvm::TimeTraceScope TimeScope("Frontend", StringRef("")); PrettyStackTraceString CrashInfo("Per-file LLVM IR generation"); This looks more like `Fron

[PATCH] D63361: Pretend NRVO variables are references so they can be found by debug info

2019-06-14 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. +@aprantl @dblaikie The basic idea of this change is that clang should store implicit sret pointer arguments into a static alloca, and the dbg.declare should reference the static alloca instead of referring to the LLVM argument directly. The idea is that that will be more

[PATCH] D63369: [AST] Fixed extraneous warnings for binary conditional operator

2019-06-14 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added inline comments. Comment at: clang/test/Sema/warn-binary-conditional-expression-unused.c:8 +a ? : ++b; +a ? a : ++b; +++a ? : b; //expected-warning{{expression result unused}} Note to other reviewers: Whether or not we should wa

r363472 - [X86] Add checks that immediate for reducesd/ss fits in 8-bits.

2019-06-14 Thread Craig Topper via cfe-commits
Author: ctopper Date: Fri Jun 14 16:23:19 2019 New Revision: 363472 URL: http://llvm.org/viewvc/llvm-project?rev=363472&view=rev Log: [X86] Add checks that immediate for reducesd/ss fits in 8-bits. Modified: cfe/trunk/lib/Sema/SemaChecking.cpp Modified: cfe/trunk/lib/Sema/SemaChecking.cpp UR

[PATCH] D63361: Pretend NRVO variables are references so they can be found by debug info

2019-06-14 Thread Amy Huang via Phabricator via cfe-commits
akhuang updated this revision to Diff 204878. akhuang added a comment. - fix test case Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63361/new/ https://reviews.llvm.org/D63361 Files: clang/lib/CodeGen/CGDebugInfo.cpp clang/lib/CodeGen/CGDecl.c

[PATCH] D63361: Pretend NRVO variables are references so they can be found by debug info

2019-06-14 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl requested changes to this revision. aprantl added inline comments. This revision now requires changes to proceed. Comment at: clang/lib/CodeGen/CGDecl.cpp:1572 + ConvertTypeForMem(getContext().getLValueReferenceType(Ty)); + DebugAddr = CreateTempAlloca(RefTy

[PATCH] D58164: Block+lambda: allow reference capture

2019-06-14 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak updated this revision to Diff 204882. ahatanak added a comment. - Add another test case which has a block nested inside a lambda and causes clang to crash. - Fix the capture type passed to `addCapture` in `RebuildLambdaScopeInfo`. Repository: rC Clang CHANGES SINCE LAST ACTION htt

[PATCH] D63369: [AST] Fixed extraneous warnings for binary conditional operator

2019-06-14 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/AST/Expr.cpp:2351-2352 return false; if (!Exp->getLHS()) return true; return Exp->getLHS()->isUnusedResultAWarning(WarnE, Lo

[PATCH] D62883: [analyzer] Track conditions of terminator statements on which the reported node depends on

2019-06-14 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D62883#1544283 , @NoQ wrote: > However, this heuristic breaks when the same code appears in an inlined stack > frame. Because given the context, we need to prove that this check makes > sense *in this context*. I strongly su

[PATCH] D58164: Block+lambda: allow reference capture

2019-06-14 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. I think I now have a better idea of what's causing the crash in IRGen. The root of the problem is that, when `RebuildLambdaScopeInfo` is called to rebuild the scope info for the generic lambda, the type of the captured variable (`s` in `test2` and `test3` in `test/Cod

[PATCH] D58164: Block+lambda: allow reference capture

2019-06-14 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a reviewer: rsmith. ahatanak added a comment. Richard, could you shed light on why it's done this way? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58164/new/ https://reviews.llvm.org/D58164 ___ cfe-c

[PATCH] D62899: [analyzer][UninitializedObjectChecker] Mark uninitialized regions as interesting.

2019-06-14 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Ping, anything against this? :) Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62899/new/ https://reviews.llvm.org/D62899 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://list

[PATCH] D63371: Rewrite ConstStructBuilder with a mechanism that can cope with splitting and updating constants.

2019-06-14 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith created this revision. rsmith added a reviewer: rjmccall. Herald added a project: clang. This adds a ConstantBuilder class that deals with incrementally building an aggregate constant, including support for overwriting previously-emitted parts of the aggregate with new values. This fixes a

[PATCH] D63366: AMDGPU: Add GWS instruction builtins

2019-06-14 Thread Stanislav Mekhanoshin via Phabricator via cfe-commits
rampitec accepted this revision. rampitec added a comment. This revision is now accepted and ready to land. LGTM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63366/new/ https://reviews.llvm.org/D63366 ___ cfe-commits mailing list cfe-commi

[PATCH] D62899: [analyzer][UninitializedObjectChecker] Mark uninitialized regions as interesting.

2019-06-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. I don't remember what exactly does `markInteresting()` do and these tests don't really convince me that it does anything at all. Halp? >.< Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62899/new/ https://reviews.llvm.org/D62899 __

[PATCH] D53295: Mark store and load of block invoke function as invariant.group

2019-06-14 Thread Piotr Padlewski via Phabricator via cfe-commits
Prazek added inline comments. Comment at: lib/CodeGen/CGBlocks.cpp:1318 +CGM.getModule().getMDKindID("invariant.load"), +llvm::MDNode::get(getLLVMContext(), None)); + rjmccall wrote: > yaxunl wrote: > > rjmccall wrote: > > > OpenCL blocks are stil

[PATCH] D63367: [clang-doc] Add basic support for templates and typedef

2019-06-14 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tools-extra/clang-doc/Serialize.cpp:182 static RecordDecl *getDeclForType(const QualType &T) { - auto *Ty = T->getAs(); - if (!Ty) -return nullptr; - return Ty->getDecl()->getDefinition(); + if (const auto *D = T->g

[PATCH] D63080: [analyzer] Track indices of arrays

2019-06-14 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus updated this revision to Diff 204888. Szelethus added a comment. One more test just for good measure, don't enable null fp suppression. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63080/new/ https://reviews.llvm.org/D63080 Files: clang/lib/StaticAnalyzer/Core/BugReporterV

[PATCH] D62645: [Sema] Resolve placeholder types before type deduction to silence spurious `-Warc-repeated-use-of-weak` warnings

2019-06-14 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added inline comments. Comment at: lib/Sema/SemaDecl.cpp:11101 + if (auto *placeholderType = Init->getType()->getAsPlaceholderType()) +if (placeholderType->getKind() == BuiltinType::PseudoObject) { + Res = CheckPlaceholderExpr(Init).get(); -

[PATCH] D62645: [Sema] Resolve placeholder types before type deduction to silence spurious `-Warc-repeated-use-of-weak` warnings

2019-06-14 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak updated this revision to Diff 204889. ahatanak marked 2 inline comments as done. ahatanak added a comment. Address review comments. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62645/new/ https://reviews.llvm.org/D62645 Files: include/clang/Sema/Sema

[PATCH] D63080: [analyzer] Track indices of arrays

2019-06-14 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. Great, thanks!! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63080/new/ https://reviews.llvm.org/D63080 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin

[PATCH] D62883: [analyzer] Track conditions of terminator statements on which the reported node depends on

2019-06-14 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D62883#1542802 , @Szelethus wrote: > If you hover your mouse over the icon, you can also read a comment of mine. > When you open a report, in the right corner of the source code you'll find a > dropdown menu, allowing you to

[clang-tools-extra] r363481 - [clangd] Index API and implementations for relations

2019-06-14 Thread Nathan Ridge via cfe-commits
Author: nridge Date: Fri Jun 14 19:26:47 2019 New Revision: 363481 URL: http://llvm.org/viewvc/llvm-project?rev=363481&view=rev Log: [clangd] Index API and implementations for relations Summary: This builds on the relations support added in D59407, D62459, and D62471 to expose relations in Symbol

[PATCH] D62839: [clangd] Index API and implementations for relations

2019-06-14 Thread Nathan Ridge via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363481: [clangd] Index API and implementations for relations (authored by nridge, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: https://

[PATCH] D62888: [NewPM] Port Sancov

2019-06-14 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan updated this revision to Diff 204892. leonardchan marked 9 inline comments as done. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62888/new/ https://reviews.llvm.org/D62888 Files: clang/lib/CodeGen/BackendUtil.cpp clang/test/CodeGen/

[PATCH] D62888: [NewPM] Port Sancov

2019-06-14 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan added inline comments. Comment at: clang/lib/CodeGen/BackendUtil.cpp:1231-1232 + MPM.addPass(ModuleSanitizerCoveragePass(SancovOpts)); + MPM.addPass( + createModuleToFunctionPassAdaptor(SanitizerCoveragePass(SancovOpts))); +} c

[PATCH] D63080: [analyzer] Track indices of arrays

2019-06-14 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware accepted this revision. baloghadamsoftware added a comment. This revision is now accepted and ready to land. LGTM! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63080/new/ https://reviews.llvm.org/D63080 ___ cfe-commits m

<    1   2