Re: Use conditional internal functions in if-conversion

2018-05-25 Thread Richard Biener
On Fri, May 25, 2018 at 12:12 PM Richard Sandiford < richard.sandif...@linaro.org> wrote: > Richard Biener writes: > > On Wed, May 16, 2018 at 12:17 PM Richard Sandiford < > > richard.sandif...@linaro.org> wrote: > >> This patch uses IFN_COND_* to vectorise conditionally-executed, > >> potentiall

Re: [PATCH] wwwdocs: Update Intel CET for GCC 8 changes

2018-05-25 Thread Richard Biener
On Fri, May 25, 2018 at 12:49 PM H.J. Lu wrote: > Only -fcf-protection is needed to enable Intel CET. > OK to check in? OK. > H.J. > --- > Index: changes.html > === > RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-8/changes.html,v > retrie

Re: Implement SLP of internal functions

2018-05-25 Thread Richard Biener
On Fri, May 25, 2018 at 12:31 PM Richard Sandiford < richard.sandif...@linaro.org> wrote: > Richard Biener writes: > >> Index: gcc/tree-vect-slp.c > >> === > >> --- gcc/tree-vect-slp.c 2018-05-16 11:02:46.262494712 +0100 > >> +++ gcc

[PATCH] Print working directory only in intermediate format (PR gcov-profile/84846).

2018-05-25 Thread Martin Liška
Hi. As requested by Eric, let's print working directory just in intermediate format: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84846#c8 gcov.exp tests works with the patch. Ready for trunk? Martin gcc/ChangeLog: 2018-05-25 Martin Liska PR gcov-profile/84846 * gcov.c (out

Re: [PATCH] Check ifunc_resolver only on FUNCTION_DECL

2018-05-25 Thread H.J. Lu
On Thu, May 24, 2018 at 04:43:25AM -0700, H.J. Lu wrote: > Since ifunc_resolver is only valid on FUNCTION_DECL, check ifunc_resolver > only on FUNCTION_DECL. > > Please test it on Darwin. > > > H.J. > --- > PR target/85900 > PR target/85345 > * varasm.c (assemble_alias): Check

Re: Use conditional internal functions in if-conversion

2018-05-25 Thread Richard Sandiford
Richard Biener writes: > On Fri, May 25, 2018 at 12:12 PM Richard Sandiford < > richard.sandif...@linaro.org> wrote: > >> Richard Biener writes: >> > On Wed, May 16, 2018 at 12:17 PM Richard Sandiford < >> > richard.sandif...@linaro.org> wrote: >> >> This patch uses IFN_COND_* to vectorise condit

Re: Use conditional internal functions in if-conversion

2018-05-25 Thread Richard Biener
On Fri, May 25, 2018 at 1:49 PM Richard Sandiford < richard.sandif...@linaro.org> wrote: > Richard Biener writes: > > On Fri, May 25, 2018 at 12:12 PM Richard Sandiford < > > richard.sandif...@linaro.org> wrote: > > > >> Richard Biener writes: > >> > On Wed, May 16, 2018 at 12:17 PM Richard Sand

Re: Use conditional internal functions in if-conversion

2018-05-25 Thread Richard Biener
On Fri, May 25, 2018 at 2:02 PM Richard Biener wrote: > On Fri, May 25, 2018 at 1:49 PM Richard Sandiford < > richard.sandif...@linaro.org> wrote: > > Richard Biener writes: > > > On Fri, May 25, 2018 at 12:12 PM Richard Sandiford < > > > richard.sandif...@linaro.org> wrote: > > > > > >> Richar

[PATCH] Enhance BB vectorization dependence analysis

2018-05-25 Thread Richard Biener
This simplifies data-ref analysis further and to make that work enhances BB vectorization dependence analysis as a comment suggested. I've needed to add tbaa_p flags to some of the alias disambiguators. Bootstrapped and tested on x86_64-unknown-linux-gnu, SPEC 2k6 build is running right now. Ri

[PATCH] libgcc: Add support for --disable-libgcov

2018-05-25 Thread Rasmus Villemoes
When trying to build gcc 6.4.0 targeting VxWorks 5.5, I ran into libgcov not building against the VxWorks system headers - there are multiple issues such as gcc-src/libgcc/../gcc/gcov-io.c:78:3: warning: implicit declaration of function 'getpid' [-Wimplicit-function-declaration] s_flock.l_pid

Re: Use conditional internal functions in if-conversion

2018-05-25 Thread Richard Sandiford
Richard Biener writes: > On Fri, May 25, 2018 at 1:49 PM Richard Sandiford < > richard.sandif...@linaro.org> wrote: > >> Richard Biener writes: >> > On Fri, May 25, 2018 at 12:12 PM Richard Sandiford < >> > richard.sandif...@linaro.org> wrote: >> > >> >> Richard Biener writes: >> >> > On Wed, Ma

Re: [PATCH][AArch64] Fix aarch64_ira_change_pseudo_allocno_class

2018-05-25 Thread Wilco Dijkstra
Richard Sandiford wrote: > Conceptually what we're saying here is that if the given classes > include both GENERAL_REGS and FP_REGS, we'll choose between them > based on the mode of the register.  And that makes sense for any > class that includes both GENERAL_REGS and FP_REGS.  We could write > i

Re: [PATCH] gcc/configure.ac: add --disable-systemtap switch

