Re: [PATCH] rs6000: Testcases for rl*i*

2016-11-25 Thread David Edelsohn
On Fri, Nov 25, 2016 at 8:51 PM, Segher Boessenkool wrote: > These testcases test that we generate the expected code for all of the > rl*i* instructions, that is, rotate-and-mask and rotate-and-mask-insert > for immediate rotation counts. All the testcases do rotate, shift left, > as well as shif

[PATCH] rs6000: Testcases for rl*i*

2016-11-25 Thread Segher Boessenkool
These testcases test that we generate the expected code for all of the rl*i* instructions, that is, rotate-and-mask and rotate-and-mask-insert for immediate rotation counts. All the testcases do rotate, shift left, as well as shift right; if that results in an instruction that does not exist the t

Re: [PATCH 3/9] Add option -moutline-msabi-xlogues

2016-11-25 Thread Daniel Santos
Thank you very much for your review! On 11/25/2016 05:51 PM, Sandra Loosemore wrote: On 11/22/2016 10:19 PM, Daniel Santos wrote: diff --git a/gcc/config/i386/i386.opt b/gcc/config/i386/i386.opt index 9eef558..f556978 100644 --- a/gcc/config/i386/i386.opt +++ b/gcc/config/i386/i386.opt @@ -528

Re: [PATCH 3/9] Add option -moutline-msabi-xlogues

