[Patch][AMD GCN][OpenMP] Add gcc/config/gcn/t-omp-device for OpenMP declare variant kind/arch/isa

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

[Patch][AMD GCN][OpenMP] Add gcc/config/gcn/t-omp-device for OpenMP declare variant kind/arch/isa

Tobias Burnus-3
This adds gcc/config/gcn/t-omp-device to augment the nvptx, hsa and x86
host implementation.

This compiler has -march= carrizo/fiji/gfx900/gfx906 (for Corrizo, Fiji
and Vega GPUs; arch names aligned with LLVM and passed on to the linker).

This patch uses kind = "gnu" and those -march names for arch *and* isa,
but can argue about this choice.

(I have build the GCN compiler, but didn't do any additional tests –
also because GCN as offloading compiler is not yet supported on the trunk.)

OK for the trunk?

Tobias


gcn-omp.diff (4K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: [Patch][AMD GCN][OpenMP] Add gcc/config/gcn/t-omp-device for OpenMP declare variant kind/arch/isa

Jakub Jelinek
On Mon, Nov 04, 2019 at 04:31:10PM +0100, Tobias Burnus wrote:
> This adds gcc/config/gcn/t-omp-device to augment the nvptx, hsa and x86 host
> implementation.
>
> This compiler has -march= carrizo/fiji/gfx900/gfx906 (for Corrizo, Fiji and
> Vega GPUs; arch names aligned with LLVM and passed on to the linker).
>
> This patch uses kind = "gnu" and those -march names for arch *and* isa, but

You mean "gpu" ;)

> can argue about this choice.

My preference would be that arch on amdgcn is something like amdgcn or gcn.
I hope the general distinction between arch and isa will be something that
will be discussed next Tuesday on the language committee, so hopefully we'll
know more afterwards and can tweak afterwards depending on the outcome.

Ok with that change.

        Jakub

Reply | Threaded
Open this post in threaded view
|

Re: [Patch][AMD GCN][OpenMP] Add gcc/config/gcn/t-omp-device for OpenMP declare variant kind/arch/isa

Andrew Stubbs-4
On 04/11/2019 15:37, Jakub Jelinek wrote:
> My preference would be that arch on amdgcn is something like amdgcn or gcn.
> I hope the general distinction between arch and isa will be something that
> will be discussed next Tuesday on the language committee, so hopefully we'll
> know more afterwards and can tweak afterwards depending on the outcome.
>
> Ok with that change.

I'm fine with this, too. The OpenMP support should be posted Real Soon Now.

We've not been terribly consistent with "gcn" vs. "amdgcn", which is
unfortunate, but we are where we are. Most of the API enums have "GCN",
so let's use that, for now.

Andrew
Reply | Threaded
Open this post in threaded view
|

Re: [Patch][AMD GCN][OpenMP] Add gcc/config/gcn/t-omp-device for OpenMP declare variant kind/arch/isa

Jakub Jelinek
On Mon, Nov 04, 2019 at 04:33:27PM +0000, Andrew Stubbs wrote:

> On 04/11/2019 15:37, Jakub Jelinek wrote:
> > My preference would be that arch on amdgcn is something like amdgcn or gcn.
> > I hope the general distinction between arch and isa will be something that
> > will be discussed next Tuesday on the language committee, so hopefully we'll
> > know more afterwards and can tweak afterwards depending on the outcome.
> >
> > Ok with that change.
>
> I'm fine with this, too. The OpenMP support should be posted Real Soon Now.
>
> We've not been terribly consistent with "gcn" vs. "amdgcn", which is
> unfortunate, but we are where we are. Most of the API enums have "GCN", so
> let's use that, for now.

With the way it is defined in the OpenMP spec, there can be actually aliases, so
having both gcn and amdgcn as supported arch is fine too.

        Jakub