2018-05-25 Thread Eric Gallager
On 5/24/18, Jeff Law wrote: > On 05/12/2018 08:00 AM, Sergei Trofimovich via gcc-patches wrote: >> From: Sergei Trofimovich >> >> Before the change systemtap probes were enabled >> if target headers had sys/sdt.h at ./configure time. >> >> After the change explicitly ask to enable or disable >> f

[PATCH, alpha]: Improve fix for PR83628

2018-05-25 Thread Uros Bizjak
Hello! Attached patch improves fix for PR83628 by providing ashlsi3 pattern. This allows combiner to remove subregs of inner DImode ashift. 2018-05-25 Uros Bizjak PR target/83628 * config/alpha/alpha.md (ashlsi3): New insn pattern. (*ashlsi_se): Rename from *ashldi_se. Define as

Re: [RFC] fixincludes: vxworks: add hack around ioLib.h/unistd.h mutual inclusion

2018-05-25 Thread Bruce Korb
Ick. Looks like the right fix to me and it is clearly constrained to vxworks platforms. Approved by me. On Fri, May 25, 2018 at 1:58 AM, Rasmus Villemoes wrote: > In old VxWorks headers (5.5), ioLib.h includes unistd.h via > > #include "unistd.h" > > We copy ioLib to include-fixed, with a few fix

Re: [PATCH] handle local aggregate initialization in strlen (PR 83821)

2018-05-25 Thread Martin Sebor
On 05/25/2018 12:06 AM, Marc Glisse wrote: On Thu, 24 May 2018, Martin Sebor wrote: On 05/24/2018 03:40 PM, Marc Glisse wrote: On Wed, 23 May 2018, Martin Sebor wrote: On 05/23/2018 08:57 AM, Jeff Law wrote: On 05/10/2018 04:05 PM, Marc Glisse wrote: On Thu, 10 May 2018, Martin Sebor wrote

Re: [ARM/FDPIC 02/21] [ARM] FDPIC: Handle arm*-*-uclinuxfdpiceabi in configure scripts

2018-05-25 Thread Joseph Myers
On Fri, 25 May 2018, Christophe Lyon wrote: > In libtool.m4, we use uclinuxfdpiceabi in cases where ELF shared > libraries support is required, as uclinux does not guarantee that. To confirm: has this libtool.m4 patch gone upstream (or at least been submitted upstream, if not yet reviewed)? --

Re: [PATCH] libgcc: Add support for --disable-libgcov

2018-05-25 Thread Joseph Myers
A new configure option should be documented in install.texi. -- Joseph S. Myers jos...@codesourcery.com

Re: C++ PATCHes to xvalue handling

2018-05-25 Thread Sudakshina Das
On 23/05/18 18:21, Jason Merrill wrote: The first patch implements the adjustments from core issues 616 and 1213 to the value category of subobjects of class prvalues: they were considered prvalues themselves, but that was kind of nonsensical. Now they are considered xvalues. Along with this, I

Simplify _Rb_tree instantiation

2018-05-25 Thread François Dumont
Hi As we are at working on associative containers I'd like to propose this last patch to remove the copy constructible constraint on the _Compare functor when it is supposed to be default constructed. This way the _Compare is built directly at its final place.     * include/bits/stl_tree.h (

Re: [RFC] fixincludes: vxworks: add hack around ioLib.h/unistd.h mutual inclusion

2018-05-25 Thread Jeff Law
On 05/25/2018 08:47 AM, Bruce Korb wrote: > Ick. Looks like the right fix to me and it is clearly constrained to > vxworks platforms. Approved by me. Thanks. Installed on the trunk. jeff

Re: [PATCH] testsuite: Introduce be/le selectors

2018-05-25 Thread Segher Boessenkool
On Fri, May 25, 2018 at 10:30:58AM +0100, Richard Earnshaw (lists) wrote: > On 24/05/18 18:28, Segher Boessenkool wrote: > > On Wed, May 23, 2018 at 10:07:18AM +0100, Richard Earnshaw (lists) wrote: > >> On 22/05/18 22:21, Jeff Law wrote: > >>> On 05/21/2018 03:46 PM, Segher Boessenkool wrote: > >>

Re: [C++ PATCH] Do not warn about zero-as-null when NULL is used.

2018-05-25 Thread Jason Merrill
On Thu, May 24, 2018 at 8:04 PM, Ville Voutilainen wrote: > I smacked my head against conversion_null_warnings for a while, > and then I realized that we could just stop convert_like_real from > changing the node type for null_node. Won't that sometimes mean that the result has the wrong type? I

Re: [PATCH] consider MIN_EXPR in get_size_range() (PR 85888)

2018-05-25 Thread Martin Sebor
On 05/25/2018 01:02 AM, Richard Biener wrote: On Thu, May 24, 2018 at 11:22 PM Martin Sebor wrote: On 05/24/2018 11:15 AM, Richard Biener wrote: On May 24, 2018 7:02:17 PM GMT+02:00, Martin Sebor wrote: On 05/24/2018 03:39 AM, Richard Biener wrote: On Thu, May 24, 2018 at 12:50 AM Martin

Re: [C++ PATCH] Do not warn about zero-as-null when NULL is used.

2018-05-25 Thread Ville Voutilainen
On 25 May 2018 at 20:27, Jason Merrill wrote: > On Thu, May 24, 2018 at 8:04 PM, Ville Voutilainen > wrote: >> I smacked my head against conversion_null_warnings for a while, >> and then I realized that we could just stop convert_like_real from >> changing the node type for null_node. > > Won't t

Re: [C++ PATCH] Do not warn about zero-as-null when NULL is used.

