Re: [PATCH, committed] * pt.c (make_auto_1): Use input_location rather than BUILTINS_LOCATION.

2013-09-16 Thread Eric Botcazou
> Apologies if this was out of context. This was a change suggested and > reviewed by Jason > (http://gcc.gnu.org/ml/gcc-patches/2013-09/msg01114.html). Then don't repost it on gcc-patches, it is already available on gcc-cvs: http://gcc.gnu.org/ml/gcc-cvs/2013-09/msg00473.

Re: [PATCH] Fix segfault with inlining

2013-09-17 Thread Eric Botcazou
est on DECL_CONTEXT is superfluous? Possibly indeed, but with nested functions you can have PARM_DECLs of different origins in a given function body, although this may be irrelevant for tree-inline.c. -- Eric Botcazou

Re: [PATCH] Fix segfault with inlining

2013-09-17 Thread Eric Botcazou
hat we're already in SSA form, so parameters can be represented by SSA_NAMEs without defining statements. -- Eric Botcazou

Re: [PATCH] Fix segfault with inlining

2013-09-17 Thread Eric Botcazou
> That's true... so you can only simplify is_parameter_of by dropping > the context check. OK, thanks, installed with this modification and the fix for the oversight spotted by Jakub, after retesting on x86-64/Linux. -- Eric Botcazou

[Ada] Fix bogus return value for function with In Out parameter

2013-09-18 Thread Eric Botcazou
. 2013-09-18 Eric Botcazou * gcc-interface/trans.c (Subprogram_Body_to_gnu): Pop the stack of return variables for subprograms using the CICO mechanism. 2013-09-18 Eric Botcazou * gnat.dg/in_out_parameter4.adb: New test. -- Eric BotcazouIndex: gcc-interface

[Ada] Fix crash in ASIS mode

2013-09-18 Thread Eric Botcazou
Tested on x86_64-suse-linux, applied on the mainline. 2013-09-18 Eric Botcazou * gcc-interface/decl.c (gnat_to_gnu_entity) : New. -- Eric BotcazouIndex: gcc-interface/decl.c === --- gcc-interface/decl.c (revision

[Ada] Fix PR ada/58264

2013-09-18 Thread Eric Botcazou
Attr_First and Attr_Last. 2013-09-18 Eric Botcazou * gnat.dg/array_bounds_test2.adb: New test. -- Eric BotcazouIndex: gcc-interface/trans.c === --- gcc-interface/trans.c (revision 202688) +++ gcc-interface/trans.c

[patch] Fix ICE in insert_clobber_before_stack_restore

2013-09-18 Thread Eric Botcazou
opy assignment statement. Tested on x86_64-suse-linux, OK for mainline and 4.8 branch? What about the 4.7 branch? 2013-09-18 Eric Botcazou * tree-ssa-ccp.c (insert_clobber_before_stack_restore): Recurse on copy assignment statements. 2013-09-18 Eric Botca

Re: [PATCH] RTEMS: Add LEON3/SPARC multilibs

2013-09-19 Thread Eric Botcazou
are of a different opinion here. 2013-08-09 Eric Botcazou * configure.ac: Add GAS check for LEON instructions on SPARC. * configure: Regenerate. * config.in: Likewise. * config.gcc (with_cpu): Remove sparc-leon*-* and deal with LEON in the

Fix glitch in gimplification of asm

2013-09-22 Thread Eric Botcazou
x", "eax"); in the .gimple file because the TREE_CHAIN of clobbers isn't reset to NULL_TREE, unlike for the outputs and the inputs. Tested on x86_64-suse-linux, applied on the mainline as obvious. 2013-09-22 Eric Botcazou * gimplify.c (gimplify_asm_expr): Reset t

Re: [ping][PATCH][1 of 2] Add value range info to SSA_NAME for zero sign extension elimination in RTL

2013-09-23 Thread Eric Botcazou
ome/eric/svn/gcc/gcc/toplev.c:1891 #13 toplev_main (argc=14, argv=0x7fffdca8) at /home/eric/svn/gcc/gcc/toplev.c:1967 #14 0x76f2a23d in __libc_start_main () from /lib64/libc.so.6 #15 0x000000635381 in _start () at ../sysdeps/x86_64/elf/start.S:113 (gdb) p name $1 = (tree) 0x0 -- Eric Botcazou

Re: [PATCH, ARM, LRA] Prepare ARM build with LRA

2013-09-24 Thread Eric Botcazou
IFT + || GET_CODE (x) == ASHIFTRT + || GET_CODE (x) == LSHIFTRT + || GET_CODE (x) == ROTATE + || GET_CODE (x) == ROTATERT); +} ROTATE and ROTATERT aren't really shifting operations though, so are they really needed here? -- Eric Botcazou

Re: [PATCH, PR 57748] Check for out of bounds access, Part 2

