Commit Graph

77 Commits

Author SHA1 Message Date
Shilei Tian b917433835 [NFC][Doc] Finish atomic compare 2022-06-02 21:50:07 -04:00
Mike Rice 48d6a6c9ad [OpenMP][NFC] update status for 'omp_all_memory' directive to 'done' 2022-06-02 17:31:33 -07:00
Joel E. Denny 4a36813669 [OpenACC][OpenMP] Document atomic-in-teams extension
That is, put D126323 in the status doc and explain its relationship to
OpenACC support.

Reviewed By: jdoerfert

Differential Revision: https://reviews.llvm.org/D126547
2022-05-27 18:53:19 -04:00
Joseph Huber 15e62062c0 [Clang][Docs] Update information on the new driver now that it's default
Summary:
This patch updates some of the documentation on the new driver now that
it's the default. Also the ABI for embedding these images changed.
2022-04-18 15:05:09 -04:00
dreachem 02a05097e7 [OpenMP][NFC] update status for 5.1 'nothing' directive to 'worked on'
Differential Revision: https://reviews.llvm.org/D119440
2022-02-10 09:22:44 -06:00
Joseph Huber 28ab5944cd [Clang][Docs] Add documention for new OpenMP offloading driver
This patch adds more documentation for the OpenMP offloading driver.
This includes a new file that describes the overall pipeline becuase
that was not previously explained in full elsewhere.

Reviewed By: ABataev

Differential Revision: https://reviews.llvm.org/D118815
2022-02-03 13:09:49 -05:00
Deepak Eachempati d976fb0204 [OpenMP][NFC] update status for 5.1 'fail' atomic extension
Update status for the atomic 'fail' clause to "worked on".

Reviewed By: cchen

Differential Revision: https://reviews.llvm.org/D115901
2021-12-17 11:46:37 -06:00
Alexey Bataev 80256605f8 [OpenMP] support depend clause for taskwait directive, by Deepak
Eachempati.

This patch adds clang (parsing, sema, serialization, codegen) support for the 'depend' clause on the 'taskwait' directive.

Reviewed By: ABataev

Differential Revision: https://reviews.llvm.org/D113540
2021-11-19 06:30:17 -08:00
cchen 8c68bd480f [OpenMP][NFC] Add declare variant and metadirective to support page 2021-09-21 11:28:13 -05:00
AndreyChurbanov 608338cca5 [OpenMP][NFC] Added comment on OpenMP 5.0 task affinity pilot implementation 2021-09-08 18:12:31 +03:00
Joel E. Denny 83ddfa0d22 [OpenMP][OpenACC] Implement `ompx_hold` map type modifier extension in Clang (1/2)
This patch implements Clang support for an original OpenMP extension
we have developed to support OpenACC: the `ompx_hold` map type
modifier.  The next patch in this series, D106510, implements OpenMP
runtime support.

Consider the following example:

```
 #pragma omp target data map(ompx_hold, tofrom: x) // holds onto mapping of x
 {
   foo(); // might have map(delete: x)
   #pragma omp target map(present, alloc: x) // x is guaranteed to be present
   printf("%d\n", x);
 }
```

The `ompx_hold` map type modifier above specifies that the `target
data` directive holds onto the mapping for `x` throughout the
associated region regardless of any `target exit data` directives
executed during the call to `foo`.  Thus, the presence assertion for
`x` at the enclosed `target` construct cannot fail.  (As usual, the
standard OpenMP reference count for `x` must also reach zero before
the data is unmapped.)

Justification for inclusion in Clang and LLVM's OpenMP runtime:

* The `ompx_hold` modifier supports OpenACC functionality (structured
  reference count) that cannot be achieved in standard OpenMP, as of
  5.1.
* The runtime implementation for `ompx_hold` (next patch) will thus be
  used by Flang's OpenACC support.
* The Clang implementation for `ompx_hold` (this patch) as well as the
  runtime implementation are required for the Clang OpenACC support
  being developed as part of the ECP Clacc project, which translates
  OpenACC to OpenMP at the directive AST level.  These patches are the
  first step in upstreaming OpenACC functionality from Clacc.
* The Clang implementation for `ompx_hold` is also used by the tests
  in the runtime implementation.  That syntactic support makes the
  tests more readable than low-level runtime calls can.  Moreover,
  upstream Flang and Clang do not yet support OpenACC syntax
  sufficiently for writing the tests.
* More generally, the Clang implementation enables a clean separation
  of concerns between OpenACC and OpenMP development in LLVM.  That
  is, LLVM's OpenMP developers can discuss, modify, and debug LLVM's
  extended OpenMP implementation and test suite without directly
  considering OpenACC's language and execution model, which can be
  handled by LLVM's OpenACC developers.
* OpenMP users might find the `ompx_hold` modifier useful, as in the
  above example.

