Fix PR rtl-optimization/55630

2012-12-16 Thread Eric Botcazou
This is an ICE for g++.dg/pr48660.C on HP-PA/Linux introduced by: http://gcc.gnu.org/ml/gcc-patches/2012-10/msg00745.html When I wrote it, I convinced myself that the HP-PA wasn't using the BLKmode registers path any more and wrapped everything in PARALLELs for return values, so it tested the

[SPARC] Fix PR target/55673

2012-12-16 Thread Eric Botcazou
As reported by Tomash, the handling of the before and after cases is reversed in sparc_emit_membar_for_model. Moreover, there is a pasto in sync.md that disables the atomic_store expander. Tested on SPARC/Linux, applied on the mainline and 4.7 branch. 2012-12-16 Eric Botcazou

Re: [fortran, patch] Allow displaying backtraces from user code

2012-12-16 Thread Tobias Burnus
Janus Weil wrote: So, in principle I'm fine with all your BACKTRACE_* variants (except for _splurge, maybe;) Or, why not just (plain and simple) BACKTRACE? The name is the same as backtrace() in glibc, but otherwise, sure why not. _show/_print might be preferable in the sense that they convey

Re: [Patch, Fortran] PR 55072: [4.6/4.7/4.8 Regression] Missing internal_pack leads to wrong code with derived type

2012-12-16 Thread Janus Weil
Hi Tobias, here is a patch for a pretty bad wrong-code regression, which affects all maintained releases of gfortran. For discussion see bugzilla. 2012-12-15 Janus Weilja...@gcc.gnu.org PR fortran/55072 * trans-array.c (gfc_conv_array_parameter): No packing was done for

Re: [Patch,Fortran] reset dynamic type with MOVE_ALLOC (was: Re: [Patch, Fortran] Small patch for calls to gfc_deallocate_scalar_with_status)

2012-12-16 Thread Paul Richard Thomas
Dear Tobias, This does what it is advertised to do - OK for trunk Thanks for the patch. Paul PS Thomas has beaten it to me on the other two patches; they look OK for trunk to me too. On 9 December 2012 20:04, Tobias Burnus bur...@net-b.de wrote: Janus Weil wrote: The expr to al-expr change

Re: [fortran, patch] Allow displaying backtraces from user code

2012-12-16 Thread Janus Weil
So, in principle I'm fine with all your BACKTRACE_* variants (except for _splurge, maybe;) Or, why not just (plain and simple) BACKTRACE? The name is the same as backtrace() in glibc, but otherwise, sure why not. _show/_print might be preferable in the sense that they convey that stuff

Re: Patch to enable unlimited polymorphism to gfortran

2012-12-16 Thread Tobias Burnus
Thanks for the patch, here is a first but incomplete review. I think the patch looks mostly okay. Running your test cases through crayftn, I found: if (SAME_TYPE_AS (obj1, u1) .neqv. .FALSE.) call abort ^ ftn-1698 crayftn: ERROR $MAIN, File =

[PATCH] Fix Infinite loop in pointer_set_insert

2012-12-16 Thread John David Anglin
The attached patch fixes a regression introduced on the trunk to fix PR middle-end/52640. The fix was previously applied to the 4.6 and 4.7 branches. Tested on hppa-unknown-linux-gnu with full bootstrap. OK for trunk? Dave -- J. David Anglin

Re: [PATCH] Fix Infinite loop in pointer_set_insert

2012-12-16 Thread Richard Biener
On Sun, Dec 16, 2012 at 5:33 PM, John David Anglin d...@hiauly1.hia.nrc.ca wrote: The attached patch fixes a regression introduced on the trunk to fix PR middle-end/52640. The fix was previously applied to the 4.6 and 4.7 branches. Tested on hppa-unknown-linux-gnu with full bootstrap. OK

Re: Patch to enable unlimited polymorphism to gfortran

2012-12-16 Thread Paul Richard Thomas
Dear Tobias, Up front, thanks for this initial feedback. Dominique informed me on #gfortran that the patch works as advertised. ...snip... Running your test cases through crayftn, I found: if (SAME_TYPE_AS (obj1, u1) .neqv. .FALSE.) call abort ^ ftn-1698

Re: Patch to enable unlimited polymorphism to gfortran

2012-12-16 Thread Tobias Burnus
Paul Richard Thomas wrote: + /* Unlimited polymorphic pointers should have their vptr nullified. */ + if (UNLIMITED_POLY (sym) CLASS_DATA (sym)-attr.pointer) +gfc_defer_symbol_init (sym); Why? If the pointer has never been pointer-associated, one shouldn't access It's so that

Re: [PATCH] Fix Infinite loop in pointer_set_insert

2012-12-16 Thread Dominique Dhumieres
The attached patch fixes a regression introduced on the trunk to ... This breaks bootstrap on x86_64-apple-darwin10: ../../work/gcc/varasm.c:2094:13: error: 'pending_assemble_externals_processed' defined but not used [-Werror=unused-variable] static bool pending_assemble_externals_processed;

[patch] std::thread must rethrow __forced_unwind exceptions

2012-12-16 Thread Jonathan Wakely
* src/c++11/thread.cc (execute_native_thread_routine): Do not swallow __forced_unwind exceptions. * testsuite/30_threads/thread/native_handle/cancel.cc: New. Tested x86_64-linux, committed to trunk, will commit to 4.7 and 4.6 branches asap. commit

[PATCH][Revisedx2] PR55679: skip invalid tests from r194458 on darwin

2012-12-16 Thread Jack Howarth
The attached revised patch disables three asan tests introduced in r194458 which are invalid on darwin. The g++.dg/asan/interception-test-1.C test should be dg-skip-if'd on darwin since mac function interposition is used instead of interception. The c-c++-common/asan/swapcontext-test-1.c

Re: [PATCH][Revisedx2] PR55679: skip invalid tests from r194458 on darwin

2012-12-16 Thread Dominique Dhumieres
Hi jack, +// { dg-skip-if Darwin lacks RLIMIT_AS in setrlimit { *-*-darwin* } } The comment is not fully accurate. See pr55679 comment #17 for some analysis and another candidate patch for rlimit-mmap-test-1.c (it will detect any fix by Apple). Cheers, Dominique

Re: Patch to enable unlimited polymorphism to gfortran

2012-12-16 Thread Tobias Burnus
Paul Richard Thomas wrote: The problem is with the way in which extends_type_of is organised. It takes the _vptr directly. Unless it is null for undefined pointers, a segfault is triggered. So what? If I have: integer, pointer :: ptr ptr = 5 will also lead to a segfault (or a bus error);

[PATCH] Another fix for PR54838

2012-12-16 Thread Marek Polacek
Here's a fix for the C++ TC part of this PR. The issue was that we had a loop with header and two latches, and via delete_basic_block we deleted both latches, but we weren't removing the loop properly. This ICEd later on because in merge_latch_edges there's an assert: gcc_assert (latches.length

Re: [cxx-conversion] Convert tree-sra.c'candidates to hash_table

2012-12-16 Thread Lawrence Crowl
On 12/13/12, Martin Jambor mjam...@suse.cz wrote: On Thu, Dec 13, 2012 at 11:05:49AM -0800, Lawrence Crowl wrote: On 12/12/12, Jakub Jelinek ja...@redhat.com wrote: On Tue, Dec 11, 2012 at 02:44:41PM -0800, Lawrence Crowl wrote: +/* Hash a tree in a uid_decl_map. */ + +inline