2013-09-24 Thread Eric Botcazou
bold and is presumably papering over the underlying issue... > That said, I still believe that fixing the misalign path in > expand_assignment would be better than trying to avoid it. For this > testcase the issue is again that expand_assignment passes the wrong > mode/target to the > movmisalign optab. ...then let's just fix the movmisalign stuff. -- Eric Botcazou

Re: [PATCH, ARM, LRA] Prepare ARM build with LRA

2013-09-24 Thread Eric Botcazou
x) { return GET_CODE (x) == MULT || GET_CODE (x) == ASHIFT; } and call it from set_address_index? -- Eric Botcazou

Re: [PATCH, LRA] Remove REG_DEAD and REG_UNUSED notes.

2013-09-24 Thread Eric Botcazou
manually deal with the REG_DEAD and REG_UNUSED notes (unlike REG_EQUAL and REG_EQUIV notes), as the DF framework is supposed to do it for you. -- Eric Botcazou

Re: [PATCH, ARM, LRA] Prepare ARM build with LRA

2013-09-24 Thread Eric Botcazou
T || ASHIFT test in set_address_index by a call to must_be_index_p, 3. Add the new cases to must_be_index_p directly, with a comment saying that there are e.g. for the ARM. -- Eric Botcazou

Re: [ping][PATCH][1 of 2] Add value range info to SSA_NAME for zero sign extension elimination in RTL

2013-09-25 Thread Eric Botcazou
> Sorry for missing this problem when committing Kugan's patch. > > I have just committed the attached patch, which I hope fixes all the > spaces/indentation issues introduced. Thanks a lot! -- Eric Botcazou

Re: [PATCH, ARM, LRA] Prepare ARM build with LRA

2013-09-25 Thread Eric Botcazou
_p): Add shifting and rotate operations handling. > (set_address_base): Use must_be_base_p predicate. > (set_address_index):Use must_be_index_p predicate. OK for mainline, if you add the missing space after GET_MODE in enum machine_mode mode = GET_MODE(XEXP (x, 0)); -- Eric Botcazou

Re: [PATCH, ARM, LRA] Prepare ARM build with LRA

2013-09-25 Thread Eric Botcazou
s even clearer with the predicates I think. -- Eric Botcazou

Re: [PATCH, LRA] Remove REG_DEAD and REG_UNUSED notes.

2013-09-25 Thread Eric Botcazou
is entitled to do it as well. But the proper fix to this is to recompute the REG_DEAD/REG_UNUSED notes at the beginning of postreload. -- Eric Botcazou

Re: [PATCH, ARM, LRA] Prepare ARM build with LRA

2013-09-25 Thread Eric Botcazou
, but OK, feel free to revert the de-duplication part, but add comments saying that the functions must be kept synchronized. -- Eric Botcazou

Remove obsolete comment

2013-09-26 Thread Eric Botcazou
The first part is obsolete since r91570 at least, for the second part about MEM_KEEP_ALIAS_SET_P it's more recent. Tested on x86_64-suse-linux, applied on the mainline. 2013-09-26 Eric Botcazou * expr.c (expand_assignment): Remove obsolete comment. -- Eric BotcazouIndex: e

Re: [PATCH][RFC] Remove quadratic loop with component_uses_parent_alias_set

2013-09-26 Thread Eric Botcazou
ALIAS_SET_P (to_rtx) && MEM_ALIAS_SET (to_rtx) != 0) > set_mem_alias_set (to_rtx, alias_set); > > seem to miss MEM_ALIAS_SET (to_rtx) being ALIAS_SET_MEMORY_BARRIER? > Or alias_set being zero / ALIAS_SET_MEMORY_BARRIER? This code predates ALIAS_SET_MEMORY_BARRIER. -- Eric Botcazou

Re: [PATCH, PR 57748] Check for out of bounds access, Part 2

2013-09-26 Thread Eric Botcazou
EM here. Look at all the code just below the block. Given how hard it is to eliminate spills to memory in RTL once they are generated, this shouldn't be taken lightly. -- Eric Botcazou

Re: [PATCH, PR 57748] Check for out of bounds access, Part 2

2013-09-27 Thread Eric Botcazou
he code below. And it already lists explicit cases where we really need to splill to memory. -- Eric Botcazou

Re: [PATCH, ARM, LRA] Prepare ARM build with LRA

2013-09-27 Thread Eric Botcazou
(baseness): Remove must_be_base_p and must_be_index_p checks. > (decompose_normal_address): Classify as much as possible in the > main loop. Yes, fine by me, thanks. -- Eric Botcazou

Re: RFA: Store the REG_BR_PROB probability directly as an int

2013-09-27 Thread Eric Botcazou
> Thanks for the testing. It also passes bootstrap on x86_64-linux-gnu. > OK to install? Yes, thanks. -- Eric Botcazou

