Re: [PATCH] Support simd function declarations via a pre-include.

2018-11-19 Thread Jakub Jelinek
On Mon, Nov 19, 2018 at 01:15:43PM +0100, Martin Liška wrote: > 2018-11-15 Martin Liska > > * config/gnu-user.h (TARGET_F951_OPTIONS): New. > * gcc.c (find_fortran_preinclude_file): New function > to handle Fortran pre-include. > > gcc/fortran/ChangeLog: > > 2018-11-15 Mart

Re: [PATCH] Support simd function declarations via a pre-include.

2018-11-19 Thread Martin Liška
On 11/16/18 4:12 PM, Martin Liška wrote: > On 11/16/18 2:49 PM, Jakub Jelinek wrote: >> On Fri, Nov 16, 2018 at 02:24:42PM +0100, Martin Liška wrote: >>> + if (gfc_match (" (%n) attributes simd", builtin) != MATCH_YES) >>> +return MATCH_ERROR; >>> + >>> + int builtin_kind = 0; >>> + if (gfc_

Re: [PATCH] Support simd function declarations via a pre-include.

2018-11-19 Thread Martin Liška
On 11/17/18 7:16 PM, Bernhard Reutner-Fischer wrote: > Hi > >> I'm sending version, I changed the container to hash_map that should >> provide >> faster look up. >> >> I've been testing the patch right now. > > In find_fortran_preinclude_file() you allocate the filename. Sure, but that's driver

Re: [PATCH] Support simd function declarations via a pre-include. (was: [PATCH][RFC]Overloading intrinsics)

2018-11-17 Thread Bernhard Reutner-Fischer
On 15 November 2018 21:54:23 CET, Jakub Jelinek wrote: >> Can we use plain -include like in C? > >Wouldn't that be confusing whether it is included in preprocessor only >or if >it is included as a magic fortran include line at the beginning? Yes, of course. Forgot that its a cpp argument. So -f

Re: [PATCH] Support simd function declarations via a pre-include.

2018-11-17 Thread Bernhard Reutner-Fischer
Hi >I'm sending version, I changed the container to hash_map that should >provide >faster look up. > >I've been testing the patch right now. In find_fortran_preinclude_file() you allocate the filename. diff --git a/gcc/fortran/scanner.c b/gcc/fortran/scanner.c index 55d6dafdb5d..4e500f88174 1006

Re: [PATCH] Support simd function declarations via a pre-include.

2018-11-17 Thread Paul Richard Thomas
Hi All, Forget my remark about mp_prop_design.f90. ifort -parallel means just that and has nothing to do with vectorization. Sorry for the noise. Paul On Sat, 17 Nov 2018 at 13:29, Paul Richard Thomas wrote: > > Hi All, > > I took a few moments away from what I really must be doing to try out

Re: [PATCH] Support simd function declarations via a pre-include.

2018-11-17 Thread Paul Richard Thomas
Hi All, I took a few moments away from what I really must be doing to try out an earlier version of the patch. There are quite a few CRs in the patch and the third chunk in gcc.c was rejected, although I cannot see why. I made a change to scanner.c to prevent the segfault that results from not hav

Re: [PATCH] Support simd function declarations via a pre-include.

2018-11-16 Thread Martin Liška
On 11/16/18 2:49 PM, Jakub Jelinek wrote: > On Fri, Nov 16, 2018 at 02:24:42PM +0100, Martin Liška wrote: >> + if (gfc_match (" (%n) attributes simd", builtin) != MATCH_YES) >> +return MATCH_ERROR; >> + >> + int builtin_kind = 0; >> + if (gfc_match (" (notinbranch)") == MATCH_YES) > > I thi

Re: [PATCH] Support simd function declarations via a pre-include.

2018-11-16 Thread Jakub Jelinek
On Fri, Nov 16, 2018 at 02:24:42PM +0100, Martin Liška wrote: > + if (gfc_match (" (%n) attributes simd", builtin) != MATCH_YES) > +return MATCH_ERROR; > + > + int builtin_kind = 0; > + if (gfc_match (" (notinbranch)") == MATCH_YES) I think you need " ( notinbranch )" here. > +builtin_

Re: [PATCH] Support simd function declarations via a pre-include.

2018-11-16 Thread Martin Liška
On 11/15/18 9:54 PM, Jakub Jelinek wrote: > On Thu, Nov 15, 2018 at 08:40:13PM +0100, Bernhard Reutner-Fischer wrote: >> On 14 November 2018 12:35:27 CET, Jakub Jelinek wrote: >> --- a/gcc/config/gnu-user.h +++ b/gcc/config/gnu-user.h @@ -170,3 +170,6 @@ see the files COPYING3 and C

Re: [PATCH] Support simd function declarations via a pre-include. (was: [PATCH][RFC]Overloading intrinsics)

2018-11-15 Thread Jakub Jelinek
On Thu, Nov 15, 2018 at 08:40:13PM +0100, Bernhard Reutner-Fischer wrote: > On 14 November 2018 12:35:27 CET, Jakub Jelinek wrote: > > >> --- a/gcc/config/gnu-user.h > >> +++ b/gcc/config/gnu-user.h > >> @@ -170,3 +170,6 @@ see the files COPYING3 and COPYING.RUNTIME > >respectively. If not, see

Re: [PATCH] Support simd function declarations via a pre-include. (was: [PATCH][RFC]Overloading intrinsics)

2018-11-15 Thread Bernhard Reutner-Fischer
On 14 November 2018 12:35:27 CET, Jakub Jelinek wrote: >> --- a/gcc/config/gnu-user.h >> +++ b/gcc/config/gnu-user.h >> @@ -170,3 +170,6 @@ see the files COPYING3 and COPYING.RUNTIME >respectively. If not, see >>LD_STATIC_OPTION " --whole-archive -llsan --no-whole-archive " \ >>LD_DYNAMI

Re: [PATCH] Support simd function declarations via a pre-include.

2018-11-14 Thread Jakub Jelinek
On Wed, Nov 14, 2018 at 03:09:49PM +0100, Martin Liška wrote: > > So omp-simd-notinbranch or omp_simd_notinbranch? > > Any particular reason for this weird syntax and for not also > > supporting inbranch or just simd? > > Questionable whether to support as current glibc vector ABI only uses > not

Re: [PATCH] Support simd function declarations via a pre-include.

2018-11-14 Thread Martin Liška
On 11/14/18 12:35 PM, Jakub Jelinek wrote: > On Wed, Nov 14, 2018 at 11:06:04AM +0100, Martin Liška wrote: >> Question I have is about default search locations for the header file. On my >> machine I can >> see: >> access("/home/marxin/bin/gcc2/lib64/gcc/x86_64-pc-linux-gnu/9.0.0/math-vector-fortr

Re: [PATCH] Support simd function declarations via a pre-include. (was: [PATCH][RFC]Overloading intrinsics)

2018-11-14 Thread Jakub Jelinek
On Wed, Nov 14, 2018 at 12:35:27PM +0100, Jakub Jelinek wrote: > > + > > + When we come here, we have already matched the !GCC$ builtin string. */ > > +match > > +gfc_match_gcc_builtin (void) > > +{ > > + char builtin[GFC_MAX_SYMBOL_LEN + 1]; > > + > > + if (gfc_match_name (builtin) != MATCH_Y

Re: [PATCH] Support simd function declarations via a pre-include. (was: [PATCH][RFC]Overloading intrinsics)

2018-11-14 Thread Jakub Jelinek
On Wed, Nov 14, 2018 at 12:56:26PM +0100, Jakub Jelinek wrote: > One possibility is > if (gfc_match ("(%n) attributes simd", name) == MATCH_YES) " (%n) attributes simd" to be precise, so that whitespace is allowed in free form between builtin and (. And the following parsing might be " ( notinb

Re: [PATCH] Support simd function declarations via a pre-include. (was: [PATCH][RFC]Overloading intrinsics)

2018-11-14 Thread Jakub Jelinek
On Wed, Nov 14, 2018 at 11:06:04AM +0100, Martin Liška wrote: > Question I have is about default search locations for the header file. On my > machine I can > see: > access("/home/marxin/bin/gcc2/lib64/gcc/x86_64-pc-linux-gnu/9.0.0/math-vector-fortran.h", > R_OK) = -1 ENOENT (No such file or dire