Re: [PATCH 0/8] fortran: Inline MINLOC/MAXLOC without DIM argument [PR90608]

2024-08-07 Thread Mikael Morin
Hello, Le 06/08/2024 à 22:57, Thomas Koenig a écrit : Hi Mikael and Harald, - inline expansion is inhibited at -Os.  But wouldn't it be good if    we make this expansion also dependent on -ffrontend-optimize?    (This was the case for rank-1 before your patch). By the way, I disabled the min

Re: [PATCH 0/8] fortran: Inline MINLOC/MAXLOC without DIM argument [PR90608]

2024-08-07 Thread Mikael Morin
Hello, Le 06/08/2024 à 22:05, Harald Anlauf a écrit : Hi Mikael, thanks for this nice set of patches! I've played around a bit, and it seems to look good. I have only minor comments left (besides the nan issue raised): - inline expansion is inhibited at -Os.  But wouldn't it be good if   we

Re: [PATCH 0/8] fortran: Inline MINLOC/MAXLOC without DIM argument [PR90608]

2024-08-07 Thread Harald Anlauf
Hi Mikael, Thomas! Am 07.08.24 um 11:11 schrieb Mikael Morin: Hello, Le 06/08/2024 à 22:57, Thomas Koenig a écrit : Hi Mikael and Harald, - inline expansion is inhibited at -Os.  But wouldn't it be good if    we make this expansion also dependent on -ffrontend-optimize?    (This was the case

[PATCH, v3] OpenMP: Constructors and destructors for "declare target" static aggregates

2024-08-07 Thread Tobias Burnus
CCed Fortran because of the first item: This patch now uses (again like in v1) a builtin for 'omp_is_initial_device'; like in v2, it is compile-time evaluated, but this time (new!) it also handled the case that a user wrote that routine. Note: The omp_… namespace is owned by OpenMP, i.e. if i

Re: [PATCH, v3] OpenMP: Constructors and destructors for "declare target" static aggregates

2024-08-07 Thread Jakub Jelinek
On Wed, Aug 07, 2024 at 02:08:42PM +0200, Tobias Burnus wrote: > On Aug 1, 2024, Jakub Jelinek wrote: > > On Tue, Jul 30, 2024 at 10:51:56PM +0200, Tobias Burnus wrote: > > > - char id[sizeof (SSDF_IDENTIFIER) + 1 /* '\0' */ + 32]; > > > + tree name; > > > ... > > I'd just use a single buffer her

Re: [PATCH, v3] OpenMP: Constructors and destructors for "declare target" static aggregates

2024-08-07 Thread Tobias Burnus
Hi Jakub, for C/C++, -fno-builtin-omp_is_initial_device already disabled the expansion. I added it also for Fortran. Plus added a C and a Fortran testcase for the disable flag. * * * Wording wise, it failed before for Fortran with: f951: Warning: command-line option ‘-fno-builtin-omp_is_i

Re: [PATCH, v3] OpenMP: Constructors and destructors for "declare target" static aggregates

2024-08-07 Thread Jakub Jelinek
On Wed, Aug 07, 2024 at 05:57:05PM +0200, Tobias Burnus wrote: > for C/C++, -fno-builtin-omp_is_initial_device already disabled the > expansion. Good idea. > RFC: Should be document this new built-in some where? If so, where? As part > of the routine description in libgomp.texi? Or in extend.texi

Re: [PATCH, v3] OpenMP: Constructors and destructors for "declare target" static aggregates

2024-08-07 Thread Jakub Jelinek
On Wed, Aug 07, 2024 at 06:58:23PM +0200, Jakub Jelinek wrote: > > For Fortran, this plus into gfc_get_extern_function_decl, i.e. that name > > appears as external declaration. While the user could mess around, it checks > > that it is a function and the return type is the expected on (i.e. logical