Re: [PATCH, RTL] Prepare ARM build with LRA

2013-09-27 Thread Eric Botcazou
> below is a trivial patch, which makes both parts of test signed. > With this, bootstrap completes on powerpc-darwin9 - however, you might want > to check that it still does what you intended. Please install under PR middle-end/58547 if not already done. -- Eric Botcazou

Re: [PATCH][RFC] Remove quadratic loop with component_uses_parent_alias_set

2013-09-27 Thread Eric Botcazou
; components one at a time. > * emit-rtl.c (set_mem_attributes_minus_bitpos): Adjust. FWIW it looks fine to me. -- Eric Botcazou

[patch] Fix PR bootstrap/58509

2013-09-27 Thread Eric Botcazou
same object. So the attached seriously refines it, restricting it to parameters with reference type and leaning towards being less conservative. Again, this should only affect Ada. Tested on x86_64-suse-linux, OK for the mainline? 2013-09-27 Eric Botcazou PR bootstrap/58509

[SPARC] Add peephole for memory barriers

2013-09-29 Thread Eric Botcazou
This is a bit gross, but this prevents consecutive memory barriers from being generated, for example on accesses to atomic objects in Ada. Tested on SPARC/Solaris, applied on the mainline. 2013-09-29 Eric Botcazou * config/sparc/sync.md: Add peephole for consecutive memory barriers

[patch] Minor TARGET_MEM_REF cleanup

2012-09-29 Thread Eric Botcazou
dex: ivtmp.3_1, step: 4, offset: 0B] so the pass analyzes the store but not the load, which seems an oversight. The patch also folds copy_mem_ref_info into its only user and removes it. Tested on x86_64-suse-linux, OK for mainline? 2012-09-29 Eric Botcazou * tree.h (copy_mem_ref_i

Re: [rtl] combine a vec_concat of 2 vec_selects from the same vector

2012-09-29 Thread Eric Botcazou
XP (trueop0, 0)) == mode, then XEXP (trueop0, 0) is a 2-element vector so the only possible case is (0,1). That would probably even be more correct since you don't test CONST_INT_P for the indices, while the test is done in the VEC_SELECT case. Why not generalizing to all kinds of VEC_SELECTs instead of just scalar ones? -- Eric Botcazou

Re: RFA: Fix PR rtl-optimization/38449 (patch updated)

2012-09-29 Thread Eric Botcazou
cold partitioning.", + bool, (const_rtx follower, const_rtx followee), + hook_bool_const_rtx_const_rtx_true) Explicitly mention that both FOLLOWER and FOLLOWEE are JUMP_INSN instructions. -- Eric Botcazou

Re: [PATCH] Add -Og optimization level - optimize for compile-time/debugging experience

2012-09-29 Thread Eric Botcazou
> Which means that -O0 should also set optimize_debug to 1? -O0 is > then !optimize && optimize_debug and -Og is optimize == 1 && > optimize_debug. That sounds more confusing than helpful though. Adding (|| optimize_debug) in the relevant places is probably good enough. -- Eric Botcazou

[SPARC] Fix recent and older thinkos

2012-09-30 Thread Eric Botcazou
sted on SPARC/Linux, applied on the mainline. 2012-09-30 Eric Botcazou * reorg.c (relax_delay_slots): Use delay_insn consistently. * config/sparc/sparc.c (gen_stack_pointer_dec): Delete. (sparc_expand_epilogue): Use gen_stack_pointer_inc and adjust. (sparc_flat_ex

Re: [rtl] combine a vec_concat of 2 vec_selects from the same vector

2012-10-01 Thread Eric Botcazou
the above date and add the missing space at the end of: /* Try to merge 2 VEC_SELECTs from the same vector into a single one. */ -- Eric Botcazou

[i386] Fix unwind/debug info for nested functions on 64-bit Windows

2012-10-01 Thread Eric Botcazou
a). Tested on x86_64-suse-linux and with a 4.7-based SEH-enabled compiler for 64- Bit Windows. OK for mainline and 4.7 branch? 2012-10-01 Eric Botcazou * config/i386/i386.c (ix86_expand_prologue): Emit frame info for the special register pushes before frame probing

Re: [rtl] combine a vec_concat of 2 vec_selects from the same vector

2012-10-01 Thread Eric Botcazou
> > /* Try to merge 2 VEC_SELECTs from the same vector into a single one. */ > > I was trying to avoid splitting in 2 lines, but ok I'll split. Indeed. Then you can remove the '2' above, it doesn't add much. -- Eric Botcazou

[patch] Introduce DECL_NONLOCAL_FRAME

2012-10-02 Thread Eric Botcazou
Hi, this is the seemingly non-controversial part of the FRAME splitting patch. It introduces the DECL_NONLOCAL_FRAME flag, sets it during nested function lowering and... that's pretty much it. Tested on x86_64-suse-linux, OK for mainline? 2012-10-02 Eric Botcazou * t

