Re: [PATCH] Fix up ppc64-linux profiledbootstrap - .toc section references in .debug_loc (PR target/51957)

2012-01-24 Thread Alan Modra
On Tue, Jan 24, 2012 at 08:36:11AM +0100, Jakub Jelinek wrote: If you relax the checking too much, don't you risk that something other than the TOC register value is being added to the UNSPEC_TOCREL? Say, if you have an 8byte object in .toc, and some loop body uses ((char *) object)[1 + iv];

Re: [PATCH] PR c++/50852 - loose template parameter comparison

2012-01-24 Thread Dodji Seketeli
How about if we just store a pointer to the template parameter list and do comp_template_parms? I tried a variation of this approach below. My understanding is that comp_template_parms wouldn't work as is, at least because it can lead to an endless recursion: Suppose we start comparing the

Re: Fix regression on PR46590 (slow compile with -O0)

2012-01-24 Thread Richard Guenther
On Mon, Jan 23, 2012 at 6:01 PM, Michael Matz m...@suse.de wrote: Hi, On Sat, 21 Jan 2012, Eric Botcazou wrote: Trivially fixing the thinko (iterating over (work bit-and old_conflict) in the first inner loop) would fix the testcase but in general create too few conflicts, i.e. generate

Re: [ C frontend ] add support for builtins that take signed and unsigned md types

2012-01-24 Thread Richard Guenther
On Mon, Jan 23, 2012 at 6:12 PM, Mike Stump mikest...@comcast.net wrote: On Jan 23, 2012, at 3:00 AM, Richard Guenther wrote: So, yes, please have only one loop. Updated patch included. Ok? Ok. Thanks, Richard.

Re: RFA: cgraph PATCH for c++/51812 (link failure with undefined/unneeded virtual function)

2012-01-24 Thread Richard Guenther
On Mon, Jan 23, 2012 at 7:03 PM, Jason Merrill ja...@redhat.com wrote: In this testcase, main doesn't call anything, so the inline functions in the classes can be optimized away, and we don't need the vtables or the virtual functions they refer to.  But cgraph_decide_is_function_needed wants to

Patch ping

2012-01-24 Thread Jakub Jelinek
Hi! I'd like to ping following patch: - http://gcc.gnu.org/ml/gcc-patches/2012-01/msg00819.html P2 option handling ICE with -Wp,-pie or -Wp,-shared Jakub

Re: RFA: fix PR 51649

2012-01-24 Thread Richard Guenther
On Mon, Jan 23, 2012 at 8:36 PM, Tom Tromey tro...@redhat.com wrote: This patch fixes some pretty-printer bugs pointed out in PR 51649. The bug in the PR is that the pretty-printers don't work if you build with --enable-symvers=gnu-versioned-namespace. This patch adds test cases for all the

Re: RFA: fix PR 51649

2012-01-24 Thread Jakub Jelinek
On Tue, Jan 24, 2012 at 11:29:12AM +0100, Richard Guenther wrote: We're technically in regression-fixes-only mode. We give target/language maintainers some extra freedom though - while C++/libstdc++ are considered release critical and thus should not regress at this point I'm less sure about

Re: [PATCH] Fix for PR51879 - Missed tail merging with non-const/pure calls