See new documentation introduced by this patch in `openmp/docs` for
more detail on the functionality of this extension and its
relationship with OpenACC.  For example, it explains how the runtime
must support two reference counts, as specified by OpenACC.

Clang recognizes `ompx_hold` unless `-fno-openmp-extensions`, a new
command-line option introduced by this patch, is specified.

Reviewed By: ABataev, jdoerfert, protze.joachim, grokos

Differential Revision: https://reviews.llvm.org/D106509
2021-08-31 16:13:49 -04:00
Kazu Hirata 612048aec1 [clang] Fix typos in documentation (NFC) 2021-08-21 12:17:58 -07:00
Michael Kruse ba2be8deba [clang/OpenMP][docs] Update OpenMP support list for unroll. 2021-08-03 18:11:17 -05:00
Aaron Ballman de59f56440 [OpenMP] Support OpenMP 5.1 attributes
OpenMP 5.1 added support for writing OpenMP directives using [[]]
syntax in addition to using #pragma and this introduces support for the
new syntax.

In OpenMP, the attributes take one of two forms:
[[omp::directive(...)]] or [[omp::sequence(...)]]. A directive
attribute contains an OpenMP directive clause that is identical to the
analogous #pragma syntax. A sequence attribute can contain either
sequence or directive arguments and is used to ensure that the
attributes are processed sequentially for situations where the order of
the attributes matter (remember:
https://eel.is/c++draft/dcl.attr.grammar#4.sentence-4).

The approach taken here is somewhat novel and deserves mention. We
could refactor much of the OpenMP parsing logic to work for either
pragma annotation tokens or for attribute clauses. It would be a fair
amount of effort to share the logic for both, but it's certainly
doable. However, the semantic attribute system is not designed to
handle the arbitrarily complex arguments that OpenMP directives
contain. Adding support to thread the novel parsed information until we
can produce a semantic attribute would be considerably more effort.
What's more, existing OpenMP constructs are not (often) represented as
semantic attributes. So doing this through Attr.td would be a massive
undertaking that would likely only benefit OpenMP and comes with
additional risks. Rather than walk down that path, I am taking
advantage of the fact that the syntax of the directives within the
directive clause is identical to that of the #pragma form. Once the
parser recognizes that we're processing an OpenMP attribute, it caches
all of the directive argument tokens and then replays them as though
the user wrote a pragma. This reuses the same OpenMP parsing and
semantic logic directly, but does come with a risk if the OpenMP
committee decides to purposefully diverge their pragma and attribute
syntaxes. So, despite this being a novel approach that does token
replay, I think it's actually a better approach than trying to do this
through the declarative syntax in Attr.td.
2021-07-12 06:51:19 -04:00
cchen 924cdff0ae [OpenMP5][DOCS] Update status of masked construct and correct the color
for omp_target_is_present, NFC.
2021-04-15 17:19:04 -05:00
Shilei Tian 2a95cb5858 [Clang][Docs] Claim the atomic compare
I'm working on the implementation of OpenMP 5.1 feature `atomic compare`.

Reviewed By: jdoerfert

Differential Revision: https://reviews.llvm.org/D100507
2021-04-15 11:10:15 -04:00
cchen 3d816537df [OpenMP51][DOCS] Claimed masked construct and report current patch, NFC. 2021-04-09 15:21:13 -05:00
Mike Rice 2165c0d389 [OPENMP][DOCS]Update status of the supported constructs, NFC. 2021-04-02 12:31:36 -07:00
cchen 56b39afb58 [OpenMP51][DOCS] Mark "add present modifier in defaultmap clause" as
done, NFC.
2021-04-01 11:02:23 -05:00
Michael Kruse 4b15b2df23 [clang][OpenMP][docs] Update loop transformation status.
Mark tiling as done and unrolling as being worked on.
2021-03-05 17:26:55 -06:00
Johannes Doerfert 6e7101530d [OpenMP][Docs] Mark finished features as done
Reviewed By: ABataev

Differential Revision: https://reviews.llvm.org/D94185
2021-01-07 14:39:18 -06:00
cchen 1b8ed1d03d [OpenMP51][DOCS] Claim "add present modifier in defaultmap clause", NFC. 2020-12-01 16:07:00 -06:00
cchen 77e98eaee2 [OpenMP50][DOCS] Mark target data non-contiguous as done, NFC. 2020-11-24 16:07:39 -06:00
dreachem 7046be1730 [OpenMP] [DOCS] Update OMP5.1 feature status table [NFC]
Adding features in OpenMP 5.1 specification, as documented in feature change history, to the 5.1 table. I alphabetized the rows of the table according to the category. For deprecating master construct, I just used 'other' as the category.

Reviewed By: jdoerfert

Differential Revision: https://reviews.llvm.org/D90802
2020-11-18 10:46:42 -06:00
Joel E. Denny 03bb545b68 [OpenMP][Docs] Mark `present` map type modifier as done 2020-08-05 10:03:31 -04:00
Joel E. Denny 26cf9c1704 [OpenMP][Docs] Add map clause reordering status as unclaimed 2020-08-05 10:03:31 -04:00
Michael Kruse 18eba165e7 [OpenMP][docs] Update loop tiling status. 2020-07-31 13:01:55 -05:00
Joel E. Denny 3d06fc0049 [OpenMP][Docs] Mark `present` motion modifier as done 2020-07-30 12:21:37 -04:00
Johannes Doerfert 7db017bf34 [OpenMP][Docs] Update Clang Support docs after D75591 2020-07-29 10:21:05 -05:00
Joel E. Denny f250eb37cd [OpenMP][Docs] Update `present` modifier status 2020-07-27 19:23:55 -04:00
Joel E. Denny d6e79e3dd6 [OpenMP][Docs] Update `present` map type modifier status 2020-07-15 11:17:00 -04:00
Joel E. Denny 3fa666b883 [OpenMP][Docs] Mark TR8 `present` as claimed in docs 2020-06-24 14:21:11 -04:00
Alexey Bataev 264f0dbef8 [OPENMP][DOCS]Update status of supported constructs, NFC. 2020-06-23 08:53:58 -04:00
Alexey Bataev eed45b5fa2 [OPENMP][DOCS]Update status of supported constructs, NFC. 2020-06-18 13:29:33 -04:00
Alexey Bataev 993c43aea5 [OPENMP][DOCS]Update status of the supported constrcuts, NFC. 2020-06-16 12:25:08 -04:00
Alexey Bataev c8a869c5e0 [OPENMP][DOCS]Update status of implemented features, NFC. 2020-05-20 10:54:53 -04:00
Alexey Bataev e0ae907ab5 [OPENMP][DOCS]Update status of oimplemented constructs, NFC. 2020-04-07 15:45:08 -04:00
Alexey Bataev 39ada46889 [OPENMP][DOCS]Mark array shaping as done, NFC. 2020-03-31 19:12:52 -04:00
Florian Hahn 684ee2057f [clang/docs] Fix various sphinx warnings/errors in docs.
There are a few places with unexpected indents that trip over sphinx and
other syntax errors.

Also, the C++ syntax highlighting does not work for
    class [[gsl::Owner(int)]] IntOwner {

Use a regular code:: block instead.

There are a few other warnings errors remaining, of the form
'Duplicate explicit target name: "cmdoption-clang--prefix"'. They seem
to be caused by the following
  .. option:: -B<dir>, --prefix <arg>, --prefix=<arg>

I am no Restructured Text expert, but it seems like sphinx 1.8.5
tries to generate the same target for the --prefix <arg> and
--prefix=<arg>. This pops up in a lot of places and I am not sure how to
best resolve it

Reviewers: jfb, Bigcheese, dexonsmith, rjmccall

Reviewed By: rjmccall

Differential Revision: https://reviews.llvm.org/D76534
2020-03-21 16:06:33 +00:00
Alexey Bataev cf1f8f9bec [OPENMP][DOCS]Update list of constructs and status, NFC. 2020-03-19 10:20:29 -04:00
Alexey Bataev 0d7c8c07d2 [OPENMP][DOCS]Mark depobj as implemented, NFC. 2020-03-11 13:26:01 -04:00
Johannes Doerfert 5313abdbca [OpenMP][NFC] Update OpenMPSupport table 2020-02-15 00:40:39 -06:00
Alexey Bataev 7ecf066e65 [OPENMP][DOCS]Fix misprint, NFC. 2020-02-13 15:43:05 -05:00
Alexey Bataev 3eb1b59ec0 [OPENMP50][DOCS]Claim iterators and add reference to array shaping
patch, NFC.
2020-02-13 15:05:19 -05:00
Alexey Bataev 3203e1bc2e [OPENMP50][DOCS]Update list of supported constructs, NFC. 2020-02-13 15:02:59 -05:00
Alexey Bataev 43b98ffed0 [OPENMP][DOCS]Update status of support constructs, NFC. 2020-02-13 12:28:17 -05:00
Alexey Bataev 569dc65c63 [OPNEMP50][DOCS]Mark array shaping expression as claimed, NFC. 2020-02-05 10:02:39 -05:00
Kelvin Li ac43033631 [OpenMP] [DOCS] Update OMP5.0 feature status table [NFC]
Differential Revision: https://reviews.llvm.org/D72901
2020-02-03 18:30:36 -05:00
Alexey Bataev 6c3252e521 [OPENMP][DOCS]Update status of conditional lastprivate, NFC. 2020-02-03 12:43:40 -05:00
Alexey Bataev 3cb934c94e [OPENMP][DOCS]Update status of OpenMP 5.0 features, NFC. 2019-12-24 12:39:59 -05:00