[Ada] Couple of minor tweaks

2012-10-02 Thread Eric Botcazou
This avoids applying the NRV optimization for small structures and creating useless elaboration variables for loops. Tested on x86_64-suse-linux, applied on the mainline and 4.7 branch. 2012-10-02 Eric Botcazou * gcc-interfaces/decl.c (elaborate_expression_1): Use the variable for

Adjust gcc.dg/lower-subreg-1.c for SPARC

2012-10-04 Thread Eric Botcazou
Tested on SPARC/Solaris 10, applied on the mainline. 2012-10-04 Eric Botcazou PR rtl-optimization/54739 * gcc.dg/lower-subreg-1.c: Also skip on SPARC. -- Eric BotcazouIndex: gcc.dg/lower-subreg-1.c

[testsuite] Add support for -fdump-ada-spec

2012-10-04 Thread Eric Botcazou
Hi, the recent breakage of -fdump-ada-spec revealed that the switch isn't exercised in the testsuite. This patch adds the missing support. Tested on x86_64-suse-linux, OK for mainline? What of the 4.7 branch? 2012-10-04 Eric Botcazou * lib/gcc-dg.exp (cleanup-ada-spec)

Adjust gcc.dg/lto/20120723_0.c for SPARC

2012-10-04 Thread Eric Botcazou
As noted by Martin in http://gcc.gnu.org/ml/gcc-patches/2012-08/msg00116.html, the testcase is invalid C and cannot pass on SPARC 32-bit because of the ABI. Tested on SPARC/Solaris 10, applied on the mainline. 2012-10-04 Eric Botcazou * gcc.dg/lto/20120723_0.c: Skip on SPARC 32-bit

Re: [PATCH] Fix PR54811

2012-10-05 Thread Eric Botcazou
7;s recent changes in that area. -- Eric Botcazou

Re: RFA: Simplifying truncation and integer lowpart subregs

2012-10-06 Thread Eric Botcazou
/* SUBREG of a hard register => just change the register number > and/or mode. If the hard register is not valid in that mode, > suppress this simplification. If the hard register is the stack, Likewise. -- Eric Botcazou

Re: RFA: Simplifying truncation and integer lowpart subregs

2012-10-06 Thread Eric Botcazou
or TRUNCATEs and truncations to the lowpart, and why it is correct to generate new TRUNCATEs in the latter case. -- Eric Botcazou

Re: RFA: Simplifying truncation and integer lowpart subregs

2012-10-07 Thread Eric Botcazou
ON_MODES_P. > (simplify_subreg): Use simplify_truncate for lowpart subregs > where both the inner and outer modes are scalar integers. This looks good to me, thanks. -- Eric Botcazou

[testsuite] Minor housekeeping work

2012-10-08 Thread Eric Botcazou
Recent tests added to gcc.dg/tree-ssa don't clean up after themselves. Tested on x86_64-suse-linux, applied on the mainline as obvious. 2012-10-08 Eric Botcazou * gcc.dg/tree-ssa/slsr-30.c: Use correct cleanup directive. * gcc.dg/tree-ssa/attr-hotcold-2.c: Lik

[RFC] Implement load sinking in loops

2012-10-08 Thread Eric Botcazou
led at -O2 in the patch for measurement purposes but, given how rarely it triggers (e.g. exactly 10 occurrences in a GCC bootstrap, compiler-only, all languages except Go), it's probably best suited to -O3. Or perhaps we don't care and it should simply be dropped... Thoughts? Tested on x86_64-su

[RFC] Fix PR rtl-optimization/54315 (partially)

2012-10-08 Thread Eric Botcazou
ueabi (for now), where it also removes stores for small structures. Comments? 2012-10-08 Eric Botcazou * calls.c (expand_call): Don't deal specifically with BLKmode values returned in naked registers. * expr.h (copy_blkmode_from_reg): Adjust prototype.

[c-family] Small tweak to -fdump-ada-spec

2012-10-09 Thread Eric Botcazou
Hi, we noticed that we dump TEMPLATE_DECLs that are built for template friend declarations in the current file, which doesn't really make sense. Tested on x86_64-suse-linux, OK for the mainline? 2012-10-09 Eric Botcazou * c-ada-spec.c (dump_ada_template): Bail out for tem

[patch] Fix PR bootstrap/54820

2012-10-09 Thread Eric Botcazou
: LDFLAGS is correctly passed and set in gcc/ at configure time during stage 1, but a 'make' invocation from the toplevel passes an empty LDFLAGS to gcc/. Tested on x86_64-suse-linux, OK for the mainline? 2012-10-09 Eric Botcazou PR bootstrap/54820 * Ma

Re: [Patch, test] Enable to prune warnings for tests defined in one exp file

2012-10-10 Thread Eric Botcazou
* gcc.target/arm/arm.exp (dg_runtest_extra_prunes): Skip all the > harmless > architecture switch conflict warnings. Why does this appear in the gcc/ChangeLog on the 4.7 branch? -- Eric Botcazou

Fix PR testsuite/54867

2012-10-11 Thread Eric Botcazou
The new scan-rtl-dump-not I recently added needs to be tweaked so as to cater to x86-64 platforms like Solaris where the prologue isn't elided. Tested on x86_64-suse-linux, applied on the mainline as obvious. 2012-10-11 Eric Botcazou PR testsuite/54867 * gcc.dg/pr4419

Re: [c-family] Small tweak to -fdump-ada-spec

2012-10-11 Thread Eric Botcazou
> 2012-10-09 Eric Botcazou > > * c-ada-spec.c (dump_ada_template): Bail out for template declarations > declaring something coming from another file. That's a small patch affecting only -fdump-ada-spec so I went ahead and installed it on the mainline. -- Eric Botcazou

Re: [patch] Fix PR bootstrap/54820

2012-10-11 Thread Eric Botcazou
> 2012-10-09 Eric Botcazou > PR bootstrap/54820 > * Makefile.tpl (STAGE1_FLAGS_TO_PASS): New variable. > (host_modules): Add STAGE1_FLAGS_TO_PASS to args. > * Makefile.in: Regenerate. > * configure.ac (have_static_libs): New variable an

Re: [RFA:] Fix frame-pointer-clobbering in builtins.c:expand_builtin_setjmp_receiver

2012-10-12 Thread Eric Botcazou
tin_setjmp call. This is > - also called directly by the SJLJ exception handling code. */ > + also called directly by the SJLJ exception handling code. > + If RECEIVER_LABEL is NULL, instead the port-specific parts of a > + nonlocal goto handler are emitted. */ The "port-specific parts" wording is a bit confusing I think. I'd just write: If RECEIVER_LABEL is NULL, instead contruct a nonlocal goto handler. -- Eric Botcazou