2012-01-24 Thread Richard Guenther
On Mon, Jan 23, 2012 at 10:27 PM, Tom de Vries tom_devr...@mentor.com wrote: Richard, Jakub, the following patch fixes PR51879. Consider the following test-case: ... int bar (int); void baz (int); void foo (int y) {  int a;  if (y == 6)    a = bar (7);  else    a = bar (7);  baz

Re: [patch] Fix mismatched #pragma GCC visibility

2012-01-24 Thread Paolo Carlini
Hi, While trying to improve clang's handling of #pragma GCC visibility I found out that libstdc++-v3/libsupc++/typeinfo looks like #pragma GCC visibility push(default) extern C++ { #pragma GCC visibility pop } Is that supposed to work or just happens to? If desired, the attached patch moves

Re: [PATCH] Improve PHI-OPT when there are multiple phis

2012-01-24 Thread Richard Guenther
On Tue, Jan 24, 2012 at 7:34 AM, Andrew Pinski andrew.pin...@caviumnetworks.com wrote: Hi,  Right now PHI-OPT does try to handle the case where we have multiple PHIs but the other PHIs have the same value for the edges we care about. This fixes the issue and allows PHI-OPT to handle a few

Re: [patch] Fix mismatched #pragma GCC visibility

2012-01-24 Thread Jakub Jelinek
On Tue, Jan 24, 2012 at 11:45:55AM +0100, Paolo Carlini wrote: Hi, While trying to improve clang's handling of #pragma GCC visibility I found out that libstdc++-v3/libsupc++/typeinfo looks like #pragma GCC visibility push(default) extern C++ { #pragma GCC visibility pop } Is that

Re: Patch ping

2012-01-24 Thread Richard Guenther
On Tue, Jan 24, 2012 at 11:28 AM, Jakub Jelinek ja...@redhat.com wrote: Hi! I'd like to ping following patch: - http://gcc.gnu.org/ml/gcc-patches/2012-01/msg00819.html  P2 option handling ICE with -Wp,-pie or -Wp,-shared Ok. Thanks, Richard.        Jakub

Re: [patch] Fix mismatched #pragma GCC visibility

2012-01-24 Thread Paolo Carlini
Thanks for raising the issue. To me the above looks like a straightforward typo, which we should fix as soon as possible (not sure whether we could also diagnose it). Jason, Jakub, can you confirm? While we can change it, it is certainly valid as is, #pragma GCC visibility can happen in lots of

Re: [build] Cleanup rs6000/t-ppccomm configurations (PR other/51022)

2012-01-24 Thread Alan Modra
On Mon, Dec 05, 2011 at 07:25:35PM -0500, David Edelsohn wrote: Is this fixed or is someone writing a follow-up patch? This does the trick. You could also use case ${host}:${with_multisubdir} in *:*32*) ;; powerpc64-*:* | *:*64*)

Re: [build] Cleanup rs6000/t-ppccomm configurations (PR other/51022)

2012-01-24 Thread Paolo Bonzini
On 01/24/2012 12:20 PM, Alan Modra wrote: On Mon, Dec 05, 2011 at 07:25:35PM -0500, David Edelsohn wrote: Is this fixed or is someone writing a follow-up patch? This does the trick. You could also use case ${host}:${with_multisubdir} in *:*32*) ;;

[patch] remove empty directories (libgo, libstdc++-v3, libgomp)

2012-01-24 Thread Matthias Klose
Ok to remove these three empty directories? libgo/go/exp/template libstdc++-v3/testsuite/30_threads/condition_variable_any/requirements libgomp/config/linux/arm

Re: [build] Cleanup rs6000/t-ppccomm configurations (PR other/51022)

2012-01-24 Thread Rainer Orth
Alan Modra amo...@gmail.com writes: On Mon, Dec 05, 2011 at 07:25:35PM -0500, David Edelsohn wrote: Is this fixed or is someone writing a follow-up patch? This does the trick. You could also use case ${host}:${with_multisubdir} in *:*32*) ;;

Re: [RFC] Fixing expansion of misaligned MEM_REFs on strict-alignment targets

2012-01-24 Thread Richard Guenther
On Fri, 6 Jan 2012, Martin Jambor wrote: Hi, I'm trying to teach our expander how to deal with misaligned MEM_REFs on strict alignment targets. We currently generate code which leads to bus error signals due to misaligned accesses. I admit my motivation is not any target in particular

Re: [patch] remove empty directories (libgo, libstdc++-v3, libgomp)

2012-01-24 Thread Jonathan Wakely
On 24 January 2012 11:31, Matthias Klose wrote: Ok to remove these three empty directories? libgo/go/exp/template libstdc++-v3/testsuite/30_threads/condition_variable_any/requirements libgomp/config/linux/arm OK for the libstdc++ dir, I should have removed it in rev 180454 Thanks.

