[PATCH 00/18, nds32] Committed: Fix incompatible ABI implementation for variadic function.

2014-09-03 Thread Chung-Ju Wu
Hi, all, The variadic function ABI implmentation of current nds32 port on trunk is incompatible to the past Andes toolchains. Fixing it requires many changes on the different files. I split these changes into several patches so that we can precisely describe the purpose of each implementation in

[PATCH 18/18, nds32] No need to take padding into consideration in Andes ABI2 because we can pass arguments in registers for variadic function.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214869: https://gcc.gnu.org/r214869 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_must_pass_in_stack): New implementation for TARGET_MUST_PASS_IN_STACK. Best regards, jasonwucj 0018-PATCH-18-No-need-to-take-padding-into-con

[PATCH 17/18, nds32] Provide TARGET_ARG_PARTIAL_BYTES so that we can have structure argument partially in registers and stack.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214868: https://gcc.gnu.org/r214868 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_arg_partial_bytes): New implementation for TARGET_ARG_PARTIAL_BYTES. Best regards, jasonwucj 0017-PATCH-17-Provide-TARGET_ARG_PARTIAL_BYTES-s

[PATCH 16/18, nds32] Emit stack push instructions for varargs at prologue stage and emit stack adjustment instructions for varargs at epilogue stage.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214867: https://gcc.gnu.org/r214867 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_expand_prologue): Emit stack push instructions for varargs implementation. (nds32_expand_epilogue): Emit stack adjustment instructions fo

[PATCH 15/18, nds32] Since we are going to provide new heuristic for fp-as-gp optimization, we better not to set cfun->machine->fp_as_gp_p at prologue expanding.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214866: https://gcc.gnu.org/r214866 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_expand_prologue): Suppress fp-as-gp optimization detection. Best regards, jasonwucj 0015-PATCH-15-Since-we-are-going-to-provide-new-heuristic

[PATCH 14/18, nds32] Deal with nameless arguments in nds32_function_arg() and nds32_function_arg_advance().

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214865: https://gcc.gnu.org/r214865 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_function_arg): Deal with nameless arguments. (nds32_function_arg_advance): Deal with nameless arguments. * config/nds32/nds32.h (

[PATCH ARM]memset inlining patch for arm

2014-09-03 Thread Bin Cheng
Hi, This patch is posted/approved before at https://gcc.gnu.org/ml/gcc-patches/2014-07/msg01398.html Unfortunately, it was reverted because a latent bug revealed causing glibc build failure and I didn't have enough time to fix back at that time. Now with the potential bug resolved by https://gcc.gn

[PATCH 13/18, nds32] Since argument pointer must be 8-byte alignment, our first parameter may require 4-byte offset if pushed varargs is not 8-byte aligned.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214863: https://gcc.gnu.org/r214863 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.h (FIRST_PARM_OFFSET): Set proper location according to the value of crtl->args.pretend_args_size. Best regards, jasonwucj 0013-PATCH-13-Since-argumen

[PATCH 12/18, nds32] Prepare necessary varargs information in compute_stack_frame().

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214862: https://gcc.gnu.org/r214862 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_compute_stack_frame): Prepare necessary varargs information. Best regards, jasonwucj 0012-PATCH-12-Prepare-necessary-varargs-information-in-c

Re: [PATCH] Add -fno-instrument-function

2014-09-03 Thread Andi Kleen
> No, not a new "fake" option either but just initialize > DECL_NO_INSTRUMENT_FUNCTION_ENTRY_EXIT properly when > not doing -pg or -mfentry (that is, set it to 1). The only way would be to handle it in build_decl itself. There seem to be a bazillion callers all over the tree that all do their cust

[PATCH 11/18, nds32] Implement TARGET_SETUP_INCOMING_VARARGS target hook.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214861: https://gcc.gnu.org/r214861 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_setup_incoming_varargs): New implementation for TARGET_SETUP_INCOMING_VARARGS. (nds32_strict_argument_naming): Refine comment. *

[PATCH 10/18, nds32] Define and rename some GPR-specific stuff.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214859: https://gcc.gnu.org/r214859 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_function_arg): Define and rename some GPR-specific stuff. (nds32_function_arg_advance): Likewise. (nds32_init_cumulative_args): L

[PATCH 09/18, nds32] Remove unused variables.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214858: https://gcc.gnu.org/r214858 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_expand_prologue): Remove unused variables. (nds32_expand_epilogue): Likewise. (nds32_expand_prologue_v3push): Likewise. (nds32_ex

[PATCH COMMIT]Handle REG addressing mode in output_move_neon explicitly

2014-09-03 Thread Bin Cheng
Hi, This patch is posted/approved before at https://gcc.gnu.org/ml/gcc-patches/2014-07/msg00311.html It's one prerequisite patch for memset inlining patch on ARM. Unfortunately, it was reverted along with it because the whole patch set revealed a latent bug causing glibc build failure and I didn't

[PATCH 08/18, nds32] We need to make sure it is NOT a variadic function so that some v3push/v3pop preparation can be applied.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214857: https://gcc.gnu.org/r214857 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_compute_stack_frame): Do not use v3push/v3pop for variadic function. * config/nds32/nds32.md (prologue, epilogue): Likewise. Best regar