Re: [RFC PATCH] Add support for sparc compare-and-branch.

2012-10-13 Thread Eric Botcazou
T_VIS4, > define __VIS__ to 0x400. What's the relationship between VIS4 and SPARC-T4 exactly? The above manual only speaks of VIS3 as far as I can see. And the CBcond instructions are not marked as belonging to VIS (3 or 4), so using -mvis4 for them seems strange. Why not make them depend on -mcpu=niagara4 instead? -- Eric Botcazou

Fix PR rtl-optimization/54871

2012-10-13 Thread Eric Botcazou
s is mightily confusing. Tested on x86_64-suse-linux and SPARC/Solaris, applied on the mainline. 2012-10-13 Eric Botcazou PR rtl-optimization/54871 * loop-iv.c (simplify_using_initial_values): When scanning previous basic blocks, prune the recorded conditions i

Re: [PR38711] Use DF_LIVE in IRA if it available (for -O2 and higher)

2012-10-13 Thread Eric Botcazou
can be done in a follow-up patch if necessary.) So, in the end, does the patch enable DF_LIVE at -O1 or not? There seems to be a contradiction between the subject and the body of the message. If yes, perhaps an acceptable compromise would be to keep things unchanged at -O1. -- Eric Botcazou

Re: [PR38711] Use DF_LIVE in IRA if it available (for -O2 and higher)

2012-10-13 Thread Eric Botcazou
e it's resource.c so...). -- Eric Botcazou

Re: [patch] PR54919 - fix variable expansion in RTL loop unrolling

2012-10-14 Thread Eric Botcazou
there make it clear that's indeed the intent. > Tested with a bootstrapped compiler. Test coverage isn't great, > because variable expansion is not enabled by default. OK, thanks (if you also add the testcase to gcc.dg with the special options). -- Eric Botcazou

[patch] Fix PR rtl-optimization/54870

2012-10-14 Thread Eric Botcazou
cfun->gimple_df->escaped.vars. Tested on x86-64/Linux and SPARC64/Solaris, OK for mainline and 4.7 branch? 2012-10-14 Eric Botcazou PR rtl-optimization/54870 * dse.c (can_escape): Test cfun->gimple_df->escaped.vars as well. * gimplify.c (mark_addressable): If this

Re: Fix twolf -funroll-loops -O3 miscompilation (a semi-latent web.c bug)

2012-10-14 Thread Eric Botcazou
help optimization. Removing it > just because b is dead at that point would be unnecessarily > pessimistic. But if you have a REG_DEAD note for b on the first insn, then you cannot rematerialize the REG_EQUAL note after it, otherwise bad things can happen. See PR rtl-optimization/51505 for an example. -- Eric Botcazou