2016-11-25 Thread Sandra Loosemore
On 11/22/2016 10:19 PM, Daniel Santos wrote: diff --git a/gcc/config/i386/i386.opt b/gcc/config/i386/i386.opt index 9eef558..f556978 100644 --- a/gcc/config/i386/i386.opt +++ b/gcc/config/i386/i386.opt @@ -528,6 +528,11 @@ Enum(calling_abi) String(sysv) Value(SYSV_ABI) EnumValue Enum(calling

Re: [PATCH] avoid calling alloca(0)

2016-11-25 Thread Jeff Law
On 11/23/2016 06:15 PM, Martin Sebor wrote: gcc_assert works only in some instances (e.g., in c-ada-spec.c:191) but not in others because some actually do make the alloca(0) call at runtime: at a minimum, lto.c:3285, reg-stack.c:2008, and tree-ssa-threadedge.c:344 assert during bootstrap. You mi

Re: [PATCH] avoid calling alloca(0)

2016-11-25 Thread Jeff Law
On 11/24/2016 12:42 AM, Jakub Jelinek wrote: After reviewing a few more of the XALLOCAVEC calls in the affected files I suspect that those to alloca(0) pointed out by the warning may be just a subset that GCC happens to see thanks to constant propagation. If that's so then changing this subset t

Re: Pointer Bounds Checker and trailing arrays (PR68270)

2016-11-25 Thread Ilya Enkovich
2016-11-25 15:47 GMT+03:00 Alexander Ivchenko : > Hi, > > The patch below addresses PR68270. could you please take a look? > > 2016-11-25 Alexander Ivchenko > >* c-family/c.opt (flag_chkp_flexible_struct_trailing_arrays): >Add new option. >* tree-chkp.c (chkp_parse_array_

[PATCH, fortran, committed] Fix documentation typo

2016-11-25 Thread Janne Blomqvist
Hi, committed the following as obvious: Index: ChangeLog === --- ChangeLog (revision 242883) +++ ChangeLog (working copy) @@ -1,3 +1,8 @@ +2016-11-25 Janne Blomqvist + + * intrinsic.texi: Fix ptrdiff_t typo in ISO_C_BIND

Hurd port for gcc go PATCH 19-23(23)

2016-11-25 Thread Svante Signell
* src_libgo_runtime_netpoll.goc.diff: Fix restricted word bug.   Rename variable errno to errno1. * src_libgo_go_os_os_test.go.diff: Allow EFBIG return code to big seeks. * src_libgo_go_syscall_syscall_gnu_test.go: New file:   Define Type and Whence as 32bit in syscall.Flock_t * src_libgo_testsuite

Hurd port for gcc go PATCH 11-18(23)

2016-11-25 Thread Svante Signell
* src_libgo_go_net_sendfile_gnu.go.diff: New file * src_libgo_go_net_sock_gnu.go.diff: New file * src_libgo_go_net_sockopt_gnu.go.diff: New file * src_libgo_go_net_sockoptip_gnu.go.diff: New file * src_libgo_go_syscall_libcall_gnu_386.go.diff: New file * src_libgo_go_syscall_libcall_gnu.go.diff: Ne

Hurd port for gcc go PATCH 1-4(23)

2016-11-25 Thread Svante Signell
Hi, Attached are patches to enable gccgo to build properly on Debian GNU/Hurd on gcc-6 (6-6.2.1-5). The first three patches are Debian-specific: * debian_rules.defs.diff: Enables build of gccgo for GNU/Hurd Define patches for the generated series file: * debian_rules.patch.diff:  Enables split-

Hurd port for gcc go PATCH 5-10(23)

2016-11-25 Thread Svante Signell
* src_libgo_configure.ac.diff: Define GOOS=gnu and LIBGO_IS_GNU * src_libgo_Makefile.am.diff: Add support for GNU/Hurd. * src_libgo_Makefile.in.diff: Update accordingly with autreconf2.64 * src_libgo_mksysinfo.sh.diff: Define SYS_IOCTL to 0 if not defined,  Fix: #define EWOULDBLOCK EAGAIN in  Fix:

Re: [PATCH] avoid calling alloca(0)

2016-11-25 Thread Jeff Law
On 11/24/2016 12:47 AM, Jakub Jelinek wrote: On Wed, Nov 23, 2016 at 02:27:05PM -0700, Jeff Law wrote: I believe we should be warning on trying to allocation 0 bytes of memory via malloc, realloc or alloca, with the exception of a non-builtin alloca with no return value, but I think we've covere

[PATCH] Optimiza aggregate a = b = c = {} (PR c/78408)

2016-11-25 Thread Jakub Jelinek
Hi! This patch optimizes a = {}; b = a; into a = {}; b = {}; and similarly for memset instead of the first stmt and/or memcpy instead of the second one. Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? 2016-11-25 Jakub Jelinek PR c/78408 * tree-ssa-ccp.c:

[committed] Add 2 tests

2016-11-25 Thread Jakub Jelinek
Hi! In order to close these 2 PRs fixed recently by Segher, I've added the corresponding tests and am going to close them as fixed. 2016-11-25 Jakub Jelinek PR rtl-optimization/78438 PR rtl-optimization/78477 * gcc.c-torture/execute/pr78438.c: New test. * gcc.c

Re: [PATCH] Fix ICE on CONST_WIDE_INT in simplify_immed_subreg (PR rtl-optimization/78526)

2016-11-25 Thread Jakub Jelinek
On Fri, Nov 25, 2016 at 06:50:17PM +, Richard Sandiford wrote: > I think this is still wrong for modes that are wide enough to use > CONST_WIDE_INT but aren't a multiple of a HWI in size. In that The loop iterates by value_bit, which is 8 bits. Thus, indeed, it will misbehave if there is a C

Re: [PATCH] Fix ICE on CONST_WIDE_INT in simplify_immed_subreg (PR rtl-optimization/78526)

2016-11-25 Thread Richard Sandiford
Jakub Jelinek writes: > Hi! > > If we try to simplify a paradoxical subreg of a CONST_WIDE_INT, > we can ICE, because wi::extract_uhwi doesn't like accessing > bytes beyond the precision. > for (i = 0; i < elem_bitsize; i += value_bit) > *vp++ = wi::extract_uhwi (val, i, value_bit); > for

Re: [patch,avr]: Improve code as of PR41076

2016-11-25 Thread Denis Chertykov
2016-11-25 18:34 GMT+03:00 Georg-Johann Lay : > Mentioned PR is about composing 16-bit values out of 8-bit values which due > to integer promotions likes to work on 16-bit values. > > The patch adds 3 combiner patterns to catch such situations and then split > after reload. Some more splitting is

Re: Ping: Re: [patch, avr] Add flash size to device info and make wrap around default

2016-11-25 Thread Denis Chertykov
I'm sorry for delay. I have a problem with the patch: (Stripping trailing CRs from patch; use --binary to disable.) patching file avr-arch.h (Stripping trailing CRs from patch; use --binary to disable.) patching file avr-devices.c (Stripping trailing CRs from patch; use --binary to disable.) patch

one more patch for PR77541

2016-11-25 Thread Vladimir N Makarov
Uros pointed me out that I should use another target for the PR test. Here is the patch committed as rev. 242881. 2016-11-25 Vladimir Makarov PR rtl-optimization/77541 * gcc.target/i386/pr77541.c: Change target to int128. Index: gcc.target/i386/pr77541.c ===

Re: [PATCH v2] aarch64: Add split-stack initial support

2016-11-25 Thread Adhemerval Zanella
On 15/11/2016 16:38, Wilco Dijkstra wrote: > > On 07/11/2016 16:59, Adhemerval Zanella wrote: >> On 14/10/2016 15:59, Wilco Dijkstra wrote: > >> There is no limit afaik on gold split stack allocation handling, >> and I think one could be added for each backend (in the method >> override require

[PATCH] Fix ICE on CONST_WIDE_INT in simplify_immed_subreg (PR rtl-optimization/78526)

2016-11-25 Thread Jakub Jelinek
Hi! If we try to simplify a paradoxical subreg of a CONST_WIDE_INT, we can ICE, because wi::extract_uhwi doesn't like accessing bytes beyond the precision. for (i = 0; i < elem_bitsize; i += value_bit) *vp++ = wi::extract_uhwi (val, i, value_bit); for (; i < elem_bitsize; i += value_bit)

[C++ PATCH] Fix ICE with scoped enums and -g (PR c++/72808)

2016-11-25 Thread Jakub Jelinek
Hi! As mentioned in the PR, we ICE during type verification called from dwarf2out, because a class has different TYPE_FIELDS from its variants. In particular it contains an extra CONST_DECL. While CONST_DECLs are ignored for C/C++ in dwarf2out.c, I think they aren't ignored for Fortran/Ada, so ign

[PATCH] Fix -fcompare-debug issues in IPA-ICF (PR lto/78211)

2016-11-25 Thread Jakub Jelinek
Hi! IPA-ICF performs some code-generation visible changes from hash table traversal, where the hash values can be different between -g and -g0 (I bet it hashes DECL_UID in somewhere, perhaps other things). The following patch fixes it by adding a vector next to the hash table, which tracks the gro

Re: [Patch, Fortran, OOP] PR 60853: Failure to disambiguate generic with unlimited polymorphic

2016-11-25 Thread Janus Weil
Hi Paul, > This looks fine to me - OK for trunk. thanks a lot. Committed as r242880. Cheers, Janus > On 25 November 2016 at 13:40, Janus Weil wrote: >> Hi all, >> >> here is a patch that fixes a rejects-valid problem with an >> unlimited-polymorphic variable in a generic procedure. Removing

[PATCH] Fix a couple of issues in gimple-ssa-sprintf.c

2016-11-25 Thread Jakub Jelinek
Hi! Here is an attempt to fix a couple of bugs in gimple-ssa-sprintf.c. First of all, it assumes size_t is always the same as uintmax_t, which is not necessarily the case. Second, it uses static tree {,u}intmax_type_node; variables for caching those types, but doesn't register them with GC; but th

[committed] Fix combine ICE with out of bounds shift (PR rtl-optimization/78527)

2016-11-25 Thread Jakub Jelinek
Hi! The following testcase ICEs in the combiner, because we try to optimize HImode SUBREG of SImode LSHIFTRT with shift count 80, so width is -48, and in the end we call smallest_mode_for_size (-48, MODE_INT) and that function has unsigned int as first argument; most of the ports don't have modes

Re: [Patch, Fortran, OOP] PR 60853: Failure to disambiguate generic with unlimited polymorphic

2016-11-25 Thread Paul Richard Thomas
Dear Janus, This looks fine to me - OK for trunk. Best regards and thanks Paul On 25 November 2016 at 13:40, Janus Weil wrote: > Hi all, > > here is a patch that fixes a rejects-valid problem with an > unlimited-polymorphic variable in a generic procedure. Removing the > line with UNLIMITED_PO

Re: [PATCH] (v2) Add a "compact" mode to print_rtx_function

2016-11-25 Thread Dominik Vogt
On Tue, Nov 22, 2016 at 10:38:42AM -0500, David Malcolm wrote: > On Tue, 2016-11-22 at 15:45 +0100, Jakub Jelinek wrote: > > On Tue, Nov 22, 2016 at 03:38:04PM +0100, Bernd Schmidt wrote: > > > On 11/22/2016 02:37 PM, Jakub Jelinek wrote: > > > > Can't it be done only if xloc.file contains any fanc

RE: [AArch64][ARM][GCC][PATCHv2 3/3] Add tests for missing Poly64_t intrinsics to GCC

2016-11-25 Thread Tamar Christina
> > > A few comments about this new version: > > * arm-neon-ref.h: why do you create > CHECK_RESULTS_NAMED_NO_FP16_NO_POLY64? > > Can't you just add calls to CHECK_CRYPTO in the existing > > CHECK_RESULTS_NAMED_NO_FP16? Yes, that should be fine, I didn't used to have CHECK_CRYPTO before and when

Re: [0/3] Fix PR78120, in ifcvt/rtlanal/i386.

2016-11-25 Thread Segher Boessenkool
On Fri, Nov 25, 2016 at 10:15:25AM +0100, Richard Biener wrote: > On Thu, Nov 24, 2016 at 5:14 PM, Segher Boessenkool > wrote: > > On Thu, Nov 24, 2016 at 08:48:04AM -0700, Jeff Law wrote: > >> On 11/24/2016 07:53 AM, Segher Boessenkool wrote: > >> > > >> >That we compare different kinds of costs

Re: [tree-tailcall] Check if function returns it's argument

2016-11-25 Thread Jeff Law
On 11/25/2016 01:07 AM, Richard Biener wrote: For the tail-call, issue should we artificially create a lhs and use that as return value (perhaps by a separate pass before tailcall) ? __builtin_memcpy (a1, a2, a3); return a1; gets transformed to: _1 = __builtin_memcpy (a1, a2, a3) return _1; S

[patch,avr]: Improve code as of PR41076

2016-11-25 Thread Georg-Johann Lay
Mentioned PR is about composing 16-bit values out of 8-bit values which due to integer promotions likes to work on 16-bit values. The patch adds 3 combiner patterns to catch such situations and then split after reload. Some more splitting is performed after reload for: and, ior, xor of reg-r

Re: [0/3] Fix PR78120, in ifcvt/rtlanal/i386.

2016-11-25 Thread Jeff Law
On 11/25/2016 02:15 AM, Richard Biener wrote: That's a good question ;) The stage 3 definition has a loophole via "go file a bug about feature X, then it's a bugfix!". Right. That loophole has existed since we've moved to the current model -- we extend a level of trust to our developers not t

Re: [AArch64][ARM][GCC][PATCHv2 3/3] Add tests for missing Poly64_t intrinsics to GCC

2016-11-25 Thread Christophe Lyon
On 25 November 2016 at 15:53, Christophe Lyon wrote: > Hi Tamar, > > On 24 November 2016 at 12:45, Tamar Christina wrote: >> Hi Christoph, >> >> I have combined most of the tests in p64_p128 except for the >> vreinterpret_p128 and vreinterpret_p64 ones because I felt the number >> of code that wo

Re: [AArch64][ARM][GCC][PATCHv2 3/3] Add tests for missing Poly64_t intrinsics to GCC

2016-11-25 Thread Christophe Lyon
Hi Tamar, On 24 November 2016 at 12:45, Tamar Christina wrote: > Hi Christoph, > > I have combined most of the tests in p64_p128 except for the > vreinterpret_p128 and vreinterpret_p64 ones because I felt the number > of code that would be have to be added to p64_p128 vs having them in those > fi

[OBVIOUS] [PATCH] Fix documentation reference (PR web/71666)

2016-11-25 Thread Martin Liška
The patch is selecting the proper section where -fprofile-generate is documented. Martin >From 00a7b92ef9bc7158a3e7202deb9b18b8d95dd5d2 Mon Sep 17 00:00:00 2001 From: marxin Date: Fri, 25 Nov 2016 15:11:48 +0100 Subject: [PATCH] Fix documentation reference (PR web/71666) gcc/ChangeLog: 2016-11

Re: [PATCH] Fix ICE with -Wuninitialized (PR tree-optimization/78455)

2016-11-25 Thread Andreas Schwab
On Nov 23 2016, Christophe Lyon wrote: > Since you committed this patch (r242733), I've noticed a regression: > gcc.dg/uninit-pred-6_c.c warning (test for warnings, line 43) > > now fails on some arm targets, for instance arm-none-linux-gnueabihf > --with-cpu=cortex-a5 --with-fpu=vfpv3-d16-fp16

Re: [PATCH] Fix PR78515

2016-11-25 Thread Richard Biener
On Fri, 25 Nov 2016, Martin Jambor wrote: > Hi, > > On Fri, Nov 25, 2016 at 12:01:38PM +0100, Richard Biener wrote: > > > > I am testing the following to beat some sanity into > > compute_complex_assign_jump_func. > > That the function does not handle ternary operations (did we have them > sin

Re: [PATCH] Tree-level fix for PR 69526

2016-11-25 Thread Richard Biener
On Wed, Nov 16, 2016 at 4:54 PM, Robin Dapp wrote: > Found some time to look into this again. > >> Index: tree-ssa-propagate.c >> === >> --- tree-ssa-propagate.c(revision 240133) >> +++ tree-ssa-propagate.c(working cop

Re: [PATCH] Fix PR78515

2016-11-25 Thread Martin Jambor
Hi, On Fri, Nov 25, 2016 at 12:01:38PM +0100, Richard Biener wrote: > > I am testing the following to beat some sanity into > compute_complex_assign_jump_func. That the function does not handle ternary operations (did we have them since the beginning?) is clearly my fault and the patch is fine.

Re: [PR 70965] Schedule extra pass_rebuild_cgraph_edges

2016-11-25 Thread Jan Hubicka
> On Thu, Nov 24, 2016 at 5:44 PM, Martin Jambor wrote: > > Hi, > > > > after discussing this with Honza, we have decided that scheduling an > > extra pass_rebuild_cgraph_edges after pass_fixup_cfg is the correct > > way to keep the cgraph consistent with gimple IL when early IPA passes > > need i

Pointer Bounds Checker and trailing arrays (PR68270)

2016-11-25 Thread Alexander Ivchenko
Hi, The patch below addresses PR68270. could you please take a look? 2016-11-25 Alexander Ivchenko * c-family/c.opt (flag_chkp_flexible_struct_trailing_arrays): Add new option. * tree-chkp.c (chkp_parse_array_and_component_ref): Forbid narrowing when chkp_parse_arr

[Patch, Fortran, OOP] PR 60853: Failure to disambiguate generic with unlimited polymorphic

2016-11-25 Thread Janus Weil
Hi all, here is a patch that fixes a rejects-valid problem with an unlimited-polymorphic variable in a generic procedure. Removing the line with UNLIMITED_POLY fixes the error and the rest of the patch is just slightly refactoring the for-loop. Regtested successfully on x86_64-linux-gnu. Ok for t

Re: [Patch, fortran] PR78293 - - [5/6/7 Regression] SIGABRT with function result used as argument

2016-11-25 Thread Paul Richard Thomas
Dear All, Since both Andre and I have taken a good look at this rather small patch, I decided to commit it as revision 242875. My movements are such that I will have to hold off on 5- and 6-branches until the week after next. Best regards Paul PS Andre, I wasn't trying to make you feel bad but

Re: [PATCH][GCC][PATCHv3] Improve fpclassify w.r.t IEEE like numbers in GIMPLE.

2016-11-25 Thread Tamar Christina
Hi Joseph, I have updated the patch with the changes, w.r.t to the formatting, there are tabs there that seem to be rendered at 4 spaces wide. In my editor setup at 8 spaces they are correct. Kind Regards, Tamar From: Joseph Myers Sent: Thursday, November

Re: [Patch, fortran] PR78293 - - [5/6/7 Regression] SIGABRT with function result used as argument

2016-11-25 Thread Andre Vehreschild
Hi Thomas, > Andre put me to shame with a devastatingly simple replacement for a > horribly complicated and wrong patch that I was getting into. I did not mean to. I happened to work in the same area and the PR's description rang a whole chorus of bells what might have been going wrong. > The pa

Re: [PATCH PR78507/PR78510]Fix two ICEs in pattern (cond (cmp (convert1? @1) @3) (convert2? @1) @2).

2016-11-25 Thread Richard Biener
On Fri, Nov 25, 2016 at 12:20 PM, Bin.Cheng wrote: > On Fri, Nov 25, 2016 at 8:23 AM, Richard Biener > wrote: >> On Thu, Nov 24, 2016 at 4:22 PM, Bin Cheng wrote: >>> Hi, >>> This patch fixes two issues in newly introduced pattern: (cond (cmp >>> (convert1? @1) @3) (convert2? @1) @2). >>> For P

Re: [PATCH, ARM] Further improve stack usage on sha512 (PR 77308)

2016-11-25 Thread Ramana Radhakrishnan
On Sun, Nov 6, 2016 at 2:18 PM, Bernd Edlinger wrote: > Hi! > > This improves the stack usage on the sha512 test case for the case > without hardware fpu and without iwmmxt by splitting all di-mode > patterns right while expanding which is similar to what the shift-pattern > does. It does nothing

Re: [PATCH PR78507/PR78510]Fix two ICEs in pattern (cond (cmp (convert1? @1) @3) (convert2? @1) @2).

2016-11-25 Thread Bin.Cheng
On Fri, Nov 25, 2016 at 8:23 AM, Richard Biener wrote: > On Thu, Nov 24, 2016 at 4:22 PM, Bin Cheng wrote: >> Hi, >> This patch fixes two issues in newly introduced pattern: (cond (cmp >> (convert1? @1) @3) (convert2? @1) @2). >> For PR78507, we need to check if from_type is INTEGRAL_TYPE_P expl

Re: [PATCH] combine: Convert subreg-of-lshiftrt to zero_extract properly (PR78390)

2016-11-25 Thread Paolo Bonzini
On 24/11/2016 15:01, Michael Matz wrote: >> > (set (reg:DI 69) >> > (zero_extract:DI (reg:DI 65 [ v_x ]) <- >> > (const_int 32 [0x20]) >> > (const_int 20 [0x14]))) > Hmm, this transformation (from v_x>>12 to zext(v_x,32,20) is only valid > when the top 20 bits of v_

[PATCH] Fix PR78515

2016-11-25 Thread Richard Biener
I am testing the following to beat some sanity into compute_complex_assign_jump_func. There's still that odd 'stmt2' hanging around that gets set to sth else than stmt with op1 = gimple_assign_rhs1 (stmt); if (TREE_CODE (op1) == SSA_NAME) { if (SSA_NAME_IS_DEFAULT_DEF (op1))

Re: [PATCH] Fix Ada bootstrap

2016-11-25 Thread Richard Biener
27;W'); > end record; > > begin > null; > end; > eric@polaris:~/build/gcc/native> gcc/gnat1 -quiet p.adb > +===GNAT BUG DETECTED==+ > | 7.0.0 20161125 (experimental) [trunk revision 242863] (x86_64-suse-linux) > GCC error:| > | in siz

Re: [PATCH] Don't use priority {cd}tors if not supported by a target (PR, gcov-profile/78086)

2016-11-25 Thread Jan Hubicka
> Hi. > > Using priority {cd}tors on a target that does not support that can cause > failures (see the PR). > Apart from that, I decided to use priority 100 for both gcov_init and > gcov_exit functions as > the reserved range includes priority 100. Moreover, I enhanced test-cases we > have. >

[AArch64][GCC][PATCH] Add more Poly64_t intrinsics to GCC

2016-11-25 Thread Tamar Christina
Hi all, This adds the following NEON intrinsics to the Aarch64 back-end of GCC: * vsriq_n_p64 * vsri_n_p64 * vextq_p64 * vext_p64 * vceq_p64 * vbslq_p64 * vbsl_p64 Added new tests for these and ran regression tests on aarch64-none-linux-gnu and on arm-none-linux-gnueabihf. Tests added in other p

Re: [PATCH] Fix Ada bootstrap

2016-11-25 Thread Eric Botcazou
.. 'Z'; type Arr is array (Char range <>) of Integer; type Rec (D : Char) is record A : Arr (D .. 'W'); end record; begin null; end; eric@polaris:~/build/gcc/native> gcc/gnat1 -quiet p.adb +===GNAT BUG DETECTED==

Re: [GCC][AArch64][PATCH][Testsuite] Fix failing test vector_initialization_nostack.c

2016-11-25 Thread James Greenhalgh
On Mon, Nov 07, 2016 at 02:05:27PM +, Tamar Christina wrote: > Hi all, > > This fixes (PR78142) by turning off scheduling for the test. > r241590 is causing more registers to be used and so > the SP registered happens to be picked and used. > > This test I believe was checking explicitly that

Re: [PATCH] Fix PR78343

2016-11-25 Thread Richard Biener
On Thu, 24 Nov 2016, Richard Biener wrote: > > I am testing the following patch for an optimization regression where > a loop made dead by final value replacement was made used again by > DOM 20 passes later. The real issue here is that we do not get rid > of dead loops until very late so this p

Re: [PATCH] Fix Ada bootstrap

2016-11-25 Thread Richard Biener
ll tests fail to link not finding the RTS. > +===GNAT BUG DETECTED==+ > | 7.0.0 20161125 (experimental) [trunk revision 242863] (x86_64-suse-linux) > GCC error:| > | in size_binop_loc, at fold-const.c:1744

Re: [PATCH] Fix Ada bootstrap

2016-11-25 Thread Martin Liška
On 11/25/2016 10:20 AM, Richard Biener wrote: > > Bootstrap and testing in progress. > > Richard. > > 2016-11-25 Richard Biener > > * gimple-fold.c (fold_stmt_1): Check may_propagate_copy > before valueizing return stmts. > > Index: gcc/gimple-fold.c > ==

Re: [PATCH] Fix Ada bootstrap

2016-11-25 Thread Eric Botcazou
ion (c41104a): +===GNAT BUG DETECTED==+ | 7.0.0 20161125 (experimental) [trunk revision 242863] (x86_64-suse-linux) GCC error:| | in size_binop_loc, at fold-const.c:1744 | | Error detected at c41104a.adb:60:33

[RFC PATCH, i386]: Separate operations with mask registers from operations with general registers

2016-11-25 Thread Uros Bizjak
Hello! Attached patch tries to fix the mess with operations where register allocator is free to use either mask or general registers. There are plenty of problems with this approach: a) missing operations wth general registers - kxnor operation with general register does not exist - kandn operatio

[PATCH] Fix Ada bootstrap

2016-11-25 Thread Richard Biener
Bootstrap and testing in progress. Richard. 2016-11-25 Richard Biener * gimple-fold.c (fold_stmt_1): Check may_propagate_copy before valueizing return stmts. Index: gcc/gimple-fold.c === --- gcc/gimple-fold.c

Re: change initialization of ptrdiff_type_node

2016-11-25 Thread Richard Biener
On Fri, 25 Nov 2016, Prathamesh Kulkarni wrote: > On 25 November 2016 at 13:43, Richard Biener wrote: > > On Fri, 25 Nov 2016, Jakub Jelinek wrote: > > > >> On Fri, Nov 25, 2016 at 01:28:06PM +0530, Prathamesh Kulkarni wrote: > >> > --- a/gcc/lto/lto-lang.c > >> > +++ b/gcc/lto/lto-lang.c > >> >

Re: [0/3] Fix PR78120, in ifcvt/rtlanal/i386.

2016-11-25 Thread Richard Biener
On Thu, Nov 24, 2016 at 5:14 PM, Segher Boessenkool wrote: > On Thu, Nov 24, 2016 at 08:48:04AM -0700, Jeff Law wrote: >> On 11/24/2016 07:53 AM, Segher Boessenkool wrote: >> > >> >That we compare different kinds of costs (which really has no meaning at >> >all, it's a heuristic at best) in variou

Re: change initialization of ptrdiff_type_node

2016-11-25 Thread Prathamesh Kulkarni
On 25 November 2016 at 13:43, Richard Biener wrote: > On Fri, 25 Nov 2016, Jakub Jelinek wrote: > >> On Fri, Nov 25, 2016 at 01:28:06PM +0530, Prathamesh Kulkarni wrote: >> > --- a/gcc/lto/lto-lang.c >> > +++ b/gcc/lto/lto-lang.c >> > @@ -1271,8 +1271,30 @@ lto_init (void) >> >gcc_assert (TYPE

Re: [Patch ARM 17/17] Enable _Float16 for ARM.

2016-11-25 Thread Christophe Lyon
Hi James, On 16 November 2016 at 15:15, Kyrill Tkachov wrote: > > On 11/11/16 15:42, James Greenhalgh wrote: >> >> Hi, >> >> Finally, having added support for single-step DFmode to HFmode >> conversions, >> this patch adds support for _Float16 to the ARM back-end. >> >> That means making sure th

Re: [PATCH v3] bb-reorder: Improve compgotos pass (PR71785)

2016-11-25 Thread Jakub Jelinek
On Sat, Nov 19, 2016 at 09:15:42PM +0100, Andreas Schwab wrote: > * gcc.c-torture/execute/comp-goto-1.c (insn_t): Change offset to > signed int. The same testcase is copied to gcc.dg/tree-prof/, just with extra dg- directives. Committed as obvious: 2016-11-25 Jakub Jelinek

Re: [PR 70965] Schedule extra pass_rebuild_cgraph_edges

2016-11-25 Thread Richard Biener
On Thu, Nov 24, 2016 at 5:44 PM, Martin Jambor wrote: > Hi, > > after discussing this with Honza, we have decided that scheduling an > extra pass_rebuild_cgraph_edges after pass_fixup_cfg is the correct > way to keep the cgraph consistent with gimple IL when early IPA passes > need it, such as is

Re: [tree-tailcall] Check if function returns it's argument

2016-11-25 Thread Prathamesh Kulkarni
On 25 November 2016 at 13:55, Richard Biener wrote: > On Fri, 25 Nov 2016, Prathamesh Kulkarni wrote: > >> On 25 November 2016 at 13:37, Richard Biener wrote: >> > On Fri, 25 Nov 2016, Prathamesh Kulkarni wrote: >> > >> >> On 24 November 2016 at 18:08, Richard Biener wrote: >> >> > On Thu, 24 No

Re: [PATCH 1/2 v3] PR77822

2016-11-25 Thread Dominik Vogt
On Thu, Nov 24, 2016 at 08:33:32AM -0700, Jeff Law wrote: > On 11/24/2016 02:59 AM, Dominik Vogt wrote: > >On Wed, Nov 23, 2016 at 01:22:31PM -0700, Jeff Law wrote: > >>> PR target/77822 > >>> * system.h (SIZE_POS_IN_RANGE): New. > >>OK. Though system.h seems like an unfortunate place. Would

Re: [PATCH 2/2 v3] PR77822

2016-11-25 Thread Dominik Vogt
On Mon, Nov 21, 2016 at 12:05:42PM +0100, Dominik Vogt wrote: > On Thu, Nov 17, 2016 at 04:54:17PM +0100, Dominik Vogt wrote: > > On Thu, Nov 17, 2016 at 04:53:03PM +0100, Dominik Vogt wrote: > > > The following two patches fix PR 77822 on s390x for gcc-7. As the > > > macro doing the argument ran

Re: [tree-tailcall] Check if function returns it's argument

2016-11-25 Thread Richard Biener
On Fri, 25 Nov 2016, Prathamesh Kulkarni wrote: > On 25 November 2016 at 13:37, Richard Biener wrote: > > On Fri, 25 Nov 2016, Prathamesh Kulkarni wrote: > > > >> On 24 November 2016 at 18:08, Richard Biener wrote: > >> > On Thu, 24 Nov 2016, Prathamesh Kulkarni wrote: > >> > > >> >> On 24 Novem

Re: [PATCH PR78507/PR78510]Fix two ICEs in pattern (cond (cmp (convert1? @1) @3) (convert2? @1) @2).

2016-11-25 Thread Richard Biener
On Thu, Nov 24, 2016 at 4:22 PM, Bin Cheng wrote: > Hi, > This patch fixes two issues in newly introduced pattern: (cond (cmp > (convert1? @1) @3) (convert2? @1) @2). > For PR78507, we need to check if from_type is INTEGRAL_TYPE_P explicitly, > this patch adds check for that. > Note we don't che

[Patch, testsuite] Fix bogus pr64427.c failure for avr

2016-11-25 Thread Senthil Kumar Selvaraj
The smaller int size for the avr target breaks the test's expectation on the number of iterations. The failure goes away if 32 bit ints are used in place of a plain int. Fix by conditionally typedef int32_t to __INT32_TYPE__ for targets with int size < 4, and then use int32_t everywher

Re: [tree-tailcall] Check if function returns it's argument

2016-11-25 Thread Prathamesh Kulkarni
On 25 November 2016 at 13:37, Richard Biener wrote: > On Fri, 25 Nov 2016, Prathamesh Kulkarni wrote: > >> On 24 November 2016 at 18:08, Richard Biener wrote: >> > On Thu, 24 Nov 2016, Prathamesh Kulkarni wrote: >> > >> >> On 24 November 2016 at 17:48, Richard Biener wrote: >> >> > On Thu, 24 No

Re: [PATCH] eliminate calls to snprintf(0, 0, ...) with known return value (pr78476)

2016-11-25 Thread Markus Trippelsdorf
On 2016.11.22 at 20:02 -0700, Martin Sebor wrote: > > gcc/ChangeLog: > > PR tree-optimization/78476 > * gimple-ssa-sprintf.c (struct pass_sprintf_length::call_info): > Add a member. > (handle_gimple_call): Adjust signature. > (try_substitute_return_value): Remove cal

Re: change initialization of ptrdiff_type_node

2016-11-25 Thread Richard Biener
On Fri, 25 Nov 2016, Jakub Jelinek wrote: > On Fri, Nov 25, 2016 at 01:28:06PM +0530, Prathamesh Kulkarni wrote: > > --- a/gcc/lto/lto-lang.c > > +++ b/gcc/lto/lto-lang.c > > @@ -1271,8 +1271,30 @@ lto_init (void) > >gcc_assert (TYPE_MAIN_VARIANT (const_tm_ptr_type_node) > > == const

[PATCH] remove invalid "tail +16c" in config/acx.m4

2016-11-25 Thread ma . jiang
Hi all, In "config/acx.m4", there are still some "tail +16c" which are invalid on POSIX systems. In my opinion, all "tail +16c" should be changed to "tail -c +16" directly, as most systems has accept the latter. And, to skip first 16 bytes, we should use "tail -c +17" instead of "tail -c

Re: [tree-tailcall] Check if function returns it's argument

2016-11-25 Thread Richard Biener
On Fri, 25 Nov 2016, Prathamesh Kulkarni wrote: > On 24 November 2016 at 18:08, Richard Biener wrote: > > On Thu, 24 Nov 2016, Prathamesh Kulkarni wrote: > > > >> On 24 November 2016 at 17:48, Richard Biener wrote: > >> > On Thu, 24 Nov 2016, Prathamesh Kulkarni wrote: > >> > > >> >> On 24 Novem

Re: change initialization of ptrdiff_type_node

2016-11-25 Thread Jakub Jelinek
On Fri, Nov 25, 2016 at 01:28:06PM +0530, Prathamesh Kulkarni wrote: > --- a/gcc/lto/lto-lang.c > +++ b/gcc/lto/lto-lang.c > @@ -1271,8 +1271,30 @@ lto_init (void) >gcc_assert (TYPE_MAIN_VARIANT (const_tm_ptr_type_node) > == const_ptr_type_node); > > - ptrdiff_type_node = integer

Re: [Patch, tentative] Use MOVE_MAX_PIECES instead of MOVE_MAX in gimple_fold_builtin_memory_op

2016-11-25 Thread Richard Biener
On Thu, 24 Nov 2016, Senthil Kumar Selvaraj wrote: > > Richard Biener writes: > > > On Thu, 24 Nov 2016, Richard Biener wrote: > > > >> On Thu, 24 Nov 2016, Senthil Kumar Selvaraj wrote: > >> > >> > Hi, > >> > > >> > I've been analyzing a failing regtest (gcc.dg/strlenopt-8.c) for the > >>