2018-05-25 Thread Ville Voutilainen
On 25 May 2018 at 20:38, Ville Voutilainen wrote: > On 25 May 2018 at 20:27, Jason Merrill wrote: >> On Thu, May 24, 2018 at 8:04 PM, Ville Voutilainen >> wrote: >>> I smacked my head against conversion_null_warnings for a while, >>> and then I realized that we could just stop convert_like_real

Re: [PATCH] consider MIN_EXPR in get_size_range() (PR 85888)

2018-05-25 Thread Richard Biener
On May 25, 2018 7:31:43 PM GMT+02:00, Martin Sebor wrote: >On 05/25/2018 01:02 AM, Richard Biener wrote: >> On Thu, May 24, 2018 at 11:22 PM Martin Sebor >wrote: >> >>> On 05/24/2018 11:15 AM, Richard Biener wrote: On May 24, 2018 7:02:17 PM GMT+02:00, Martin Sebor > >> wrote: > On 05/24

Re: C++ PATCH for c++/85883, class tmpl args deduction fail with new

2018-05-25 Thread Jason Merrill
On Thu, May 24, 2018 at 4:10 PM, Marek Polacek wrote: > Here we were failing to deduce template arguments for a class, because the > code in build_new only handled the case when INIT had 1 element. That works > for e.g. new auto (foo) or new Foo{1, 2}, but not new Foo(1, 2). I noticed > that it

Re: [PATCH] consider MIN_EXPR in get_size_range() (PR 85888)

2018-05-25 Thread Martin Sebor
On 05/25/2018 11:51 AM, Richard Biener wrote: On May 25, 2018 7:31:43 PM GMT+02:00, Martin Sebor wrote: On 05/25/2018 01:02 AM, Richard Biener wrote: On Thu, May 24, 2018 at 11:22 PM Martin Sebor wrote: On 05/24/2018 11:15 AM, Richard Biener wrote: On May 24, 2018 7:02:17 PM GMT+02:00, M

Re: Simplify _Rb_tree instantiation

2018-05-25 Thread Ville Voutilainen
On 25 May 2018 at 19:50, François Dumont wrote: > Hi > > As we are at working on associative containers I'd like to propose this last > patch to remove the copy constructible constraint on the _Compare functor > when it is supposed to be default constructed. > > This way the _Compare is built dire

Re: [PATCH] PR target/85358 patch v2: Add target hook to prevent default widening

2018-05-25 Thread Michael Meissner
I redid the patch to make the target hook only apply for scalar float points, and I removed all of the integer only subcases. I have checked this on a little endian Power8 system, and verified that it bootstraps correctly and there are no regressions. I have just started an x86_64 build. Assumin

[PATCH, committed] Additional fix related to PR85712

2018-05-25 Thread Bill Schmidt
Hi, While backporting https://gcc.gnu.org/ml/gcc-patches/2018-05/msg01183.html to older release branches, I ran across a corner case that can cause an ICE. When replace_mult_candidate replaces a candidate with a copy, it does so in situ. Later we may attempt to replace it again under a different

Re: Simplify _Rb_tree instantiation

2018-05-25 Thread Jonathan Wakely
On 25/05/18 21:35 +0300, Ville Voutilainen wrote: On 25 May 2018 at 19:50, François Dumont wrote: Hi As we are at working on associative containers I'd like to propose this last patch to remove the copy constructible constraint on the _Compare functor when it is supposed to be default construc

Re: Simplify _Rb_tree instantiation

2018-05-25 Thread Ville Voutilainen
On 25 May 2018 at 22:16, Jonathan Wakely wrote: >> Why is this patch removing _Compare() calls? That changes the >> initialization >> of _Compare from value-initialization to default-initialization, which >> is a breaking change. > > > The _Rb_tree_key_compare base class will still value-initializ

[OpenACC] Update OpenACC data clause semantics to the 2.5 behavior

2018-05-25 Thread Cesar Philippidis
This patch updates GCC's to support OpenACC 2.5's data clause semantics. In OpenACC 2.5, copy, copyin and copyout all behave like their present_or_* counterparts in OpenACC 2.0. The patch also adds support for the new finalize and if_present data clauses introduced in OpenACC 2.5. The finalize

Re: C++ PATCHes to xvalue handling

2018-05-25 Thread Jason Merrill
On Fri, May 25, 2018 at 12:40 PM, Sudakshina Das wrote: > On 23/05/18 18:21, Jason Merrill wrote: >> >> The first patch implements the adjustments from core issues 616 and >> 1213 to the value category of subobjects of class prvalues: they were >> considered prvalues themselves, but that was kind

Re: [PATCH] consider MIN_EXPR in get_size_range() (PR 85888)