Re: [RFC PATCH] Add support for sparc compare-and-branch.

2012-10-15 Thread Eric Botcazou
his point. How is this done on the Solaris Studio side? Couldn't we add a new architecture to the compiler (-mcpu=sparc4, with -mcpu=niagara4 as first variant), and define __sparc4__ for the preprocessor? -- Eric Botcazou

Re: [patch] Fix PR rtl-optimization/54870

2012-10-15 Thread Eric Botcazou
it in mark_addressable by means of decls_to_pointers and pi->pt.vars. That seems a bit redundant with cfun->gimple_df->escaped.vars, but why not. -- Eric Botcazou

Re: [patch] Fix PR rtl-optimization/54870

2012-10-15 Thread Eric Botcazou
ll})&A.17]; you don't know until expand whether this will a memcpy or a move by pieces and the info is needed for the enhanced DSE to work properly. -- Eric Botcazou

Fix double write of unchecked conversion to volatile variable

2012-10-15 Thread Eric Botcazou
the mainline. 2012-10-15 Eric Botcazou * expr.c (expand_expr_real_1) : Do not unnecessarily copy the object in the MEM_P case. 2012-10-15 Eric Botcazou * gnat.dg/unchecked_convert9.ad[sb]: New test. -- Eric B

[RFC] Fix spill failure at -O on 64-bit Windows

2012-10-15 Thread Eric Botcazou
ached patch prevents the invariant from being hoisted in this very particular case. Any better idea? Tested on x86_64-suse-linux. 2012-10-15 Eric Botcazou * loop-invariant.c: Include target.h. (check_dependency): Return false for an uninitialized argument register

[c-family] Fix -fdump-ada-spec buglet in C++

2012-10-15 Thread Eric Botcazou
Hi, since the sizetype change, we generate invalid Ada for flexible array members with -fdump-ada-spec in C++. The attached patch fixes this issue and also partially revamps the code to polish some rough edges. Tested on x86_64-suse-linux, OK for mainline? 2012-10-15 Eric Botcazou c

Re: [patch] Fix PR rtl-optimization/54870

2012-10-16 Thread Eric Botcazou
> As I'm not sure how to best do that I suggest we do a more proper RTL > DSE hack by adding a 'libcall-call-escape'-set which we can add to > instead of calling mark_addressable this late. We need to add all > partitions of a decl here, of course, and we need to query it from > can_escape. That

Re: [patch] Clean up code looking for call rtx

2012-10-16 Thread Eric Botcazou
hen is XEXP(call,0) _not_ a MEM? Good question. The manual seems to answer "never": A `call' expression has two operands, as follows: (call (mem:FM ADDR) NBYTES) -- Eric Botcazou

Re: [RFC PATCH] Add support for sparc compare-and-branch.

2012-10-16 Thread Eric Botcazou
ever we want > here. OK, thanks. I keep thinking that we should use -mcpu=sparc4/-D__sparc4__ for new instructions in the SPARC-T4 architecture that aren't related to VIS. And given Rainer's insight, I agree that switching to the -m{32,64} -xarch= scheme with recent assemblers is the way to go. I'll try and get my hands on one of them... -- Eric Botcazou

Re: [asan] Emit GIMPLE directly, small cleanups

2012-10-16 Thread Eric Botcazou
er end. IMHO we need to decide what to do in this case once for all. -- Eric Botcazou

Re: [RFC] Fix spill failure at -O on 64-bit Windows

2012-10-17 Thread Eric Botcazou
zed hard registers. The failure mode is very specific (and might be unique to the 64-bit ABI on Windows) so I'm not sure it's worth generalizing. -- Eric Botcazou

Re: [RFC] Fix spill failure at -O on 64-bit Windows

2012-10-17 Thread Eric Botcazou
alarmingly fast rates :-) > But I suppose your point of view is more pragmatic in this peculiar case. I'm just realistic: you don't want to make substantial changes in a powerful optimization pass just because of a corner case in an exotic language on a semi-exotic platform. :-) -- Eric Botcazou

Re: Tidy store_bit_field_1 & co.

2012-10-17 Thread Eric Botcazou
>mode = GET_MODE (op0); > - > - /* Now MODE is either some integral mode for a MEM as OP0, > - or is a full-word for a REG as OP0. TOTAL_BITS corresponds. > - The bit field is contained entirely within OP0. > - BITPOS is the starting bit number within OP0. > - (OP0's mode may actually be narrower than MODE.) */ > + gcc_assert (SCALAR_INT_MODE_P (mode)); > + /* Note that bitsize + bitnum can be greater than GET_MODE_BITSIZE (mode) > + for invalid input, such as f5 from gcc.dg/pr48335-2.c. */ Blank line after the assertion. >if (BYTES_BIG_ENDIAN) > - /* BITPOS is the distance between our msb > - and that of the containing datum. > - Convert it to the distance from the lsb. */ > - bitpos = total_bits - bitsize - bitpos; > +/* BITNUM is the distance between our msb > + and that of the containing datum. > + Convert it to the distance from the lsb. */ > +bitnum = GET_MODE_BITSIZE (mode) - bitsize - bitnum; So bitnum can be negative? Is that new or pre-existing? -- Eric Botcazou

Re: [asan] Emit GIMPLE directly, small cleanups

2012-10-17 Thread Eric Botcazou
t to run again into the issues we had with acats (Rainer puts a lot of efforts to clean up the mess here). -- Eric Botcazou

Re: [PATCH] Rs6000 infrastructure cleanup (switches), revised patch #2f

2012-10-18 Thread Eric Botcazou
n of macro 'OPTION_MASK_ALTIVEC' #define TARGET_ALTIVEC ((rs6000_isa_flags & OPTION_MASK_ALTIVEC) != 0) ^ /nile.build/botcazou/gcc-head/src/libobjc/../gcc/config/rs6000/sysv4.h:301:4: note: in expansion of macro 'TARGET_ALTIVEC' ((TARGET_ALTIVEC && TREE_CODE (TREE_TYPE (FIELD)) == VECTOR_TYPE) \ ^ /nile.build/botcazou/gcc-head/src/libobjc/encoding.c:1138:19: note: in expansion of macro 'ADJUST_FIELD_ALIGN' desired_align = ADJUST_FIELD_ALIGN (type, desired_align); ^ make[1]: *** [encoding.lo] Error 1 make[1]: Leaving directory `/nfs/nile/nile.build/botcazou/gcc-head/powerpc- linux-gnu/powerpc-linux-gnu/libobjc' make: *** [all-target-libobjc] Error 2 -- Eric Botcazou