Re: [RFC] Fixing expansion of misaligned MEM_REFs on strict-alignment targets

2012-01-24 Thread Richard Guenther
On Tue, 24 Jan 2012, Richard Guenther wrote: One issue that I am running into now is that we need to robustify/change expand_assignment quite a bit. I have a patch for SRA that makes sure to create properly aligned MEM_REFs but then we have, for example MEM[p].m = ... and in the

Re: [libitm] Link eh-1.exe with -shared-libgcc on Solaris (PR libitm/51822)

2012-01-24 Thread Rainer Orth
Richard Henderson r...@redhat.com writes: On 01/17/2012 04:07 AM, Rainer Orth wrote: * The 32-bit failures on Solaris 8 to 10 have a different root cause: _Unwind_Find_FDE returns NULL for an address in _ZGTtL2f1v (f1()). It turns out that there are two copies of the unwinder in

Re: [trans-mem,c++] PR51928

2012-01-24 Thread Aldy Hernandez
On 01/23/12 18:34, Patrick Marlier wrote: Hi, In this PR51928, it tries to look_for_tm_attr_overrides on a thunk but there is no DECL_NAME for thunk. So it fails in lookup_fnfields_idx_nolazy because name is NULL. #0 0x00764b5a in lookup_fnfields_idx_nolazy (type=0x769f77e0,

Re: [trans-mem] Do not instrument thread locals

2012-01-24 Thread Aldy Hernandez
On 01/24/12 01:34, Richard Henderson wrote: On 01/24/2012 09:59 AM, Patrick Marlier wrote: 2012-01-23 Patrick Marlierpatrick.marl...@gmail.com * trans-mem.c (requires_barrier): Do not instrument thread local variables and emit save/restore for them. testsuite/ChangeLog

Re: [patch] remove empty directories (libgo, libstdc++-v3, libgomp)

2012-01-24 Thread Jakub Jelinek
On Tue, Jan 24, 2012 at 12:31:46PM +0100, Matthias Klose wrote: Ok to remove these three empty directories? libgo/go/exp/template libstdc++-v3/testsuite/30_threads/condition_variable_any/requirements libgomp/config/linux/arm The libgomp one only if you also remove linux/arm path from

[PATCH][2/n] Fix PR50444, SRA and misaligned accesses

2012-01-24 Thread Richard Guenther
This creates a get_pointer_alignment_1 function, similar to get_object_alignment_1 for use by SRA (and for consistency). SRA needs to be conservative with its alignment assertions when building MEM_REFs. The following patch changes the single place where we build them. Together with the posted

Re: [trans-mem,c++] PR51928

2012-01-24 Thread Patrick Marlier
On 01/24/2012 08:32 AM, Aldy Hernandez wrote: On 01/23/12 18:34, Patrick Marlier wrote: Hi, In this PR51928, it tries to look_for_tm_attr_overrides on a thunk but there is no DECL_NAME for thunk. So it fails in lookup_fnfields_idx_nolazy because name is NULL. #0 0x00764b5a in

Re: [build] Cleanup rs6000/t-ppccomm configurations (PR other/51022)

2012-01-24 Thread David Edelsohn
On Tue, Jan 24, 2012 at 6:20 AM, Alan Modra amo...@gmail.com wrote: On Mon, Dec 05, 2011 at 07:25:35PM -0500, David Edelsohn wrote: Is this fixed or is someone writing a follow-up patch? This does the trick.  You could also use        case ${host}:${with_multisubdir} in            *:*32*)  

[PATCH][3/n] Fix PR50444, misalignment issues and SRA

