Re: [Aarch64] Fix conditional branches with target far away.

2018-03-30 Thread Sameera Deshpande
On 30 March 2018 at 16:39, Richard Sandiford wrote: >> Hi Sudakshina, >> >> Thanks for pointing that out. Updated the conditions for attribute >> length to take care of boundary conditions for offset range. >> >> Please find attached the updated patch. >> >> I have

[PATCH] [PR c++/85039] no type definitions in builtin offsetof

2018-03-30 Thread Alexandre Oliva
Types defined within a __builtin_offsetof argument don't always get properly recorded as members of their context types, so if they're anonymous, we may fail to assign them an anon type index for mangling and ICE. We shouldn't allow types to be introduced in __builtin_offsetof, I think, so I've

Re: [Aarch64] Fix conditional branches with target far away.

2018-03-30 Thread Sameera Deshpande
Hi Richard, The testcase is working with the patch you suggested, thanks for pointing that out. On 30 March 2018 at 16:54, Sameera Deshpande wrote: > On 30 March 2018 at 16:39, Richard Sandiford > wrote: >>> Hi Sudakshina, >>> >>>

[patch, fortran, testsuite, committed] Remove illegal code from substr_6.f90

2018-03-30 Thread Thomas Koenig
Hello world, F2003, 6.1.1. "Substrings" states that Both the starting point and the ending point shall be within the range 1, 2, ..., n unless the starting point exceeds the ending point, in which case the substring has length zero. The attached patch, which corrects the test case, has been

Re: [PATCH] [PR c++/84943] allow folding of array indexing indirect_ref

2018-03-30 Thread Alexandre Oliva
On Mar 29, 2018, Alexandre Oliva wrote: > Here's a patch that should take care of the marking a namespace-scoped > or static member function as used when taking its address, thus working > around (fixing?) the reported problem. > Regstrapping now. Ok to install if it passes?

[PATCH] [PR c++/85027] deal with baselink in save_expr in instantiate_type

2018-03-30 Thread Alexandre Oliva
We use SAVE_EXPRs in conditional expressions without the middle operand, to evaluate the first operand only once. When the conversion of the first operand fails, we may call instantiate_type get a better error message. We have code to peel off the SAVE_EXPR there, but then we may end up with a

Re: [Aarch64] Fix conditional branches with target far away.

2018-03-30 Thread Richard Sandiford
> Hi Sudakshina, > > Thanks for pointing that out. Updated the conditions for attribute > length to take care of boundary conditions for offset range. > > Please find attached the updated patch. > > I have tested it for gcc testsuite and the failing testcase. Ok for trunk? > > On 22 March 2018 at

[og7, openacc, committed] Add vector-length-128-{1,2,3}.c test-cases

2018-03-30 Thread Tom de Vries
Hi, this patch adds three testcases, setting vector length to 128 in three different ways: 1. the vector_length clause 2. the -fopenacc-dim option 3. the GOMP_OPENACC_DIM variable The tests contains: - a check of the dimensions that the compiler decides upon - a check of the dimensions used

Re: [PATCH] [PR c++/84943] allow folding of array indexing indirect_ref

2018-03-30 Thread Jason Merrill
On Fri, Mar 30, 2018 at 3:48 AM, Alexandre Oliva wrote: > On Mar 29, 2018, Alexandre Oliva wrote: > >> Here's a patch that should take care of the marking a namespace-scoped >> or static member function as used when taking its address, thus working >> around

Re: [PATCH] [PR c++/85039] no type definitions in builtin offsetof

2018-03-30 Thread Jason Merrill
On Fri, Mar 30, 2018 at 3:55 AM, Alexandre Oliva wrote: > Types defined within a __builtin_offsetof argument don't always get > properly recorded as members of their context types, so if they're > anonymous, we may fail to assign them an anon type index for mangling > and ICE.

Re: [og7] vector_length extension part 2: Generalize state propagation and synchronization

2018-03-30 Thread Tom de Vries
On 03/30/2018 03:07 AM, Tom de Vries wrote: On 03/02/2018 05:55 PM, Cesar Philippidis wrote: As a follow up patch will show, the nvptx BE falls back to using vector_length = 32 when a vector loop is nested inside a worker loop. I disabled the fallback, and analyzed the vred2d-128.c illegal

Re: [PATCH][GCC][mid-end] Allow larger copies when target supports unaligned access [Patch (1/2)]

