Skip to content

Commit

Permalink
Merged main:7c9c2a2ea5e3 into amd-gfx:357c325e0649
Browse files Browse the repository at this point in the history
Local branch amd-gfx 357c325 Merged main:0b46f19a9ecd into amd-gfx:978a6104758f
Remote branch main 7c9c2a2 Revert "[RISCV] Legalize select when Zbt extension available"
  • Loading branch information
Sw authored and Sw committed Jan 14, 2021
2 parents 357c325 + 7c9c2a2 commit e2ab3cd
Show file tree
Hide file tree
Showing 25 changed files with 938 additions and 712 deletions.
14 changes: 5 additions & 9 deletions clang-tools-extra/clangd/ClangdServer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -243,15 +243,11 @@ void ClangdServer::codeComplete(PathRef File, Position Pos,
// No speculation in Fallback mode, as it's supposed to be much faster
// without compiling.
vlog("Build for file {0} is not ready. Enter fallback mode.", File);
} else {
if (CodeCompleteOpts.Index && CodeCompleteOpts.SpeculativeIndexRequest) {
SpecFuzzyFind.emplace();
{
std::lock_guard<std::mutex> Lock(
CachedCompletionFuzzyFindRequestMutex);
SpecFuzzyFind->CachedReq =
CachedCompletionFuzzyFindRequestByFile[File];
}
} else if (CodeCompleteOpts.Index) {
SpecFuzzyFind.emplace();
{
std::lock_guard<std::mutex> Lock(CachedCompletionFuzzyFindRequestMutex);
SpecFuzzyFind->CachedReq = CachedCompletionFuzzyFindRequestByFile[File];
}
}
ParseInputs ParseInput{IP->Command, &TFS, IP->Contents.str()};
Expand Down
10 changes: 0 additions & 10 deletions clang-tools-extra/clangd/CodeComplete.h
Original file line number Diff line number Diff line change
Expand Up @@ -82,16 +82,6 @@ struct CodeCompleteOptions {
/// Expose origins of completion items in the label (for debugging).
bool ShowOrigins = false;

/// If set to true, this will send an asynchronous speculative index request,
/// based on the index request for the last code completion on the same file
/// and the filter text typed before the cursor, before sema code completion
/// is invoked. This can reduce the code completion latency (by roughly
/// latency of sema code completion) if the speculative request is the same as
/// the one generated for the ongoing code completion from sema. As a sequence
/// of code completions often have the same scopes and proximity paths etc,
/// this should be effective for a number of code completions.
bool SpeculativeIndexRequest = false;

// Populated internally by clangd, do not set.
/// If `Index` is set, it is used to augment the code completion
/// results.
Expand Down
1 change: 0 additions & 1 deletion clang-tools-extra/clangd/tool/ClangdMain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -828,7 +828,6 @@ clangd accepts flags on the commandline, and in the CLANGD_FLAGS environment var
Opts.CodeComplete.IncludeIndicator.Insert.clear();
Opts.CodeComplete.IncludeIndicator.NoInsert.clear();
}
Opts.CodeComplete.SpeculativeIndexRequest = Opts.StaticIndex;
Opts.CodeComplete.EnableFunctionArgSnippets = EnableFunctionArgSnippets;
Opts.CodeComplete.AllScopes = AllScopesCompletion;
Opts.CodeComplete.RunParser = CodeCompletionParse;
Expand Down
1 change: 0 additions & 1 deletion clang-tools-extra/clangd/unittests/CodeCompleteTests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2339,7 +2339,6 @@ TEST(CompletionTest, EnableSpeculativeIndexRequest) {

IndexRequestCollector Requests;
Opts.Index = &Requests;
Opts.SpeculativeIndexRequest = true;

auto CompleteAtPoint = [&](StringRef P) {
cantFail(runCodeComplete(Server, File, Test.point(P), Opts));
Expand Down
90 changes: 74 additions & 16 deletions clang/docs/OpenCLSupport.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,34 +17,92 @@
OpenCL Support
==================

Clang fully supports all OpenCL C versions from 1.1 to 2.0.
Clang has complete support of OpenCL C versions from 1.0 to 2.0.

Please refer to `Bugzilla
<https://bugs.llvm.org/buglist.cgi?component=OpenCL&list_id=172679&product=clang&resolution=--->`__
for the most up to date bug reports.
Clang also supports :ref:`the C++ for OpenCL kernel language <cxx_for_opencl_impl>`.

There is an ongoing work to support :ref:`OpenCL 3.0 <opencl_300>`.

There are also other :ref:`new and experimental features <opencl_experimenal>` available.

For general issues and bugs with OpenCL in clang refer to `Bugzilla
<https://bugs.llvm.org/buglist.cgi?component=OpenCL&list_id=172679&product=clang&resolution=--->`__.

.. _cxx_for_opencl_impl:

C++ for OpenCL Implementation Status
====================================

Bugzilla bugs for this functionality are typically prefixed
with '[C++]'.
Clang implements language version 1.0 published in `the official
release of C++ for OpenCL Documentation
<https://github.com/KhronosGroup/OpenCL-Docs/releases/tag/cxxforopencl-v1.0-r1>`_.

Differences to OpenCL C
-----------------------
Limited support of experimental C++ libraries is described in the `experimental features <opencl_experimenal>`.

Bugzilla bugs for this functionality are typically prefixed
with '[C++4OpenCL]' - click `here
<https://bugs.llvm.org/buglist.cgi?component=OpenCL&list_id=204139&product=clang&query_format=advanced&resolution=---&sh ort_desc=%5BC%2B%2B4OpenCL%5D&short_desc_type=allwordssubstr>`_
to view the full bug list.

TODO!

Missing features or with limited support
----------------------------------------

- Use of ObjC blocks is disabled.

- Global destructor invocation is not generated correctly.

- Initialization of objects in `__constant` address spaces is not guaranteed to work.

- `addrspace_cast` operator is not supported.
- Use of ObjC blocks is disabled and therefore the ``enqueue_kernel`` builtin
function is not supported currently. It is expected that if support for this
feature is added in the future, it will utilize C++ lambdas instead of ObjC
blocks.

- IR generation for global destructors is incomplete (See:
`PR48047 <https://llvm.org/PR48047>`_).

- There is no distinct file extension for sources that are to be compiled
in C++ for OpenCL mode (See: `PR48097 <https://llvm.org/PR48097>`_)

.. _opencl_300:

OpenCL 3.0 Implementation Status
================================

The following table provides an overview of features in OpenCL C 3.0 and their
implementation status.

+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Category | Feature | Status | Reviews |
+==============================+==============================================================+======================+======================= ====================================================+
| Command line interface | New value for ``-cl-std`` flag | :good:`done` | https://reviews.llvm.o rg/D88300 |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Predefined macros | New version macro | :good:`done` | https://reviews.llvm.o rg/D88300 |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Predefined macros | Feature macros | :part:`worked on` | https://reviews.llvm.o rg/D89869 |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Feature optionality | Generic address space | :none:`unclaimed` | |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Feature optionality | Builtin function overloads with generic address space | :part:`worked on` | https://reviews.llvm.o rg/D92004 |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Feature optionality | Program scope variables in global memory | :none:`unclaimed` | |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Feature optionality | 3D image writes including builtin functions | :none:`unclaimed` | |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Feature optionality | read_write images including builtin functions | :none:`unclaimed` | |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Feature optionality | C11 atomics memory scopes, ordering and builtin function | :part:`worked on` | https://reviews.llvm.o rg/D92004 (functions only) |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Feature optionality | Device-side kernel enqueue including builtin functions | :none:`unclaimed` | |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Feature optionality | Pipes including builtin functions | :part:`worked on` | https://reviews.llvm.o rg/D92004 (functions only) |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| Feature optionality | Work group collective functions | :part:`worked on` | https://reviews.llvm.o rg/D92004 |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| New functionality | RGBA vector components | :none:`unclaimed` | |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| New functionality | Subgroup functions | :part:`worked on` | https://reviews.llvm.o rg/D92004 |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+
| New functionality | Atomic mem scopes: subgroup, all devices including functions | :part:`worked on` | https://reviews.llvm.o rg/D92004 (functions only) |
+------------------------------+--------------------------------------------------------------+----------------------+----------------------- ----------------------------------------------------+

.. _opencl_experimenal:

Experimental features
=====================
Expand Down
Loading

0 comments on commit e2ab3cd

Please sign in to comment.