Restore bootstrap on IA-64/Linux

2012-10-18 Thread Eric Botcazou
An unused variable left in except.c after Easwaran's recent patch. Tested on ia64-suse-linux, applied on the mainline as obvious. 2012-10-18 Eric Botcazou * except.c (sjlj_emit_function_enter): Remove unused variable. -- Eric BotcazouIndex: exc

[c-family] Small fix for -fdump-ada-spec

2012-10-18 Thread Eric Botcazou
The recent introduction of virtual locations revealed a weak spot in the implementation of -fdump-ada-spec. Tested on x86_64-suse-linux, applied on the mainline as obvious. 2012-10-18 Eric Botcazou * c-ada-spec.c (LOCATION_COL): Delete. (compare_location): New function

Re: [PATCH] Rs6000 infrastructure cleanup (switches), revised patch #2f

2012-10-19 Thread Eric Botcazou
ur respective systems? Thanks in > advance. It works for me, thanks. -- Eric Botcazou

[ping] couple of fixes

2012-10-19 Thread Eric Botcazou
Unwind/debug info on x86-64/Windows: http://gcc.gnu.org/ml/gcc-patches/2012-10/msg00013.html PR bootstrap/54820 (stage #1 bootstrap failure) http://gcc.gnu.org/ml/gcc-patches/2012-10/msg01093.html -- Eric Botcazou

Re: Tidy store_bit_field_1 & co.

2012-10-20 Thread Eric Botcazou
punning between equal-sized modes. */ rtx sub = simplify_gen_subreg (fieldmode, op0, GET_MODE (op0), bitnum / BITS_PER_UNIT); if (sub) { emit_move_insn (sub, value); return true; } } In any case, no need to retest, I'd apply it and wait for the apocalypse. :-) -- Eric Botcazou

Re: [RFC] Fix PR rtl-optimization/54315 (partially)

2012-10-20 Thread Eric Botcazou
(store_expr): Likewise. > (store_field): Likewise. Applied after testing on x86_64-suse-linux and mips64el-linux-gnu, where it also removes stores for small structures (at least for n32). -- Eric Botcazou

Follow-up to PR rtl-optimization/44194