2012-01-24 Thread Richard Guenther
This addresses a defect in handling movmisalign-handled stores when they are wrapped in component-references (think of a vector mode aggregate containing a single vector, wrapped with a BIT_FIELD_REF to store a single vector element). I ran into this issue while trying to fix PR50444 (and made

[patch, testsuite] fix test gcc.dg/pr50908-2.c

2012-01-24 Thread Greta Yorsh
The test gcc.dg/pr50908-2.c fails on arm and other targets where short enums is the default. arm-none-eabi-gcc /work/local-checkouts/main/gcc-fsf/gcc/testsuite/gcc.dg/pr50908-2.c /work/local-checkouts/main/gcc-fsf/gcc/testsuite/gcc.dg/pr50908-2.c:39:8: error: width of 'code' exceeds its type

[Patch ARM] Fix PR 49069.

2012-01-24 Thread Sameera Deshpande
Hi, Please find attached the patch fixing bug 49069. This patch is tested with check-gcc on trunk and 4.6 without regression. OK for trunk? Is it fine to backport to 4.6 branch? ChangeLog: 2012-01-24 Sameera Deshpande sameera.deshpa...@arm.com PR target/49069

Re: [v3] libstdc++/49829

2012-01-24 Thread Matthias Klose
On 24.01.2012 00:27, Benjamin Kosnik wrote: This modularizes the libstdc++ sources such that the resulting library binaries are now composed of three convenience libraries. In short: this breaks builds configured with --enable-libstdcxx-debug. Tried the following (not yet working) fix.

C++ PATCH for c++/51973 (rejects-valid with explicit template args in call in function signature)

2012-01-24 Thread Jason Merrill
When we compare dependent names, we need to compare any explicit template args as well. Tested x86_64-pc-linux-gnu, applying to trunk. commit 7446bd5c430bab0ea5b496b93d92d298bb023572 Author: Jason Merrill ja...@redhat.com Date: Tue Jan 24 10:42:22 2012 -0500 PR c++/51973 * tree.c

Go patch committed: Better handling of erroneous functions

2012-01-24 Thread Ian Lance Taylor
This patch to the Go frontend improves the handling of erroneous function signatures, avoiding knock-on errors in various different ways. It has no effect on correct programs. Bootstrapped and ran Go testsuite on x86_64-unknown-linux-gnu. Committed to mainline. Ian Index:

Fix target/51968: arm neon ice on vconcat

2012-01-24 Thread Richard Henderson
When I re-arranged the vconcat support for vec_perm, I forgot that one must emit *something* in order to effect a split; failure is equated with nothing being emitted. Tested with qemu-arm, with more testing by the PR reporter. Committed. r~ PR target/51968 * config/arm/arm.c

[patch] libitm: Fix wake-up of readers in futex-based serial lock.

2012-01-24 Thread Torvald Riegel
This patch fixes a lost wake-up bug in the futex-based serial lock implementation. The previous code lacked some pieces of synchronization (a seq_cst barrier and resetting a flag that is checked by the respective futex_wait()), which led to those lost wake-ups when waking and waiting were racing

sparc: fix v7 memory barrier handling

2012-01-24 Thread Richard Henderson
While investigating atomic-test-and-set problems, I found that sparc v7 wasn't matching the memory barrier as desired. The problem turned out to be that the lack of a match_code containing const_int meant that genpreds generated the wrong mode test within the predicate. Which meant that no

Re: [patch, testsuite] fix test gcc.dg/pr50908-2.c

2012-01-24 Thread Mike Stump
On Jan 24, 2012, at 7:55 AM, Greta Yorsh wrote: The test gcc.dg/pr50908-2.c fails on arm and other targets where short enums is the default. * gcc.dg/pr50908-2.c (dg-options): Add -fno-short-enums. Ok.

[Patch, Fortran] PR 51966 - Fix struct constructor with character-parameter

2012-01-24 Thread Tobias Burnus
Hi all, first: I am still looking for someone to review my patch at http://gcc.gnu.org/ml/fortran/2012-01/msg00197.html * * * In PR 44857, a patch was added which changed: = dt_constructor ( character_parameter_array ) to = dt_constructor ( (/ character(len=n) ::

Re: [libitm] Link eh-1.exe with -shared-libgcc on Solaris (PR libitm/51822)

2012-01-24 Thread Richard Henderson
On 01/25/2012 12:03 AM, Rainer Orth wrote: Er.. how did we get two copies? The link line boils down to ld -o eh-1.exe crt1.o crti.o crtbegin.o eh-1.o -litm -lstdc++ -lm -lgcc -lgcc_eh -lc -lgcc -lgcc_eh crtend.o crtn.o The eh-1.o reference to _Unwind_Resume drags in one copy of the

Re: [patch] libitm: Fix wake-up of readers in futex-based serial lock.

2012-01-24 Thread Richard Henderson
On 01/25/2012 04:43 AM, Torvald Riegel wrote: libitm: Fix wake-up of readers in futex-based serial lock. libitm/ * config/linux/rwlock.cc (GTM::gtm_rwlock::write_unlock): Fix reader wake-up. Ok. r~

Re: [PATCH] Fix PR33763

2012-01-24 Thread Joseph S. Myers
On Mon, 16 Jan 2012, Richard Guenther wrote: + /* Do not merge an extern inline decl with any other decl either. */ + if ((DECL_DECLARED_INLINE_P (newdecl) + DECL_EXTERNAL (newdecl)) + || (!flag_gnu89_inline +(DECL_DECLARED_INLINE_P (newdecl) +

Re: [testsuite] Avoid assuming argc != 0

2012-01-24 Thread Richard Sandiford
Mike Stump mikest...@comcast.net writes: On Jan 23, 2012, at 11:13 AM, Richard Sandiford wrote: One fix is attached. Another would be to read from a volatile variable that has been initialised to 1. Other possibilities exist too of course. Tested on mipsisa64-elf. OK to install? Ok. I

[MIPS, committed] Fix target conditions for MIPS3D instructions

2012-01-24 Thread Richard Sandiford
All the MIPS3D patterns were testing the wrong condition: TARGET_PAIRED_SINGLE_FLOAT rather than TARGET_MIPS3D. I think this has been latent since the MIPS3D support was added, but it was shielded by the definitions of the built-in functions, which require TARGET_MIPS3D. We now use these

[ping 4] [patch] attribute to reverse bitfield allocations

2012-01-24 Thread DJ Delorie
Ping 4... Ping 3? It's been months with no feedback... Ping 2 ? http://gcc.gnu.org/ml/gcc-patches/2011-07/msg01889.html http://gcc.gnu.org/ml/gcc-patches/2011-07/msg02555.html http://gcc.gnu.org/ml/gcc-patches/2012-01/msg00529.html

[MIPS, committed] Clean up vect.exp results

2012-01-24 Thread Richard Sandiford
...for -mpaired-single at least. Although the patch shows the intention of making this specific to -mpaired-single, we don't distinguish between integer and float capabilities, so the condition effectively triggers for Loongson integer vectors too. The patch is still correct for floats on

[committed] Avoid optabs.c warning

2012-01-24 Thread Richard Sandiford
If the target doesn't have an atomic_test_and_set pattern, we'd warn about mode being unused. Tested on mips64-linux-gnu and applied as obvious. Richard gcc/ * optabs.c (gen_atomic_test_and_set): Use each argument. Index: gcc/optabs.c

[pph] Factor out some tree header reading code (issue5575050)

2012-01-24 Thread Diego Novillo
This patch factors out some code, which was making debugging unnecessarily confusing. When we read the header of a tree, we first read an LTO tag marker to identify what kind of tree we are reading. However, we were doing this *outside* of pph_in_tree_header, which resulted in code duplication

Fix several atomic_test_and_set problems

2012-01-24 Thread Richard Henderson
I thought there was a PR for this, but I can't find it. A report about problems using the atomic_test_and_set pattern for SH showed that we weren't being completely sane with the mode handling of the boolean output. Further investigation showed that the docs didn't match the implementation (or

Go patch committed: Fix type switch block

2012-01-24 Thread Ian Lance Taylor
In Go, in a type switch like switch t := 0; t := x.(type) the two variables named 't' are in different blocks; they are not a redefinition. This patch implements that in gccgo. Bootstrapped and ran Go testsuite on x86_64-unknown-linux-gnu. Committed to mainline. Ian diff -r

Re: C++ PATCH for c++/51889 (problem overloading function using in template)

2012-01-24 Thread Fabien Chêne
2012/1/19 Jason Merrill ja...@redhat.com: When we have a class-scope using-declaration that nominates functions, we want to insert those functions into the derived class' CLASSTYPE_METHOD_VEC.  In non-template code we do this in handle_using_decl, which is called from check_bases_and_members.  

[RFC] Disable FWPROP on pathological cases

2012-01-24 Thread Eric Botcazou
Starting with the 4.5.x series, we have pathological cases (Ada code generated by a code generator from a model) where FWPROP takes 80% of the compilation time at -O1 (for essentially no benefits). There are very few basic blocks (typically 1) and tens of thousands of uses registered with DF,

Re: [RFC] Disable FWPROP on pathological cases

2012-01-24 Thread Jakub Jelinek
On Tue, Jan 24, 2012 at 10:26:28PM +0100, Eric Botcazou wrote: +static bool +is_too_expensive (const char *pass) +{ + int ratio = DF_USES_TABLE_SIZE () / (n_basic_blocks - NUM_FIXED_BLOCKS); + + /* Trying to propagate into uses in functions with gigantic basic blocks + will take a

Re: [4.7][google] Adding a new option -fstack-protector-strong. (issue 5461043)

2012-01-24 Thread xur
OK for google branches. http://codereview.appspot.com/5461043/diff/16001/gcc/cfgexpand.c File gcc/cfgexpand.c (right): http://codereview.appspot.com/5461043/diff/16001/gcc/cfgexpand.c#newcode1597 gcc/cfgexpand.c:1597: contain an array or are arrays. */ , before or, and two spaces before */.

Re: [4.7][google] Adding a new option -fstack-protector-strong. (issue 5461043)

2012-01-24 Thread davidxl
Also need to update doc/invoke.texi file for the new option. http://codereview.appspot.com/5461043/diff/16001/gcc/cfgexpand.c File gcc/cfgexpand.c (right): http://codereview.appspot.com/5461043/diff/16001/gcc/cfgexpand.c#newcode1531 gcc/cfgexpand.c:1531: record_or_union_type_has_array

Go patch committed: Do not allow slice of array literal

2012-01-24 Thread Ian Lance Taylor
Go does not permit taking a slice of an array literal. This patch implements that in the gccgo frontend, and cleans up a bit of the surrounding code. One now-obsolete test case is removed. Bootstrapped and ran Go testsuite on x86_64-unknown-linux-gnu. Committed to mainline. Ian Index:

Re: [RFC] Disable FWPROP on pathological cases

2012-01-24 Thread Steven Bosscher
On Tue, Jan 24, 2012 at 10:26 PM, Eric Botcazou ebotca...@adacore.com wrote: Starting with the 4.5.x series, we have pathological cases (Ada code generated by a code generator from a model) where FWPROP takes 80% of the compilation time at -O1 (for essentially no benefits).  There are very few

Re: PR lto/51698 and the state of LTO + transactional memory

2012-01-24 Thread Richard Henderson
On 01/25/2012 10:16 AM, Aldy Hernandez wrote: The attached patch fixes the ICE in the PR, though it won't do what the user ultimately wants to do, given the limitations described. Perhaps we could create another PR and tag it with an enhancement request. An enhancement request pr sounds good.

Go patch committed: Error if type switch case can not match

2012-01-24 Thread Ian Lance Taylor
This patch to the Go frontend adds in an error if a case in a type switch can not match the type of the switch value, because the case type does not implement methods of the switch value. Bootstrapped and ran Go testsuite on x86_64-unknown-linux-gnu. Committed to mainline. Ian diff -r

[pph] Merge unemitted_tinfo_decls and keyed_classes (issue5575053)

2012-01-24 Thread Lawrence Crowl
Merge unemitted_tinfo_decls and keyed_classes. We do not have a test case failing for keyed_classes, so the latter is anticipatory. Add a 'pph asm xokay' test marker for assembly differences that are benign. We would rather have identical assembly, but it is just not important right now. These

Go patch committed: Update to current Go testsuite

2012-01-24 Thread Ian Lance Taylor
I have committed a patch to update the testsuite under gcc/testsuite/go.test/test to the current Go testsuite. This overall patch is too large to include in this e-mail message. There were some changes to the testsuite driver, which I have included here. Ran Go testsuite on

[libitm] Minor changes to libitm.h

2012-01-24 Thread Patrick Marlier
Hi, I propose some minor modifications to libitm.h: * Add a link to current TM-ABI document. * Remove ITM_REGPARM from _ITM_beginTransaction since on x86-32, a variadic function ignores regparm. * Add ITM_PURE to _ITM_addUserCommitAction and _ITM_addUserUndoAction to be usable inside

Re: [libitm] Minor changes to libitm.h

2012-01-24 Thread Torvald Riegel
On Tue, 2012-01-24 at 19:12 -0500, Patrick Marlier wrote: I propose some minor modifications to libitm.h: * Add a link to current TM-ABI document. We should link to libitm.texi instead because this describes the interface that we implement. * Remove ITM_REGPARM from _ITM_beginTransaction

Re: [trans-mem] Do not instrument thread locals

2012-01-24 Thread Andi Kleen
Patrick Marlier patrick.marl...@gmail.com writes: Hi, I found that all thread local variables are instrumented with _ITM_W/R* calls whereas they should not be shared with other threads. This patch takes care of thread locals into requires_barrier and also adds the local save/restore for

Re: [libitm] Minor changes to libitm.h

2012-01-24 Thread Patrick Marlier
On 01/24/2012 07:32 PM, Torvald Riegel wrote: * Remove ITM_REGPARM from _ITM_beginTransaction since on x86-32, a variadic function ignores regparm. * Add ITM_PURE to _ITM_addUserCommitAction and _ITM_addUserUndoAction to be usable inside transactions. Those should be called from

[RFC] libstdc++ atomic_flag changes

2012-01-24 Thread Richard Henderson
The issue that I'm trying to solve is that we will have at least two targets whose test-and-set insn does not define set as 1, as a variable of type bool would expect. In the case of Sparc we *could* make the test-and-set implementation test for any non-zero value, but in the case of m68k the

Re: [RFC] libstdc++ atomic_flag changes

2012-01-24 Thread Benjamin Kosnik
The issue that I'm trying to solve is that we will have at least two targets whose test-and-set insn does not define set as 1, as a variable of type bool would expect. In the case of Sparc we *could* make the test-and-set implementation test for any non-zero value, but in the case of m68k

Re: [patch] Fix mismatched #pragma GCC visibility

2012-01-24 Thread Rafael Ávila de Espíndola
While we can change it, it is certainly valid as is, #pragma GCC visibility can happen in lots of places and just marks where the default visibility is adjusted. If clang errors on this, it is broken. It doesn't. As far as I can tell, in the absence of templates clang produces the same

C++ PATCH for c++/51917 (wrong tinfo hints on some targets)

2012-01-24 Thread Jason Merrill
As it turns out, this bug depended on vector allocation size. xref_basetypes asks for space for a certain number of bases, then fills up the vector, and assumes that if there's any space left we must have hit a shared virtual base, i.e. diamond-shaped inheritance. But since my vec.c patch for

Re: [v3] libstdc++/49829

2012-01-24 Thread Benjamin Kosnik
this breaks builds configured with --enable-libstdcxx-debug. confirmed Tried the following (not yet working) fix. OK. The attached is closer, but still not quite there. -benjamindiff --git a/libstdc++-v3/src/Makefile.am b/libstdc++-v3/src/Makefile.am index 87b2a16..59cc57d 100644 ---

[PATCH] Partially fix 51988: value_replacement in PHIOPT should handle even the cases where there are other PHIs even with non equal value

2012-01-24 Thread Andrew Pinski
Hi, value_replacement in PHIOPT currently works only when there is one PHI (which is non virtual). http://gcc.gnu.org/ml/gcc-patches/2012-01/msg01195.html improves the situation but we can improve it even more as replacing a PHI argument with a SSA_NAME is almost always a benefit. This patch