Re: Fold acc_on_device

2015-10-05 Thread Segher Boessenkool
On Thu, Oct 01, 2015 at 08:33:07AM -0400, Nathan Sidwell wrote: > 2015-10-01 Nathan Sidwell > > * builtins.c: Don't include gomp-constants.h. > (fold_builtin_1): Don't fold acc_on_device here. > * gimple-fold.c: Include gomp-constants.h. > (gimple_fold_builtin_acc_on_dev

[PATCH] Early exit to avoid redundant computations

2015-10-05 Thread Aditya Kumar
Analyze only those bbs which are outside the region for uses which might be defined inside the region. This is intended to improve the compile time. This algorithm may be further improved by only looking at the successors of region as these regions are sese. Added FIXMEs to make this improvement in

[PATCH v2] SH FDPIC backend support

2015-10-05 Thread Rich Felker
On Fri, Oct 02, 2015 at 07:36:27AM +0900, Oleg Endo wrote: > On Thu, 2015-10-01 at 17:35 -0400, Rich Felker wrote: > > This is a forward-port of the abandoned SH FDPIC patch from 2010: > > > > https://gcc.gnu.org/ml/gcc-patches/2010-08/msg01536.html > > > > I'm submitting it at this point for ini

Re: [patch 0/3] Header file reduction. - unified patches

2015-10-05 Thread Andrew MacLeod
On 10/05/2015 05:11 PM, Andrew MacLeod wrote: I can switch to -u.. I've just never seen the request before. I can regenerate the patches with -u if you want. You are right, the patches are significantly easier to read with -u.. I've changed my svn diff script.here's all 3 patches: And

[PATCH 1/2] [Refactoring graphite] Move declarations, assign types, renaming.

2015-10-05 Thread Aditya Kumar
1. Move declarations near the assignment/usage. 2. Assign type to members which were void*. 3. Rename scop->context to scop::param_context, and scop::ctx to scop::isl_context No functional changes intended. Passes regtest and bootstrap. gcc/ChangeLog: 2015-10-05 Aditya Kumar * graphi

Re: [AARCH64] Add missing entries in iterator vwcore

2015-10-05 Thread Kugan
On 05/10/15 21:33, James Greenhalgh wrote: > On Thu, Oct 01, 2015 at 09:41:20PM +0100, Kugan wrote: >> Hi, >> >> In "aarch64_get_lane" operand 0 is VEL, so for %0, >> iterator vwcore should (?) support all the modes in VEL. >> >> Ran into following error with a local patch for an existing test c

RE: [PATCH, MIPS] Frame header optimization for MIPS O32 ABI

2015-10-05 Thread Moore, Catherine
> -Original Message- > From: Steve Ellcey [mailto:sell...@imgtec.com] > Sent: Monday, October 05, 2015 1:16 PM > To: Moore, Catherine > Cc: Matthew Fortune; GCC Patches > Subject: RE: [PATCH, MIPS] Frame header optimization for MIPS O32 ABI > > On Mon, 2015-09-28 at 22:10 +, Moore, C

Re: [google][gcc-4_9] encode and compress cc1 option strings in gcov_module_info

2015-10-05 Thread Xinliang David Li
unsigned ggc_memory = gcov_read_unsigned (); + unsigned marker = 0, len = 0, k; + char **string_array, *saved_cc1_strings; + for (unsigned j = 0; j < 7; j++) Do not use hard coded number. Use the enum defined in coverage.c. +string_array[j] = xstrdup (gcov_read_s

Re: using scratchpads to enhance RTL-level if-conversion: the new patch now passes bootstrap with the default BUILD_CONFIG [i.e. no stage2-to-stage3 comparison errors even with debugging info off in s

2015-10-05 Thread Sebastian Pop
On Mon, Oct 5, 2015 at 6:02 PM, Joseph Myers wrote: > Is this Samsung Austin R&D Center? If so, yes, there's an assignment Yes.

[PATCH][PING^2][C++] Fix PR67333

2015-10-05 Thread Mikhail Maltsev
PING. On 08/27/2015 09:27 PM, Mikhail Maltsev wrote: > Hi. > This patch fixes a rejects-valid bug related to volatile-qualified arguments > of > constexpr functions. This is essentially a one-line change in constexpr.c. > Bootstrapped and regtested on x86_64-pc-linux-gnu. OK for trunk? > > gcc/c

[PATCH 8/9] ENABLE_CHECKING refactoring: target-specific parts

2015-10-05 Thread Mikhail Maltsev
gcc/ChangeLog: 2015-10-05 Mikhail Maltsev * config/alpha/alpha.c (alpha_function_arg): Use gcc_checking_assert. * config/arm/arm.c (arm_unwind_emit_sequence): Adjust to use CHECKING_P. * config/bfin/bfin.c (hwloop_optimize): Likewise. * config/i386/i386.c (ix86_

Re: [PATCH 7/9] ENABLE_CHECKING refactoring: middle-end, LTO FE

2015-10-05 Thread Mikhail Maltsev
gcc/ChangeLog: 2015-10-05 Mikhail Maltsev * attribs.c (check_attribute_tables): Define new function. (init_attributes): Use it. * cfgcleanup.c (try_optimize_cfg): Use flag_checking. * cfgexpand.c (expand_goto, expand_debug_expr): Likewise. (pass_expand::

[PATCH 6/9] ENABLE_CHECKING refactoring: generators

2015-10-05 Thread Mikhail Maltsev
gcc/ChangeLog: 2015-10-05 Mikhail Maltsev * genautomata.c: Use CHECKING_P instead of ENABLE_CHECKING. * genconditions.c: Define CHECKING_P in generated code. * genextract.c: Use CHECKING_P instead of ENABLE_CHECKING. * gengtype.c (main): Likewise. * geng

Re: [PATCH 5/9] ENABLE_CHECKING refactoring: pool allocators

2015-10-05 Thread Mikhail Maltsev
gcc/ChangeLog: 2015-10-05 Mikhail Maltsev * alloc-pool.h (base_pool_allocator::initialize, ::allocate, ::remove): Adjust to use CHECKING_P. >From ed727b2279dd36e2fbf1ab6956270cbd487b1a01 Mon Sep 17 00:00:00 2001 From: Mikhail Maltsev Date: Sun, 4 Oct 2015 22:50:40 +0300 Subje

[PATCH 4/9] ENABLE_CHECKING refactoring: Fortran

2015-10-05 Thread Mikhail Maltsev
gcc/fortran/ChangeLog: 2015-10-05 Mikhail Maltsev * trans-common.c (create_common): Adjust to use flag_checking. * trans.c (gfc_add_modify_loc): Use gcc_checking_assert. >From 8113b4d5bc943772145abdd6562d4af6093d9718 Mon Sep 17 00:00:00 2001 From: Mikhail Maltsev Date: Sat,

[PATCH 3/9] ENABLE_CHECKING refactoring: Java and Ada

2015-10-05 Thread Mikhail Maltsev
gcc/java/ChangeLog: 2015-10-05 Mikhail Maltsev * decl.c (java_mark_decl_local): Use flag_checking instead of ENABLE_CHECKING. gcc/ada/ChangeLog: 2015-10-05 Mikhail Maltsev * gcc-interface/decl.c (gnat_to_gnu_entity): Use gcc_checking_assert. * gcc-interfa

Re: [PATCH 2/9] ENABLE_CHECKING refactoring: libcpp

2015-10-05 Thread Mikhail Maltsev
libcpp/ChangeLog: 2015-10-05 Mikhail Maltsev * include/line-map.h: Fix use of ENABLE_CHECKING. * init.c: Likewise. * macro.c (struct macro_arg_token_iter, set_arg_token, macro_arg_token_iter_init, macro_arg_token_iter_forward, macro_arg_token_iter_get_to

[PATCH 1/9] ENABLE_CHECKING refactoring

2015-10-05 Thread Mikhail Maltsev
Hi! This is an updated series of patches which converts 'ENABLE_CHECKING' macro into a flag, 'flag_checking' (and 'CHECKING_P' macro in several cases). For now flag_checking is always initialized with the value of 'CHECKING_P', but later it can be turned into a proper command-line flag and probabl

RE: [RFA] Compact EH Patch

2015-10-05 Thread Moore, Catherine
> -Original Message- > From: Richard Henderson [mailto:r...@redhat.com] > Subject: Re: [RFA] Compact EH Patch > Richard, Thanks for the patch review. Matthew, Would you please take a look at the MIPS-specific pieces before I resubmit the patch? There will be a small change to the data

Do not compare types in operands_equal_p if OEP_ADDRESS_OF is set

2015-10-05 Thread Jan Hubicka
Hi, While looking for uses of useless_type_conversion on non-gimple register types I run across few that seem to be completely unnecesary and I would like to get rid of them in hope to get rid of code comparing functions/method type and possibly more. usless_type_conversion is about operations on

Re: using scratchpads to enhance RTL-level if-conversion: the new patch now passes bootstrap with the default BUILD_CONFIG [i.e. no stage2-to-stage3 comparison errors even with debugging info off in s

2015-10-05 Thread Joseph Myers
On Mon, 5 Oct 2015, Abe wrote: > [Bernd wrote:] > > To be able to include your code we need to have a copyright assignment to > > the FSF from you. > > [...] Have you gone through the copyright assignment process? > > Since I am doing this work as part of my job at Samsung, I have it on good > au

[google][gcc-4_9] encode and compress cc1 option strings in gcov_module_info

2015-10-05 Thread Rong Xu
Hi, This patch is for google branch only. It encodes and compresses various cc1 option strings in gcov_module_info to reduce the lipo instrumented object size. The savings are from string compression and the reduced number of relocations. More specifically, we replace the following fields in gco

Re: [PATCH, rs6000] Fix PR target/67808, LRA ICE on double to long double conversion

2015-10-05 Thread Michael Meissner
Ok, after spending the day on going down the rabbit hole of trying to optimize just about every, here are my patches. Note, I simplified the constraints to eliminate some rare possibilities, like optimizing converting from double to long double if the double happened to be in a GPR register and th

Re: C PATCH for c/65345 (file-scope _Atomic expansion with floats)

2015-10-05 Thread Kaz Kojima
Marek Polacek wrote: > Joseph reminded me that I had forgotten about this patch. As mentioned > here , I'm > removing the XFAILs in the tests so people are likely to see new FAILs. > > I think the following targets will need similar fix a

Re: [RFC] COMDAT Safe Module Level Multi versioning

2015-10-05 Thread Sriraman Tallam
On Wed, Sep 9, 2015 at 4:01 PM, Sriraman Tallam wrote: > On Wed, Sep 2, 2015 at 4:32 PM, Sriraman Tallam wrote: >> >> On Tue, Aug 18, 2015 at 9:46 PM, Cary Coutant wrote: >> >> Thanks, will make those changes. Do you recommend a different name >> >> for this flag like -fmake-comdat-functions-st

[patch 4/3] Header file reduction - Tools for contrib

2015-10-05 Thread Andrew MacLeod
Here's the patch to add all the tools to contrib/headers. There are 9 tools I used over the run of the project. They were developed in various stages and iterations, but I tried to at least have some common interface things, and I tried some cleaning up and documentation. No commenting on th

Re: [patch 0/3] Header file reduction.

2015-10-05 Thread Andrew MacLeod
On 10/05/2015 04:37 PM, Bernd Schmidt wrote: On 10/05/2015 10:10 PM, Andrew MacLeod wrote: Its just an example of the sort of redundant includes the tool removes. And your assertion turns out to be incorrect... bitmap.h is barely used outside the backend, thus it is included in the backend.h agg

Re: [PATCH] Remove restriction for remote testing

2015-10-05 Thread Joseph Myers
On Mon, 5 Oct 2015, Mike Stump wrote: > or otherwise unconditionally put -latomic on the link line (some place > that isn’t protected by is_remote host). Remembering of course that it needs to be done in a way that doesn't leave it there for other .exp files executed after atomic.exp. -- Jose

Re: [patch 0/3] Header file reduction.

2015-10-05 Thread Bernd Schmidt
On 10/05/2015 10:10 PM, Andrew MacLeod wrote: Its just an example of the sort of redundant includes the tool removes. And your assertion turns out to be incorrect... bitmap.h is barely used outside the backend, thus it is included in the backend.h aggregator (This is the only header now which inc

[PATCH] remove dead code used by the old cloog scheduler

2015-10-05 Thread Sebastian Pop
--- gcc/graphite-dependences.c | 255 + gcc/graphite-poly.h| 3 - 2 files changed, 1 insertion(+), 257 deletions(-) diff --git a/gcc/graphite-dependences.c b/gcc/graphite-dependences.c index e39394a..2c4f92c 100644 --- a/gcc/graphite-dependenc

[PATCH] remove dead code used by the old cloog scheduler

2015-10-05 Thread Sebastian Pop
--- gcc/graphite-dependences.c | 36 gcc/graphite-poly.h| 3 --- 2 files changed, 39 deletions(-) diff --git a/gcc/graphite-dependences.c b/gcc/graphite-dependences.c index e39394a..37535d5 100644 --- a/gcc/graphite-dependences.c +++ b/gcc/graphite-de

Re: [patch 0/3] Header file reduction.

2015-10-05 Thread Andrew MacLeod
On 10/05/2015 09:27 AM, Bernd Schmidt wrote: On 10/02/2015 04:22 AM, Andrew MacLeod wrote: The patches are generated by a pair of tools. * gcc-order-includes goes through the headers and canonically reorders some of our more common/troublesome headers and removes any duplicates. This includes

Re: Cache reals for 1/4, 1/6 and 1/9

2015-10-05 Thread Richard Sandiford
Marc Glisse writes: > On Mon, 5 Oct 2015, Richard Sandiford wrote: > >>> I do believe you still have some code growth since the inline dconst >>> function always expands code that will initialize the constant. IMO >>> that's not desirable. >> >> I don't disagree. I find dconst0 much easier to rea

Re: [PATCH] Remove restriction for remote testing

2015-10-05 Thread Mike Stump
On Sep 28, 2015, at 5:35 AM, James Norris wrote: > The attached patch fixes a problem when doing remote testing. > Specifically, testing of the atomic tests found in gcc/atomic. > The code in atomic_init precludes the setting of the variable > 'link_flags' when doing remote testing. The conditiona

Re: Cache reals for 1/4, 1/6 and 1/9

2015-10-05 Thread Richard Biener
On October 5, 2015 8:04:59 PM GMT+02:00, Mike Stump wrote: >On Oct 5, 2015, at 7:47 AM, Richard Sandiford > wrote: >> - return real_equal (&TREE_REAL_CST (expr), &dconst0) >> + return real_equal (&TREE_REAL_CST (expr), &dconst<0> ()) > >On behalf of mere mortals, hiding the syntax &dcon

Re: [patch] Update template instantiation documentation

2015-10-05 Thread Sandra Loosemore
On 10/05/2015 10:40 AM, Jason Merrill wrote: Looks good to me, thanks. Jason Looks good to me, too. -Sandra

Re: Cache reals for 1/4, 1/6 and 1/9

2015-10-05 Thread Mike Stump
On Oct 5, 2015, at 7:47 AM, Richard Sandiford wrote: > - return real_equal (&TREE_REAL_CST (expr), &dconst0) > + return real_equal (&TREE_REAL_CST (expr), &dconst<0> ()) On behalf of mere mortals, hiding the syntax &dconst<0> () into a header file as in implementation detail is entirel

Go patch committed: Update Unicode letters table to Unicode 8.0.0

2015-10-05 Thread Ian Lance Taylor
This patch by Chris Manghane updates the Go frontend unicode letters table to Unicode 8.0.0. This fixes https://golang.org/issue/12322 . Bootstrapped and ran Go testsuite on x86_64-unknown-linux-gnu. Committed to mainline. Ian Index: gospec.c ==

Re: RFC: Patch to allow spill slot alignment greater than the stack alignment

2015-10-05 Thread Mike Stump
On Oct 5, 2015, at 9:46 AM, Steve Ellcey wrote: > One example of an issue I have run into is with the DWARF unwind > generation and 'Rule 16' in dwarf2cfi.c. It assumes the AND instruction > has an integer constant argument but MIPS can't do an AND with a > constant like -16 so it has to put it i

Re: [C++ Patch] PR 53856

2015-10-05 Thread Jason Merrill
OK. Jason

Re: [C++ Patch] PR 53856

2015-10-05 Thread Paolo Carlini
Hi, On 10/05/2015 07:10 PM, Jason Merrill wrote: On 10/05/2015 12:50 PM, Paolo Carlini wrote: + else if (!current_class_type || CLASSTYPE_IS_TEMPLATE (current_class_type)) +msg = G_("default argument for template parameter for class enclosing %qD"); Why would this be right when !current

Re: [PATCH, rs6000] Fix PR target/67808, LRA ICE on double to long double conversion

2015-10-05 Thread Peter Bergner
On Mon, 2015-10-05 at 13:12 -0400, Michael Meissner wrote: > I have attached a better version of the patch. I'll note that I have not committed the earlier patch and will hold off while we sort out what is best here. > This gives the constraints: > > #1: op0 = m, op1 = d, op2 = d > #2: o

[PATCH v2, i386]: Enable -mstackrealign and 'force_align_arg_pointer' attribute for x86_64

2015-10-05 Thread Uros Bizjak
On Sun, Oct 4, 2015 at 5:26 PM, Uros Bizjak wrote: > As shown in PR 66697 [1] and WineHQ bug [2], an application can > misalign incoming stack to less than ABI mandated 16 bytes. While it > is possible to use -mincoming-stack-boundary=2 (= 4 bytes) for 32 bit > targets to emit stack realignment

Re: Cache reals for 1/4, 1/6 and 1/9

2015-10-05 Thread Marc Glisse
On Mon, 5 Oct 2015, Richard Sandiford wrote: I do believe you still have some code growth since the inline dconst function always expands code that will initialize the constant. IMO that's not desirable. I don't disagree. I find dconst0 much easier to read than dconst<0> (). In some ways I wa

Re: [C++ Patch] PR 53856

2015-10-05 Thread Jason Merrill
On 10/05/2015 12:50 PM, Paolo Carlini wrote: + else if (!current_class_type || CLASSTYPE_IS_TEMPLATE (current_class_type)) +msg = G_("default argument for template parameter for class enclosing %qD"); Why would this be right when !current_class_type? Jason

RE: [PATCH, MIPS] Frame header optimization for MIPS O32 ABI

2015-10-05 Thread Steve Ellcey
On Mon, 2015-09-28 at 22:10 +, Moore, Catherine wrote: > Hi Steve, I'm sorry for the delay in reviewing this patch. > Some changes have been committed upstream (see revision #227941) that will > require updates to this patch. > Please post the update for review. Other comments are embedded.

Re: [PATCH, rs6000] Fix PR target/67808, LRA ICE on double to long double conversion

2015-10-05 Thread Michael Meissner
On Fri, Oct 02, 2015 at 02:04:48PM -0500, Peter Bergner wrote: > PR67808 exposes a problem with the constraints in the *extenddftf2_internal > pattern, in that it allows TFmode operands to occupy Altivec registers > which they are not allowed to do. Reload was able to work around the > problem, bu

Re: Cache reals for 1/4, 1/6 and 1/9

2015-10-05 Thread Bernd Schmidt
On 10/05/2015 07:00 PM, Richard Sandiford wrote: If my original patch isn't acceptable, I thought I'd approved it. another old-school way of doing it would be to have a .def file of all the constants that we want. They could then all be global variables, rather than having some that are and

Re: RFC: Patch to allow spill slot alignment greater than the stack alignment

2015-10-05 Thread Bernd Schmidt
On 10/05/2015 06:46 PM, Steve Ellcey wrote: One example of an issue I have run into is with the DWARF unwind generation and 'Rule 16' in dwarf2cfi.c. It assumes the AND instruction has an integer constant argument but MIPS can't do an AND with a constant like -16 so it has to put it in a regist

Re: Cache reals for 1/4, 1/6 and 1/9

2015-10-05 Thread Richard Sandiford
Bernd Schmidt writes: > On 10/05/2015 05:22 PM, Richard Sandiford wrote: >> Bernd Schmidt writes: >>> On 10/05/2015 04:47 PM, Richard Sandiford wrote: @@ -9536,7 +9520,7 @@ fold_builtin_classify (location_t loc, tree fndecl, tree arg, int builtin_index) {

Re: RFC: Patch to allow spill slot alignment greater than the stack alignment

2015-10-05 Thread H.J. Lu
On Mon, Oct 5, 2015 at 9:46 AM, Steve Ellcey wrote: > On Mon, 2015-10-05 at 09:21 -0700, H.J. Lu wrote: >> On Mon, Oct 5, 2015 at 9:10 AM, Steve Ellcey wrote: > >> > There probably is some way to get dynamic stack alignment to work on >> > MIPS, but I am not sure I can do it. The only platform t

Re: [C++ Patch] PR 53856

2015-10-05 Thread Paolo Carlini
Hi, On 09/24/2015 03:24 PM, Jason Merrill wrote: On 09/22/2015 03:31 PM, Paolo Carlini wrote: msg = G_("default template arguments may not be used in " "partial specializations"); + else if (current_class_type && !CLASSTYPE_IS_TEMPLATE (current_class_type)) +/* Per [temp.p

Re: RFC: Patch to allow spill slot alignment greater than the stack alignment

2015-10-05 Thread Steve Ellcey
On Mon, 2015-10-05 at 09:21 -0700, H.J. Lu wrote: > On Mon, Oct 5, 2015 at 9:10 AM, Steve Ellcey wrote: > > There probably is some way to get dynamic stack alignment to work on > > MIPS, but I am not sure I can do it. The only platform that I see that > > uses dynamic stack alignment is x86. I

Re: [patch] Update template instantiation documentation

2015-10-05 Thread Jason Merrill
Looks good to me, thanks. Jason

Re: [PATCH] Clear SSA_NAME_ANTI_RANGE_P when appropriate (PR tree-optimization/67821)

2015-10-05 Thread Marek Polacek
On Mon, Oct 05, 2015 at 06:27:53PM +0200, Richard Biener wrote: > On October 5, 2015 4:46:44 PM GMT+02:00, Marek Polacek > wrote: > >On Mon, Oct 05, 2015 at 04:26:49PM +0200, Richard Biener wrote: > >> > > Otherwise other setters of SSA_NAME_RANGE_INFO would need to make > >> > > sure SSA_NAME_AN

Re: [PATCH] Clear SSA_NAME_ANTI_RANGE_P when appropriate (PR tree-optimization/67821)

2015-10-05 Thread Richard Biener
On October 5, 2015 4:46:44 PM GMT+02:00, Marek Polacek wrote: >On Mon, Oct 05, 2015 at 04:26:49PM +0200, Richard Biener wrote: >> > > Otherwise other setters of SSA_NAME_RANGE_INFO would need to make >> > > sure SSA_NAME_ANTI_RANGE_P is cleared as well. >> > >> > They mostly do, if I'm looking

Re: [patch] Update template instantiation documentation

2015-10-05 Thread Jonathan Wakely
On 03/10/15 10:44 -0600, Sandra Loosemore wrote: On 10/03/2015 06:47 AM, Jonathan Wakely wrote: https://gcc.gnu.org/onlinedocs/gcc/Template-Instantiation.html currently says that using -frepo "is your best option for application code written for the Borland model, as it just works." That was tr

Re: RFC: Patch to allow spill slot alignment greater than the stack alignment

2015-10-05 Thread H.J. Lu
On Mon, Oct 5, 2015 at 9:10 AM, Steve Ellcey wrote: > On Mon, 2015-10-05 at 10:41 +0200, Bernd Schmidt wrote: >> On 10/02/2015 10:57 PM, Steve Ellcey wrote: >> > I have spent some time trying to do dynamic stack alignment on MIPS and had >> > considerable trouble. The problems are mainly due to t

[PATCH] Fix ICE for SIMD clones usage in LTO

2015-10-05 Thread Ilya Enkovich
Hi, When SIMD clone is created original function may be defined in another partition. In this case SIMD clone also has to have in_other_partition flag. Now it doesn't and we get an ICE. This patch fixes it. Bootstrapped and regtested for x86_64-unknown-linux-gnu. OK for trunk? Thanks, Ily

Re: RFC: Patch to allow spill slot alignment greater than the stack alignment

2015-10-05 Thread Steve Ellcey
On Mon, 2015-10-05 at 10:41 +0200, Bernd Schmidt wrote: > On 10/02/2015 10:57 PM, Steve Ellcey wrote: > > I have spent some time trying to do dynamic stack alignment on MIPS and had > > considerable trouble. The problems are mainly due to the dwarf based stack > > unwinding and setjmp/longjmp usag

[gomp4] [nvptx] Don't explicitly pass "-lgomp" to the offload compiler (was: nvptx offloading linking)

2015-10-05 Thread Thomas Schwinge
Hi! On Wed, 13 May 2015 22:11:36 +0200, I wrote: > On Wed, 22 Apr 2015 17:08:26 +0200, Bernd Schmidt > wrote: > > On 04/21/2015 05:58 PM, Jakub Jelinek wrote: > > > > > suggests that while it is nice that when building nvptx accel compiler > > > we build libgcc.a, libc.a, libm.a, libgfortran.a

Re: [PATCH, i386, AVX512] PR target/67849: Avoid upper-bank registers when splitting vec_extract_lo instruction.

2015-10-05 Thread Uros Bizjak
On Mon, Oct 5, 2015 at 5:54 PM, Alexander Fomin wrote: > This patch addresses PR target/67849. Given a machine that does not > support AVX512VL, following "else" branch for vec_exract_lo insn > may result in a split using YMMs from upper-bank, hence invalid > assembly. Tuning define_insn pattern a

[PATCH, i386, AVX512] PR target/67849: Avoid upper-bank registers when splitting vec_extract_lo instruction.

2015-10-05 Thread Alexander Fomin
This patch addresses PR target/67849. Given a machine that does not support AVX512VL, following "else" branch for vec_exract_lo insn may result in a split using YMMs from upper-bank, hence invalid assembly. Tuning define_insn pattern and define_split constraints eliminates this problem. Please tak

Re: [PATCH] Add verifier for leaked SSA names

2015-10-05 Thread Jeff Law
On 10/05/2015 02:56 AM, Richard Biener wrote: I was building the verification step into the ssa name manager. Essentially at the point where we flush from the pending to the free list, we should have a consistent state. Yeah, though when SSA verifiers run the state should also be consistent and

Re: Do not use TYPE_CANONICAL in useless_type_conversion

2015-10-05 Thread Jan Hubicka
> >+ /* For aggregates compare only the size and mode. Accesses to fields do > >have > >+ a type information by themselves and thus we only care if we can i.e. > >+ use the types in move operations. */ > >else if (AGGREGATE_TYPE_P (inner_type) > >&& TREE_CODE (inner_type) ==

Re: [PATCH] Fix PR67783, quadraticness in IPA inline analysis

2015-10-05 Thread Jan Hubicka
> On Thu, 1 Oct 2015, Richard Biener wrote: > > > > > The following avoids quadraticness in the loop depth by only considering > > loop header defs as IVs for the analysis of the loop_stride predicate. > > This will miss cases like > > > > foo (int inv) > > { > > for (i = inv; i < n; ++i) > >

Re: Cache reals for 1/4, 1/6 and 1/9

2015-10-05 Thread Bernd Schmidt
On 10/05/2015 05:22 PM, Richard Sandiford wrote: Bernd Schmidt writes: On 10/05/2015 04:47 PM, Richard Sandiford wrote: @@ -9536,7 +9520,7 @@ fold_builtin_classify (location_t loc, tree fndecl, tree arg, int builtin_index) { r = TREE_REAL_CST (arg); if (real_isinf

Re: RFC: PATCH for front end parts of C++ transactional memory TS

2015-10-05 Thread Jason Merrill
On 10/05/2015 05:00 AM, Andreas Schwab wrote: Jason Merrill writes: diff --git a/gcc/testsuite/g++.dg/tm/eh1.C b/gcc/testsuite/g++.dg/tm/eh1.C new file mode 100644 index 000..1561211 --- /dev/null +++ b/gcc/testsuite/g++.dg/tm/eh1.C @@ -0,0 +1,10 @@ +// A handler can involve a transaction-

Re: Cache reals for 1/4, 1/6 and 1/9

2015-10-05 Thread Richard Sandiford
Bernd Schmidt writes: > On 10/05/2015 04:47 PM, Richard Sandiford wrote: >> @@ -9536,7 +9520,7 @@ fold_builtin_classify (location_t loc, tree fndecl, >> tree arg, int builtin_index) >> { >>r = TREE_REAL_CST (arg); >>if (real_isinf (&r)) >> -return real_compare (GT_EXP

Move sqrt and cbrt simplifications to match.pd

2015-10-05 Thread Richard Sandiford
This patch moves the sqrt and cbrt simplification rules to match.pd. builtins.c now only does the constant folding. Bootstrapped & regression-tested on x86_64-linux-gnu. OK to install? Thanks, Richard gcc/ * builtins.c (fold_builtin_sqrt, fold_builtin_cbrt): Delete. (fold_built

Re: using scratchpads to enhance RTL-level if-conversion: the new patch now passes bootstrap with the default BUILD_CONFIG [i.e. no stage2-to-stage3 comparison errors even with debugging info off in s

2015-10-05 Thread Bernd Schmidt
Oh, one other thing. To be able to include your code we need to have a copyright assignment to the FSF from you. I see one previous commit from you, but only a trivial one and with a corporate email address. Have you gone through the copyright assignment process? Bernd

Re: C PATCH for c/65345 (file-scope _Atomic expansion with floats)

2015-10-05 Thread Joseph Myers
On Sat, 3 Oct 2015, David Edelsohn wrote: > It's poor form to fix a bug only on x86 that is common to all targets > and leave the problem "as an exercise for the reader" for all other > targets -- essentially banishing the other targets to second-class > status with respect to conformance -- espec

Re: Cache reals for 1/4, 1/6 and 1/9

2015-10-05 Thread Bernd Schmidt
On 10/05/2015 04:47 PM, Richard Sandiford wrote: @@ -9536,7 +9520,7 @@ fold_builtin_classify (location_t loc, tree fndecl, tree arg, int builtin_index) { r = TREE_REAL_CST (arg); if (real_isinf (&r)) - return real_compare (GT_EXPR, &r, &dconst0) +

Generalize gimple_val_nonnegative_real_p

2015-10-05 Thread Richard Sandiford
The upcoming patch to move sqrt and cbrt simplifications to match.pd caused a regression because the (abs @0)->@0 simplification didn't trigger for: (abs (convert (abs X))) The simplification is based on tree_expr_nonnegative_p, which is pretty weak for gimple (it gives up if it sees an SSA_N

Re: [PATCH] Clear SSA_NAME_ANTI_RANGE_P when appropriate (PR tree-optimization/67821)

2015-10-05 Thread Marek Polacek
On Mon, Oct 05, 2015 at 04:26:49PM +0200, Richard Biener wrote: > > > Otherwise other setters of SSA_NAME_RANGE_INFO would need to make > > > sure SSA_NAME_ANTI_RANGE_P is cleared as well. > > > > They mostly do, if I'm looking right, e.g. > > tree-ssa-phiopt.c:1016 > > tree-ssa-loop-im.c:1224 >

Re: Cache reals for 1/4, 1/6 and 1/9

2015-10-05 Thread Richard Sandiford
Richard Biener writes: > On Thu, Oct 1, 2015 at 3:59 PM, Bernd Schmidt wrote: >> On 10/01/2015 03:51 PM, Richard Sandiford wrote: >>> >>> We have a global 1/2 and a cached 1/3, but recalculate 1/4, 1/6 and 1/9 >>> each time we need them. That seems a bit arbitrary and makes the folding >>> code

Re: [PATCH] Clear SSA_NAME_ANTI_RANGE_P when appropriate (PR tree-optimization/67821)

2015-10-05 Thread Richard Biener
On Mon, 5 Oct 2015, Marek Polacek wrote: > On Mon, Oct 05, 2015 at 04:08:05PM +0200, Richard Biener wrote: > > On Mon, 5 Oct 2015, Marek Polacek wrote: > > > > > Here, we were crashing on an assert in duplicate_ssa_name_range_info: > > > > > > 506 gcc_assert (!SSA_NAME_ANTI_RANGE_P (name)); >

Re: [PATCH] Clear SSA_NAME_ANTI_RANGE_P when appropriate (PR tree-optimization/67821)

2015-10-05 Thread Marek Polacek
On Mon, Oct 05, 2015 at 04:08:05PM +0200, Richard Biener wrote: > On Mon, 5 Oct 2015, Marek Polacek wrote: > > > Here, we were crashing on an assert in duplicate_ssa_name_range_info: > > > > 506 gcc_assert (!SSA_NAME_ANTI_RANGE_P (name)); > > > > The problem is that reset_flow_sensitive_info w

Re: [PR other/65021] mkoffloads -save-temps handling, and cleanup cleanup

2015-10-05 Thread Thomas Schwinge
Hi Bernd! On Mon, 5 Oct 2015 14:12:06 +0200, Bernd Schmidt wrote: > On 10/05/2015 12:04 PM, Thomas Schwinge wrote: > > In a similar vein to the earlier patch to "Pass on the verbose flag "-v" > > to/in the mkoffloads", here is a patch to make the mkoffloads handle > > "-save-temps", and this patc

Re: [patch 0/3] Header file reduction.

2015-10-05 Thread Richard Biener
On Mon, Oct 5, 2015 at 3:27 PM, Bernd Schmidt wrote: > On 10/02/2015 04:22 AM, Andrew MacLeod wrote: >> >> The patches are generated by a pair of tools. >> * gcc-order-includes goes through the headers and canonically reorders >> some of our more common/troublesome headers and removes any duplicat

Re: [PATCH] Clear SSA_NAME_ANTI_RANGE_P when appropriate (PR tree-optimization/67821)

2015-10-05 Thread Richard Biener
On Mon, 5 Oct 2015, Marek Polacek wrote: > Here, we were crashing on an assert in duplicate_ssa_name_range_info: > > 506 gcc_assert (!SSA_NAME_ANTI_RANGE_P (name)); > > The problem is that reset_flow_sensitive_info wasn't clearing the > SSA_NAME_ANTI_RANGE_P flag; I don't think NULL SSA_NAME_R

Re: [patch 0/3] Header file reduction.

2015-10-05 Thread Bernd Schmidt
On 10/02/2015 04:22 AM, Andrew MacLeod wrote: The patches are generated by a pair of tools. * gcc-order-includes goes through the headers and canonically reorders some of our more common/troublesome headers and removes any duplicates. This includes headers which are included by other headers.

[PATCH] Clear SSA_NAME_ANTI_RANGE_P when appropriate (PR tree-optimization/67821)

2015-10-05 Thread Marek Polacek
Here, we were crashing on an assert in duplicate_ssa_name_range_info: 506 gcc_assert (!SSA_NAME_ANTI_RANGE_P (name)); The problem is that reset_flow_sensitive_info wasn't clearing the SSA_NAME_ANTI_RANGE_P flag; I don't think NULL SSA_NAME_RANGE_INFO can ever describe an anti-range... Bootstra

Re: C PATCH for c/65345 (file-scope _Atomic expansion with floats)

2015-10-05 Thread Marek Polacek
On Sat, Oct 03, 2015 at 08:58:19PM -0400, David Edelsohn wrote: > The bug was not x86-specific. The fix happens to be in > target-specific code, but that's the luck of the draw. Numerous other > GCC developers have fixed bugs or added features that required tweaks > to all ports. Not all targets

Re: [AArch64] [TLSIE][2/2] Implement TLS IE for tiny model

2015-10-05 Thread Jiong Wang
James Greenhalgh writes: > Hi Jiong, > > I was looking at another bug and in the process of auditing our code > spotted an issue with this patch from back in June... > > On Fri, Jun 19, 2015 at 10:15:38AM +0100, Jiong Wang wrote: >> diff --git a/gcc/config/aarch64/aarch64.md b/gcc/config/aarch64/

Re: [PATCH] Unswitching outer loops.

2015-10-05 Thread Yuri Rumyantsev
Thanks Richard. I'd like to answer on your last comment related to using of exit edge argument for edge that skips loop. Let's consider the following test-case: #include #define N 32 float *foo(int ustride, int size, float *src) { float *buffer, *p; int i, k; if (!src) return NULL;

Re: Do not use TYPE_CANONICAL in useless_type_conversion

2015-10-05 Thread Bernd Schmidt
+ /* For aggregates compare only the size and mode. Accesses to fields do have + a type information by themselves and thus we only care if we can i.e. + use the types in move operations. */ else if (AGGREGATE_TYPE_P (inner_type) && TREE_CODE (inner_type) == TREE_CODE (out

Re: [PATCH] Remove restriction for remote testing

2015-10-05 Thread Bernd Schmidt
On 10/05/2015 02:00 PM, James Norris wrote: Ping. As I said previously, I think appending "-latomic" unconditionally in atomic_init is probably a better solution because I'm not convinced that the things atomic_link_flags does are appropriate in a remote host situation. Bernd

Re: [PR other/65021] mkoffloads -save-temps handling, and cleanup cleanup

2015-10-05 Thread Bernd Schmidt
On 10/05/2015 12:04 PM, Thomas Schwinge wrote: In a similar vein to the earlier patch to "Pass on the verbose flag "-v" to/in the mkoffloads", here is a patch to make the mkoffloads handle "-save-temps", and this patch also happens to address , "nvptx mkoffload doesn'

[PATCH 2/2][ARC] Add support for ARCv2 CPUs

2015-10-05 Thread Claudiu Zissulescu
Just realized this patch haven't went thru to the mailing list. Reposted. This patch adds basic support (libgcc) for Synopsys' ARCv2 CPUs. Can this be committed? Thanks, Claudiu ChangeLog: 2015-08-28 Claudiu Zissulescu * config/arc/dp-hack.h: Add support for ARCHS.

Re: [PATCH] Remove restriction for remote testing

2015-10-05 Thread James Norris
Ping. On 09/28/2015 07:35 AM, James Norris wrote: Hi, The attached patch fixes a problem when doing remote testing. Specifically, testing of the atomic tests found in gcc/atomic. The code in atomic_init precludes the setting of the variable 'link_flags' when doing remote testing. The conditiona

Re: [PATCH] SH FDPIC backend support

2015-10-05 Thread Oleg Endo
On Sun, 2015-10-04 at 22:16 -0400, Rich Felker wrote: > This is FDPIC-specific. Because there is fundamentally no way for a > function to find its own GOT (it has one GOT for each process using > the code containing the function), its GOT address has to be a > (hidden) argument to the function whic

Re: [AArch64] [TLSIE][2/2] Implement TLS IE for tiny model

2015-10-05 Thread James Greenhalgh
Hi Jiong, I was looking at another bug and in the process of auditing our code spotted an issue with this patch from back in June... On Fri, Jun 19, 2015 at 10:15:38AM +0100, Jiong Wang wrote: > diff --git a/gcc/config/aarch64/aarch64.md b/gcc/config/aarch64/aarch64.md > index 8b061ba..be9da5b 10

Re: [PATCH] Fix PR67783, quadraticness in IPA inline analysis

2015-10-05 Thread Richard Biener
On Thu, 1 Oct 2015, Richard Biener wrote: > > The following avoids quadraticness in the loop depth by only considering > loop header defs as IVs for the analysis of the loop_stride predicate. > This will miss cases like > > foo (int inv) > { > for (i = inv; i < n; ++i) > { > int derived_i

Re: [PATCH] Remove gimplifier use from PRE

2015-10-05 Thread Richard Biener
On Thu, 1 Oct 2015, Richard Biener wrote: > > The following patch from the match-and-simplify branch removes > gimplifier use from PRE replacing it with use of the gimple_build API > building GIMPLE directly. > > Bootstrapped on x86_64-unknown-linux-gnu, testing in progress. The 5th (or so) ref

[Patch ARM/ AArch64] Fix typo in vcvt_f16.c testcase .

2015-10-05 Thread Ramana Radhakrishnan
Hi, This test worked by accident. While looking at why this was failing randomly in my builds for arm-none-eabi, I discovered a bug in the way in which the testcases were written up in this case. Tested on arm-none-eabi cross fixing the issues that I was seeing with this test. Applied to trun

Re: Remove REAL_VALUE_FROM_CONST_DOUBLE

2015-10-05 Thread Richard Biener
On Mon, Oct 5, 2015 at 12:47 PM, Richard Sandiford wrote: > To maintain symmetry after the previous removal of > CONST_DOUBLE_FROM_REAL_VALUE, this patch also gets rid of > REAL_VALUE_FROM_CONST_DOUBLE. All the macro did was copy the > contents of CONST_DOUBLE_REAL_VALUE into a temporary real_val

Re: using scratchpads to enhance RTL-level if-conversion: the new patch now passes bootstrap with the default BUILD_CONFIG [i.e. no stage2-to-stage3 comparison errors even with debugging info off in s

2015-10-05 Thread Bernd Schmidt
This is currently not really reviewable due to broken indentation, possibly due to whitespace damage from your mailer or not following coding guidelines. Please ensure your code is formatted the same way as all other code in gcc. I'll point out some of the problems, but please investigate ht

Re: Remove remaining uses of CONST_DOUBLE_FROM_REAL_VALUE

2015-10-05 Thread Richard Biener
On Mon, Oct 5, 2015 at 12:45 PM, Richard Sandiford wrote: > This patch replaces all uses of CONST_DOUBLE_FROM_REAL_VALUE > with the already-existing const_double_from_real_value. > > Bootstrapped & regression-tested on x86_64-linux-gnu. Also tested by > building one target per CPU directory and c

Re: Remove remaining uses of REAL_ARITHMETIC

2015-10-05 Thread Richard Biener
On Mon, Oct 5, 2015 at 12:44 PM, Richard Sandiford wrote: > This patch replaces all remaining uses of the old target macro > REAL_ARITHMETIC with calls to the (now generic) real_arithmetic > function. > > Bootstrapped & regression-tested on x86_64-linux-gnu. Also tested by > building one target p

  1   2   >