public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Tobias Burnus <tobias@codesourcery.com>
To: Gerald Pfeifer <gerald@pfeifer.com>
Cc: gcc-patches <gcc-patches@gcc.gnu.org>,
	Jakub Jelinek <jakub@redhat.com>,
	Tobias Burnus <tobias@codesourcery.com>
Subject: Re: [wwwdocs] gcc-13/changes.html + projects/gomp/: OpenMP update
Date: Mon, 16 Jan 2023 09:17:56 +0100	[thread overview]
Message-ID: <3007e1a3-2840-7847-69f4-d5c951ef1e9e@codesourcery.com> (raw)
In-Reply-To: <9a83714b-d74f-3db9-6b93-533f1631c642@pfeifer.com>

Hi Gerald,

On 14.01.23 22:47, Gerald Pfeifer wrote:

> I made a couple of incremental edits. See below for what I just pushed
> (and please speak up if you see any issues).
>
> commit 2f870cba5aaaa8c81449beb618a9030824360a25

...

> --- a/htdocs/gcc-13/changes.html
> +++ b/htdocs/gcc-13/changes.html
> @@ -54,10 +54,10 @@ a work-in-progress.</p>

...

> +      <code>requires</code> directive are now accepted. However, the
>         <code>requires_offload</code>, <code>unified_address</code>
> -      and <code>unified_shared_memory</code> clauses cause that the
> -      only available device is the initial device (the host). Fortran now
> +      and <code>unified_shared_memory</code> clauses imply the initial
> +      device (= the host) as the only available device. Fortran now

I really stumble over the "as" – that sounds wrong and I fail to parse this part.
I think it should be "is".

On the technical side, in principle, available devices are the host (aka "initial device") –
and all installed** (nonhost) devices – in our case nvptx and (amd)gcn GPUs.

However, when using 'requires', all installed devices which do not fulfill
the requirement(s) are removed from the list of available devices. In case of
'dynamic_allocators', all devices support it, in case of 'reverse_offload' all installed
amdgcn devices are filtered out and, for unified-shared memory,* neither nvptx nor
amdgcn support it – and are removed from the list – such that at the end, only
the host remains. (Hence, device code ('target regions') will run on the host
→ host fallback.)

BTW: Before the release, further updates to changes.html are required. – For instance,
as alluded in the previous paragraph, 'reverse offload' is (now) supported for nvptx.
(But not yet with amdgcn.)

Tobias

(*) There is support for unified-shared memory for both nvptx and gcn,
but the existing patches either have to be reviewed or to be revised.

(**) I coined the term 'installed device'. OpenMP since TR11 contains some
definitions for 'available devices' – which consists of the union of supported
and accessible devices (possibly after sorting and further filtering). Namely:

accessible devices – The host device and all non-host devices accessible for execution.

supported devices – The host device and all non-host devices supported by the
implementation for execution of target code for which the device-related requirements
of the requires directive are fulfilled.

The available-devices-var is in turn by default "*" – where "* expands to all accessible
and supported devices". (The device list can be further filtered and sorted via
the environment variable OMP_AVAILABLE_DEVICES.)

-----------------
Siemens Electronic Design Automation GmbH; Anschrift: Arnulfstraße 201, 80634 München; Gesellschaft mit beschränkter Haftung; Geschäftsführer: Thomas Heurung, Frank Thürauf; Sitz der Gesellschaft: München; Registergericht München, HRB 106955

  reply	other threads:[~2023-01-16  8:18 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-02  7:37 Tobias Burnus
2022-09-08 15:40 ` Jakub Jelinek
2023-01-14 21:47 ` Gerald Pfeifer
2023-01-16  8:17   ` Tobias Burnus [this message]
2023-01-16 22:16     ` Gerald Pfeifer
2023-01-18 12:39       ` Tobias Burnus
2023-01-20 17:50         ` Jakub Jelinek
2023-01-21 12:48           ` Gerald Pfeifer
2023-01-21 12:53             ` Tobias Burnus
2023-01-23  9:00               ` Tobias Burnus
2023-01-23  9:06                 ` Gerald Pfeifer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3007e1a3-2840-7847-69f4-d5c951ef1e9e@codesourcery.com \
    --to=tobias@codesourcery.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=gerald@pfeifer.com \
    --cc=jakub@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).