[PATCH 07/18, nds32] Consider varargs situation when creating stack operation assembly code.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214856: https://gcc.gnu.org/r214856 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push): Check rtx for varargs implementation. (nds32_output_stack_pop): Likewise. * config/nds32/nds32-p

[PATCH 06/18, nds32] Add a function to indentify if FUNC is a interrupt service routine.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214855: https://gcc.gnu.org/r214855 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32-isr.c (nds32_isr_function_p): Define new function to check if FUNC is an interrupt service routine. * config/nds32/nds32-protos.h (nds32_isr_funct

Re: [Patch AArch64] Fix for PR62040

2014-09-03 Thread Carrot Wei
Changed the coding style. 2014-09-03 Guozhi Wei PR target/62040 * gcc.target/aarch64/pr62040.c: New test. Index: pr62040.c === --- pr62040.c (revision 0) +++ pr62040.c (revision 0) @@ -0,0 +1,21 @@ +/* { dg-do c

[PATCH ARM]Use stricter constraint for pattern arm_movqi_insn to avoid constant pool

2014-09-03 Thread Bin Cheng
Hi, This patch is to fix a potential bug in arm pattern "arm_movqi_insn". For the pattern, (define_insn "*arm_movqi_insn" [(set (match_operand:QI 0 "nonimmediate_operand" "=r,r,r,l,r,l,Uu,r,m") (match_operand:QI 1 "general_operand" "r,r,I,Py,K,Uu,l,m,r"))] "TARGET_32BIT && ( regis

[PATCH 05/18, nds32] Preparation in nds32.h of using registers to save varargs.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214854: https://gcc.gnu.org/r214854 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.h (machine_function): Add some fields for variadic arguments implementation. Best regards, jasonwucj 0005-PATCH-05-Preparation-in-nds32.h-of-using-reg

[PATCH 04/18, nds32] In nds32_valid_stack_push_pop_p(), we look into OP rtx to see if we indeed save $fp/$gp/$lp registers.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214853: https://gcc.gnu.org/r214853 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32-predicates.c (nds32_valid_stack_push_pop): Rename to ... (nds32_valid_stack_push_pop_p): ... this. * config/nds32/nds32-protos.h: Likewise

[PATCH 03/18, nds32] Refine the implementation and consider CFA restore information for stack v3push/v3pop.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214852: https://gcc.gnu.org/r214852 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_gen_stack_v3push): Rename to ... (nds32_emit_stack_v3push): ... this. (nds32_gen_stack_v3pop): Rename to ... (nds32_emit_stack_v3

[PATCH 02/18, nds32] Refine the implementation and consider CFA restore information for stack push/pop multiple.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214851: https://gcc.gnu.org/r214851 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.c (nds32_gen_stack_push_multiple): Rename to ... (nds32_emit_stack_push_multiple): ... this. (nds32_gen_stack_pop_multiple): Rename to ...

[PATCH 01/18, nds32] Define PIC_OFFSET_TABLE_REGNUM to $gp register.

2014-09-03 Thread Chung-Ju Wu
Hi, all, Committed as Rev. 214849: https://gcc.gnu.org/r214849 gcc/ChangeLog 2014-09-03 Chung-Ju Wu * config/nds32/nds32.h (PIC_OFFSET_TABLE_REGNUM): Define. Best regards, jasonwucj 0001-PATCH-01-Define-PIC_OFFSET_TABLE_REGNUM-to-gp-regist.patch Description: Binary data

[wwwdocs] Buildstat update for 4.9

2014-09-03 Thread Raghunath Lolur
Hi, Please find an update of test results for 4.9 as below: Test Results for 4.9.1 : aarch64-linux-gnu Best Regards, Raghunath Lolur. Index: buildstat.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.9/buildstat.html,v retrieving

[PATCH, rs6000] Handle vec_extract and splat patterns in analyze_swaps

2014-09-03 Thread Bill Schmidt
Hi, This patch adds more special handling to analyze_swaps to allow us to improve more computations. Previously I had disallowed VEC_SELECT in all cases. This is now changed to allow a select of a single lane, either for an extract operation or for a splat operation. If a computation containing

[PATCH, rs6000] Correct optimization of VSX extract-load for little endian

2014-09-03 Thread Bill Schmidt
Hi, The *vsx_extract__load pattern performs a scalar load of memory when possible, rather than a vector load followed by an extract. The assembly for the pattern always loads the 0th memory doubleword element, but the pattern match selects the 0th for big-endian and the 1st for little-endian, lea

Re: [PATCH] Force rtl templates to be inlined

2014-09-03 Thread Andi Kleen
> > Anyway, removing !optimize checks in favor of flag_no_inline checks > and initializing that properly is a cleanup as well. Patch looks good to me. -Andi

Re: [PATCH 2/2] Enable elimination of zext/sext

2014-09-03 Thread Kugan
>> I added this part of the code (in cfgexpand.c) to handle binary/unary/.. >> gimple operations and used the LHS value range to infer the assigned >> value range. I will revert this part of the code as this is wrong. >> >> I dont think checking promoted_mode for temp will be necessary here as >> c

[Patch, gcc, testsuite]Disable xordi3-opt.c/iordi3-opt.c on thumb1 target

2014-09-03 Thread Tony Wang
Hi there, This is a test case clean up patch, because orr/eor instruction for thumb1 has only two variant: ORRS , ORR , No is available for thumb1 encoding, so test case xordi3-opt.c/iordi3-opt.c is invalid for thumb1 target. This patch just disabled them for thumb1 target. Ok for the trunk

RE: [PATCH 3/3,ARM,libgcc]Code size optimization for the fmul/fdiv and dmul/ddiv function in libgcc

2014-09-03 Thread Tony Wang
Ping 2? > -Original Message- > From: Tony Wang [mailto:tony.w...@arm.com] > Sent: Thursday, August 28, 2014 2:02 PM > To: 'gcc-patches@gcc.gnu.org' > Cc: Richard Earnshaw; Ramana Radhakrishnan > Subject: RE: [PATCH 3/3,ARM,libgcc]Code size optimization for the fmul/fdiv > and dmul/ddiv fu

RE: [PATCH 2/3,ARM,libgcc]Code size optimization for the fmul/fdiv and dmul/ddiv function in libgcc

2014-09-03 Thread Tony Wang
Ping 2? > -Original Message- > From: Tony Wang [mailto:tony.w...@arm.com] > Sent: Thursday, August 28, 2014 2:02 PM > To: 'gcc-patches@gcc.gnu.org' > Cc: Richard Earnshaw; Ramana Radhakrishnan > Subject: RE: [PATCH 2/3,ARM,libgcc]Code size optimization for the fmul/fdiv > and dmul/ddiv fu

RE: [PATCH 1/3,ARM,libgcc]Code size optimization for the fmul/fdiv and dmul/ddiv function in libgcc

2014-09-03 Thread Tony Wang
Ping 2? > -Original Message- > From: Tony Wang [mailto:tony.w...@arm.com] > Sent: Thursday, August 28, 2014 2:02 PM > To: 'gcc-patches@gcc.gnu.org' > Cc: Richard Earnshaw; Ramana Radhakrishnan > Subject: RE: [PATCH 1/3,ARM,libgcc]Code size optimization for the fmul/fdiv > and dmul/ddiv fu

RE: [Patch ARM] Fix PR target/56846

2014-09-03 Thread Tony Wang
Ping? > -Original Message- > From: Tony Wang [mailto:tony.w...@arm.com] > Sent: Monday, August 25, 2014 6:33 PM > To: 'gcc-patches@gcc.gnu.org'; 'd...@debian.org'; > 'aph-...@littlepinkcloud.com'; Richard Earnshaw; Ramana > Radhakrishnan > Subject: [Patch ARM] Fix PR target/56846 > > Hi

Re: [RFC] Tweak gcc.c-torture/execute/pr39228.c

2014-09-03 Thread Kaz Kojima
Jeff Law wrote: >> * gcc.c-torture/execute/pr39228.c: Use dg-additional-options >> instead of dg-options and remove sh*-*-* from its target list. >> Add "inline" keyword to test functions. > Wouldn't we be better off moving this into execute/ieee? I've tried it and found that all e

Re: [PATCH libstdc++ v5] - Add xmethods for std::vector and std::unique_ptr

2014-09-03 Thread Siva Chandra
On Wed, Sep 3, 2014 at 3:35 PM, Jonathan Wakely wrote: > I was waiting to see which version of the patch actually works, so > that users can use the xmethods. There's no point committing the patch > if they aren't installed and can't be used! Doesn't the latest version of the patch I posted work

PATCH for Re: New GCC mirror

2014-09-03 Thread Gerald Pfeifer
On Fri, 29 Aug 2014, ConcertPass Mirrors Admin wrote: > we set up a new GCC mirror for the community. > > URL: http://mirrors.concertpass.com/gcc/ > Organization/Contact: ConcertPass (ad...@mirrors.concertpass.com) > Location: United States, Michigan > > Please, add it to your mirror list page.

Re: Make many more options use CPP()

2014-09-03 Thread Joseph S. Myers
On Sat, 30 Aug 2014, Manuel L?pez-Ib??ez wrote: > gcc/ChangeLog: > > 2014-08-30 Manuel L?pez-Ib??ez > > * doc/options.texi: Document that Var and Init are required if CPP > is given. > * optc-gen.awk: Require Var and Init if CPP is given. > * common.opt (Wpedantic): Use Init.

Re: [PATCH libstdc++ v5] - Add xmethods for std::vector and std::unique_ptr

2014-09-03 Thread Jonathan Wakely
On 03/09/14 11:01 -0700, Siva Chandra wrote: Ping. I am not sure if the "OK to ping weekly" applies to GCC patches as well. I apologize if it has to be longer. I was waiting to see which version of the patch actually works, so that users can use the xmethods. There's no point committing the pat

Re: [PATCH][IRA] Analysis of register usage of functions for usage by IRA.

2014-09-03 Thread Tom de Vries
On 03-09-14 20:12, Ulrich Weigand wrote: Just for my curiosity, why is the second condition (after &&) needed in this clause in the first place? > if (ira_hard_reg_set_intersection_p (regno, mode, >+ *crossed_calls_clobber_regs) >+

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

2014-09-03 Thread Jeff Law
On 08/13/14 03:44, Richard Biener wrote: I don't see that this pass should "scrog" a loop beyond repair. Btw, the "proper" way of just fixing loops up (assuming that all loop headers are still at their appropriate place) is to _just_ do loops_set_state (LOOPS_NEED_FIXUP). This pass can quite ea

Re: [C++ Patch] PR 58102 aka DR 1405

2014-09-03 Thread Jason Merrill
On 09/03/2014 06:53 AM, Paolo Carlini wrote: The issue, AFAICS, boils down to the difference itself between cxx_eval_outermost_constant_expr and cxx_eval_constant_expression: changing constant_value_1 means that in principle all the calls of the latter (for VAR_DECLs) are impacted. Oh, right.

Re: Enable EBX for x86 in 32bits PIC code

2014-09-03 Thread Vladimir Makarov
On 2014-08-29 2:47 AM, Ilya Enkovich wrote: Seems your patch doesn't cover all cases. Attached is a modified patch (with your changes included) and a test where double constant is wrongly rematerialized. I also see in ira dump that there is still a copy of PIC reg created: Initialization of or

Re: [PATCH] Enable -Wlogical-not-parentheses by -Wall

2014-09-03 Thread Marek Polacek
On Wed, Sep 03, 2014 at 12:53:21PM -0600, Jeff Law wrote: > On 09/02/14 09:53, Marek Polacek wrote: > >Now that PR61271 and PR62270 have been fixed, we can enable > >-Wlogical-not-parentheses by -Wall. I think this warning proved > >useful. > > > >Bootstrapped/regtested on x86_64-linux and ppc64-l

Re: [PATCH, Pointer Bounds Checker 9/x] Cgraph extension

2014-09-03 Thread Jeff Law
On 07/24/14 03:59, Ilya Enkovich wrote: -- 2014-07-24 Ilya Enkovich * cgraph.h (cgraph_thunk_info): Add add_pointer_bounds_args field. (cgraph_node): Add instrumented_version, orig_decl and instrumentation_clone fields. (symtab_alias_target): Allow IPA_

Re: [PATCH, Pointer Bounds Checker 24/x] PRE

2014-09-03 Thread Jeff Law
On 08/18/14 07:02, Ilya Enkovich wrote: On 03 Jun 11:33, Richard Biener wrote: On Tue, Jun 3, 2014 at 9:13 AM, Ilya Enkovich wrote: Hi, This patch preserves CALL_WITH_BOUNDS flag for calls during PRE. Ok. Richard. Merging with the trunk I found that op2 field of vn_reference_op_struct i

Re: [gomp4] Add tables generation

2014-09-03 Thread Thomas Schwinge
Hi! On Mon, 18 Aug 2014 20:07:59 +0400, Ilya Verbin wrote: > I discovered an issue in the LTO streaming out for target - currently any > file (even without any pragma) compiled with -fopenmp/-fopenacc contains > .gnu.target_lto_* sections. This increases the size of an object file and > makes

Re: [PATCH, Pointer Bounds Checker 37/x] Support va_arg_pack and va_arg_pack_len

2014-09-03 Thread Jeff Law
On 08/18/14 09:03, Ilya Enkovich wrote: Hi, This patch adds support for va_arg_pack and va_arg_pack_len for instrumented functions into inliner. There are two things to do: 1) ignore bounds args when computing va_arg_pack_len 2) remove bounds args when expanding va_arg_pack in not instrument

Re: [PATCH, Pointer Bounds Checker 36/x] IPA pure const

2014-09-03 Thread Jeff Law
On 08/18/14 08:47, Ilya Enkovich wrote: Hi, This small patch adds support for new reference type for IPA pure const analysis. Thanks, Ilya -- 2014-08-15 Ilya Enkovich * ipa-pure-const.c (propagate_pure_const): Support IPA_REF_CHKP. OK. jeff

Re: [PATCH, Pointer Bounds Checker 23/x] Function split

2014-09-03 Thread Jeff Law
On 08/18/14 09:55, Ilya Enkovich wrote: On 04 Jun 01:15, Jeff Law wrote: On 06/03/14 01:10, Ilya Enkovich wrote: Hi, This patch does not allow splitting in case bounds are returned until retutrned bounds are supported. It also propagates instrumentation marks for generated call and function

Re: [RFC] Tweak gcc.c-torture/execute/pr39228.c

2014-09-03 Thread Jeff Law
On 09/02/14 23:26, Kaz Kojima wrote: Oleg Endo wrote: -mieee should be the default on sh* and thus can be removed from the dg-options line, or is it not? If -mieee is still needed (for alpha) maybe it's better to use dg-additional-options instead? Sure. The attached is a revised one. Reg

Re: [PING][PATCH] Fix environment variables restoring in GCC testsuite.

2014-09-03 Thread Jeff Law
On 09/01/14 03:09, Maxim Ostapenko wrote: Subject: [PATCH] Fix environment variables restoring in GCC testsuite. Date: Fri, 22 Aug 2014 14:39:16 +0400 From: Maxim Ostapenko To: GCC Patches CC: Yury Gribov , Slava Garbuzov Hi, When testing, I've noticed, that Asan-bootst

Re: [PATCH] Enable -Wlogical-not-parentheses by -Wall

2014-09-03 Thread Jeff Law
On 09/02/14 09:53, Marek Polacek wrote: Now that PR61271 and PR62270 have been fixed, we can enable -Wlogical-not-parentheses by -Wall. I think this warning proved useful. Bootstrapped/regtested on x86_64-linux and ppc64-linux, ok for trunk? 2014-08-26 Marek Polacek * doc/invoke.te

Re: RFA: Merge definitions of get_some_local_dynamic_name

2014-09-03 Thread Jeff Law
On 09/02/14 12:36, Richard Sandiford wrote: Several targets define a function like i386's get_some_local_dynamic_name. The function looks through the current output function and returns the first (arbitrary) local-dynamic symbol that it finds. The result can be used in a call to __tls_get_addr,

Re: [Patch, Fortran] Component declarations overwrite types of Cray Pointee variables

2014-09-03 Thread Tobias Burnus
Fritz Reese wrote: The typespecs for Cray pointees are overwritten by the typespecs of components with the same name which are declared later. Here is a proposed patch from 4.8.3 (test case comments/ChangeLog descriptions are updated from the submission on bugzilla). The test case demonstrates th

Re: [4.9] PR 62146

2014-09-03 Thread Jeff Law
On 09/02/14 12:52, Easwaran Raman wrote: It turns out that the REG_EQUAL note is removed on a hoisted instruction (relevant code is in dead_or_predicable in ifcvt.c) if the source of the move instruction is not a function invariant. In this case, the source is a function invariant (constant) and

Re: [PATCH 2/2] Set analyzed flag of unexpanded thunks in expand_thunk

2014-09-03 Thread Jeff Law
On 09/03/14 02:45, Martin Jambor wrote: Hi, this is a followup to my previous PR-fixing patch. At ever more places we currently do if (!node->expand_thunk (false, whatever)) node->analyzed = true; and we always set the flag when expand_thunk returns with false (it only can when the fi

Re: [PATCH 1/2, PR 61654] Handle newly truly expanded artificial_thunks

2014-09-03 Thread Jeff Law
On 09/03/14 02:45, Martin Jambor wrote: Hi, I did not think it was possible, but it can happen that when duplicate_thunk_for_node creates a duplicate of a thunk which previously expand_thunk left alone to be expanded into assembly by the back end, the newly created thunk does get expanded by exp

Re: [PATCH][IRA] Analysis of register usage of functions for usage by IRA.

2014-09-03 Thread Ulrich Weigand
Tom de Vries wrote: > thanks for noticing this. I agree, this looks wrong, and is probably an > oversight. [ It seems that s390 is the only target defining > IRA_HARD_REGNO_ADD_COST_MULTIPLIER, so this problem didn't show up on any > other > target. ] > > I think attached patch fixes it. > >

Re: [PATCH libstdc++ v5] - Add xmethods for std::vector and std::unique_ptr

2014-09-03 Thread Siva Chandra
Ping. I am not sure if the "OK to ping weekly" applies to GCC patches as well. I apologize if it has to be longer. On Wed, Aug 27, 2014 at 3:58 PM, Jonathan Wakely wrote: > On 27 August 2014 23:38, Siva Chandra wrote: >> You are probably already doing it, but just in case: are you using GDB >> 7.

Re: [debug-early] reuse variable DIEs and fix their context

2014-09-03 Thread Aldy Hernandez
[Jason, Richard]: Is it useful for my patches to contain ChangeLog entries? I find them mildly annoying for something that will inevitably be rewritten multiple times, but if it aids in reviewing my WIP, I am more than happy to continue including them. On 08/28/14 11:01, Jason Merrill wrote:

Re: RFA: Document first operand to RTX_AUTOINC

2014-09-03 Thread Jeff Law
On 09/02/14 12:00, Richard Sandiford wrote: As Jeff suggested here: https://gcc.gnu.org/ml/gcc-patches/2014-08/msg00390.html this patch documents that the first operand to an RTX_AUTOINC is the automodified register. Tested on x86_64-linux-gnu. OK to install? Thanks, Richard gcc/ * d

Re: [PATCH 4/4] aarch64: Don't duplicate calls_alloca check

2014-09-03 Thread Richard Henderson
On 09/03/2014 04:06 AM, Marcus Shawcroft wrote: > On 22 August 2014 23:05, Richard Henderson wrote: >> Generic code already handles calls_alloca for determining >> the need for a frame pointer. >> >> * config/aarch64/aarch64.c (aarch64_frame_pointer_required): Don't >> check calls_

Re: [PATCH][IRA] Analysis of register usage of functions for usage by IRA.

2014-09-03 Thread Tom de Vries
On 01-09-14 18:41, Ulrich Weigand wrote: Tom de Vries wrote: * ira-costs.c (ira_tune_allocno_costs): Use ALLOCNO_CROSSED_CALLS_CLOBBERED_REGS to adjust costs. In debugging PR 53864 on s390x-linux, I ran into a weird change in behavior that occurs when the following part of thi

Re: fix gfcov regression

2014-09-03 Thread Dominique Dhumieres
> does this fix it? The answer after a quick update is yes, further testing scheduled for tonight. Thanks, Dominique

Re: [PATCH, testsuite]: Compile gcc.dg/20111227-?.c for x86 targets only.

2014-09-03 Thread Uros Bizjak
On Wed, Sep 3, 2014 at 4:53 PM, Mike Stump wrote: > On Sep 3, 2014, at 1:03 AM, Uros Bizjak wrote: >> These testcases were intended to be compiled on x86 targets only [1]. > > Not a bug deal, but would a git mv bla gcc.target/i386 be more appropriate? I have considered this option, but the funct

Re: [patch] prevent tree sinking of trapping stmts

2014-09-03 Thread Olivier Hainque
On Sep 3, 2014, at 15:27 , Richard Biener wrote: > Eventually the FE can still simply set flag_exeptions / > flag_non_call_exceptions? > It will still not be correct for all cases > but at least external throw predicates would work ... Yes, these would work. I have always been worried about th

Re: [FORTRAN PATCH] Two -Wlogical-not-parentheses fixes (PR fortran/62270)

2014-09-03 Thread Marek Polacek
On Tue, Sep 02, 2014 at 09:29:51PM +0200, Thomas Koenig wrote: > Am 02.09.2014 17:32, schrieb Tobias Burnus: > > > > Marek Polacek wrote: > >> This patch fixes the last two spots where -Wlogical-not-parentheses > >> warns. See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62270#c3 > >> if you want

Re: [PATCH] PowerPC: Implement TARGET_ATOMIC_ASSIGN_EXPAND_FENV

2014-09-03 Thread Joseph S. Myers
On Wed, 3 Sep 2014, Maciej W. Rozycki wrote: > (floating-point environment is of course unsupported for soft-float > targets and for the SPE FPU another change is required to implement > floating-point environment handling to complement one proposed here). Support for SPE will depend on the C

Re: [PATCH] Don't init ira_spilled_reg_stack_slots in ira if using lra.

2014-09-03 Thread Vladimir Makarov
On 2014-09-03 5:26 AM, Kito Cheng wrote: ping! The patch saves some compilation time for LRA based targets. It is ok to commit. Thanks, Kito. On Wed, Aug 27, 2014 at 10:49 PM, Kito Cheng wrote: Hi all: This patch is clean up useless initialize for IRA with LRA. 2014-08-27 Kito Cheng

Re: [PATCH, testsuite]: Compile gcc.dg/20111227-?.c for x86 targets only.

2014-09-03 Thread Mike Stump
On Sep 3, 2014, at 1:03 AM, Uros Bizjak wrote: > These testcases were intended to be compiled on x86 targets only [1]. Not a bug deal, but would a git mv bla gcc.target/i386 be more appropriate? > 2014-09-03 Uros Bizjak > >* gcc.dg/20111227-2.c: Compile only for x86 targets. >* gcc.d

Re: [PATCH][AArch64] Fix wrong ".cfi_def_cfa_offset" in epilogue

2014-09-03 Thread Jiong Wang
On 03/09/14 11:33, Marcus Shawcroft wrote: On 20 August 2014 09:43, Jiong Wang wrote: gcc/ * config/aarch64/aarch64.c (aarch64_expand_epilogue): Remove redundant cfa offset update. OK /Marcus thanks for review. this fix is included in Richard H's patch at https://gcc.gnu.org/ml/gcc-

[PATCH] Speedup -Og

2014-09-03 Thread Richard Biener
I seem to have lost this patch in my dev tree for some reason. After introducing --param max-combine-insns it was the idea to restrict combine to two-insn combines for -Og as combine is a major RTL compile-time hog. Bootstrapped and tested on x86_64-unknown-linux-gnu, applied. Richard. 2014-09-

Re: [PATCH] PowerPC: Implement TARGET_ATOMIC_ASSIGN_EXPAND_FENV

2014-09-03 Thread Uros Bizjak
Hello! > While at it, may I propose another change on top of this? > > I've noticed the test case is rather slow, it certainly takes much more > time than the average one, I've seen elapsed times of well over a minute > on reasonably fast hardware and occasionally a timeout midway through even > t

Re: [PATCH] PowerPC: Implement TARGET_ATOMIC_ASSIGN_EXPAND_FENV

2014-09-03 Thread Maciej W. Rozycki
On Tue, 2 Sep 2014, Adhemerval Zanella wrote: > Ping. > > On 19-08-2014 13:54, Adhemerval Zanella wrote: > > Ping. > > > > On 06-08-2014 17:21, Adhemerval Zanella wrote: > >> On 01-08-2014 12:31, Joseph S. Myers wrote: > >>> On Thu, 31 Jul 2014, David Edelsohn wrote: > >>> > Thanks for imple

[PATCH] combine: Allow substituting the target reg of a clobber

2014-09-03 Thread Segher Boessenkool
This came up when investigating PR62151. In that PR combine messes up a four-insn combination. It should really have done the combination of the first three insns in that. The second of those instructions sets a register; the third clobbers the same. Substituting the source of the set into the

Re: [patch] prevent tree sinking of trapping stmts

2014-09-03 Thread Richard Biener
On Wed, Sep 3, 2014 at 3:25 PM, Olivier Hainque wrote: > > On Sep 3, 2014, at 15:05 , Richard Biener wrote: >> Well, but that's a bug in the Ada frontend if it does exceptions behind >> GCCs back. > > I agree that this is a problem and that could_throw_p is a better > predicate. I wasn't convin

Re: [patch] prevent tree sinking of trapping stmts

2014-09-03 Thread Olivier Hainque
On Sep 3, 2014, at 15:05 , Richard Biener wrote: > Well, but that's a bug in the Ada frontend if it does exceptions behind > GCCs back. I agree that this is a problem and that could_throw_p is a better predicate. I wasn't convinced by my own answer but hadn't really pinpointed why before hitt

Re: [PATCH PR62151]Fix uninitialized register issue caused by distribute_notes in combine pass

2014-09-03 Thread Segher Boessenkool
On Wed, Sep 03, 2014 at 10:34:39AM +0800, Bin.Cheng wrote: > >> Now I guess this check could be relaxed if somewhere else in combine we'd > >> recognize the substitution into a clobber and simply omit it in that case. > > > > Yeah. > > > > In the testcase, combine tries combining 76,77 (77 is that

Re: fix gfcov regression

2014-09-03 Thread Nathan Sidwell
On 09/03/14 04:06, Dominique Dhumieres wrote: I've committed the patch now. It (r214840) breaks bootstrap on darwin: does this fix it? nathan 2014-09-03 Nathan sidwell * libgcov-interface.c (STRONG_ALIAS): Rename to ... (ALIAS): ... here. Make weak. Adjust uses. Index:

[committed] Add testcase from PR62294

2014-09-03 Thread Marek Polacek
This adds a testcase for PR62294 that I just fixed on the 4.9 branch. Tested on x86_64-linux, applying to trunk. 2014-09-03 Marek Polacek PR c/62294 * gcc.dg/pr62294.c: New test. * gcc.dg/pr62294.h: New file. diff --git gcc/testsuite/gcc.dg/pr62294.c gcc/testsuite/gcc

Re: [Patch AArch64] Fix for PR62040

2014-09-03 Thread Marcus Shawcroft
On 20 August 2014 00:43, Carrot Wei wrote: > Hi > > Current AArch64 backend can generate rtl expressions like > (vec_duplicate:DI (const_int 0 [0])), which causes ICE in > simplify_const_unary_operation because vec_duplicate should generate > vector mode only. > > As suggested by Andrew in the bug

Re: [patch] prevent tree sinking of trapping stmts

2014-09-03 Thread Richard Biener
On Wed, Sep 3, 2014 at 2:49 PM, Olivier Hainque wrote: > Hi Richard, > > (Thanks for your feedback) > > On Sep 3, 2014, at 12:52 , Richard Biener wrote: >> I don't quite follow this reasoning. Why would a trapping FP operation >> not be undefined behavior without -fnon-call-exceptions? That is,

Re: [Patch AArch64] Fix for PR62040

2014-09-03 Thread Marcus Shawcroft
On 20 August 2014 20:51, Carrot Wei wrote: > Good suggestion. Add the testcase. > > thanks > Guozhi Wei > > 2014-08-20 Guozhi Wei > > PR target/62040 > * gcc.target/aarch64/pr62040.c: New test. > > Index: pr62040.c > ==

[PATCH][RFC] Restrict, take 42

2014-09-03 Thread Richard Biener
Ok, so with recent activity in that mgrid bug (PR55334) I tried to remember what solution we thought of after determining that ADD_RESTRICT is a no-go. The following very prototypish patch implements the idea of computing known non-dependences and maintaining them over the compilation (mainly inl

Re: [patch] prevent tree sinking of trapping stmts

2014-09-03 Thread Olivier Hainque
Hi Richard, (Thanks for your feedback) On Sep 3, 2014, at 12:52 , Richard Biener wrote: > I don't quite follow this reasoning. Why would a trapping FP operation > not be undefined behavior without -fnon-call-exceptions? That is, > don't you want to check stmt_could_throw_p? > > That is, what'

Re: [C PATCH] Backport a fix for PR62294 to 4.9

2014-09-03 Thread Marek Polacek
On Tue, Sep 02, 2014 at 05:01:10PM +, Joseph S. Myers wrote: > On Tue, 2 Sep 2014, Marek Polacek wrote: > > > PR62294 reports that 4.9 does not emit an "incompatible pointer type" > > warning in certain scenario. I unknowingly broke this in r207335, and > > then fixed it in r210980, which is

[PATCH] Fix for tree-ssa-pre

2014-09-03 Thread Martin Liška
Hello, I've encountered and issue in a ltrans for libxul.so (with LTO). The patch fixes uninitialized value for a given argument, pre-approved by Richard. Thanks, Martin gcc/ChangeLog: 2014-09-03 Martin Liska * tree-ssa-sccvn.c (vn_reference_lookup_call): default (NULL) value

Re: [PATCH 4/4] aarch64: Don't duplicate calls_alloca check

2014-09-03 Thread Marcus Shawcroft
On 22 August 2014 23:05, Richard Henderson wrote: > Generic code already handles calls_alloca for determining > the need for a frame pointer. > > * config/aarch64/aarch64.c (aarch64_frame_pointer_required): Don't > check calls_alloca. Ok Thanks /Marcus

Re: [PATCH 3/4] aarch64: Tidy prologue local variables

2014-09-03 Thread Marcus Shawcroft
On 22 August 2014 23:05, Richard Henderson wrote: > Don't continually re-read data from cfun->machine. > > * config/aarch64/aarch64.c (aarch64_expand_prologue): Load > cfun->machine->frame.hard_fp_offset into a local variable. OK /Marcus

Re: [PATCH] Add -fno-instrument-function

2014-09-03 Thread Richard Biener
On Tue, Sep 2, 2014 at 5:00 PM, Andi Kleen wrote: >> Hmm, why not make -no-pg (does that exist?) and/or -mno-fentry > > I'm not sure. > >> do this? That is, I don't see the need for a new option. > > That would be really odd behavior. An yes/no option whose default > is controlled by other object

Re: [PATCH 2/4] aarch64: Tidy prologue unwind notes

2014-09-03 Thread Marcus Shawcroft
On 22 August 2014 23:05, Richard Henderson wrote: > We were marking more than necessary in aarch64_set_frame_expr. > Fold the reduced function into aarch64_expand_prologue as necessary. > > * config/aarch64/aarch64.c (aarch64_set_frame_expr): Remove. > (aarch64_expand_prologue): Us

Re: [PATCH 1/4] aarch64: Improve epilogue unwind info

2014-09-03 Thread Marcus Shawcroft
On 22 August 2014 23:05, Richard Henderson wrote: > Delay cfi restore opcodes until the stack frame is deallocated. > This reduces the number of cfi advance opcodes required. > > We perform a similar optimization in the x86_64 epilogue. > > > * config/aarch64/aarch64.c (aarch64_popwb_singl

Re: [C++ Patch] PR 58102 aka DR 1405

2014-09-03 Thread Paolo Carlini
Hi, On 09/02/2014 05:45 PM, Jason Merrill wrote: On 09/02/2014 11:07 AM, Paolo Carlini wrote: Anyway, what about the below? Certainly works for the tests which we have got. Hmm. This is definitely an improvement, as it allows a subset of a non-volatile glvalue of literal type that refers to

Re: [patch] prevent tree sinking of trapping stmts

2014-09-03 Thread Richard Biener
On Wed, Sep 3, 2014 at 12:28 PM, Olivier Hainque wrote: > Hello, > > For the testcase below, the tree-ssa-sink pass sinks the first a = b + c; > assignment within the if branch. > > This is problematic when the + operation on floats could trap, as it gets > moved > out of the path that dominates

Re: [PATCH, PR 62015] Clear aggregate values intersection when jump function flag require us to punt

2014-09-03 Thread Richard Biener
On Wed, Sep 3, 2014 at 10:47 AM, Martin Jambor wrote: > Hi, > > this PR revealed that the aggregate value intersection code in IPA-CP > has one more problem in it, namely when jump function flags show that > a PASS_THROUGH jump function cannot be used at all, it must also clear > the intersection

Re: [PATCH, PR 61986] Produce aggregate replacement nodes in ascending order of offsets

2014-09-03 Thread Richard Biener
On Wed, Sep 3, 2014 at 10:46 AM, Martin Jambor wrote: > Hi, > > intersecting known aggregate values coming along a given set of call > graph edges requires that all lists are in ascending order of offsets > in order to perform it in only one sweep through each of them. > However, aggregate replace

Re: [RFC] Tweak gcc.c-torture/execute/pr39228.c

2014-09-03 Thread Richard Biener
On Wed, Sep 3, 2014 at 8:28 AM, Kaz Kojima wrote: > Uros Bizjak wrote: >> -/* { dg-options "-mieee" { target sh*-*-* alpha*-*-* } } */ >> +/* { dg-options "-w -mieee" { target sh*-*-* alpha*-*-* } } */ >> /* { dg-skip-if "No Inf/NaN support" { spu-*-* } "*" "" } */ >> >> Please use /* { dg-add-o

[PATCH][match-and-simplify] Fix error in VCE pattern

2014-09-03 Thread Richard Biener
The pattern (and the fold_unary code it was derived from) stripping inner conversions from VIEW_CONVERT_EXPRs is bogus as in that it doesn't make sure the the size of the types match. This triggers a IL verification for gfortran.fortran-torture/compile/forall-1.f90 otherwise. Committed to the br

Re: [PATCH][AArch64] Fix wrong ".cfi_def_cfa_offset" in epilogue

2014-09-03 Thread Marcus Shawcroft
On 20 August 2014 09:43, Jiong Wang wrote: > gcc/ > * config/aarch64/aarch64.c (aarch64_expand_epilogue): Remove redundant cfa > offset update. OK /Marcus

  1   2   >