2012-10-21 Thread Eric Botcazou
As remarked by Richard S., we can now allow sibling calls in the PARALLEL case after the fix for PR rtl-optimization/44194. Tested on x86_64-suse-linux and mips64el-linux-gnu, applied on the mainline. 2012-10-21 Eric Botcazou PR rtl-optimization/44194 * calls.c (expand_call

XFAIL a couple of gnat.dg testcases on MIPS

2012-10-21 Thread Eric Botcazou
They are reported as failing with the n32 ABI, but the failures are spurious. Tested on mips64el-linux-gnu, applied on the mainline and 4.7 branch. 2012-10-21 Eric Botcazou * gnat.dg/specs/atomic1.ads: XFAIL on MIPS. * gnat.dg/specs/addr1.ads: Likewise. -- Eric

[MIPS] Implement static stack checking

2012-10-21 Thread Eric Botcazou
mips64el-linux-gnu (n32/32/64), OK for the mainline? 2012-10-21 Eric Botcazou * config/mips/linux-common.h (STACK_CHECK_STATIC_BUILTIN): Define. (STACK_CHECK_PROTECT): Likewise. * config/mips/mips-protos.h (mips_output_probe_stack_range): Declare. * config/mips

[Ada] Do not generate special PARM_DECL in LTO mode

2012-10-22 Thread Eric Botcazou
We generate a special PARM_DECL for Out parameters passed by copy at -O0, but it doesn't play nice with LTO so this patch removes it when LTO is enabled. Tested on x86_64-suse-linux, applied on the mainline and 4.7 branch. 2012-10-22 Eric Botcazou * gcc-interface/d

[Ada] Fix ICE on loop with modular iteration variable

2012-10-22 Thread Eric Botcazou
This is a regression at -O present on mainline and 4.7 branch. The compiler inadvertently uses a non-base type for the base type of a modular iteration variable on 32-bit architectures. Tested on x86_64-suse-linux, applied on the mainline and 4.7 branch. 2012-10-22 Eric Botcazou

[Ada] Fix ICE on new limited_with use in Ada 2012

2012-10-22 Thread Eric Botcazou
Botcazou * gcc-interface/decl.c (gnat_to_gnu_entity) : In type annotation mode, break circularities introduced by AI05-0151. 2012-10-22 Eric Botcazou * gnat.dg/specs/limited_with4.ads: New test. * gnat.dg/specs/limited_with4_pkg.ads: New helper. -- Eric

[Ada] Adjust rest_of_record_type_compilation to sizetype change

2012-10-22 Thread Eric Botcazou
The function does a bit of pattern matching to emit the special encoding for variable-sized record types in the debug info and it needs to be adjusted to the sizetype change. Tested on x86_64-suse-linux, applied on the mainline. 2012-10-22 Eric Botcazou * gcc-interface/utils.c

[Ada] Plug small hole in handling of volatile components

2012-10-22 Thread Eric Botcazou
This pertains only to small arrays, for which we fail to take into account a pragma Volatile on the component type or a pragma Volatile_Component. Tested on x86_64-suse-linux, applied on the mainline and 4.7 branch. 2012-10-22 Eric Botcazou * gcc-interface/decl.c

Re: [Ada] Do not generate special PARM_DECL in LTO mode

2012-10-22 Thread Eric Botcazou
he VAR_DECL emitted in the outermost function scope. It doesn't survive with optimization enabled so we don't bother generating it in this case. -- Eric Botcazou

Re: [MIPS] Implement static stack checking

2012-10-22 Thread Eric Botcazou
the delay slot; there's > a blank line after it instead. That's all handled by output_asm_insn > though.) Thanks for the incantation! > OK with those changes, thanks. I'll retest with the changes tomorrow. Thanks for the review. -- Eric Botcazou

Re: [MIPS] Implement static stack checking

2012-10-22 Thread Eric Botcazou
$0,0(r1) > > ? The latter will always probe once, the former won't, if ROUNDED_SIZE == 0. -- Eric Botcazou

Re: Tidy extract_bit_field_1 & co.

2012-10-23 Thread Eric Botcazou
hat the processed OP0 > has an integral mode. > (store_split_bit_field): Update the call to store_fixed_bit_field. This looks good to me (modulo the counterpart of the corresponding change in the first patch for which I cannot really tell whether it's right or wrong). -- Eric Botcazou

Follow-up to PR bootstrap/54820

2012-10-23 Thread Eric Botcazou
fail. Tested with GCC 4.3 and GCC 4.5, OK for mainline? 2012-10-23 Eric Botcazou PR bootstrap/54820 * configure.ac (have_static_libs): Force 'no' for GCC version < 4.5. * configure: Regenerate. -- Eric BotcazouI

Re: Tidy store_bit_field_1 & co.

2012-10-23 Thread Eric Botcazou
> > so both the following hold: > > offset = 0 > bitpos = bitnum % BITS_PER_WORD + ( - ); > > offset = 0 > bitpos = bitnum + ( - ); > > 6) For REG, BYTES_BIG_ENDIAN, !BITS_BIG_ENDIAN: > > Like (5) but we also have: > > unit = GET_MODE_BITSIZE (op_mode); > if (BITS_BIG_ENDIAN != BYTES_BIG_ENDIAN) > xbitpos = unit - bitsize - xbitpos; > > This is the same as before, except that the UNIT assignment became > part of (5). > > Hope I've got that right... > > Of course, the idea is that the new code should make sense from first > principles. This was just trying to show that it isn't supposed to have > changed the behaviour. Thanks for the explanation (or rather the proof :-). No objections by me. -- Eric Botcazou

<    1   2   3   4   5   6   7   8   9   10   >