r363908 - [clang][AST] Refactoring ASTNameGenerator to use pimpl pattern (NFC).

2019-06-19 Thread Puyan Lotfi via cfe-commits
Author: zer0 Date: Wed Jun 19 23:01:06 2019 New Revision: 363908 URL: http://llvm.org/viewvc/llvm-project?rev=363908=rev Log: [clang][AST] Refactoring ASTNameGenerator to use pimpl pattern (NFC). The original pimpl pattern used between CodegenNameGenerator and CodegenNameGeneratorImpl did a good

[PATCH] D63584: [clang][AST] Refactoring ASTNameGenerator to use pimpl pattern (NFC).

2019-06-19 Thread Puyan Lotfi via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363908: [clang][AST] Refactoring ASTNameGenerator to use pimpl pattern (NFC). (authored by zer0, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to

[PATCH] D63227: [analyzer] Better timers.

2019-06-19 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: clang/lib/StaticAnalyzer/Core/ExprEngine.cpp:228 -ExprEngine::~ExprEngine() { - BR.FlushReports(); NoQ wrote: > xazax.hun wrote: > > Hmm. Maybe add an assert that all the bug reports are flushed at this > > point?

[PATCH] D60455: [SYCL] Implement SYCL device code outlining

2019-06-19 Thread Ronan Keryell via Phabricator via cfe-commits
keryell added inline comments. Comment at: clang/test/SemaSYCL/device-attributes.cpp:3 + +[[clang::sycl_kernel]] int gv2 = 0; // expected-warning {{'sycl_kernel' attribute only applies to functions}} +__attribute((sycl_kernel)) int gv3 = 0; // expected-warning {{'sycl_kernel'

[PATCH] D63584: [clang][AST] Refactoring ASTNameGenerator to use pimpl pattern (NFC).

2019-06-19 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd accepted this revision. compnerd added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/AST/Mangle.cpp:343 -std::vector -ASTNameGenerator::getAllManglings(const ObjCContainerDecl *OCD) { + std::vector getAllManglings(const

[PATCH] D63156: [clang][NewPM] Add -fno-experimental-new-pass-manager to tests

2019-06-19 Thread Chandler Carruth via Phabricator via cfe-commits
chandlerc added a comment. just a minor comment on one of these... Comment at: clang/test/CodeGen/pgo-sample.c:10 + +// The new pass manager analog to PrunEH is a combination of 'function-attrs' +// and 'function(simplify-cgf)'. s/PrunEH/PruneEH/

[PATCH] D63277: [CUDA][HIP] Don't set "comdat" attribute for CUDA device stub functions.

2019-06-19 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall added a comment. Alright, thanks. I agree that per the documentation this should be sufficient. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63277/new/ https://reviews.llvm.org/D63277 ___

[PATCH] D61989: [clang-tidy] enable modernize-concat-nested-namespaces on header files

2019-06-19 Thread Xiao Shi via Phabricator via cfe-commits
shixiao updated this revision to Diff 205731. shixiao added a comment. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61989/new/ https://reviews.llvm.org/D61989 Files: clang-tools-extra/clang-tidy/modernize/ConcatNestedNamespacesCheck.cpp

[PATCH] D63580: [clang][NewPM] Do not eliminate available_externally durng `-O2 -flto` runs

2019-06-19 Thread Chandler Carruth via Phabricator via cfe-commits
chandlerc accepted this revision. chandlerc added a comment. This revision is now accepted and ready to land. LGTM, again, really nice. Tiny tweak below. Comment at: llvm/test/Other/available-externally-lto.ll:1 +; Ensure that we don't emit available_externally functions at

[PATCH] D63577: [clang][NewPM] Move EntryExitInstrumenterPass to the start of the pipeline

2019-06-19 Thread Chandler Carruth via Phabricator via cfe-commits
chandlerc accepted this revision. chandlerc added a comment. This revision is now accepted and ready to land. LGTM, nice! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63577/new/ https://reviews.llvm.org/D63577

[PATCH] D63584: [clang][AST] Refactoring ASTNameGenerator to use pimpl pattern (NFC).

2019-06-19 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi marked an inline comment as done. plotfi added inline comments. Comment at: clang/lib/AST/Mangle.cpp:343 -std::vector -ASTNameGenerator::getAllManglings(const ObjCContainerDecl *OCD) { + std::vector getAllManglings(const ObjCContainerDecl *OCD) { StringRef

[PATCH] D63584: [clang][AST] Refactoring ASTNameGenerator to use pimpl pattern (NFC).

2019-06-19 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi updated this revision to Diff 205729. plotfi added a comment. full context Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63584/new/ https://reviews.llvm.org/D63584 Files: clang/include/clang/AST/Mangle.h clang/lib/AST/Mangle.cpp

[PATCH] D57086: Ignore trailing NullStmts in StmtExprs for GCC compatibility

2019-06-19 Thread Dominic Ferreira via Phabricator via cfe-commits
domdom added a comment. In D57086#1550514 , @aaron.ballman wrote: > In D57086#1549632 , @domdom wrote: > > > clang-format the patch > > > Thanks! Do you need someone to commit on your behalf? You are very

[PATCH] D63584: [clang][AST] Refactoring ASTNameGenerator to use pimpl pattern (NFC).

2019-06-19 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi updated this revision to Diff 205728. plotfi added a comment. moving datalayout.h Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63584/new/ https://reviews.llvm.org/D63584 Files: clang/include/clang/AST/Mangle.h clang/lib/AST/Mangle.cpp

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

2019-06-19 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan updated this revision to Diff 205727. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63174/new/ https://reviews.llvm.org/D63174 Files: clang/test/CodeGen/avx512-reduceMinMaxIntrin.c clang/test/CodeGen/avx512f-builtins.c

[PATCH] D63538: [analyzer][CFG] Return the correct terminator condition

2019-06-19 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. I think this kinda makes sense, but also it looks like a risky change, because who knows how many times we have took the old behavior for granted. In particular, i'm slightly worried about this breaking the wonky logic of `ExprEngine::VisitLogicalExpr` (cf. D59857

[PATCH] D63584: [clang][AST] Refactoring ASTNameGenerator to use pimpl pattern (NFC).

2019-06-19 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi created this revision. plotfi added reviewers: compnerd, aaron.ballman. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D63584 Files: clang/include/clang/AST/Mangle.h clang/lib/AST/Mangle.cpp

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

2019-06-19 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan added a comment. In D63174#1549601 , @chandlerc wrote: > OMG, I'm so sorry, I had no idea that the tests would explode like that... > Yeah, I don't think that's useful > > Maybe a better approach is to just explicitly run the code through

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

2019-06-19 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D62899#1549715 , @Szelethus wrote: > Added a proper testfile. The only downside of it is that it doesn't test > anything. Use creduce! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62899/new/

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

2019-06-19 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan updated this revision to Diff 205722. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63174/new/ https://reviews.llvm.org/D63174 Files: clang/test/CodeGen/avx512-reduceMinMaxIntrin.c clang/test/CodeGen/avx512f-builtins.c

[PATCH] D62825: [C++2a] Add __builtin_bit_cast, used to implement std::bit_cast

2019-06-19 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington updated this revision to Diff 205713. erik.pilkington marked 16 inline comments as done. erik.pilkington added a comment. Address review comments, thanks! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62825/new/ https://reviews.llvm.org/D62825 Files:

[PATCH] D62825: [C++2a] Add __builtin_bit_cast, used to implement std::bit_cast

2019-06-19 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington added inline comments. Comment at: clang/lib/AST/ExprConstant.cpp:5461-5469 +case APValue::LValue: { + LValue LVal; + LVal.setFrom(Info.Ctx, Val); + APValue RVal; + if (!handleLValueToRValueConversion(Info, BCE, Ty.withConst(), +

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

2019-06-19 Thread Amy Huang via Phabricator via cfe-commits
akhuang added inline comments. Comment at: clang/lib/CodeGen/CodeGenFunction.cpp:908 --EI; llvm::Value *Addr = Builder.CreateStructGEP(nullptr, &*EI, Idx); Addr = Builder.CreateAlignedLoad(Addr, getPointerAlign(), "agg.result"); rnk wrote: >

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

2019-06-19 Thread Amy Huang via Phabricator via cfe-commits
akhuang updated this revision to Diff 205712. akhuang marked 2 inline comments as done. akhuang added a comment. Herald added a subscriber: javed.absar. - fix alignment of pointer in inalloca case - make existing tests stop failing by changing some and adding a check for existing return value

[PATCH] D63277: [CUDA][HIP] Don't set "comdat" attribute for CUDA device stub functions.

2019-06-19 Thread Konstantin Pyzhov via Phabricator via cfe-commits
kpyzhov added a comment. In D63277#1550870 , @rjmccall wrote: > This optimization is disabled for functions not in COMDAT sections? Is that > documented somewhere? It is documented here:

[PATCH] D63156: [clang][NewPM] Add -fno-experimental-new-pass-manager to tests

2019-06-19 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan added a comment. >> **CodeGen/pgo-sample.c [No new fix]**: The test checks that `PruneEH` runs, >> but there doesn’t seem to be a corresponding new PM pass for it. Should >> there be? If there is one then we can just check for that in the debug PM >> dump. > > The analog would be

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

2019-06-19 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan updated this revision to Diff 205707. Herald added subscribers: dexonsmith, steven_wu, javed.absar, mehdi_amini. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63174/new/ https://reviews.llvm.org/D63174 Files:

[PATCH] D63156: [clang][NewPM] Add -fno-experimental-new-pass-manager to tests

2019-06-19 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan updated this revision to Diff 205708. leonardchan marked 3 inline comments as done. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63156/new/ https://reviews.llvm.org/D63156 Files: clang/test/CodeGen/aggregate-assign-call.c

RE: r363855 - [clang] Adapt ASTMatcher to explicit(bool) specifier

2019-06-19 Thread via cfe-commits
Hi Gauthier, Your commit seemed to have broken the build on Windows. Can you take a look? http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast/builds/110 494.204 [1215/36/2881] Linking CXX executable bin\clang-query.exe FAILED: bin/clang-query.exe cmd.exe /C "cd .

[PATCH] D63227: [analyzer] Better timers.

2019-06-19 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ marked an inline comment as done. NoQ added inline comments. Comment at: clang/lib/StaticAnalyzer/Core/ExprEngine.cpp:228 -ExprEngine::~ExprEngine() { - BR.FlushReports(); xazax.hun wrote: > Hmm. Maybe add an assert that all the bug reports are flushed at

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

2019-06-19 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363898: [analyzer] exploded-graph-rewriter: Implement a --diff mode. (authored by dergachev, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to

[PATCH] D63580: [clang][NewPM] Do not eliminate available_externally durng `-O2 -flto` runs

2019-06-19 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan created this revision. leonardchan added reviewers: chandlerc, phosek, echristo, serge-sans-paille. leonardchan added a project: clang. Herald added subscribers: llvm-commits, dexonsmith, steven_wu, hiraditya, inglorion, mehdi_amini. Herald added a project: LLVM. This fixes

[PATCH] D63519: [analyzer] exploded-graph-rewriter: Fix escaping and unescaping of StringRegions.

2019-06-19 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363897: [analyzer] exploded-graph-rewriter: Fix escaping StringRegions. (authored by dergachev, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to

[PATCH] D62716: [analyzer] Fix JSON dumps for dynamic types, add test.

2019-06-19 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363894: [analyzer] Fix JSON dumps for dynamic type information. (authored by dergachev, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

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

2019-06-19 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363896: [analyzer] Fix JSON dumps for store clusters. (authored by dergachev, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D62754: [analyzer] Fix JSON dumps for location contexts.

2019-06-19 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363895: [analyzer] Fix JSON dumps for location contexts. (authored by dergachev, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D62440: [analyzer] NFC: Change evalCall() to provide a CallEvent.

2019-06-19 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363893: [analyzer] NFC: Change evalCall() to provide a CallEvent. (authored by dergachev, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

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

2019-06-19 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Jun 19 16:33:59 2019 New Revision: 363898 URL: http://llvm.org/viewvc/llvm-project?rev=363898=rev Log: [analyzer] exploded-graph-rewriter: Implement a --diff mode. In this mode the tool would avoid duplicating the contents of the program state on every node, replacing

[PATCH] D63118: [analyzer] DeadStores: Add a crude suppression files generated by DriverKit IIG.

2019-06-19 Thread Phabricator 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 rL363892: [analyzer] DeadStores: Add a crude suppression files generated by DriverKit IIG. (authored by dergachev,

[PATCH] D63117: [analyzer] RetainCount: Add support for OSRequiredCast().

2019-06-19 Thread Phabricator 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 rL363891: [analyzer] RetainCount: Add support for OSRequiredCast(). (authored by dergachev, committed by ). Herald added a

r363897 - [analyzer] exploded-graph-rewriter: Fix escaping StringRegions.

2019-06-19 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Jun 19 16:33:55 2019 New Revision: 363897 URL: http://llvm.org/viewvc/llvm-project?rev=363897=rev Log: [analyzer] exploded-graph-rewriter: Fix escaping StringRegions. Quotes around StringRegions are now escaped and unescaped correctly, producing valid JSON.

[PATCH] D63579: [clang-scan-deps] print the dependencies to stdout and remove the need to use -MD options in the CDB

2019-06-19 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. arphaman added reviewers: Bigcheese, aganea. Herald added subscribers: tschuett, dexonsmith, jkorous. Herald added a project: clang. The gathered dependencies are now printed to the STDOUT instead of being written to disk. The tool also doesn't need the dependency

r363894 - [analyzer] Fix JSON dumps for dynamic type information.

2019-06-19 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Jun 19 16:33:45 2019 New Revision: 363894 URL: http://llvm.org/viewvc/llvm-project?rev=363894=rev Log: [analyzer] Fix JSON dumps for dynamic type information. They're now valid JSON. Differential Revision: https://reviews.llvm.org/D62716 Modified:

r363892 - [analyzer] DeadStores: Add a crude suppression files generated by DriverKit IIG.

2019-06-19 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Jun 19 16:33:39 2019 New Revision: 363892 URL: http://llvm.org/viewvc/llvm-project?rev=363892=rev Log: [analyzer] DeadStores: Add a crude suppression files generated by DriverKit IIG. IIG is a replacement for MIG in DriverKit: IIG is autogenerating C++ code. Suppress

r363896 - [analyzer] Fix JSON dumps for store clusters.

2019-06-19 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Jun 19 16:33:51 2019 New Revision: 363896 URL: http://llvm.org/viewvc/llvm-project?rev=363896=rev Log: [analyzer] Fix JSON dumps for store clusters. Include a unique pointer so that it was possible to figure out if it's the same cluster in different program states.

r363895 - [analyzer] Fix JSON dumps for location contexts.

2019-06-19 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Jun 19 16:33:48 2019 New Revision: 363895 URL: http://llvm.org/viewvc/llvm-project?rev=363895=rev Log: [analyzer] Fix JSON dumps for location contexts. Location context ID is a property of the location context, not of an item within it. It's useful to know the id even

r363891 - [analyzer] RetainCount: Add support for OSRequiredCast().

2019-06-19 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Jun 19 16:33:34 2019 New Revision: 363891 URL: http://llvm.org/viewvc/llvm-project?rev=363891=rev Log: [analyzer] RetainCount: Add support for OSRequiredCast(). It's a new API for custom RTTI in Apple IOKit/DriverKit framework that is similar to OSDynamicCast() that's

r363893 - [analyzer] NFC: Change evalCall() to provide a CallEvent.

2019-06-19 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Jun 19 16:33:42 2019 New Revision: 363893 URL: http://llvm.org/viewvc/llvm-project?rev=363893=rev Log: [analyzer] NFC: Change evalCall() to provide a CallEvent. This changes the checker callback signature to use the modern, easy to use interface. Additionally, this

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-06-19 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 updated this revision to Diff 205696. xbolva00 added a comment. Addressed review notes. Thanks! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63082/new/ https://reviews.llvm.org/D63082 Files: include/clang/Basic/DiagnosticGroups.td

r363890 - [X86] Correct the __min_vector_width__ attribute on a few intrinsics.

2019-06-19 Thread Craig Topper via cfe-commits
Author: ctopper Date: Wed Jun 19 16:27:04 2019 New Revision: 363890 URL: http://llvm.org/viewvc/llvm-project?rev=363890=rev Log: [X86] Correct the __min_vector_width__ attribute on a few intrinsics. Modified: cfe/trunk/lib/Headers/avx512bwintrin.h cfe/trunk/lib/Headers/avx512vlintrin.h

[PATCH] D63575: [WebAssembly] Add builtin functions for creating vector constants

2019-06-19 Thread Thomas Lively via Phabricator via cfe-commits
tlively added a comment. This CL does not provide a mechanism for enforcing that the lanes of a floating point vector are constant, and it doesn't look like clang supports that kind of check. That makes this CL a half-baked solution, so I'm not sure we should actually go in this direction.

[clang-tools-extra] r363889 - [clangd] Include the diagnostics's code when comparing diagnostics

2019-06-19 Thread Nathan Ridge via cfe-commits
Author: nridge Date: Wed Jun 19 16:11:02 2019 New Revision: 363889 URL: http://llvm.org/viewvc/llvm-project?rev=363889=rev Log: [clangd] Include the diagnostics's code when comparing diagnostics Summary: This fixes https://github.com/clangd/clangd/issues/60 Reviewers: kadircet Reviewed By:

[PATCH] D63316: [clangd] Include the diagnostics's code when comparing diagnostics

2019-06-19 Thread Nathan Ridge via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363889: [clangd] Include the diagnosticss code when comparing diagnostics (authored by nridge, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to

[PATCH] D63316: [clangd] Include the diagnostics's code when comparing diagnostics

2019-06-19 Thread Nathan Ridge via Phabricator via cfe-commits
nridge updated this revision to Diff 205694. nridge added a comment. Add requested test case Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63316/new/ https://reviews.llvm.org/D63316 Files: clang-tools-extra/clangd/Protocol.h

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-19 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added inline comments. Comment at: clang/lib/StaticAnalyzer/Core/CoreEngine.cpp:401 + case Stmt::GCCAsmStmtClass: +return; } nickdesaulniers wrote: > nickdesaulniers wrote: > > NoQ wrote: > > > Please add a TODO to actually implement

[PATCH] D61809: [BPF] Preserve debuginfo array/union/struct type/access index

2019-06-19 Thread Yonghong Song via Phabricator via cfe-commits
yonghong-song marked an inline comment as done. yonghong-song added a comment. @eli.friedman Sorry for replying late. I am outside US and currently in PTO. Will back to US soon to address your comments. > can we really expect the user to know which expressions to apply this to? Yes, this is

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-19 Thread Tom Roeder via Phabricator via cfe-commits
tmroeder added a comment. I can confirm that this fixes the clang-tidy crash I observed in trying to analyze the kernel. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63533/new/ https://reviews.llvm.org/D63533

[PATCH] D63578: AMDGPU: Add DS GWS sema builtins

2019-06-19 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. arsenm added a parent revision: D63576: AMDGPU: Add intrinsics for DS GWS semaphore instructions. https://reviews.llvm.org/D63578

[PATCH] D63423: [Diagnostics] Diagnose misused xor as pow

2019-06-19 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 updated this revision to Diff 205692. xbolva00 added a comment. Improved code, added const. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63423/new/ https://reviews.llvm.org/D63423 Files: include/clang/Basic/DiagnosticGroups.td include/clang/Basic/DiagnosticSemaKinds.td

[PATCH] D63577: [clang][NewPM] Move EntryExitInstrumenterPass to the start of the pipeline

2019-06-19 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan created this revision. leonardchan added reviewers: chandlerc, phosek, echristo, serge-sans-paille. leonardchan added a project: clang. This fixes `CodeGen/x86_64-instrument-functions.c` when running under the new pass manager. The pass should go before any other pass to prevent

[PATCH] D60974: Clang IFSO driver action.

2019-06-19 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi updated this revision to Diff 205686. plotfi added a comment. This should address the shared lib issue. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60974/new/ https://reviews.llvm.org/D60974 Files:

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-06-19 Thread Arnaud Bienner via Phabricator via cfe-commits
ArnaudBienner added inline comments. Comment at: lib/Sema/SemaChecking.cpp:11103 + + if (auto *BO = dyn_cast(E)) { +BinaryOperator::Opcode Opc = BO->getOpcode(); Shouldn't that be "const auto*" instead? I'm surprised dyn_cast casts away const qualifier, but

[PATCH] D63575: [WebAssembly] Add builtin functions for creating vector constants

2019-06-19 Thread Thomas Lively via Phabricator via cfe-commits
tlively created this revision. tlively added reviewers: dschuff, aheejin. Herald added subscribers: cfe-commits, sunfish, jgravelle-google, sbc100. Herald added a project: clang. These builtins do not offer any functionality over the normal aggregate initialization for vector types, except that

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-19 Thread Nathan Huckleberry via Phabricator via cfe-commits
Nathan-Huckleberry marked an inline comment as done. Nathan-Huckleberry added inline comments. Comment at: clang/test/Analysis/egraph-asm-goto-no-crash.cpp:1 +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-dump-egraph=%t.dot %s +// RUN: cat %t.dot | FileCheck %s

[PATCH] D63518: WIP BitStream reader: propagate errors

2019-06-19 Thread JF Bastien via Phabricator via cfe-commits
jfb added a comment. In D63518#1550827 , @bruno wrote: > Hi JF. Thanks for working on this, nice improvement to error handling! > > The overall approach is pretty solid and should prevent a lot of red herring > while investigating hard to reproduce

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

2019-06-19 Thread Anton Afanasyev via Phabricator via cfe-commits
anton-afanasyev updated this revision to Diff 205673. anton-afanasyev added a comment. Updated, changed test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63325/new/ https://reviews.llvm.org/D63325 Files: clang/lib/CodeGen/CodeGenAction.cpp

[PATCH] D63108: [OpenMP] Add support for handling declare target to clause when unified memory is required

2019-06-19 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added a comment. Still need to update the test but the rest of the code is updated. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63108/new/ https://reviews.llvm.org/D63108 ___ cfe-commits mailing list

[PATCH] D63108: [OpenMP] Add support for handling declare target to clause when unified memory is required

2019-06-19 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 205667. gtbercea marked an inline comment as done. gtbercea added a comment. - Merge MT_Link and MT_To with unified memory cases. - Transform switch into if statements. - Fix declare target attribute checks. Repository: rC Clang CHANGES SINCE LAST

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-19 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added inline comments. Comment at: clang/lib/StaticAnalyzer/Core/CoreEngine.cpp:401 + case Stmt::GCCAsmStmtClass: +return; } nickdesaulniers wrote: > NoQ wrote: > > Please add a TODO to actually implement this functionality. >

[PATCH] D60455: [SYCL] Implement SYCL device code outlining

2019-06-19 Thread Alexey Bader via Phabricator via cfe-commits
bader added inline comments. Comment at: clang/test/SemaSYCL/device-attributes.cpp:3 + +[[clang::sycl_kernel]] int gv2 = 0; // expected-warning {{'sycl_kernel' attribute only applies to functions}} +__attribute((sycl_kernel)) int gv3 = 0; // expected-warning {{'sycl_kernel'

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-19 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added inline comments. Comment at: clang/test/Analysis/egraph-asm-goto-no-crash.cpp:1 +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-dump-egraph=%t.dot %s +// RUN: cat %t.dot | FileCheck %s NoQ wrote: > NoQ wrote: > > NoQ wrote: >

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-19 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/test/Analysis/egraph-asm-goto-no-crash.cpp:1 +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-dump-egraph=%t.dot %s +// RUN: cat %t.dot | FileCheck %s NoQ wrote: > NoQ wrote: > > Ugh, you picked an exotic

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-19 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/test/Analysis/egraph-asm-goto-no-crash.cpp:1 +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-dump-egraph=%t.dot %s +// RUN: cat %t.dot | FileCheck %s NoQ wrote: > Ugh, you picked an exotic test as an

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-19 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/test/Analysis/egraph-asm-goto-no-crash.cpp:1 +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-dump-egraph=%t.dot %s +// RUN: cat %t.dot | FileCheck %s Ugh, you picked an exotic test as an example. Let's

[PATCH] D63535: [clang][AST] ASTNameGenerator: A refactoring of CodegenNameGeneratorImpl (NFC).

2019-06-19 Thread Puyan Lotfi via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363878: [clang][AST] ASTNameGenerator: A refactoring of CodegenNameGeneratorImpl (NFC). (authored by zer0, committed by ). Herald added subscribers: llvm-commits, mgorny. Herald added a project: LLVM.

r363878 - [clang][AST] ASTNameGenerator: A refactoring of CodegenNameGeneratorImpl (NFC).

2019-06-19 Thread Puyan Lotfi via cfe-commits
Author: zer0 Date: Wed Jun 19 13:51:35 2019 New Revision: 363878 URL: http://llvm.org/viewvc/llvm-project?rev=363878=rev Log: [clang][AST] ASTNameGenerator: A refactoring of CodegenNameGeneratorImpl (NFC). This is a NFC refactor move of CodegenNameGeneratorImpl from clang::Index to clang:AST

[PATCH] D60455: [SYCL] Implement SYCL device code outlining

2019-06-19 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon added inline comments. Comment at: clang/include/clang/Basic/AttrDocs.td:263-264 +entry point to device code i.e. will be called by host in run time. +Here is a code example of the SYCL program, which demonstrates the need for +this attribute: +.. code-block:: c++

[PATCH] D60455: [SYCL] Implement SYCL device code outlining

2019-06-19 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon updated this revision to Diff 205663. Fznamznon added a comment. Appled part of comments from @aaron.ballman: - Fixed grammar and code style in all places except sycl_kernel docs - Added a lit test which checks that sycl_device attribute implicitly added to proper declarations

r363873 - Print whether a generic selection expression is result dependent when dumping the AST to JSON.

2019-06-19 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Wed Jun 19 13:16:55 2019 New Revision: 363873 URL: http://llvm.org/viewvc/llvm-project?rev=363873=rev Log: Print whether a generic selection expression is result dependent when dumping the AST to JSON. Modified: cfe/trunk/include/clang/AST/JSONNodeDumper.h

r363871 - Reapply "r363684: AMDGPU: Add GWS instruction builtins"

2019-06-19 Thread Matt Arsenault via cfe-commits
Author: arsenm Date: Wed Jun 19 12:55:49 2019 New Revision: 363871 URL: http://llvm.org/viewvc/llvm-project?rev=363871=rev Log: Reapply "r363684: AMDGPU: Add GWS instruction builtins" Modified: cfe/trunk/include/clang/Basic/BuiltinsAMDGPU.def

r363869 - Print out the union field being initialized by an InitListExpr when dumping the AST to JSON.

2019-06-19 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Wed Jun 19 12:40:07 2019 New Revision: 363869 URL: http://llvm.org/viewvc/llvm-project?rev=363869=rev Log: Print out the union field being initialized by an InitListExpr when dumping the AST to JSON. Modified: cfe/trunk/include/clang/AST/JSONNodeDumper.h

[PATCH] D57450: [RISCV] Set MaxAtomicInlineWidth and MaxAtomicPromoteWidth for RV32/RV64 targets with atomics

2019-06-19 Thread John LLVM via Phabricator via cfe-commits
JohnLLVM added a comment. Herald added subscribers: Jim, benna, psnobl, dexonsmith. @asb: Gentle ping on this. I would really like to avoid atomics libcalls in order to make proper llvm benchmarks. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57450/new/

[PATCH] D63277: [CUDA][HIP] Don't set "comdat" attribute for CUDA device stub functions.

2019-06-19 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. This optimization is disabled for functions not in COMDAT sections? Is that documented somewhere? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63277/new/ https://reviews.llvm.org/D63277 ___ cfe-commits mailing

[PATCH] D63277: [CUDA][HIP] Don't set "comdat" attribute for CUDA device stub functions.

2019-06-19 Thread Konstantin Pyzhov via Phabricator via cfe-commits
kpyzhov updated this revision to Diff 205655. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63277/new/ https://reviews.llvm.org/D63277 Files: clang/lib/CodeGen/CodeGenModule.cpp Index: clang/lib/CodeGen/CodeGenModule.cpp

[PATCH] D63508: make -frewrite-includes handle __has_include wrapped in a macro

2019-06-19 Thread Luboš Luňák via Phabricator via cfe-commits
llunak added a comment. In D63508#1550668 , @rsmith wrote: > Perhaps we should rewrite all `#if`-like directives to `#if 0` or `#if 1`? I think that would work too and it'd be in fact a reliable simple solution. Repository: rC Clang CHANGES SINCE

[PATCH] D59744: Fix i386 ABI "__m64" type bug

2019-06-19 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added a comment. -O0 always inline isn't working because the frontend is emitting a store of vector type to memory then a load of x86_mmx to do the type coercion. The caller does the opposite to coerce back from mmx. This -O0 pipeline isn't capable of getting rid of these

r363866 - Dump the value calculated by a constant expression when dumping the AST to JSON.

2019-06-19 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Wed Jun 19 12:12:22 2019 New Revision: 363866 URL: http://llvm.org/viewvc/llvm-project?rev=363866=rev Log: Dump the value calculated by a constant expression when dumping the AST to JSON. Modified: cfe/trunk/include/clang/AST/JSONNodeDumper.h

r363859 - Switching this test to use output generated by script; NFC.

2019-06-19 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Wed Jun 19 12:07:52 2019 New Revision: 363859 URL: http://llvm.org/viewvc/llvm-project?rev=363859=rev Log: Switching this test to use output generated by script; NFC. Modified: cfe/trunk/test/AST/ast-dump-if-json.cpp Modified:

[PATCH] D63518: WIP BitStream reader: propagate errors

2019-06-19 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Hi JF. Thanks for working on this, nice improvement to error handling! The overall approach is pretty solid and should prevent a lot of red herring while investigating hard to reproduce crashes in clang, specially when implicit clang modules is involved. Dropping the

[PATCH] D63423: [Diagnostics] Diagnose misused xor as pow

2019-06-19 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. David Malcon - GCC: “I think we'd want to *not* warn if either of the operands are from a macro expansion.“ But I see no reason to follow this and why we should restrict this even more.. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63423/new/

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-06-19 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:8739 +/// // For each component specified by this mapper: +/// if (currentComponent.hasMapper()) +/// (*currentComponent.Mapper())(rt_mapper_handle, arg_base, arg_begin,

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

2019-06-19 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. I see we don't have any tests for inalloca to model this on, so I think we should skip that for this change. I'll add one later that handles arguments as well, since those are interesting. Comment at: clang/lib/CodeGen/CGDecl.cpp:1564 +Address

[PATCH] D63535: [clang][AST] ASTNameGenerator: A refactoring of CodegenNameGeneratorImpl (NFC).

2019-06-19 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi marked 3 inline comments as done. plotfi added inline comments. Comment at: clang/lib/AST/Mangle.cpp:25 #include "llvm/ADT/StringExtras.h" +#include "llvm/IR/Mangler.h" #include "llvm/Support/ErrorHandling.h" aaron.ballman wrote: > Do we have to link in

r363857 - [AST] Fixed extraneous warnings for binary conditional operator

2019-06-19 Thread Nathan Huckleberry via cfe-commits
Author: nathan-huckleberry Date: Wed Jun 19 11:37:01 2019 New Revision: 363857 URL: http://llvm.org/viewvc/llvm-project?rev=363857=rev Log: [AST] Fixed extraneous warnings for binary conditional operator Summary: Binary conditional operator gave warnings where ternary operators did not. They

[PATCH] D63535: [clang][AST] ASTNameGenerator: A refactoring of CodegenNameGeneratorImpl (NFC).

2019-06-19 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. LGTM with a few nits. Comment at: clang/include/clang/AST/Mangle.h:253 +public: + ASTNameGenerator(ASTContext ); + bool writeName(const Decl *D, raw_ostream ); Slight preference to make

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

2019-06-19 Thread Nathan Huckleberry via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363857: [AST] Fixed extraneous warnings for binary conditional operator (authored by Nathan-Huckleberry, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed

[PATCH] D63423: [Diagnostics] Diagnose misused xor as pow

2019-06-19 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D63423#1550768 , @xbolva00 wrote: > >> Perhaps the author can run the check over a large corpus of code to see > >> whether fps come up in practice? (The presence of fps will suggest to not > >> warn in macros, but the

[PATCH] D63108: [OpenMP] Add support for handling declare target to clause when unified memory is required

2019-06-19 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: lib/CodeGen/CGExpr.cpp:2297-2319 +static Address emitDeclTargetToVarDeclLValue(CodeGenFunction , + const VarDecl *VD, QualType T) { + llvm::Optional Res = +

[PATCH] D61552: [clang] Adapt ASTMatcher to explicit(bool) specifier

2019-06-19 Thread Tyker via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL363855: [clang] Adapt ASTMatcher to explicit(bool) specifier (authored by Tyker, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

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

2019-06-19 Thread Amy Huang via Phabricator via cfe-commits
akhuang marked an inline comment as done. akhuang added inline comments. Comment at: clang/lib/CodeGen/CodeGenFunction.cpp:908 --EI; llvm::Value *Addr = Builder.CreateStructGEP(nullptr, &*EI, Idx); Addr = Builder.CreateAlignedLoad(Addr, getPointerAlign(),

  1   2   3   >