Re: [PATCH] Fix for PR/62089 (enable missing Asan checks)

2014-08-13 Thread Yury Gribov
On 08/14/2014 09:46 AM, Yury Gribov wrote: Something like this? Forgot to mention: full tested the new patch on x64 (bootstrap, regtest, Asan-bootstrap).

Re: [PATCH] Fix for PR/62089 (enable missing Asan checks)

2014-08-13 Thread Yury Gribov
On 08/13/2014 02:13 PM, Jakub Jelinek wrote: I wonder if we just shouldn't handle COMPONENT_REFs with DECL_BIT_FIELD_REPRESENTATIVE that way unconditionally. So, do the if (TREE_CODE (t) == COMPONENT_REF ... before the other checks, and else if (bitpos % BITS_PER_UNIT || bitsize != size_in_byt

Re: [PATCH] Don't set dir prefix twice (PR middle-end/60484)

2014-08-13 Thread Joey Ye
PR60484 is marked as 4.7/4.8 regression and it is reported against 4.8 recently by an user. OK backporting to 4.7/4.8? - Joey On Sat, Mar 15, 2014 at 1:43 AM, Joseph S. Myers wrote: > On Fri, 14 Mar 2014, Marek Polacek wrote: > >> This patch makes sure that we set the directory prefix of >> dum

[Committed] [PATCH, ARM] Set max_insns_skipped to MAX_INSN_PER_IT_BLOCK when optimize_size for THUMB2

2014-08-13 Thread Zhenqiang Chen
On 13 August 2014 20:29, Richard Earnshaw wrote: > On 25/02/14 09:34, Zhenqiang Chen wrote: >> Hi, >> >> Current value for max_insns_skipped is 6. For THUMB2, it needs 2 (IF-THEN) >> or 3 (IF-THEN-ELSE) IT blocks to hold all the instructions. The overhead of >> IT is 4 or 6 BYTES. >> >> If we do n

RE: [PATCH, C/C++] Add -fno-float to forbid floating point data types

2014-08-13 Thread Thomas Preud'homme
> From: Marek Polacek [mailto:pola...@redhat.com] > Sent: Tuesday, August 12, 2014 5:43 PM > On Tue, Aug 12, 2014 at 11:34:35AM +0200, Jakub Jelinek wrote: > > > > This looks wrong. c_token_starts_typename is just a function which tells > > you if certain token can start a typename, issuing diagno

[GOOGLE] Fix the bug where implicit section names prevents function splitting

2014-08-13 Thread Yi Yang
This bug is caused by my last patch, which did not differentiate between explicit section names (via attributes) and implicit section names (via -ffunction-section). This patch fixes that. -- diff --git gcc/bb-reorder.c gcc/bb-reorder.c index 8f8c420..2115b01 100644 --- gcc/bb-reorder.c +++ gcc/

Re: [PATCH] Fix find_inc in the scheduler (PR target/62025)

2014-08-13 Thread Bernd Schmidt
On 08/12/2014 09:35 PM, Jakub Jelinek wrote: As detailed in the PR, find_inc ignored any possible clobbers on inc_insn (typically %cc/flags/etc. register) and thus we could ignore all register dependencies between mem_insn and inc_insn even when we could only safely ignore the mem_reg0 register d

Re: [PATCH 124/236] PHASE 3: Per-config subdir commits

2014-08-13 Thread Jeff Law
On 08/06/14 11:21, David Malcolm wrote: / * rtx-classes-status.txt: Update --- rtx-classes-status.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rtx-classes-status.txt b/rtx-classes-status.txt index e350eaf..b22cb1e 100644 --- a/rtx-classes-status.txt +++ b

Re: [PATCH 012/236] Convert DF_REF_INSN to a function for now

2014-08-13 Thread Jeff Law
On 08/13/14 18:11, David Malcolm wrote: On Wed, 2014-08-13 at 14:34 -0600, Jeff Law wrote: On 08/13/14 14:28, David Malcolm wrote: Thanks. Although this function gets converted back to a macro in patch 191, I just realized that in the meantime that it's not inlined, as is the case for some of

[PATCH, ira] Miss checks in split_live_ranges_for_shrink_wrap

2014-08-13 Thread Zhenqiang Chen
Hi, Function split_live_ranges_for_shrink_wrap has code if (!flag_shrink_wrap) return false; But flag_shrink_wrap is TRUE by default when optimize > 0 even if the port does not support shrink-wrap. To make sure shrink-wrap is enabled, "HAVE_simple_return" must be defined and "HAVE_simple_r

Re: [PATCH 109/236] resource.c: Use rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:21, David Malcolm wrote: gcc/ * resource.c (next_insn_no_annul): Strengthen local "next" from rtx to rtx_insn *. (mark_referenced_resources): Likewise for local "insn". --- gcc/resource.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) OK. As

Re: [PATCH 108/236] reload: Use rtx_insn (also touches caller-save.c and config/arc/arc)