2018-03-30 Thread Peter Bergner
On 3/29/18 9:35 AM, Alan Modra wrote: > On Thu, Nov 16, 2017 at 03:27:01PM +, Tamar Christina wrote: >> --- a/gcc/expr.c >> +++ b/gcc/expr.c >> @@ -2769,7 +2769,9 @@ copy_blkmode_to_reg (machine_mode mode, tree src) >> >>n_regs = (bytes + UNITS_PER_WORD - 1) / UNITS_PER_WORD; >>

[og7, testsuite, committed] Add scan-offload-tree-dump

2018-03-30 Thread Tom de Vries
Hi, I've ported "Add scan-wpa-ipa-dump" (submitted here: https://gcc.gnu.org/ml/gcc-patches/2018-03/msg01529.html ) to the og7 branch, and committed it. Changes are trivial, so I'm not reposting that patch. This patch adds the possibility to scan tree dump files generated by the offloading

Re: [PATCH] [PR c++/85027] deal with baselink in save_expr in instantiate_type

2018-03-30 Thread Jason Merrill
OK. On Fri, Mar 30, 2018 at 3:49 AM, Alexandre Oliva wrote: > We use SAVE_EXPRs in conditional expressions without the middle > operand, to evaluate the first operand only once. When the conversion > of the first operand fails, we may call instantiate_type get a better >

Re: [og7] vector_length extension part 2: Generalize state propagation and synchronization

2018-03-30 Thread Tom de Vries
On 03/30/2018 05:00 PM, Cesar Philippidis wrote: I should have checked that patch with the vector length fallback disabled. Right. The patch series introduces a lot of code that is not exercised. I've added an -mlong-vector-in-workers option in my local branch and added 3 test-cases to

Re: [PATCH] [PR c++/84979] improve auto handling in explicit tmpl args for concepts

2018-03-30 Thread Jason Merrill
On Thu, Mar 29, 2018 at 6:24 PM, Alexandre Oliva wrote: > On Mar 28, 2018, Jason Merrill wrote: > >> On Wed, Mar 28, 2018 at 5:06 AM, Alexandre Oliva wrote: >>> On Mar 23, 2018, Jason Merrill wrote: >>> On Fri, Mar

Re: [og7] vector_length extension part 2: Generalize state propagation and synchronization

2018-03-30 Thread Cesar Philippidis
On 03/30/2018 07:45 AM, Tom de Vries wrote: > On 03/30/2018 03:07 AM, Tom de Vries wrote: >> On 03/02/2018 05:55 PM, Cesar Philippidis wrote: >>> As a follow up patch will show, the nvptx BE falls back to using >>> vector_length = 32 when a vector loop is nested inside a worker loop. >> >> I

Re: [PATCH] i386: Enable AVX/AVX512 features only if supported by OSXSAVE

2018-03-30 Thread H.J. Lu
On Fri, Mar 30, 2018 at 10:19 AM, Ilya Verbin wrote: > This check will always disable AVX-512 on macOS, because they > implemented on-demand support: > https://github.com/apple/darwin-xnu/blob/0a798f6738bc1db01281fc08ae024145e84df927/osfmk/i386/fpu.c#L176 > Isn't xsaveopt

Re: [PATCH][GCC][mid-end] Allow larger copies when target supports unaligned access [Patch (1/2)]

2018-03-30 Thread Peter Bergner
On 3/29/18 9:35 AM, Alan Modra wrote: > On Thu, Nov 16, 2017 at 03:27:01PM +, Tamar Christina wrote: >> --- a/gcc/expr.c >> +++ b/gcc/expr.c >> @@ -2769,7 +2769,9 @@ copy_blkmode_to_reg (machine_mode mode, tree src) >> >>n_regs = (bytes + UNITS_PER_WORD - 1) / UNITS_PER_WORD; >>

[PATCH] Improve avx512{f,bw} vec_set (PR middle-end/85090)

2018-03-30 Thread Jakub Jelinek
Hi! The code we emit on the following testcases is really terrible, with both -mavx512f -mno-avx512bw as well as -mavx512bw, rather than doing e.g. vpinsrw $0, %edi, %xmm0, %xmm1 vinserti32x4$0, %xmm1, %zmm0, %zmm0 when trying to insert into low 128-bits or

[PATCH, committed] Update my MAINTAINERS entries

