Re: [PATCH, libstdc++]: Fix PR 70975, experimental/filesystem/operations/copy.cc FAILs on Solaris 12

2016-10-27 Thread Jonathan Wakely
On 27/10/16 19:41 +0100, Jonathan Wakely wrote: On 27/10/16 20:33 +0200, Uros Bizjak wrote: Attached patch improves sendfile syscall compatibility with (older) Solaris 12, where non-null third argument is required. It also paves the way for compatibility with Solaris 10/11, where otherwise addit

Re: [PATCH, libstdc++]: Fix PR 70975, experimental/filesystem/operations/copy.cc FAILs on Solaris 12

2016-10-27 Thread Uros Bizjak
On Thu, Oct 27, 2016 at 8:43 PM, Jonathan Wakely wrote: >> Is there a good reason to call it "always_zero_offset" rather than >> something that fits on one line, like "offset"? >> >> OK for trunk anyway, thanks. > > > > (I actually already sent a similar patch, see > https://gcc.gnu.org/ml/gcc-pa

[committed] Fix simd clone creation for noreturn functions (PR middle-end/78025)

2016-10-27 Thread Jakub Jelinek
Hi! In simd_clone_adjust we weren't taking into account the possibility of no edges to the exit block. If inbranch, we still want to create the loop over the simd lanes, though of course don't have any edges from the body to the increment bb - e.g. if one calls the function with all zeros mask, i

[PATCH] Fix select type parsing (PR fortran/78026)

2016-10-27 Thread Jakub Jelinek
Hi! This PR has been reported as something related to OpenMP, but in the end I think it is unrelated, the bug I see is in the select type parsing. The problem is that if select type is the very first stmt in the TU, we parse it and before actually accepting that ST_SELECT_TYPE, we perform various

[PATCH] Fix a REE bug (PR rtl-optimization/78132)

2016-10-27 Thread Jakub Jelinek
Hi! REE breaks the following testcase on KNL, where we only accept QImode/HImode in k0-k7 registers (SImode/DImode is only supported with -mavx512bw). We have (set (reg:HI k0) (mem:HI ...)) ... (set (reg:DI rax) (zero_extend:DI (reg:HI k0))) and we optimize it into: (set (reg:DI rax) (zero_extend

[PATCH] Fix COMPONENT_REF expansion (PR rtl-optimization/77919)

2016-10-27 Thread Jakub Jelinek
Hi! The following testcase ICEs on x86_64-linux with -O1, the problem is that we expand assignment from COMPONENT_REF of MEM_REF into a V4SImode SSA_NAME. The MEM_REF has non-addressable DCmode var inside of it, and type of a struct containing a single V4SImode element. The bug seems to be that

Re: [PATCH] Fix select type parsing (PR fortran/78026)

2016-10-27 Thread Steve Kargl
On Thu, Oct 27, 2016 at 09:07:49PM +0200, Jakub Jelinek wrote: > > This PR has been reported as something related to OpenMP, but in the end > I think it is unrelated, the bug I see is in the select type parsing. > > The problem is that if select type is the very first stmt in the TU, > we parse i

Re: [PATCH] Fix select type parsing (PR fortran/78026)

2016-10-27 Thread Jakub Jelinek
On Thu, Oct 27, 2016 at 12:45:25PM -0700, Steve Kargl wrote: > Thanks for the detailed analysis. The patch looks ok to me. > I would prefer functional and cosmetic changes to be committed > separately, but in this case the cosmetic changes are small. > > > + { > > + std::swap (ns, gfc_curr

Re: [PATCH], Allow SImode to go into VSX registers on PowerPC ISA 2.07 (power8) and above

2016-10-27 Thread Segher Boessenkool
On Wed, Oct 26, 2016 at 06:51:54PM -0400, Michael Meissner wrote: > (zero_extendsi2): Reorder pattern, so RLDICL comes before > the FPR and VSX loads, but before MTVSRWZ. Remove ??, ! from the > constraints. Add MFVSRWZ and XXEXTRACTUW instructions to support > small integ

Re: [PATCH, LIBGCC] Avoid count_leading_zeros with undefined result (PR 78067)

2016-10-27 Thread Joseph Myers
On Thu, 27 Oct 2016, Bernd Edlinger wrote: > Hi, > > by code reading I became aware that libgcc can call count_leading_zeros > in certain cases which can give undefined results. This happens on > signed int128 -> float or double conversions, when the int128 is in the range > INT64_MAX+1 to UINT6

[Aarch64][PATCH] Improve Logical And Immediate Expressions

2016-10-27 Thread Michael Collison
This patch is designed to improve code generation for "and" instructions with certain immediate operands. For the following test case: int f2(int x) { x &= 0x0ff8; x &= 0xff001fff; return x; } the trunk aarch64 compiler generates: mov w1, 8184 movkw1, 0xf00, lsl 16 and

[PATCH, GCC] Fix conflicting posix_memalign declaration error

2016-10-27 Thread Caroline Tice
The posix_memalign declaration in gcc/i386/config/pmm_malloc.h is decorated with 'throw ()', which occasionally causes declaration conflict errors (some header files, not part of GCC, that declare posix_memalign, do not have the throw decoration). An example of this can be seen at https://github.c

Re: [PATCH], Allow SImode to go into VSX registers on PowerPC ISA 2.07 (power8) and above

2016-10-27 Thread Michael Meissner
On Thu, Oct 27, 2016 at 02:55:51PM -0500, Segher Boessenkool wrote: > On Wed, Oct 26, 2016 at 06:51:54PM -0400, Michael Meissner wrote: > > (zero_extendsi2): Reorder pattern, so RLDICL comes before > > the FPR and VSX loads, but before MTVSRWZ. Remove ??, ! from the > > constraints. A

[PATCH] enhance buffer overflow warnings (and c/53562)

2016-10-27 Thread Martin Sebor
The attached patch enhances the compile-time detection of buffer overflow in functions like __builtin___memcpy_chk to consider non-constant lengths known to be in a certain range and warn when the lower bound of the range doesn't fit in the destination object. The patch does the same thing for th

[ipa-vrp] ice in set_value_range

2016-10-27 Thread kugan
Hi, { tree val = ipa_get_jf_constant (jfunc); if (TREE_CODE (val) == INTEGER_CST) { + value_range vr; if (TREE_OVERFLOW_P (val)) val = drop_tree_overflow (val); - jfunc->vr_known = true; - jfunc->m_vr.type = VR_RANGE; -

Re: [RFC] Handle unary pass-through jump functions for ipa-vrp

2016-10-27 Thread kugan
Hi, On 28/10/16 01:58, Jan Hubicka wrote: gcc/testsuite/ChangeLog: 2016-10-25 Kugan Vivekanandarajah * gcc.dg/ipa/vrp7.c: New test. gcc/ChangeLog: 2016-10-25 Kugan Vivekanandarajah * ipa-cp.c (ipa_get_jf_pass_through_result): Skip unary expressions. (propagate

[arm.c] Use VAR_P

2016-10-27 Thread Prathamesh Kulkarni
Hi, This patch uses replaces TREE_CODE(x) == VAR_DECL by VAR_P(x) in arm.c. Bootstrap+tested on arm-linux-gnueabihf. OK to commit ? Thanks, Prathamesh 2016-10-28 Prathamesh Kulkarni * config/arm/arm.c (arm_const_not_ok_for_debug_p): Use VAR_P. diff --git a/gcc/config/arm/arm.c b/gcc/c

<    1   2