2014-08-13 Thread Jeff Law
On 08/06/14 11:21, David Malcolm wrote: gcc/ * reload.h (struct insn_chain): Strengthen field "insn" from rtx to rtx_insn *. (find_reloads): Likewise for param 1. (subst_reloads): Likewise for sole param. (find_equiv_reg): Likwise for param 2. (regn

Re: [PATCH] microblaze: microblaze.md: Use 'SI' instead of 'VOID' for operand 1 of 'call_value_intern'

2014-08-13 Thread Chen Gang
On 8/14/14 10:14, Michael Eager wrote: >> OK, thanks, and I shall analyze it, but excuse me, I have to do other >> things this week, so hope I can finish it within next week (2014-08-24). >> If this time point is too long to bare, please let me know. > > Take your time and let me know when you hav

Re: [PATCH] microblaze: microblaze.md: Use 'SI' instead of 'VOID' for operand 1 of 'call_value_intern'

2014-08-13 Thread Michael Eager
On 08/13/14 18:35, Chen Gang wrote: Firstly, thank you very much for spending your time resource on the related 2 patches. You're welcome. On 8/13/14 23:10, Michael Eager wrote: On 07/06/14 03:26, Chen Gang wrote: * microblaze/mocroblaze.md (call_value_intern): Use 'SI' instead of

Re: [PATCH mips] Pass -msoft-float/-mhard-float flags to GAS

2014-08-13 Thread Eric Christopher
On Tue, Aug 12, 2014 at 2:07 AM, Matthew Fortune wrote: > Eric Christopher writes: >> On Sat, Aug 9, 2014 at 12:00 PM, Matthew Fortune >> wrote: >> > Moore, Catherine writes: >> >> > -Original Message- >> >> > From: Steve Ellcey [mailto:sell...@mips.com] >> >> > Sent: Friday, August 08,

Re: [c++-concepts] explicit instantiation and specialization

2014-08-13 Thread Andrew Sutton
Ah... sorry. Leftovers. I didn't have time to run a full bootstrap build before heading out for a few days. I'll try to get those out tomorrow afternoon-ish. Andrew On Wed, Aug 13, 2014 at 9:13 PM, Ed Smith-Rowland <3dw...@verizon.net> wrote: > I get build fail: > > ../../gcc_concepts/gcc/cp/cal

Re: [PATCH] microblaze: microblaze.md: Use 'SI' instead of 'VOID' for operand 1 of 'call_value_intern'

2014-08-13 Thread Chen Gang
Firstly, thank you very much for spending your time resource on the related 2 patches. On 8/13/14 23:10, Michael Eager wrote: > On 07/06/14 03:26, Chen Gang wrote: >> >>* microblaze/mocroblaze.md (call_value_intern): Use 'SI' instead of >>'VOID' for operand 1, just like 'call_internal1' h

Re: [c++-concepts] explicit instantiation and specialization

2014-08-13 Thread Ed Smith-Rowland
I get build fail: ../../gcc_concepts/gcc/cp/call.c:8793:8: error: unused variable ‘m1’ [-Werror=unused-variable] tree m1 = get_temploid (cand1); ^ ../../gcc_concepts/gcc/cp/call.c:8794:8: error: unused variable ‘m2’ [-Werror=unused-variable] tree m2 = get_temploid (cand2);

Re: [C++ PATCH] PR c++/62101

2014-08-13 Thread Ville Voutilainen
On 14 August 2014 03:41, Jason Merrill wrote: > On 08/13/2014 07:06 PM, Ville Voutilainen wrote: > > Looks good, but > >> + int friendp = 0; > > > Let's declare friendp when it's initialized. > > And I still need a ChangeLog entry. Ok, modified patch attached. The changelog entry was attached to

Re: [C++ PATCH] PR c++/62101

2014-08-13 Thread Jason Merrill
On 08/13/2014 07:06 PM, Ville Voutilainen wrote: Looks good, but + int friendp = 0; Let's declare friendp when it's initialized. And I still need a ChangeLog entry. Jason

Re: [PATCH 000/236] Introduce rtx subclasses

2014-08-13 Thread David Malcolm
On Wed, 2014-08-06 at 13:19 -0400, David Malcolm wrote: > This is the patch series I spoke about at Cauldron in the talk > "A proposal for typesafe RTL"; slides here: > http://dmalcolm.fedorapeople.org/presentations/cauldron-2014/rtl > > They can also be seen at: > https://dmalcolm.fedorapeople.or

Re: [PATCH 012/236] Convert DF_REF_INSN to a function for now

2014-08-13 Thread David Malcolm
On Wed, 2014-08-13 at 14:34 -0600, Jeff Law wrote: > On 08/13/14 14:28, David Malcolm wrote: > > Thanks. Although this function gets converted back to a macro in patch > > 191, I just realized that in the meantime that it's not inlined, as is > > the case for some of the other macro->function conv

Re: [PATCH] Fix find_inc in the scheduler (take 2, PR target/62025)

2014-08-13 Thread Vladimir Makarov
On 2014-08-13, 6:30 PM, Jakub Jelinek wrote: On Tue, Aug 12, 2014 at 05:12:41PM -0400, Vladimir Makarov wrote: On 08/12/2014 03:35 PM, Jakub Jelinek wrote: Hi! As detailed in the PR, find_inc ignored any possible clobbers on inc_insn (typically %cc/flags/etc. register) and thus we could ignore

[PATCH,rs6000] Add pass to optimize away xxpermdi's from vector computations

2014-08-13 Thread Bill Schmidt
Hi, This patch adds a PowerPC-specific pass just prior to the first cse RTL pass. The pass runs only when generating little-endian code for Power8 with VSX enabled, and for -O1 and up. For this particular subtarget, the use of the big-endian-biased vector load and store instructions requires per

[C++ PATCH] PR c++/62101

2014-08-13 Thread Ville Voutilainen
We didn't allow deleted friend definitions, because that was diagnosed in grokdeclarator, which doesn't have knowledge of the kind of a function declaration "initializer". Move the test to grokfield and adjust where necessary. Tested on Linux x86-64. diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c index

[PATCH] Make web_entry subclassable

2014-08-13 Thread Bill Schmidt
Hi, I want to reuse some of the infrastructure in web.c (and df.h) for a target-specific RTL pass, particularly the union-find stuff. I could just copy it, I suppose, but it seems better to make the struct web_entry into a class so that I can inherit what I need. That's what this patch does. Wh

Re: __intN patch 3/5: main __int128 -> __intN conversion.

2014-08-13 Thread DJ Delorie
> A while ago I've removed a couple of those 'typedef struct' things, as > they are not required in C++ anymore. Is there any particular reason > why this couldn't be simply 'struct int_n_data_t' ? No particular reason.

Go patch committed: Fix unexpected GC interfering with closure passing

2014-08-13 Thread Ian Lance Taylor
The Go frontend passes closures through to functions using the functions __go_set_closure and __go_get_closure. The expectation is that there are no function calls between set_closure and get_closure. However, it turns out that there can be function calls if some of the function arguments require

[PATCH] Fix find_inc in the scheduler (take 2, PR target/62025)

2014-08-13 Thread Jakub Jelinek
On Tue, Aug 12, 2014 at 05:12:41PM -0400, Vladimir Makarov wrote: > On 08/12/2014 03:35 PM, Jakub Jelinek wrote: > > Hi! > > > > As detailed in the PR, find_inc ignored any possible clobbers on > > inc_insn (typically %cc/flags/etc. register) and thus we could ignore > > all register dependencies b

Re: __intN patch 3/5: main __int128 -> __intN conversion.

2014-08-13 Thread Oleg Endo
On Wed, 2014-08-13 at 18:11 -0400, DJ Delorie wrote: > This is the main __int128 -> __intN conversion patch. We support up > to four __int types per target, which may include __int128. I > include the minimal change to the msp430 backend to illustrate how to > add a target-specific __int type. >

Re: [Patch] Fix crtstuff.c when compiling with mingw tools.

2014-08-13 Thread Kai Tietz
2014-08-13 22:51 GMT+02:00 Steve Ellcey : > On Wed, 2014-08-13 at 20:42 +, Joseph S. Myers wrote: >> On Wed, 13 Aug 2014, Steve Ellcey wrote: >> >> > This is a ping on a patch I sent out a while ago to fix the GCC build >> > when building with the mingw toolset. >> >> This is not a review. >>

__intN patch 4/5: testsuite updates

2014-08-13 Thread DJ Delorie
Changes to the testsuite to make tests more portable to targets with unusual address spaces. * testsuite/ * lib/target-supports.exp (check_effective_target_size32plus): Increase size to avoid false positives on 24-bit address spaces. * gcc.c-torture/compile/limits-stringli

__intN patch 5/5: msp430-specific changes

2014-08-13 Thread DJ Delorie
This is the MSP430-specific use of the new intN framework to enable true 20-bit pointers. Since I'm one of the MSP430 maintainers, this patch is being posted for reference, not for approval. gcc/config/msp430 * config/msp430/msp430-modes.def (PSI): Add. * config/msp430/msp430-pr

__intN patch 2/5: Fix assumptions about mode precisions

2014-08-13 Thread DJ Delorie
The purpose of this set of changes is to remove assumptions in GCC about type sizes. Previous to this patch, GCC assumed that all types were powers-of-two in size, and used naive math accordingly. Old: POINTER_SIZE / BITS_PER_UNIT TYPE_SIZE GET_MODE_BITSIZE New:

__intN patch 1/5: convert-move optimization

2014-08-13 Thread DJ Delorie
This patch is part of the __intN series, but is independent. It provides an additional optimization opportunity, since the MSP430 does a lot of conversions between HImode and PSImode. * expr.c (convert_move): If the target has an explicit converter, use it. Index: gcc/expr.c ===

__intN patch 0/5: summary

2014-08-13 Thread DJ Delorie
The following five patches are the latest in my ongoing work to replace the hard-coded __int128 type with a more flexible __int system that allows target-specific types that correspond to partial-int modes. Specifically, this will allow targets to have pointers that aren't powers-of-two in size.

Re: RFC: Patch for switch elimination (PR 54742)

2014-08-13 Thread Sebastian Pop
Jeff Law wrote: > I'm pretty sure jump threading *could* handle it, but after looking > at the full testcase when it was posted, I'm not sure it's *wise* to > handle this in jump threading. Thanks for clearing my doubts. Sebastian

Re: [PATCH] Fix PR61950

2014-08-13 Thread Tobias Burnus
Hi Richard, sorry for the belated reply due to spending lazily my time at the sea ... The patch is okay - and I would even claim that it is obvious. Regarding the data type, I have no idea why it uses a hard-coded 32bit integer instead of a size-type one. I have added it as item to https://gc

[patch] make gcov-tool build configurable and fix mingw build issue

2014-08-13 Thread Rong Xu
Hi, This patch makes gcov-tool build configurable. A new configure option --disable-gcov-tool is added to disable the build. It also fixes some build issues for mingw. Tested with regression and bootstrap. mingw test is ongoing. OK to check in if mingw build passes? Thanks, -Rong gcov_tool_

Re: RFC: Patch for switch elimination (PR 54742)

2014-08-13 Thread Jeff Law
On 08/13/14 14:55, Sebastian Pop wrote: Steve Ellcey wrote: +/* This file implements an optimization where, when a variable is set + to a constant value and there is a path that leads from that definition + to a switch statement that uses that variable as its controlling expression + we du

Re: RFC: Patch for switch elimination (PR 54742)

2014-08-13 Thread Sebastian Pop
Steve Ellcey wrote: > +/* This file implements an optimization where, when a variable is set > + to a constant value and there is a path that leads from that definition > + to a switch statement that uses that variable as its controlling > expression > + we duplicate the blocks on this path

Re: [Patch] Fix crtstuff.c when compiling with mingw tools.

2014-08-13 Thread Steve Ellcey
On Wed, 2014-08-13 at 20:42 +, Joseph S. Myers wrote: > On Wed, 13 Aug 2014, Steve Ellcey wrote: > > > This is a ping on a patch I sent out a while ago to fix the GCC build > > when building with the mingw toolset. > > This is not a review. > > When pinging, please give *the gcc.gnu.org URL

Re: [patch, testsuite] Applying non_bionic effective target to particular tests

2014-08-13 Thread Joseph S. Myers
On Thu, 14 Aug 2014, Alexander Ivchenko wrote: > Hi, > > This patch disables a bunch of tests that fail when using Bionic libc. > But this is expected; three reasons: > - Bionic does not support complex functions. > - Bionic does not have tgmath.h and error.h headers. > - Bionic does not have mem

Re: [Patch] Fix crtstuff.c when compiling with mingw tools.

2014-08-13 Thread Joseph S. Myers
On Wed, 13 Aug 2014, Steve Ellcey wrote: > This is a ping on a patch I sent out a while ago to fix the GCC build > when building with the mingw toolset. This is not a review. When pinging, please give *the gcc.gnu.org URL of the patch being pinged*. -- Joseph S. Myers jos...@codesourcery.com

Re: [patch,gomp4] make fortran loop variables implicitly private in openacc

2014-08-13 Thread Tobias Burnus
Cesar Philippidis wrote: According to section 2.6.1 in the openacc spec, fortran loop variables should be implicitly private like in openmp. This patch does just so. Makes sense. Looking at the patch, I wonder whether the context is properly handled when mixing OpenMP and OpenACC. I have the f

Re: [PATCH 012/236] Convert DF_REF_INSN to a function for now

2014-08-13 Thread Jeff Law
On 08/13/14 14:28, David Malcolm wrote: Thanks. Although this function gets converted back to a macro in patch 191, I just realized that in the meantime that it's not inlined, as is the case for some of the other macro->function conversions in patches 13-16. Do I need to convert them to inline

Re: [PATCH 012/236] Convert DF_REF_INSN to a function for now

2014-08-13 Thread David Malcolm
On Tue, 2014-08-12 at 15:20 -0600, Jeff Law wrote: > On 08/06/14 11:19, David Malcolm wrote: > > DF_REF_INSN looks up the "insn" field of the referenced df_insn_info. > > This will eventually be an rtx_insn *, but for now is just an rtx. > > > > As further scaffolding: for now, convert DF_REF_INSN

Re: [PATCH] fix hardreg_cprop to honor HARD_REGNO_MODE_OK.

2014-08-13 Thread Jeff Law
On 08/11/14 07:49, Ilya Tocar wrote: Hi, I've observed SPEC2006 failure on avx512-vlbwdq branch. It was caused by hardreg_cprop. In maybe_mode_change it was assumed, that all values of the same register class and same mode. are ok. This is not the case for i386/avx512. We need to honor HARD_REG

Re: [PATCH 190/236] Remove insn_addresses_new from 'various scheduling strengthenings'

2014-08-13 Thread Jeff Law
On 08/13/14 13:32, David Malcolm wrote: On Wed, 2014-08-06 at 13:22 -0400, David Malcolm wrote: --- gcc/insn-addr.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/insn-addr.h b/gcc/insn-addr.h index e255ac4..aec09fd 100644 --- a/gcc/insn-addr.h +++ b/gcc/insn-addr.h @

Re: [PATCH 092/236] lra: use rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:21, David Malcolm wrote: gcc/ * lra-int.h (struct lra_insn_recog_data): Strengthen field "insn" from rtx to rtx_insn *. (lra_push_insn): Likewise for 1st param. (lra_push_insn_and_update_insn_regno_info): Likewise. (lra_pop_insn): Likewise fo

[patch, testsuite] Applying non_bionic effective target to particular tests

2014-08-13 Thread Alexander Ivchenko
Hi, This patch disables a bunch of tests that fail when using Bionic libc. But this is expected; three reasons: - Bionic does not support complex functions. - Bionic does not have tgmath.h and error.h headers. - Bionic does not have mempcpy and stpcpy. diff --git a/gcc/testsuite/ChangeLog b/gcc/

Re: [PATCH 005/236] Introduce as_a_nullable

2014-08-13 Thread David Malcolm
On Wed, 2014-08-13 at 12:07 +0200, Richard Biener wrote: > On Wed, Aug 13, 2014 at 12:01 PM, Martin Jambor wrote: > > Hi, > > > > On Wed, Aug 06, 2014 at 01:19:44PM -0400, David Malcolm wrote: > >> In many circumstances, is_a_helper ::test assumes that the pointer is > >> non-NULL, but sometimes y

[c++-concepts] explicit instantiation and specialization

2014-08-13 Thread Andrew Sutton
This patch re-implements explicit instantiation and specialization. The latter isn't fully tested just yet, but it's close. Constraints for explicit instantiations and specializations are deduced from their candidates, not explicitly specified as part of the declaration. 2014-08-13 Andrew Sutton

Re: [PATCH 075/236] final.c: Use rtx_insn (also touches output.c and config/arc/arc.c)

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: In particular, after this patch, the first param passed to the FINAL_PRESCAN_INSN macro is strengthened from rtx to rtx_insn *. gcc/ * output.h (final_scan_insn): Strengthen return type from rtx to rtx_insn *. (final_forward_branch_

Re: [PATCH 190/236] Remove insn_addresses_new from 'various scheduling strengthenings'

2014-08-13 Thread David Malcolm
On Wed, 2014-08-06 at 13:22 -0400, David Malcolm wrote: > --- > gcc/insn-addr.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/gcc/insn-addr.h b/gcc/insn-addr.h > index e255ac4..aec09fd 100644 > --- a/gcc/insn-addr.h > +++ b/gcc/insn-addr.h > @@ -38,7 +38,7 @@ extern int

Re: [patch] libstdc++/61841 odr-use pthread_create in std::thread constructor

2014-08-13 Thread Jakub Jelinek
On Wed, Aug 13, 2014 at 08:02:22PM +0100, Jonathan Wakely wrote: > On 13/08/14 20:47 +0200, Jakub Jelinek wrote: > >On Wed, Aug 13, 2014 at 07:40:57PM +0100, Jonathan Wakely wrote: > >>This should fix the Hurd bug in PR61841 as well as the problem > >>described in https://gcc.gnu.org/ml/gcc/2013-09

Re: [PATCH] Fix UB in diagnostic.c

2014-08-13 Thread Manuel López-Ibáñez
> This should fix an undefined behavior in diagnostics.c. > Under certain circumstances, max_width is (INT_MAX - 1), > and right_margin is -4 -> the subtraction overflows. > Changing the types to unsigned would involve changing > much more code than just one cast. > > BTW, the diagnostics we output

Re: [patch] libstdc++/61841 odr-use pthread_create in std::thread constructor

2014-08-13 Thread Jonathan Wakely
On 13/08/14 20:47 +0200, Jakub Jelinek wrote: On Wed, Aug 13, 2014 at 07:40:57PM +0100, Jonathan Wakely wrote: This should fix the Hurd bug in PR61841 as well as the problem described in https://gcc.gnu.org/ml/gcc/2013-09/msg00196.html Tested x86_64-linux, committed to trunk. This is not suita

Re: [PATCH] Fix wrong refactoring in cgraph_node::function_symbol

2014-08-13 Thread Jan Hubicka
> 2014-08-13 Ilya Enkovich > > * cgraph.c (cgraph_node::function_symbol): Fix wrong > cgraph_function_node to cgraph_node::function_symbol > refactoring. OK, thanks1 Honza > > diff --git a/gcc/cgraph.c b/gcc/cgraph.c > index 5a0b903..370a96a 100644 > --- a/gcc/cgraph.c > +++

Re: [PATCH testcase]Add bind_pic_locally to case addrtmp.c

2014-08-13 Thread Jeff Law
On 08/07/14 03:43, Bin Cheng wrote: Hi, The case depends on GCC inlining of global function, but the callee won't be inlined because it's global function and considered over-writable during run-time. This patch fixes the failure by binding it to pic locally. Is it OK? Thanks, bin gcc/testsuit

Re: [patch] libstdc++/61841 odr-use pthread_create in std::thread constructor

2014-08-13 Thread Jakub Jelinek
On Wed, Aug 13, 2014 at 07:40:57PM +0100, Jonathan Wakely wrote: > This should fix the Hurd bug in PR61841 as well as the problem > described in https://gcc.gnu.org/ml/gcc/2013-09/msg00196.html > > Tested x86_64-linux, committed to trunk. > > This is not suitable for the branches as it requires a

Re: [PATCH 061/236] combine.c: Use rtx_insn

2014-08-13 Thread Jeff Law
On 08/13/14 12:39, Jeff Law wrote: On 08/06/14 11:20, David Malcolm wrote: gcc/ * combine.c (i2mod): Strengthen this variable from rtx to rtx_insn *. (struct reg_stat_struct): Likewise for fields "last_death", "last_set". (subst_insn): Likewise for this variable. (added_links_ins

[patch] libstdc++/61841 odr-use pthread_create in std::thread constructor

2014-08-13 Thread Jonathan Wakely
This patch causes the std::thread constructor that launches a new thread to odr-use pthread_create on glibc-based targets, so that the program depends directly on pthread_create (and must be linked to libpthread) not just on the weak symbol in gthr-posix.h This should fix the Hurd bug in PR61841

Re: [PATCH 061/236] combine.c: Use rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * combine.c (i2mod): Strengthen this variable from rtx to rtx_insn *. (struct reg_stat_struct): Likewise for fields "last_death", "last_set". (subst_insn): Likewise for this variable. (added_links_insn): Likewise.

Re: [PATCH 060/236] cfgrtl.c: Use rtx subclasses

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * cfgrtl.c (can_delete_note_p): Require a const rtx_note * rather than a const_rtx. (can_delete_label_p): Require a const rtx_code_label * rather than a const_rtx. (delete_insn): Add checked cast to rtx_code_labe

Re: [PATCH 057/236] cfgcleanup.c: Use rtx_insn (also touches basic-block.h and ifcvt.c)

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * basic-block.h (flow_find_cross_jump): Strengthen params 3 and 4 "f1" and "f2" from rtx * to rtx_insn **. (flow_find_head_matching_sequence): Likewise. * cfgcleanup.c (try_simplify_condjump): Strengthen local "

Re: [PATCH 051/236] bb-reorder.c: Use rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * bb-reorder.c (copy_bb_p): Strengthen local "insn" from rtx to rtx_insn *. (get_uncond_jump_length): Likewise for locals "label", "jump". (fix_up_crossing_landing_pad): Likewise for locals "new_label", "jump", "

Re: [PATCH 050/236] auto-inc-dec.c: strengthen various rtx to rtx_insn *

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: Note to self: verified the compile on pdp11-aout gcc/ * auto-inc-dec.c (struct inc_insn): Strengthen field "insn" from rtx to rtx_insn *. (struct mem_insn): Likewise for field "insn". (reg_next_use): Strengthen from rtx * to

Re: [PATCH 049/236] asan.c: strengthen some rtx locals

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: This is an example of strengthening rtx. For example, we now have strong enough types provided by the existing scaffolding to turn "insn" and "insns" in this: for (insn = insns; insn; insn = NEXT_INSN (insn)) from plain rtx into rtx_insn *. gcc/

Re: [PATCH 048/236] alias.c: Use rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * alias.c (init_alias_analysis): Strengthen local "insn" from rtx to rtx_insn *. OK. jeff

Re: [PATCH 047/236] PHASE 2: Per-file commits in main source directory

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: This commit is a placeholder for me when rebasing, to help organize the patch kit. / * rtx-classes-status.txt: Update OK. jeff

Re: [PATCH 046/236] delete_related_insns returns an rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * rtl.h (delete_related_insns): Strengthen return type from rtx to rtx_insn *. * jump.c (delete_related_insns): Likewise, also for locals "next" and "prev". OK. Jeff

[Patch] Fix crtstuff.c when compiling with mingw tools.

2014-08-13 Thread Steve Ellcey
This is a ping on a patch I sent out a while ago to fix the GCC build when building with the mingw toolset. The problem was that crtstuff.c would not compile because it saw two different (incompatible) definitions of caddr_t, one coming from auto-host.h (set by the configure script) and one coming

Re: [PATCH 045/236] define_bypass guard functions take a pair of rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: (define_bypass) clauses in .md files can specify the name of a guard function as their final operand. Currently these functions are called with a pair of rtx. This patch strengthens insn-automata.c so that such guard functions are passed a pair of rtx_ins

Re: [PATCH 044/236] Pass "insn" as an rtx_insn within generated get_attr_ fns in insn-attrtab.c

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: Strengthen "insn" from rtx to rtx_insn * within the generated get_attr_ functions in insn-attrtab.c, without imposing a strengthening from rtx to rtx_insn * on the param itself and thus the callers. gcc/ * genattrtab.c (write_attr_get): Within the

Re: [PATCH 043/236] peephole returns an rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * output.h (peephole): Strengthen return type from rtx to rtx_insn *. * rtl.h (delete_for_peephole): Likewise for both params. * genpeep.c (main): In generated "peephole" function, strengthen return type and local "insn"

Re: [PATCH 042/236] try_split returns an rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * rtl.h (try_split): Strengthen return type from rtx to rtx_insn *. * emit-rtl.c (try_split): Likewise, also for locals "before" and "after". For now, don't strengthen param "trial", which requires adding checked casts

Re: [PATCH 041/236] Debug hooks: use rtx_insn and rtx_code_label

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * debug.h (struct gcc_debug_hooks): Strengthen param 1 of hook "label" from rtx to rtx_code_label *. Strengthen param 1 o "var_location" hook from rtx to rtx_insn *. (debug_nothing_rtx): Delete in favor of... (d

Re: [PATCH 040/236] Use rtx_insn internally within generated functions

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: With this patch, "insn" and "curr_insn" as used from C++ fragments in .md files are strengthened from rtx to rtx_insn *, allowing numerous target-specific functions to have their params be similiar strengthened. The top-level interfaces ("recog", "split",

Fwd: [PATCH] Add Berkeley qsort to libiberty to make GCC host-independent

2014-08-13 Thread Mike Stump
[ dup sorry ] On Aug 13, 2014, at 5:12 AM, Felix Yang wrote: > The qsort library function may have different behavior on > different hosts (say Linux vs MinGW). > OK for trunk? I just have one question. Why if we want to use a stable sort, and we program in C++, would we not want to just us

Re: [PATCH 039/236] create_insn_rtx_from_pattern and create_copy_of_insn_rtx return rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * sel-sched-ir.h (create_insn_rtx_from_pattern): Strengthen return type from rtx to rtx_insn *. * sel-sched-ir.h (create_copy_of_insn_rtx): Likewise. * sel-sched-ir.c (create_insn_rtx_from_pattern): Likewise. * s

Re: [PATCH 038/236] find_first_parameter_load returns an rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * rtl.h (find_first_parameter_load): Strengthen return type from rtx to rtx_insn *. * rtlanal.c (find_first_parameter_load): Strengthen return type from rtx to rtx_insn *. Add checked cast for now, to postpone s

Re: [PATCH] Add Berkeley qsort to libiberty to make GCC host-independent

2014-08-13 Thread Mike Stump
On Aug 13, 2014, at 5:12 AM, Felix Yang wrote: >The qsort library function may have different behavior on > different hosts (say Linux vs MinGW). > OK for trunk? I just have one question. Why if we want to use a stable sort, and we program in C++, would we not want to just use C++: http

Re: [PATCH 037/236] sel_bb_{head|end} return rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * sel-sched-ir.h (exit_insn): Strengthen from rtx to rtx_insn *. (sel_bb_head): Strengthen return type insn_t (currently just an rtx) to rtx_insn *. (sel_bb_end): Likewise. * sel-sched-ir.c (exit_insn): Strength

Re: [PATCH 036/236] get_last_bb_insn returns an rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * basic-block.h (get_last_bb_insn): Strengthen return type from rtx to rtx_insn *. * cfgrtl.c (get_last_bb_insn): Likewise, and for locals "tmp" and end". OK. jeff

Re: [PATCH 035/236] Return types of unlink_insn_chain and duplicate_insn_chain

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * rtl.h (unlink_insn_chain): Strengthen return type from rtx to rtx_insn *. (duplicate_insn_chain): Likewise. * cfgrtl.c (unlink_insn_chain): Strengthen return type from rtx to rtx_insn *, also for locals "prevfi

Re: [PATCH 034/236] next_cc0_user and prev_cc0_setter scaffolding

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * rtl.h (next_cc0_user): Strengthen return type from rtx to rtx_insn *. (prev_cc0_setter): Likewise. * emit-rtl.c (next_cc0_user): Strengthen return type from rtx to rtx_insn *, adding checked casts for now as n

Re: [PATCH 033/236] emit_move et al return rtx_insn *

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: gcc/ * expr.h (emit_move_insn): Strengthen return type from rtx to rtx_insn *. (emit_move_insn_1): Likewise. (emit_move_complex_push): Likewise. (emit_move_complex_parts): Likewise. * expr.c (emit_move_via_in

Re: [PATCH 032/236] emit_* functions return rtx_insn

2014-08-13 Thread Jeff Law
On 08/06/14 11:20, David Malcolm wrote: More scaffolding: strengthen the return types from the various emit_ functions from rtx to rtx_insn * (or to the rtx_barrier * subclass in a few cases). These will ultimately have their params strengthened also, but we postpone that until much later in the

Re: [PATCH] Fix PR62077

2014-08-13 Thread Jason Merrill
On 08/13/2014 10:28 AM, Richard Biener wrote: Sofar the patch survived building stage2 in a LTO bootstrap on the 4.9 branch, full testing is scheduled for trunk. The patch breaks a lot of C++ testcases, such as g++.old-deja/g++.other/cvt1.C; I think you need to share the "set the canonical typ

Re: [PATCH i386 AVX512] [8/n] Extend substs for new patterns.

2014-08-13 Thread Uros Bizjak
On Wed, Aug 13, 2014 at 4:23 PM, Kirill Yukhin wrote: >> >> In a couple of places, checks are changed to GET_MODE_SIZE >> >> (GET_MODE (operands[0])) and in a similar way, mode checks were >> >> changed to GET_MODE (operands[0]). The previous checks are more >> >> efficient and are preferred. Is

Re: [PATCH 029/236] rtl_data.x_parm_birth_insn is an insn

2014-08-13 Thread Jeff Law
On 08/13/14 11:08, David Malcolm wrote: On Wed, 2014-08-13 at 07:44 -0600, Jeff Law wrote: On 08/06/14 11:20, David Malcolm wrote: gcc/ * function.h (struct rtl_data): Strengthen field "x_parm_birth_insn" from rtx to rtx_insn *. * function.c (struct assign_parm_data_all)

Re: [PATCH 029/236] rtl_data.x_parm_birth_insn is an insn

2014-08-13 Thread David Malcolm
On Wed, 2014-08-13 at 07:44 -0600, Jeff Law wrote: > On 08/06/14 11:20, David Malcolm wrote: > > gcc/ > > * function.h (struct rtl_data): Strengthen field > > "x_parm_birth_insn" from rtx to rtx_insn *. > > * function.c (struct assign_parm_data_all): Strengthen fields > > "first_con

Re: [C++ Patch] Remove "invalid type in declaration" parser error

2014-08-13 Thread Jason Merrill
OK. Jason

Re: [PATCH 140/236] config/microblaze/microblaze.c: Use rtx_insn and rtx_code_label

2014-08-13 Thread Michael Eager
On 08/06/14 10:21, David Malcolm wrote: gcc/ * config/microblaze/microblaze.c (microblaze_call_tls_get_addr): Strengthen return type and local "insns" from rtx to rtx_insn *. (microblaze_legitimize_tls_address): Likewise for local "insns". (microblaze_block_move_lo

Re: [gomp4] Add tables generation

2014-08-13 Thread Ilya Verbin
Hi, Here is the updated patch. offload_funcs/vars are now declared in omp-low.h, the functions have a comment. Also it fixes the issue of offload_funcs/vars corruption by the garbage collector. OK for gomp-4_0-branch? -- Ilya --- gcc/Makefile.in|1 + gcc/gengtype.c |

Re: [PATCH AArch64 1/3] Don't disparage add/sub in SIMD registers

2014-08-13 Thread Vladimir Makarov
On 2014-08-13, 4:36 AM, James Greenhalgh wrote: On Tue, Aug 12, 2014 at 04:53:38PM +0100, pins...@gmail.com wrote: On Aug 12, 2014, at 7:40 AM, Alan Lawrence wrote: (It is no more expensive.) Yes on some processors it could be. Haven't we been here before [1]? This disparaging mechanis

[COMMITTED PATCH] Demangler fuzzer

2014-08-13 Thread Gary Benson
Ian Lance Taylor wrote: > On Tue, Aug 12, 2014 at 10:11 AM, Gary Benson wrote: > > Ian Lance Taylor wrote: > > > I think that by default the program should stop. That will make > > > it possible to eventually run as part of "make check". Give it > > > some number of iterations that stops it in a

Re: [PATCH] gcc/config/microblaze/microblaze.md: Remove redundant '@' to avoid compiling warning

2014-08-13 Thread Michael Eager
On 07/05/14 20:59, Chen Gang wrote: * microblaze/microblaze.md: Remove redundant '@' to avoid compiling warning. The related warning: ../../gcc/gcc/config/microblaze/microblaze.md:516: '@' is redundant for output template with single alternative Signed-off-by: Chen Gang --- gcc/

Re: [PATCH, AArch64] Use MOVN to generate 64-bit negative immediates where sensible

2014-08-13 Thread Kyrill Tkachov
On 07/08/14 20:32, Richard Henderson wrote: On 08/07/2014 02:57 AM, Kyrill Tkachov wrote: + if (one_match > zero_match) +{ + /* Set either first three quarters or all but the third. */ + mask = 0xll << (16 - first_not__match); + emit_insn (gen_rtx_SET (VOIDmode, des

  1   2   >