2018-03-30 Thread Bill Schmidt
Just updating my email address and making it a little clearer which is which between Will Schmidt and me. Committed. 2018-03-30 Bill Schmidt * MAINTAINERS: Update my email address and disambiguate myself a bit from Will Schmidt. Index: MAINTAINERS

Re: [PATCH] i386: Enable AVX/AVX512 features only if supported by OSXSAVE

2018-03-30 Thread Ilya Verbin
This check will always disable AVX-512 on macOS, because they implemented on-demand support: https://github.com/apple/darwin-xnu/blob/0a798f6738bc1db01281fc08ae024145e84df927/osfmk/i386/fpu.c#L176 (I'm not against this change, just for information). 2018-03-29 16:05 GMT+03:00 Uros Bizjak

Re: [PATCH] i386: Enable AVX/AVX512 features only if supported by OSXSAVE

2018-03-30 Thread Ilya Verbin
2018-03-30 20:56 GMT+03:00 H.J. Lu : > On Fri, Mar 30, 2018 at 10:19 AM, Ilya Verbin wrote: >> This check will always disable AVX-512 on macOS, because they >> implemented on-demand support: >>

[committed] Fix OpenMP C++ reduction error recovery (PR c++/84791)

2018-03-30 Thread Jakub Jelinek
Hi! The following patch removes errorneous reduction clause already during parsing, so that we don't ICE on it during instantiation. Bootstrapped/regtested on x86_64-linux and i686-linux, committed to trunk. 2018-03-30 Jakub Jelinek PR c++/84791 *

Re: [PATCH, rs6000] Tidy implementation of vec_ldl

2018-03-30 Thread Segher Boessenkool
Hi! On Thu, Mar 29, 2018 at 09:47:42AM -0500, Kelvin Nilsen wrote: > In summary, this patch removes two prototypes: > >   vector int vec_ldl (int, long int *) >   vector unsigned int vec_ldl (int, unsigned long int *) > > and adds eight: > >   vector bool char vec_ldl (int, bool char *) >  

Re: [PATCH, rs6000] Fix PR80546: FAIL: gcc.target/powerpc/bool3-p[78].c scan-assembler-not

2018-03-30 Thread Segher Boessenkool
Hi! On Fri, Mar 30, 2018 at 02:29:59PM -0500, Peter Bergner wrote: > +;; A mode attribute to disparage use of GPR registers, except for scalar > +;; interger modes. Typo ("integer"). > +(define_mode_attr ??r[(V16QI "??r") > + (V8HI "??r") > +

C++ PATCH for c++/85093, excess args accepted with pack expansion

2018-03-30 Thread Jason Merrill
Here an earlier fix of mine related to -fnew-ttp-matching caused us to silently discard a pack expansion argument that will be ill-formed if it's ever non-empty. It would be correct to reject this template definition immediately, since a variadic template that is well-formed only for empty packs

Re: [C++ PATCH] P0329R4: Designated Initialization

2018-03-30 Thread Jason Merrill
On Mon, Nov 13, 2017 at 5:53 PM, Jakub Jelinek wrote: > + /* If the element is an anonymous union object and the > + initializer list is a designated-initializer-list, the > + anonymous union object is initialized by the > +

[PATCH, rs6000] Fix PR80546: FAIL: gcc.target/powerpc/bool3-p[78].c scan-assembler-not

2018-03-30 Thread Peter Bergner
Currently, the vwx_mov_* move patterns diparage use of GPR registers. This tends to force all modes handled by the move patterns to prefer using VSX registers, even in cases where it doesn't make sense (ie, TImode). The bool3-p[78].c:ptr() test cases are such an example. The following patch is a

[PATCH] rs6000: Fix _mm_min_ps and _mm_max_ps (PR83315)

2018-03-30 Thread Segher Boessenkool
This makes _mm_{min,max}_ps work correctly for QNaNs. Tested on powerpc64le-linux; committing. Segher 2018-03-31 Segher Boessenkool PR target/83315 * config/rs6000/xmmintrin.h (_mm_set_ps, _mm_max_ps): Handle (quiet) NaN inputs

Re: [PATCH] [PR c++/84979] improve auto handling in explicit tmpl args for concepts

2018-03-30 Thread Alexandre Oliva
On Mar 30, 2018, Jason Merrill wrote: > On Thu, Mar 29, 2018 at 6:24 PM, Alexandre Oliva wrote: >> AFAICT we wouldn't always know, within cp_parser_template_id, whether >> the id is a type or a function. > True, it looks like sometimes we build a