Further simplify 'gcc/omp-oacc-neuter-broadcast.cc:record_field_map_t' (was: [PATCH 1/4] openacc: Middle-end worker-partitioning support)

2022-02-22 Thread Thomas Schwinge
Hi! On 2021-08-16T12:34:09+0200, I wrote: > On 2021-08-06T09:49:58+0100, Julian Brown wrote: >> On Wed, 4 Aug 2021 15:13:30 +0200 >> Thomas Schwinge wrote: >> >>> 'oacc_do_neutering' is the 'execute' function of the pass, so that >>> means every time this executes, a fresh 'field_map' is set up,

Re: [PATCH 1/4] openacc: Middle-end worker-partitioning support

2021-08-16 Thread Thomas Schwinge
Hi! On 2021-03-02T04:20:11-0800, Julian Brown wrote: > --- /dev/null > +++ b/gcc/oacc-neuter-bcast.c Allocated here: > +static parallel_g * > +omp_sese_find_par (bb_stmt_map_t *map, parallel_g *par, basic_block block) > +{ > + par = new parallel_g ([...]); > + par = new pa

Re: [PATCH 1/4] openacc: Middle-end worker-partitioning support

2021-08-16 Thread Thomas Schwinge
Hi! On 2021-03-02T04:20:11-0800, Julian Brown wrote: > --- /dev/null > +++ b/gcc/oacc-neuter-bcast.c Allocated here: > +/* Sets of SSA_NAMES or VAR_DECLs to propagate. */ > +typedef hash_set propagation_set; > + > +static void > +find_ssa_names_to_propagate ([...], > +

Re: [PATCH 1/4] openacc: Middle-end worker-partitioning support

2021-08-16 Thread Thomas Schwinge
Hi! On 2021-08-06T09:49:58+0100, Julian Brown wrote: > On Wed, 4 Aug 2021 15:13:30 +0200 > Thomas Schwinge wrote: > >> 'oacc_do_neutering' is the 'execute' function of the pass, so that >> means every time this executes, a fresh 'field_map' is set up, no >> state persists across runs (assuming I

Re: [PATCH 1/4] openacc: Middle-end worker-partitioning support

2021-08-09 Thread Thomas Schwinge
Hi! On 2021-08-06T10:25:22+0100, Julian Brown wrote: > On Wed, 4 Aug 2021 15:56:49 +0200 > Thomas Schwinge wrote: >> a nontrivial amount of data structures/logic/code did get >> duplicated from the nvptx back end, and modified slightly or >> not-so-slightly (RTL vs. GIMPLE plus certain implement

Re: [PATCH 1/4] openacc: Middle-end worker-partitioning support

2021-08-09 Thread Thomas Schwinge
Hi! On 2021-03-02T04:20:11-0800, Julian Brown wrote: > This patch implements worker-partitioning support in the middle end, > by rewriting gimple. [...] Thanks! > The OpenACC execution model requires that code > can run in either "worker single" mode where only a single worker per > gang is ac

Re: [OpenACC] Extract 'pass_oacc_loop_designation' out of 'pass_oacc_device_lower' (was: [PATCH 1/4] openacc: Middle-end worker-partitioning support)

2021-08-06 Thread Julian Brown
On Thu, 29 Jul 2021 09:49:05 +0200 Thomas Schwinge wrote: > > namespace { > > > > +const pass_data pass_data_oacc_loop_designation = > > +{ > > + GIMPLE_PASS, /* type */ > > + "oaccloops", /* name */ > > + OPTGROUP_OMP, /* optinfo_flags */ > > + TV_NONE, /* tv_id */ > > + PROP_cfg, /* pro

Re: [PATCH 1/4] openacc: Middle-end worker-partitioning support

2021-08-06 Thread Julian Brown
On Wed, 4 Aug 2021 15:56:49 +0200 Thomas Schwinge wrote: > > This version of the patch [...] > > avoids moving SESE-region finding code out > > of the NVPTX backend > > So that's 'struct bb_sese' and following functions. > > > since that code isn't used by the middle-end worker > > partitioni

Re: [PATCH 1/4] openacc: Middle-end worker-partitioning support

2021-08-06 Thread Julian Brown
On Wed, 4 Aug 2021 15:13:30 +0200 Thomas Schwinge wrote: > 'oacc_do_neutering' is the 'execute' function of the pass, so that > means every time this executes, a fresh 'field_map' is set up, no > state persists across runs (assuming I'm understanding that > correctly). Why don't we simply use st

Re: [PATCH 1/4] openacc: Middle-end worker-partitioning support

2021-08-04 Thread Thomas Schwinge
Hi! On 2021-03-02T04:20:11-0800, Julian Brown wrote: > This patch implements worker-partitioning support in the middle end, > by rewriting gimple. [...] Yay! > This version of the patch [...] > avoids moving SESE-region finding code out > of the NVPTX backend So that's 'struct bb_sese' and f

Re: [PATCH 1/4] openacc: Middle-end worker-partitioning support

2021-08-04 Thread Thomas Schwinge
Hi! On 2021-03-02T04:20:11-0800, Julian Brown wrote: > This patch implements worker-partitioning support in the middle end, > by rewriting gimple. [...] Yay! Given: > --- /dev/null > +++ b/gcc/oacc-neuter-bcast.c > +/* A map from SSA names or var decls to record fields. */ > + > +typedef ha

[OpenACC] Extract 'pass_oacc_loop_designation' out of 'pass_oacc_device_lower' (was: [PATCH 1/4] openacc: Middle-end worker-partitioning support)

2021-07-29 Thread Thomas Schwinge
Hi Julian! On 2021-03-02T04:20:11-0800, Julian Brown wrote: > This patch implements worker-partitioning support in the middle end, > [...] I've first separately pushed the mostly "mechanical changes" re "[OpenACC] Extract 'pass_oacc_loop_designation' out of 'pass_oacc_device_lower'" to master br

[PATCH 1/4] openacc: Middle-end worker-partitioning support

2021-03-02 Thread Julian Brown
A version of this patch was previously posted here: https://gcc.gnu.org/pipermail/gcc-patches/2019-November/534553.html This patch implements worker-partitioning support in the middle end, by rewriting gimple. The OpenACC execution model requires that code can run in either "worker single" mode