2018-05-25 Thread Martin Sebor
Attached is revision 3 of the patch incorporating your determine_value_range function with the requested changes. Martin PR testsuite/85888 - New test case c-c++-common/attr-nonstring-6.c from r260541 fails with excess errors gcc/ChangeLog: PR testsuite/85888 * builtins.c (expand_builtin_strn

Re: [PATCH] tighten up -Wclass-memaccess for ctors/dtors (PR 84851)

2018-05-25 Thread Martin Sebor
(I just now noticed the first two attempts were sent to the wrong list. Sorry about that.) On 05/25/2018 02:16 PM, Martin Sebor wrote: A fix for 84851 - missing -Wclass-memaccess for a memcpy in a copy ctor with a non-trivial member was implemented but disabled for GCC 8 but because it was late

Re: [PATCH][Middle-end][version 3]2nd patch of PR78809 and PR83026

2018-05-25 Thread Jeff Law
On 02/07/2018 08:36 AM, Qing Zhao wrote: > Hi, this is the 3rd version for this patch. > > the main change compared with 2nd version are: > 1. do not use “compute_objsize” to get the minimum object size per Jeff > and Richard’s > comment. Instead, add a new function “determine_min_objsize”

Re: C++ PATCHes to xvalue handling

2018-05-25 Thread Jason Merrill
On Fri, May 25, 2018 at 4:08 PM, Jason Merrill wrote: > On Fri, May 25, 2018 at 12:40 PM, Sudakshina Das wrote: >> On 23/05/18 18:21, Jason Merrill wrote: >>> >>> The first patch implements the adjustments from core issues 616 and >>> 1213 to the value category of subobjects of class prvalues: th

Re: [PATCH] refine -Wstringop-truncation and -Wsizeof-pointer-memaccess for strncat of nonstrings (PR 85602)

2018-05-25 Thread Martin Sebor
Ping: https://gcc.gnu.org/ml/gcc-patches/2018-05/msg00869.html On 05/17/2018 08:01 PM, Martin Sebor wrote: The -Wstringop-truncation and -Wsizeof-pointer-memaccess warnings I added and enhanced, respectively, in GCC 8 are arguably overly strict for source arguments declared with the nonstring at

C++ PATCH for c++/85815, reference to member of enclosing template

2018-05-25 Thread Jason Merrill
When we see INSTANCE->moo(), the type of INSTANCE is an opaque version of A that has no members. We need to recognize that it's a type we're currently inside, and use the version we're building up when looking for a base or member. Tested x86_64-pc-linux-gnu, applying to trunk. commit 675b0276548

[PATCH] Remove useless noinline variable (PR bootstrap/85921)

2018-05-25 Thread Jakub Jelinek
Hi! The following variable only makes the code larger and less readable. In addition, with some broken kernel headers that redefine noinline it breaks bootstrap. Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? 2018-05-25 Jakub Jelinek PR bootstrap/8

[PATCH, committed] fix a number of pdp11 target test failures

2018-05-25 Thread Paul Koning
This fixes a number of test failures due to test cases that are too large for pdp11 and should be skipped. Also one test case that asks for alignment larger than what pdp11 supports. paul 2018-05-25 Paul Koning * gcc.c-torture/compile/20151204.c: Skip if pdp11. * g

[PATCH] Rename ufloat to floatuns and ufix_trunc to fixuns_trunc in a few patterns (PR target/85918)

2018-05-25 Thread Jakub Jelinek
Hi! The optab is looking for floatuns2 and fixuns_trunc2, but some of the patterns are instead called ufloat2 or ufix_trunc2 and thus are only used from intrinsics. We can't change all spots, in two spots we have intentionally an floatuns2 or fixuns_trunc2 expander that uses for AVX512+ a ufloat*

[PATCH v2] libgcc: Add support for --disable-libgcov

2018-05-25 Thread Rasmus Villemoes
When trying to build gcc 6.4.0 targeting VxWorks 5.5, I ran into libgcov not building against the VxWorks system headers - there are multiple issues such as gcc-src/libgcc/../gcc/gcov-io.c:78:3: warning: implicit declaration of function 'getpid' [-Wimplicit-function-declaration] s_flock.l_pid

Re: [PATCH] Enhance BB vectorization dependence analysis

2018-05-25 Thread H.J. Lu
On Fri, May 25, 2018 at 5:48 AM, Richard Biener wrote: > > This simplifies data-ref analysis further and to make that work enhances > BB vectorization dependence analysis as a comment suggested. I've > needed to add tbaa_p flags to some of the alias disambiguators. > > Bootstrapped and tested on

Re: [PATCH] handle local aggregate initialization in strlen (PR 83821)

2018-05-25 Thread Marc Glisse
On Fri, 25 May 2018, Martin Sebor wrote: Why couldn't nonzero_chars be constant in that case? void f(const char*s){ s[0]='a'; // I know that strlen(s) is at least 1 here } I was responding specifically to your question about the strlen() CSE. Above there is no call to strlen(). What I u

[Committed] PR fortran/85786 testcase

2018-05-25 Thread Steve Kargl
pault accidently committed in r260414 the 2-line patchr from comment #5 of https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85786 which fixes the PR. I have converted the code in comment #3 into a testcase and committed to ensure that the bug does not re-appear. Code attached. 2018-05-25 Steven

[PATCH] RISC-V: Add interrupt attribute support.

2018-05-25 Thread Jim Wilson
This adds basic interrupt attribute support to the RISC-V port. This will save every register before it is used, will save every temporary and argument register and the return address register before a call, and emits a mret instruction at the end. I've included some docs and some testcases to ve

[PATCH] vx-common.h: add #define USE_TM_CLONE_REGISTRY 0

2018-05-25 Thread Rasmus Villemoes
2018-05-26 Rasmus Villemoes gcc/ * config/vx-common.h (USE_TM_CLONE_REGISTRY): #define to 0. --- gcc/config/vx-common.h | 7 +++ 1 file changed, 7 insertions(+) diff --git a/gcc/config/vx-common.h b/gcc/config/vx-common.h index 7a05b5b602a..f5c398ee4b9 100644 --- a/gcc/con

Re: [PATCH] handle local aggregate initialization in strlen (PR 83821)

2018-05-25 Thread Martin Sebor
On 05/25/2018 03:55 PM, Marc Glisse wrote: On Fri, 25 May 2018, Martin Sebor wrote: Why couldn't nonzero_chars be constant in that case? void f(const char*s){ s[0]='a'; // I know that strlen(s) is at least 1 here } I was responding specifically to your question about the strlen() CSE. A

[PATCH] crtstuff.c: remove leftover declaration of _Jv_RegisterClasses

2018-05-25 Thread Rasmus Villemoes
2018-05-26 Rasmus Villemoes libgcc/ * crtstuff.c: Remove declaration of _Jv_RegisterClasses. --- libgcc/crtstuff.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/libgcc/crtstuff.c b/libgcc/crtstuff.c index 5e894455e16..d81c527a455 100644 --- a/libgcc/crtstuff.c +++ b/lib

[PATCH, committed] fix a number of pdp11 target test failures

2018-05-25 Thread Paul Koning
Sorry, it's been a while, previous message was incomplete. This fixes a number of test failures due to test cases that are too large for pdp11 and should be skipped. Also one test case that asks for alignment larger than what pdp11 supports. paul 2018-05-25 Paul Koning * g

Re: [PATCH] Remove useless noinline variable (PR bootstrap/85921)

2018-05-25 Thread Richard Biener
On May 25, 2018 11:03:50 PM GMT+02:00, Jakub Jelinek wrote: >Hi! > >The following variable only makes the code larger and less readable. >In addition, with some broken kernel headers that redefine noinline >it breaks bootstrap. > >Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux

Re: [PATCH] PR target/85358 patch v2: Add target hook to prevent default widening

2018-05-25 Thread Richard Biener
On May 25, 2018 8:49:47 PM GMT+02:00, Michael Meissner wrote: >I redid the patch to make the target hook only apply for scalar float >points, >and I removed all of the integer only subcases. > >I have checked this on a little endian Power8 system, and verified that >it >bootstraps correctly and t

Re: [PATCH] consider MIN_EXPR in get_size_range() (PR 85888)

2018-05-25 Thread Richard Biener
On Thu, May 24, 2018 at 11:22 PM Martin Sebor wrote: > On 05/24/2018 11:15 AM, Richard Biener wrote: > > On May 24, 2018 7:02:17 PM GMT+02:00, Martin Sebor wrote: > >> On 05/24/2018 03:39 AM, Richard Biener wrote: > >>> On Thu, May 24, 2018 at 12:50 AM Martin Sebor > >> wrote: > >>> > The

Re: [PATCH GCC][1/6]Compute type mode and register class mapping

2018-05-25 Thread Richard Biener
On Fri, May 25, 2018 at 12:55 AM Jeff Law wrote: > On 05/18/2018 02:40 AM, Bin.Cheng wrote: > > On Fri, May 4, 2018 at 5:21 PM, Bin Cheng wrote: > >> Hi, > >> This is the updated version patch set computing register pressure on TREE SSA > >> and use that information to direct other loop optimize

Re: Unreviewed patch

2018-05-25 Thread Richard Biener
On Fri, May 25, 2018 at 12:57 AM Rainer Orth wrote: > The following patch has remained unreviewed for two weeks: > [build] Support SHF_EXCLUDE on non-x86 and with Solaris as > https://gcc.gnu.org/ml/gcc-patches/2018-05/msg00465.html > Most of it falls under my Solaris maintain

Re: Support fused multiply-adds in fully-masked reductions

2018-05-25 Thread Richard Biener
On Thu, May 24, 2018 at 2:17 PM Richard Sandiford < richard.sandif...@linaro.org> wrote: > Richard Biener writes: > > On Wed, May 16, 2018 at 11:26 AM Richard Sandiford < > > richard.sandif...@linaro.org> wrote: > > > >> This patch adds support for fusing a conditional add or subtract > >> with a

Re: Fold VEC_COND_EXPRs to IFN_COND_* where possible

2018-05-25 Thread Richard Biener
On Thu, May 24, 2018 at 2:21 PM Richard Sandiford < richard.sandif...@linaro.org> wrote: > Richard Biener writes: > >> 2018-05-24 Richard Sandiford > > > >> gcc/ > >> * doc/sourcebuild.texi (vect_double_cond_arith: Document. > >> * gimple-match.h (gimple_match_op::MAX_NUM_OPS

Re: Prefer open-coding vector integer division

2018-05-25 Thread Richard Biener
On Thu, May 24, 2018 at 2:52 PM Richard Sandiford < richard.sandif...@linaro.org> wrote: > Richard Biener writes: > > On Thu, May 24, 2018 at 10:31 AM Jakub Jelinek wrote: > >> On Thu, May 24, 2018 at 09:21:35AM +0100, Richard Sandiford wrote: > >> > vect_recog_divmod_pattern currently bails out

Re: Add IFN_COND_FMA functions

2018-05-25 Thread Richard Biener
On Thu, May 24, 2018 at 2:08 PM Richard Sandiford < richard.sandif...@linaro.org> wrote: > This patch adds conditional equivalents of the IFN_FMA built-in functions. > Most of it is just a mechanical extension of the binary stuff. > Tested on aarch64-linux-gnu (with and without SVE), aarch64_be-e

[ARM/FDPIC 04/21] [ARM] FDPIC: Add support for FDPIC for arm architecture

2018-05-25 Thread Christophe Lyon
The FDPIC register is hard-coded to r9, as defined in the ABI. We have to disable tailcall optimizations if we don't know if the target function is in the same module. If not, we have to set r9 to the value associated with the target module. When generating a symbol address, we have to take into

[ARM/FDPIC 02/21] [ARM] FDPIC: Handle arm*-*-uclinuxfdpiceabi in configure scripts

2018-05-25 Thread Christophe Lyon
The new arm-uclinuxfdpiceabi target behaves pretty much like arm-linux-gnueabi. In order the enable the same set of features, we have to update several configure scripts that generally match targets like *-*-linux*: in most places, we add *-uclinux* where there is already *-linux*, or uclinux* when

[ARM/FDPIC 07/21] [ARM] FDPIC: Avoid saving/restoring r9 on stack since it is RO

2018-05-25 Thread Christophe Lyon
2018-XX-XX Christophe Lyon Mickaël Guêné gcc/ * config/arm/arm.c (arm_compute_save_reg0_reg12_mask): Handle FDPIC. (thumb1_compute_save_core_reg_mask): Likewise. Change-Id: Ib534cf91704cdc740867b46a8fe45fda27894562 diff --git a/gcc/config/arm/arm.c b/g

[ARM/FDPIC 12/21] [ARM] FDPIC: Restore r9 after we call __aeabi_read_tp

2018-05-25 Thread Christophe Lyon
2018-XX-XX Christophe Lyon Mickaël Guêné gcc/ * config/arm/arm.c (arm_load_tp): Add FDPIC support. * config/arm/arm.md (load_tp_soft_fdpic): New pattern. (load_tp_soft): Disable in FDPIC mode. Change-Id: I0a2e3466c9afb869ad8e844083ad178de014658e diff -

[ARM/FDPIC 11/21] [ARM] FDPIC: Add support to unwind FDPIC signal frame

2018-05-25 Thread Christophe Lyon
2018-XX-XX Christophe Lyon Mickaël Guêné libgcc/ * unwind-arm-common.inc (ARM_SET_R7_RT_SIGRETURN) (THUMB2_SET_R7_RT_SIGRETURN, FDPIC_LDR_R12_WITH_FUNCDESC) (FDPIC_LDR_R9_WITH_GOT, FDPIC_LDR_PC_WITH_RESTORER) (FDPIC_FUNCDESC_OFFSET, ARM_NEW_RT_SI

[ARM/FDPIC 00/21] FDPIC ARM for ARM

2018-05-25 Thread Christophe Lyon
Hello, This patch series implements the GCC contribution of the FDPIC ABI for ARM targets. This ABI enables to run Linux on ARM MMU-less cores and supports shared libraries to reduce the memory footprint. Without MMU, text and data segments relative distances are different from one process to an

[ARM/FDPIC 06/21] [ARM] FDPIC: Add support for c++ exceptions

2018-05-25 Thread Christophe Lyon
When restoring a function address, we also have to restore the FDPIC register value (r9). 2018-XX-XX Christophe Lyon Mickaël Guêné gcc/ * ginclude/unwind-arm-common.h (unwinder_cache): Add reserved5 field. libgcc/ * config/arm/linux-atomic.c (_

[ARM/FDPIC 01/21] [ARM] FDPIC: Add -mfdpic option support

2018-05-25 Thread Christophe Lyon
2018-XX-XX Christophe Lyon Mickaël Guêné gcc/ * config/arm/arm.opt: Add -mfdpic option. Change-Id: Ie5c4ed7434488933de6133186da09cd3ea1291a7 diff --git a/gcc/config/arm/arm.opt b/gcc/config/arm/arm.opt index a1286a4..231c1cb 100644 --- a/gcc/config/arm/arm.opt +++ b/

[ARM/FDPIC 08/21] [ARM] FDPIC: Fix corner case of weak symbol

2018-05-25 Thread Christophe Lyon
When checking the address of a weak symbol in an executable, it is mandatory to use the GOTFUNCDESC scheme so that the address==NULL semantic is valid if the symbol is not present in the final link. 2018-XX-XX Christophe Lyon Mickaël Guêné gcc/ * config/arm/arm.c (arm_

[ARM/FDPIC 09/21] [ARM] FDPIC: Add support for taking address of nested function

2018-05-25 Thread Christophe Lyon
2018-XX-XX Christophe Lyon Mickaël Guêné gcc/ * config/arm/arm.c (arm_asm_trampoline_template): Add FDPIC support. (arm_trampoline_init): Likewise. (arm_trampoline_init): Likewise. * config/arm/arm.h (TRAMPOLINE_SIZE): Likewise. Change-I

[ARM/FDPIC 03/21] [ARM] FDPIC: Force FDPIC related options unless -mno-fdpic is provided

2018-05-25 Thread Christophe Lyon
In FDPIC mode, we set -fPIE unless the user provides -fno-PIE, -fpie, -fPIC or -fpic: indeed FDPIC code is PIC, but we want to generate code for executables rather than shared libraries by default. We also make sure to use the --fdpic assembler option, and select the appropriate linker emulation.

[ARM/FDPIC 10/21] [ARM] FDPIC: Implement legitimize_tls_address_fdpic

2018-05-25 Thread Christophe Lyon
Support additional relocations: TLS_GD32_FDPIC, TLS_LDM32_FDPIC, and TLS_IE32_FDPIC. We do not support the GNU2 TLS dialect. 2018-XX-XX Christophe Lyon Mickaël Guêné gcc/ * config/arm/arm.c (tls_reloc): Add TLS_GD32_FDPIC, TLS_LDM32_FDPIC and TLS_IE32_FDPIC.

[ARM/FDPIC 05/21] [ARM] FDPIC: Fix __do_global_dtors_aux and frame_dummy generation

2018-05-25 Thread Christophe Lyon
In FDPIC, we need to make sure __do_global_dtors_aux and frame_dummy are referenced by their address, not by pointers to the function descriptors. 2018-XX-XX Christophe Lyon Mickaël Guêné * libgcc/crtstuff.c: Add support for FDPIC. Change-Id: Iff3aec3815e8ebd87276c0107752f009

[ARM/FDPIC 15/21] [ARM][testsuite] FDPIC: Skip unsupported tests

2018-05-25 Thread Christophe Lyon
Several tests cannot work on ARM-FDPIC for various reasons: skip them, or skip some directives. gcc.dg/20020312-2.c: Skip since it forces -fno-pic. gcc.target/arm/: * Skip since r9 is clobbered by assembly code: 20051215-1.c mmx-1.c pr61948.c pr77933-1.c pr77933-2.c * Skip since the te

[ARM/FDPIC 16/21] [ARM][testsuite] FDPIC: Adjust scan-assembler patterns.

2018-05-25 Thread Christophe Lyon
In FDPIC mode, r9 is saved in addition to other registers, so update the expected patterns accordingly. 2018-XX-XX Christophe Lyon Mickaël Guêné * gcc/testsuite/ * gcc.target/arm/interrupt-1.c: Add scan-assembler pattern for arm*-*-uclinuxfdpiceabi. * g

[ARM/FDPIC 19/21] [ARM][testsuite] FDPIC: Handle *-*-uclinux*

2018-05-25 Thread Christophe Lyon
Add *-*-uclinux* to tests that work on this target. 2018-XX-XX Christophe Lyon gcc/testsuite/ * g++.dg/abi/forced.C: Add *-*-uclinux*. * g++.dg/abi/guard2.C: Likewise. * g++.dg/ext/cleanup-10.C: Likewise. * g++.dg/ext/cleanup-11.C: Likewise. * g+

[ARM/FDPIC 14/21] [ARM] FDPIC: Force LSB bit for PC in Cortex-M architecture

2018-05-25 Thread Christophe Lyon
Without this, when we are unwinding across a signal frame we can jump to an even address which leads to an exception. This is needed in __gnu_persnality_sigframe_fdpic() when restoring the PC from the signal frame since the PC saved by the kernel has the LSB bit set to zero. 2018-XX-XX Christoph

[ARM/FDPIC 17/21] [ARM][testsuite] FDPIC: Skip v8-m and v6-m tests that currently produce an ICE

2018-05-25 Thread Christophe Lyon
v6-M and v8-M are not supported currently in FDPIC mode, it's better to skip the tests. 2018-XX-XX Christophe Lyon Mickaël Guêné gcc/testsuite/ * gcc.target/arm/atomic-comp-swap-release-acquire-3.c: Skip on arm*-*-uclinuxfdpiceabi. * gcc.target/arm/atom

[ARM/FDPIC 13/21] [ARM] FDPIC: Support unwinding across thumb2 signal trampoline

2018-05-25 Thread Christophe Lyon
2018-XX-XX Christophe Lyon Mickaël Guêné libgcc/ * unwind-arm-common.inc (FDPIC_T2_LDR_R12_WITH_FUNCDESC) (FDPIC_T2_LDR_R9_WITH_GOT, FDPIC_T2_LDR_PC_WITH_RESTORER): New. (__gnu_personality_sigframe_fdpic): Support Thumb address. (get_eit_entry):

[ARM/FDPIC 18/21] [ARM][testsuite] FDPIC: Skip tests that don't work in PIC mode

2018-05-25 Thread Christophe Lyon
Some tests fail on arm*-*-uclinuxfdpiceabi because it generates PIC code and they don't support it: skip them. They also fail on arm*-linux* when forcing -fPIC. 2018-XX-XX Christophe Lyon gcc/testsuite/ * gcc.target/arm/eliminate.c: Accept only nonpic targets. * g++.dg/

[ARM/FDPIC 20/21] [ARM][testsuite] FDPIC: Enable tests on pie_enabled targets

2018-05-25 Thread Christophe Lyon
Some tests have the "nonpic" guard, but pass on arm*-*-uclinuxfdpiceabi because it is in PIE mode by default. Rather than adding this target to all these tests, add the "pie_enabled" effective target. 2018-XX-XX Christophe Lyon gcc/testsuite/ * g++.dg/cpp0x/noexcept03.C: Add pi

[ARM/FDPIC 21/21] [ARM][testsuite] FDPIC: Adjust pr43698.c to avoid clash with uclibc.

2018-05-25 Thread Christophe Lyon
uclibc defines bswap_32, so use a different name in this test. 2018-XX-XX Christophe Lyon gcc/testsuite/ * gcc.target/arm/pr43698.c (bswap_32): Rename as my_bswap_32. Change-Id: I2591bd911030814331cabf97ee5cf6cf8124b4f3 diff --git a/gcc/testsuite/gcc.target/arm/pr43698.c b/g

Re: [PATCH GCC][1/6]Compute type mode and register class mapping

2018-05-25 Thread Bin.Cheng
On Thu, May 24, 2018 at 11:55 PM, Jeff Law wrote: > On 05/18/2018 02:40 AM, Bin.Cheng wrote: >> On Fri, May 4, 2018 at 5:21 PM, Bin Cheng wrote: >>> Hi, >>> This is the updated version patch set computing register pressure on TREE >>> SSA >>> and use that information to direct other loop optimiz

[committed][AArch64] Add SVE support for integer division

2018-05-25 Thread Richard Sandiford
After the previous patch to prevent pessimisation of divisions by constants, this patch adds support for the SVE integer division instructions. Tested on aarch64-linux-gnu (with and without SVE) and aarch64_be-elf. Committed as r260712. Richard 2018-05-25 Richard Sandiford gcc/ * co

[RFC] fixincludes: vxworks: add hack around ioLib.h/unistd.h mutual inclusion

2018-05-25 Thread Rasmus Villemoes
In old VxWorks headers (5.5), ioLib.h includes unistd.h via #include "unistd.h" We copy ioLib to include-fixed, with a few fixes applied. We also wrap unistd.h, so that fixed header contains #include_next This means that when user-code does #include they'll get the fixed header (as they sho

[Ada] Detect misplaced assertions between loop invariants

2018-05-25 Thread Pierre-Marie de Rodat
Loop invariants and loop variants should all be colocated, as defined in SPARK RM 5.5.3(8). The code checking that rule was incorrectly accepting pragma Assert between two loop invariants. Now fixed. Tested on x86_64-pc-linux-gnu, committed on trunk 2018-05-25 Yannick Moy gcc/ada/ *

[Ada] Compiler loop on expression function and predicate in generic unit

2018-05-25 Thread Pierre-Marie de Rodat
This patch fixes an infinite loop in the compiler when analyzing an expression function whose expression mentions a subtype with a static predicate, and the context is a generic unit. Tested on x86_64-pc-linux-gnu, committed on trunk 2018-05-25 Ed Schonberg gcc/ada/ * sem_ch13.adb (B

[Ada] Support for C99 and C++ standard boolean types

2018-05-25 Thread Pierre-Marie de Rodat
This change the type Interfaces.C.Extensions.bool to be fully compatible with the C99 and C++ standard boolean types by making it a fully-fledged boolean type with convention C. The following C+Ada program must compile quietly in LTO mode: bool b; struct S {}; bool foo (struct S *s) { return tr

[Ada] Unbounded strings: inline Initialize and Adjust

2018-05-25 Thread Pierre-Marie de Rodat
Procedures Initialize and Adjust in the Ada.[Wide_[Wide_]]Strings.Unbounded package are now inlined for nondispatching calls. No test available (efficiency issue only). Tested on x86_64-pc-linux-gnu, committed on trunk 2018-05-25 Bob Duff gcc/ada/ * libgnat/a-strunb__shared.ads, libg

[Ada] Fix handling of Loop_Entry for CodePeer/SPARK

2018-05-25 Thread Pierre-Marie de Rodat
When the applicable Assertion_Policy is Ignore for a pragma containing an occurrence of attribute Loop_Entry, CodePeer and SPARK should still be able to analyze the corresponding pragma. GNAT frontend was wrongly translating X'Loop_Entry as X in the AST, as a side-effect of an optimization only val

[Ada] Make Max_Sensible_Delay uniform across all Posix targets

2018-05-25 Thread Pierre-Marie de Rodat
For instance: 6 months where Duration is 64bits. Heretofore LynxOS was unique in having an approximately 12 days max delay. By experimentation the actual maximum was determined and all relevant delay and sleep procedures rewritten to incrementally wait if necessary. Tested on x86_64-pc-linux-gnu,

[Ada] Checks on instantiations with formal derived types with interfaces

2018-05-25 Thread Pierre-Marie de Rodat
This patch implements the rule stated in RM 12.5.5 : the actual shall be a descendant of very progenitor of the formal type. Tested on x86_64-pc-linux-gnu, committed on trunk 2018-05-25 Ed Schonberg gcc/ada/ * sem_ch12.adb (Validate_Derived_Type_Instance): Verify that the actual

[Ada] Spurious secondary stack depletion

2018-05-25 Thread Pierre-Marie de Rodat
This patch reimplements the secondary stack allocation logic to eliminate an issue which causes the memory index to overflow while the stack itself uses very little memory, thus causing a spurious Storage_Error. The issue in details: The total amount of memory that the secondary stack can accomod

[Ada] Rewrite Iterate_Call_Parameters in more assertive style

2018-05-25 Thread Pierre-Marie de Rodat
The formal and actual parameters in a subprogram call must match each other. This is now checked with assertion (so that we can detect possible mistakes), while the production builds have less work to do. Semantics unchanged. Tested on x86_64-pc-linux-gnu, committed on trunk 2018-05-25 Piotr Tro

[Ada] Disable the creation of the main task secondary stack by the binder

2018-05-25 Thread Pierre-Marie de Rodat
Users can now specify that the binder should not create a secondary stack for the main (environment) task through the binder switch -Q0. This is useful for ZFP runtime users who allocate secondary stacks for their application themselves. Tested on x86_64-pc-linux-gnu, committed on trunk 2018-05-2

[Ada] Crash on classwide precondition on subprogram with stub

2018-05-25 Thread Pierre-Marie de Rodat
This patch allows the compiler to handle properly a classwide precondition on a primitive operation whose body is a stub and a separate subunit. Executing: gnatmake -gnata -q check ./check must yield: precondition violated with Text_IO; with Msg_Data_Block_Decoder; use Msg_Data_B

[Ada] Membership test of class-wide interface

2018-05-25 Thread Pierre-Marie de Rodat
The compiler rejects the use of a membership test when the left operand is a class-wide interface type object and the right operand is not a class-wide type. Tested on x86_64-pc-linux-gnu, committed on trunk 2018-05-25 Javier Miranda gcc/ada/ * sem_res.adb (Resolve_Membership_Op): Al

  1   2   >