[Bug rtl-optimization/48064] Optimizer produces suboptimal code for e.g. x = x ^ (x 1)

2011-03-28 Thread jasper.neumann at web dot de
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48064

Jasper Neumann jasper.neumann at web dot de changed:

   What|Removed |Added

   Severity|minor   |normal


[Bug c/48305] [4.7 Regression] ice at -O0: verify_gimple failed

2011-03-28 Thread jakub at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48305

Jakub Jelinek jakub at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |ASSIGNED
   Last reconfirmed||2011.03.28 07:44:54
 CC||jakub at gcc dot gnu.org
 AssignedTo|unassigned at gcc dot   |jakub at gcc dot gnu.org
   |gnu.org |
   Target Milestone|--- |4.7.0
Summary|ice at -O0: verify_gimple   |[4.7 Regression] ice at
   |failed  |-O0: verify_gimple failed
 Ever Confirmed|0   |1

--- Comment #1 from Jakub Jelinek jakub at gcc dot gnu.org 2011-03-28 
07:44:54 UTC ---
Shorter testcase:
int
foo (int x, char y)
{
  return (x ^ 7U  y = 0) == (1U ^ x);
}


[Bug target/48308] crosscompiling to arm fails with assembler: can't resolve '.LC4' {.rodata.str1.1 section} - '.LPIC4' {*UND* section}

2011-03-28 Thread mikpe at it dot uu.se
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48308

--- Comment #1 from Mikael Pettersson mikpe at it dot uu.se 2011-03-28 
07:47:41 UTC ---
Works for me on armv5tel-linux-gnueabi with gcc-4.6-20110325 (r171529) and
binutils-2.20.1 (heavily updated).  Please attach the intermediate assembly
file.


[Bug fortran/48298] F2003 Implement User Defined Derived Type IO (DTIO)

2011-03-28 Thread burnus at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48298

Tobias Burnus burnus at gcc dot gnu.org changed:

   What|Removed |Added

 CC||burnus at gcc dot gnu.org

--- Comment #3 from Tobias Burnus burnus at gcc dot gnu.org 2011-03-28 
07:48:51 UTC ---
(In reply to comment #1)
 Created attachment 23785 [details]
 A starting front end only patch

+  if (gfc_notify_std (GFC_STD_F2003, Fortran 2003: DT format 
+  specifier not allowed at %C) == FAILURE)

I somehow have parse problems; it sounds to me as if in Fortran 2003 the DT
specifier is not allowed. I would use:

+  if (gfc_notify_std (GFC_STD_F2003, Fortran 2003: DT format 
+  specifier at %C) == FAILURE)


[Bug lto/48309] gcc -flto -fuse-linker-plugin generates crashing executables on MinGW

2011-03-28 Thread d.g.gorbachev at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48309

--- Comment #1 from Dmitry Gorbachev d.g.gorbachev at gmail dot com 
2011-03-28 08:12:57 UTC ---
It can be a duplicate of bug 47891.


[Bug fortran/48279] [4.6/4.7 Regression] segfault in gfc_check_vardef_context

2011-03-28 Thread burnus at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48279

Tobias Burnus burnus at gcc dot gnu.org changed:

   What|Removed |Added

   Keywords||ice-on-invalid-code
 CC||burnus at gcc dot gnu.org
   Target Milestone|--- |4.6.1
Summary|segfault in |[4.6/4.7 Regression]
   |gfc_check_vardef_context|segfault in
   ||gfc_check_vardef_context

--- Comment #5 from Tobias Burnus burnus at gcc dot gnu.org 2011-03-28 
08:13:02 UTC ---
(In reply to comment #4)
   call set(get_d_string(h), 0, 'Three')

With NAG and with GCC 4.5 (and 4.3/4.4) I get the error that no specific
function could be found. Thus, I mark this PR now as regression and
ICE-on-invalid-code. I have not checked whether the other examples are valid or
not.


[Bug boehm-gc/48299] [4.7 Regression] FAIL: boehm-gc.c/thread_leak_test.c

2011-03-28 Thread ro at CeBiTec dot Uni-Bielefeld.DE
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48299

--- Comment #1 from ro at CeBiTec dot Uni-Bielefeld.DE ro at CeBiTec dot 
Uni-Bielefeld.DE 2011-03-28 08:49:47 UTC ---
Could you please check if this test worked before my patch?  It may have
been that the failure simply went unnoticed.

Thanks.
Rainer


[Bug c/48190] [regression?] Huge memory use while compiling qemu-0.4.0

2011-03-28 Thread rsandifo at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48190

rsand...@gcc.gnu.org rsandifo at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |ASSIGNED
   Last reconfirmed||2011.03.28 08:59:13
 CC||rsandifo at gcc dot gnu.org
 AssignedTo|unassigned at gcc dot   |rsandifo at gcc dot gnu.org
   |gnu.org |
 Ever Confirmed|0   |1


[Bug debug/48041] dwarf2out emits unnecessary null byte in empty .debug_abbrev section

2011-03-28 Thread mark at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48041

Mark Wielaard mark at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||FIXED
 AssignedTo|unassigned at gcc dot   |mark at gcc dot gnu.org
   |gnu.org |

--- Comment #2 from Mark Wielaard mark at gcc dot gnu.org 2011-03-28 09:10:09 
UTC ---
Patch committed.


[Bug debug/48229] DW_TAG_type_unit has no DW_AT_producer

2011-03-28 Thread jan.kratochvil at redhat dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48229

--- Comment #5 from Jan Kratochvil jan.kratochvil at redhat dot com 
2011-03-28 09:12:20 UTC ---
Created attachment 23788
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=23788
GDB patch attempt with ptype regressions.

(In reply to comment #4)
 Still I believe DW_TAG_type_unit should have DW_AT_producer as it is a
 standalone entity - but currently it is not.  I guess I have to implement your
 described althorithm into GDB instead.

It cannot work as GDB often looks up the type without any referrer from
DW_TAG_compile_unit, such as during the `ptype' GDB command.  A draft patch
thus has many regressions such as:
-PASS: gdb.base/nofield.exp: ptype struct not_empty
+FAIL: gdb.base/nofield.exp: ptype struct not_empty (GDB internal error)

This means GDB will have to start full read (like -readnow) of CUs till it
finds some CU referencing the specific type to find its DW_AT_producer.  During
scan of .debug_info for GDB partial symbols GDB currently skips over subtrees
of DIEs which reference the type signature for performance reasons, it no
longer can.

With .gdb_index there is no GDB partial symbols scan but .gdb_index also
indexes types by their name and there is no referrer ever seen during the
`ptype' GDB command.

So it means performance regression for non-.gdb_index case and a possible new
extension/version of .gdb_index to handle it.


[Bug debug/48229] DW_TAG_type_unit has no DW_AT_producer

2011-03-28 Thread jakub at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48229

--- Comment #6 from Jakub Jelinek jakub at gcc dot gnu.org 2011-03-28 
09:22:57 UTC ---
.debug_types only appears with -gdwarf-4, I don't think any gcc defaulted to
that yet, so if you are talking about DW_AT_accessibility default, IMHO just
assume the DWARF3+ semantics in .debug_types.


[Bug tree-optimization/48295] Incorrect code generated with dynamic floating point rounding mode switches

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48295

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2011.03.28 09:31:53
 Ever Confirmed|0   |1

--- Comment #2 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
09:31:53 UTC ---
Code motion optimizations (or even CSE) have no idea about dynamic rounding
mode changes, -frounding-math does not change this (this switch is only
guarding expression simplifications that usually assume round-to-nearest
behavior).

The only mode for which I'd accept such band-aid patches is -O0.

Anyway, confirmed, but long-time known with no idea when or even how
this is going to be fixed.

Btw, your testcase would be kindof invalid as you are not using the
documented standard way of accessing fenv but using inline-asm (and
we don't have a special clobber that tells GCC you touched the FP
control word).

As for CSE, try

  /* Round to upward.  */
  tem1 = a + b;
  /* Round to nearest.  */
  tem2 = a + b;
  diff = tem1 - tem2;

and see it optimized to zero at compile-time.

I suppose there is a duplicate bug somewhere about the general issue.


[Bug target/48297] Suboptimal optimization of boolean expression addition

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48297

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

   Keywords||missed-optimization
 Status|UNCONFIRMED |NEW
   Last reconfirmed||2011.03.28 09:34:02
  Component|c   |target
 Ever Confirmed|0   |1

--- Comment #1 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
09:34:02 UTC ---
Confirmed.


[Bug target/48301] Xcode 4.0's llvm-gcc can't bootstrap gcc 4.6.0 or trunk

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48301

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||INVALID

--- Comment #3 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
09:35:37 UTC ---
So llvm miscompiles cc1.  Not a GCC bug.


[Bug driver/48306] presence of gcc subdir with . in PATH causes breakdown

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48306

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |WAITING
   Last reconfirmed||2011.03.28 09:40:43
 Ever Confirmed|0   |1

--- Comment #1 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
09:40:43 UTC ---
Works for me.  How did you configure/install GCC?  What does -v output say
for the compile command?


[Bug bootstrap/48307] [4.7 Regression] Bootstrap failure

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48307

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||FIXED
   Target Milestone|--- |4.7.0

--- Comment #3 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
09:41:22 UTC ---
Fixed.


[Bug fortran/48311] New: [Quadmath] Documentation - typo, order

2011-03-28 Thread burnus at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48311

   Summary: [Quadmath] Documentation - typo, order
   Product: gcc
   Version: 4.6.0
Status: UNCONFIRMED
  Keywords: documentation
  Severity: trivial
  Priority: P3
 Component: fortran
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: bur...@gcc.gnu.org


http://gcc.gnu.org/onlinedocs/libquadmath/strtoflt128.html

The function dmath_strtopQ converts a string into a __float128 number.

Should be dmath_strtopQ - strtoflt128


http://gcc.gnu.org/onlinedocs/libquadmath/quadmath_005fsnprintf.html

I would move the comment from the very bottom to before the example - it is
currently a bit lost there.


[Bug lto/48309] gcc -flto -fuse-linker-plugin generates crashing executables on MinGW

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48309

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |WAITING
   Last reconfirmed||2011.03.28 09:45:36
 Ever Confirmed|0   |1

--- Comment #2 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
09:45:36 UTC ---
Please also specify the exact linker version you are using.


[Bug middle-end/48310] ask a question about expand_used_vars in cfgexpand.c

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48310

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||INVALID

--- Comment #1 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
09:47:01 UTC ---
Please ask questions on the GCC mailinglists, not via bugzilla.


[Bug ada/44431] [boot with C++] Conflicting exit declaration in ada/b_gnatb.c

2011-03-28 Thread gingold at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44431

--- Comment #6 from gingold at gcc dot gnu.org gingold at gcc dot gnu.org 
2011-03-28 09:49:14 UTC ---
Author: gingold
Date: Mon Mar 28 09:49:10 2011
New Revision: 171593

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171593
Log:
2011-03-28  Tristan Gingold  ging...@adacore.com

PR ada/44431
* gcc-interface/Make-lang.in (ada/b_gnat1.adb):  Replaces
ada/b_gnat1.c. Use ada output of gnatbind.
(ada/b_gnatb.adb): Ditto.
(ada/b_gnat1.o, ada/b_gnatb.o): New rules.
(ada.mostlyclean, ada.stage1)
(ada.stage2, ada.stage3, ada.stage4, ada.stageprofile)
(ada.stagefeedback): Adjust.

* gcc-interface/Makefile.in (b_gnatl.adb): Replaces b_gnatl.c
Use ada output of gnatbind.
(b_gnatm.adb): Ditto.
(b_gnatl.o, b_gnatm.o): New rules.


Modified:
trunk/gcc/ada/ChangeLog
trunk/gcc/ada/gcc-interface/Make-lang.in
trunk/gcc/ada/gcc-interface/Makefile.in


[Bug ada/44431] [boot with C++] Conflicting exit declaration in ada/b_gnatb.c

2011-03-28 Thread ebotcazou at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44431

Eric Botcazou ebotcazou at gcc dot gnu.org changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||FIXED
   Target Milestone|--- |4.7.0

--- Comment #7 from Eric Botcazou ebotcazou at gcc dot gnu.org 2011-03-28 
09:53:27 UTC ---
Presumably.  Reopen if not.


[Bug tree-optimization/48295] Incorrect code generated with dynamic floating point rounding mode switches

2011-03-28 Thread frederic.riss at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48295

--- Comment #3 from Frederic Riss frederic.riss at gmail dot com 2011-03-28 
09:58:50 UTC ---
In bug #34678 I thought you were agreeing with Joseph that -frounding-math had
a more general meaning than the one you are expressing here, but I get your
point that a more general solution should be implemented.

Regarding the validity of the testcase, I took glibc's implementation of
fesetround that I inlined. I did that because I saw that /usr/include/fenv.h
has provisions for including inline versions of the fenv routines, although
it's not the case yet for x86. So I guess it's possible that someday you get
exactly that situation even though people are using the standard routines to
switch rounding mode. In fact my private port does exactly this.

Can you think of other places than CSE that would exhibit these issues?
Unfortunately, I have to put some band-aids into place for our numerical
analysts to be able to do their jobs.


[Bug tree-optimization/48134] [4.6 Regression] ICE: in refs_may_alias_p_1, at tree-ssa-alias.c:1085 with custom flags

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48134

--- Comment #7 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
10:14:41 UTC ---
Author: rguenth
Date: Mon Mar 28 10:14:34 2011
New Revision: 171595

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171595
Log:
2011-03-28  Richard Guenther  rguent...@suse.de

Backport from mainline
2011-03-24  Richard Guenther  rguent...@suse.de

PR middle-end/48269
* tree-object-size.c (addr_object_size): Do not double-account
for MEM_REF offsets.

* gcc.dg/builtin-object-size-10.c: New testcase.

2011-03-22  Richard Guenther  rguent...@suse.de

PR tree-optimization/48228
* tree-vrp.c (vrp_visit_phi_node): Do not stop propagating
for single-arg PHIs.

* gcc.dg/Wstrict-overflow-23.c: New testcase.

2011-03-17  Richard Guenther  rguent...@suse.de

PR middle-end/48134
* tree-ssa.c (insert_debug_temp_for_var_def): If we propagated
a value make sure to fold the statement.

* gcc.dg/pr48134.c: New testcase.

2011-03-15  Richard Guenther  rguent...@suse.de

PR middle-end/48031
* fold-const.c (fold_indirect_ref_1): Do not create new variable-sized
or variable-indexed array accesses when in gimple form.

Added:
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/Wstrict-overflow-23.c
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/builtin-object-size-10.c
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/pr48134.c
Modified:
branches/gcc-4_6-branch/gcc/ChangeLog
branches/gcc-4_6-branch/gcc/fold-const.c
branches/gcc-4_6-branch/gcc/testsuite/ChangeLog
branches/gcc-4_6-branch/gcc/tree-object-size.c
branches/gcc-4_6-branch/gcc/tree-ssa.c
branches/gcc-4_6-branch/gcc/tree-vrp.c


[Bug c/48228] incorrect signed overflow warning when only 0 and 1 are used

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48228

--- Comment #6 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
10:14:40 UTC ---
Author: rguenth
Date: Mon Mar 28 10:14:34 2011
New Revision: 171595

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171595
Log:
2011-03-28  Richard Guenther  rguent...@suse.de

Backport from mainline
2011-03-24  Richard Guenther  rguent...@suse.de

PR middle-end/48269
* tree-object-size.c (addr_object_size): Do not double-account
for MEM_REF offsets.

* gcc.dg/builtin-object-size-10.c: New testcase.

2011-03-22  Richard Guenther  rguent...@suse.de

PR tree-optimization/48228
* tree-vrp.c (vrp_visit_phi_node): Do not stop propagating
for single-arg PHIs.

* gcc.dg/Wstrict-overflow-23.c: New testcase.

2011-03-17  Richard Guenther  rguent...@suse.de

PR middle-end/48134
* tree-ssa.c (insert_debug_temp_for_var_def): If we propagated
a value make sure to fold the statement.

* gcc.dg/pr48134.c: New testcase.

2011-03-15  Richard Guenther  rguent...@suse.de

PR middle-end/48031
* fold-const.c (fold_indirect_ref_1): Do not create new variable-sized
or variable-indexed array accesses when in gimple form.

Added:
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/Wstrict-overflow-23.c
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/builtin-object-size-10.c
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/pr48134.c
Modified:
branches/gcc-4_6-branch/gcc/ChangeLog
branches/gcc-4_6-branch/gcc/fold-const.c
branches/gcc-4_6-branch/gcc/testsuite/ChangeLog
branches/gcc-4_6-branch/gcc/tree-object-size.c
branches/gcc-4_6-branch/gcc/tree-ssa.c
branches/gcc-4_6-branch/gcc/tree-vrp.c


[Bug middle-end/48269] [4.6 Regression] Incorrect fortify warning for a packed struct member

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48269

--- Comment #7 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
10:14:40 UTC ---
Author: rguenth
Date: Mon Mar 28 10:14:34 2011
New Revision: 171595

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171595
Log:
2011-03-28  Richard Guenther  rguent...@suse.de

Backport from mainline
2011-03-24  Richard Guenther  rguent...@suse.de

PR middle-end/48269
* tree-object-size.c (addr_object_size): Do not double-account
for MEM_REF offsets.

* gcc.dg/builtin-object-size-10.c: New testcase.

2011-03-22  Richard Guenther  rguent...@suse.de

PR tree-optimization/48228
* tree-vrp.c (vrp_visit_phi_node): Do not stop propagating
for single-arg PHIs.

* gcc.dg/Wstrict-overflow-23.c: New testcase.

2011-03-17  Richard Guenther  rguent...@suse.de

PR middle-end/48134
* tree-ssa.c (insert_debug_temp_for_var_def): If we propagated
a value make sure to fold the statement.

* gcc.dg/pr48134.c: New testcase.

2011-03-15  Richard Guenther  rguent...@suse.de

PR middle-end/48031
* fold-const.c (fold_indirect_ref_1): Do not create new variable-sized
or variable-indexed array accesses when in gimple form.

Added:
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/Wstrict-overflow-23.c
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/builtin-object-size-10.c
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/pr48134.c
Modified:
branches/gcc-4_6-branch/gcc/ChangeLog
branches/gcc-4_6-branch/gcc/fold-const.c
branches/gcc-4_6-branch/gcc/testsuite/ChangeLog
branches/gcc-4_6-branch/gcc/tree-object-size.c
branches/gcc-4_6-branch/gcc/tree-ssa.c
branches/gcc-4_6-branch/gcc/tree-vrp.c


[Bug tree-optimization/48031] [4.4/4.5 Regression] gcc.c-torture/compile/pr42956.c ICEs gcc on m68k-linux, ivopts related?

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48031

--- Comment #18 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
10:14:39 UTC ---
Author: rguenth
Date: Mon Mar 28 10:14:34 2011
New Revision: 171595

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171595
Log:
2011-03-28  Richard Guenther  rguent...@suse.de

Backport from mainline
2011-03-24  Richard Guenther  rguent...@suse.de

PR middle-end/48269
* tree-object-size.c (addr_object_size): Do not double-account
for MEM_REF offsets.

* gcc.dg/builtin-object-size-10.c: New testcase.

2011-03-22  Richard Guenther  rguent...@suse.de

PR tree-optimization/48228
* tree-vrp.c (vrp_visit_phi_node): Do not stop propagating
for single-arg PHIs.

* gcc.dg/Wstrict-overflow-23.c: New testcase.

2011-03-17  Richard Guenther  rguent...@suse.de

PR middle-end/48134
* tree-ssa.c (insert_debug_temp_for_var_def): If we propagated
a value make sure to fold the statement.

* gcc.dg/pr48134.c: New testcase.

2011-03-15  Richard Guenther  rguent...@suse.de

PR middle-end/48031
* fold-const.c (fold_indirect_ref_1): Do not create new variable-sized
or variable-indexed array accesses when in gimple form.

Added:
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/Wstrict-overflow-23.c
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/builtin-object-size-10.c
branches/gcc-4_6-branch/gcc/testsuite/gcc.dg/pr48134.c
Modified:
branches/gcc-4_6-branch/gcc/ChangeLog
branches/gcc-4_6-branch/gcc/fold-const.c
branches/gcc-4_6-branch/gcc/testsuite/ChangeLog
branches/gcc-4_6-branch/gcc/tree-object-size.c
branches/gcc-4_6-branch/gcc/tree-ssa.c
branches/gcc-4_6-branch/gcc/tree-vrp.c


[Bug middle-end/48269] [4.6 Regression] Incorrect fortify warning for a packed struct member

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48269

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
  Known to work||4.6.1
 Resolution||FIXED
  Known to fail||4.6.0

--- Comment #8 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
10:20:54 UTC ---
Fixed.


[Bug tree-optimization/48228] incorrect signed overflow warning when only 0 and 1 are used

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48228

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

  Component|c   |tree-optimization
  Known to work||4.6.1, 4.7.0
   Target Milestone|4.7.0   |4.6.1
  Known to fail||4.6.0

--- Comment #7 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
10:21:54 UTC ---
And 4.6.1.  I'm not planning to backport further as it's also an optimization
change.


[Bug tree-optimization/48134] [4.6 Regression] ICE: in refs_may_alias_p_1, at tree-ssa-alias.c:1085 with custom flags

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48134

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED

--- Comment #8 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
10:22:30 UTC ---
Fixed.


[Bug target/47553] ARM neon vld1q_lane_u8 co. don't accept lanes = 8

2011-03-28 Thread rsandifo at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47553

--- Comment #3 from rsandifo at gcc dot gnu.org rsandifo at gcc dot gnu.org 
2011-03-28 10:23:03 UTC ---
Author: rsandifo
Date: Mon Mar 28 10:22:57 2011
New Revision: 171596

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171596
Log:
gcc/
PR target/47553
* config/arm/predicates.md (neon_lane_number): Accept 0..15.

gcc/testsuite/
PR target/47553
* gcc.target/arm/neon-vld-1.c: New test.

Added:
branches/gcc-4_6-branch/gcc/testsuite/gcc.target/arm/neon-vld-1.c
Modified:
branches/gcc-4_6-branch/gcc/ChangeLog
branches/gcc-4_6-branch/gcc/config/arm/predicates.md
branches/gcc-4_6-branch/gcc/testsuite/ChangeLog


[Bug tree-optimization/48290] FAIL: gcc.dg/vect/pr38529.c, ICE in vect_get_vec_def_for_operand, at tree-vect-stmts.c:1072

2011-03-28 Thread irar at il dot ibm.com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48290

--- Comment #3 from Ira Rosen irar at il dot ibm.com 2011-03-28 10:30:55 UTC 
---
I am going to test this patch. It checks that if we have a phi in outer loop in
the basic block after the inner loop, then this phi is really inner loop's exit
phi, i.e., its operand is defined in the inner loop. 

Index: tree-vect-loop.c
===
--- tree-vect-loop.c(revision 171466)
+++ tree-vect-loop.c(working copy)
@@ -1184,11 +1184,11 @@ vect_analyze_loop_operations (loop_vec_i
   print_gimple_stmt (vect_dump, phi, 0, TDF_SLIM);
 }

+  /* Inner-loop loop-closed exit phi in outer-loop vectorization
+ (i.e. a phi in the tail of the outer-loop).  */
   if (! is_loop_header_bb_p (bb))
 {
-  /* inner-loop loop-closed exit phi in outer-loop vectorization
- (i.e. a phi in the tail of the outer-loop).
- FORNOW: we currently don't support the case that these phis
+  /* FORNOW: we currently don't support the case that these phis
  are not used in the outerloop (unless it is double reduction,
  i.e., this phi is vect_reduction_def), cause this case
  requires to actually do something here.  */
@@ -1202,6 +1202,32 @@ vect_analyze_loop_operations (loop_vec_i
  Unsupported loop-closed phi in outer-loop.);
   return false;
 }
+
+  /* If PHI is used in the outer loop, we check that its operand
+ is defined in the inner loop.  */
+  if (STMT_VINFO_RELEVANT_P (stmt_info))
+{
+  tree phi_op;
+  gimple op_def_stmt;
+
+  if (gimple_phi_num_args (phi) != 1)
+return false;
+
+  phi_op = PHI_ARG_DEF (phi, 0);
+  if (TREE_CODE (phi_op) != SSA_NAME)
+return false;
+
+  op_def_stmt = SSA_NAME_DEF_STMT (phi_op);
+  if (!op_def_stmt || !vinfo_for_stmt (op_def_stmt))
+return false;
+
+  if (STMT_VINFO_RELEVANT (vinfo_for_stmt (op_def_stmt))
+!= vect_used_in_outer
+   STMT_VINFO_RELEVANT (vinfo_for_stmt (op_def_stmt))
+   != vect_used_in_outer_by_reduction)
+return false;
+}
+
   continue;
 }


[Bug target/47553] ARM neon vld1q_lane_u8 co. don't accept lanes = 8

2011-03-28 Thread rsandifo at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47553

--- Comment #4 from rsandifo at gcc dot gnu.org rsandifo at gcc dot gnu.org 
2011-03-28 10:32:12 UTC ---
Author: rsandifo
Date: Mon Mar 28 10:32:09 2011
New Revision: 171597

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171597
Log:
gcc/
PR target/47553
* config/arm/predicates.md (neon_lane_number): Accept 0..15.

gcc/testsuite/
PR target/47553
* gcc.target/arm/neon-vld-1.c: New test.

Added:
branches/gcc-4_5-branch/gcc/testsuite/gcc.target/arm/neon-vld-1.c
Modified:
branches/gcc-4_5-branch/gcc/ChangeLog
branches/gcc-4_5-branch/gcc/config/arm/predicates.md
branches/gcc-4_5-branch/gcc/testsuite/ChangeLog


[Bug go/48312] New: [4.7 regression] http, rpc, websocket tests hang on Solaris 2/x86

2011-03-28 Thread ro at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48312

   Summary: [4.7 regression] http, rpc, websocket tests hang on
Solaris 2/x86
   Product: gcc
   Version: 4.7.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: go
AssignedTo: i...@airs.com
ReportedBy: r...@gcc.gnu.org
  Host: i386-pc-solaris2.1[01]
Target: i386-pc-solaris2.1[01]
 Build: i386-pc-solaris2.1[01]


Created attachment 23789
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=23789
Minimal patch to get fd_rtems.go to compile.

After the latest libgo import, the network-related libgo tests hang on Solaris
10
and 11/x86.  To even get libgo to compile, I needed the attached patch to
fd_rtems.go (which should better be called fd_select.go since this is what it
really is).

Even after that, the http, rpc, and websocket tests just hang in select, as can
be seen in the pstack output from the http test:

8131:./a.out
-  lwp# 1 / thread# 1  
 fe35b3ab lwp_park (0, 0, 0)
 fe354e03 cond_wait_queue (de221678, de221660, 0, fe355329) + 63
 fe3553a1 __cond_wait (de221678, de221660, 8045158, fe3553e9) + 89
 fe3553f7 cond_wait (de221678, de221660, 80451a8, fe35542d) + 27
 fe355442 pthread_cond_wait (de221678, de221660, 80451c8, fe3f7500, 18,
8045100) + 24
 fe64467c __go_receive_acquire (de221660, 0, 8045218, fe641cb9, 80451f8,
80451f8) + 7c
 fe6447f1 __go_receive_small_closed (de221660, 0, 0, fe87d6c0, 16) + 41
 fe64489d __go_receive_small (de221660, de22c500, 0, 809eaea, 14, 1) + 2d
 fe7fd1cd libgo_testing.testing.RunTests (8088b38, de40, 30, 30, fefa0810,
fee70018) + 21d
 fe7fd481 libgo_testing.testing.Main (8088b38, de40, 30, 30, de20ebf0, 0) +
81
 08088cb4 main.main (4d9060de, 8045720, 80453f0, feffb93c, 8045400, de20) +
48
 080958ef main (1, 8045434, 804543c, 8045428, 80640c2, 80956f0) + 1df
 08064123 _start   (1, 8045788, 0, 8045790, 804579e, 80457aa) + 83
-  lwp# 24 / thread# 24  
 fe35b3ab lwp_park (0, 0, 0)
 fe354e03 cond_wait_queue (de217f68, de217f50, 0, fe355329) + 63
 fe3553a1 __cond_wait (de217f68, de217f50, cdefea68, fe3553e9) + 89
 fe3553f7 cond_wait (de217f68, de217f50, de217f50, fe35542d) + 27
 fe355442 pthread_cond_wait (de217f68, de217f50, 5a5b497, 321, 8056414, 100) +
24
 fe64467c __go_receive_acquire (de217f50, 0, 0, 807e3b8, cdefeb00, fefc0744) +
7c
 fe643d4e __go_receive_big (de217f50, cdefeb50, de229300, fe6494b7, fedf3f40,
de234f20) + 3e
 080809b2 libgo_http.http.roundTrip.pN27_libgo_http.http.persistConn (cdefec08,
de23f840, de229300, 4, 809c52c, 4) + 112
 0807e6b9 libgo_http.http.RoundTrip.pN25_libgo_http.http.Transport (cdefeccc,
de20eb60, de229300, fe6494b7, de230005, 11) + 301
 0806b2c3 http.send (cdefedb8, de229300, 80a4268, de20eb60, 0, fe3f3000) + 249
 0806b5d6 libgo_http.http.Get.pN22_libgo_http.http.Client (cdefee38, de200568,
de234f60, 16, cdf00a3c, 0) + 1de
 0806b38d libgo_http.http.Get (cdefeee8, de23, 16, fe350f13, 0, fe3f3000) +
4e
 08088f87 go.http_test.TestClient (de22c5d0, 0, fee60200, fe353c8c, fe87d6c0,
fe8cb584) + 89
 fe7fc595 testing.tRunner (de22c5d0, de222348, fe87d6c0, 80bc468, fe8cb584,
fe87d6c0) + 25
 fe7fc25a testing.$thunk0 (de22c5e0, fe3f3000, cdefefd8, fe35a535, fe3f9e00,
fee62000) + 1a
 fe641b41 start_go_thread (de21b380, fe3f3000, cdefefe8, fe35b079) + 81
 fe35b0cc _thrp_setup (cdf00a40) + 9d
 fe35b370 _lwp_start (cdf00a40, 0, 0, 0, 0, 0)
-  lwp# 25 / thread# 25  
 fe35f4a7 pollsys  (ce00ed00, 1, 0, 0)
 fe30afeb pselect  (5, de22a000, 0, 0, 0, 0) + 193
 fe30b2f1 select   (5, de22a000, 0, 0, 0, fefc0744) + 79
 fe7fb3f1 libgo_syscalls.syscall.Select (ce00ee40, 5, de22a000, de22a080, 0, 0)
+ 41
 fe6b9301 libgo_net.net.WaitFD.pN22_libgo_net.net.pollster (ce00ef14, de2300a0,
de201570, 0, 0, fe3f3000) + 221
 fe6c1515 libgo_net.net.Run.pN24_libgo_net.net.pollServer (de201570, 0,
fe87d6c0, 80bc440, fe8cb584, fe87d6c0) + e5
 fe6b5843 net.$thunk0 (de232288, fe3f3000, ce00efd8, fe35a535, fe3f9e00,
fee62000) + 13
 fe641b41 start_go_thread (de23f140, fe3f3000, ce00efe8, fe35b079) + 81
 fe35b0cc _thrp_setup (cdf00240) + 9d
 fe35b370 _lwp_start (cdf00240, 0, 0, 0, 0, 0)
-  lwp# 26 / thread# 26  
 fe35b3ab lwp_park (0, 0, 0)
 fe354e03 cond_wait_queue (de221b58, de221b40, 0, fe355329) + 63
 fe3553a1 __cond_wait (de221b58, de221b40, cddffc58, fe3553e9) + 89
 fe3553f7 cond_wait (de221b58, de221b40, cddffc98, fe35542d) + 27
 fe355442 pthread_cond_wait (de221b58, de221b40, 1, fe87d6c0, 72, fe87d6c0) +
24
 fe64467c __go_receive_acquire (de221b40, 0, fe50f9e3, fef70018, 3, 0) + 7c
 fe6447f1 __go_receive_small_closed (de221b40, 0, 0, fe87d6c0, de229280) + 41
 fe64489d __go_receive_small (de221b40, de229200, 72, de201570, fe87d6c0,
de229280) + 2d
 fe6ba741 libgo_net.net.WaitRead.pN24_libgo_net.net.pollServer 

[Bug tree-optimization/48290] FAIL: gcc.dg/vect/pr38529.c, ICE in vect_get_vec_def_for_operand, at tree-vect-stmts.c:1072

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48290

--- Comment #4 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
10:38:27 UTC ---
Thanks Ira.


[Bug target/47553] ARM neon vld1q_lane_u8 co. don't accept lanes = 8

2011-03-28 Thread rsandifo at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47553

rsand...@gcc.gnu.org rsandifo at gcc dot gnu.org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED

--- Comment #5 from rsandifo at gcc dot gnu.org rsandifo at gcc dot gnu.org 
2011-03-28 10:49:10 UTC ---
Fixed in 4.5, 4.6 and trunk.


[Bug tree-optimization/48295] Incorrect code generated with dynamic floating point rounding mode switches

2011-03-28 Thread joseph at codesourcery dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48295

--- Comment #4 from joseph at codesourcery dot com joseph at codesourcery dot 
com 2011-03-28 10:50:44 UTC ---
On Mon, 28 Mar 2011, rguenth at gcc dot gnu.org wrote:

 Btw, your testcase would be kindof invalid as you are not using the
 documented standard way of accessing fenv but using inline-asm (and
 we don't have a special clobber that tells GCC you touched the FP
 control word).

You mark the asm as reading and clobbering fpcr - that register name 
already exists in GCC, and it's a bug that glibc's fpu_control.h doesn't 
use it, though I suppose you'd need to add the mxcsr name as well.  
When -frounding-math is actually properly implemented it ought to be 
taught about target-specific registers representing rounding modes (and 
likewise exception status) so it knows how asms interact with the 
floating-point state.  (Non-const, non-pure function calls will also need 
to be presumed to interact with the state in unknown ways since they may 
end up calling fenv.h functions.)


[Bug c/48305] [4.7 Regression] ice at -O0: verify_gimple failed

2011-03-28 Thread jakub at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48305

--- Comment #2 from Jakub Jelinek jakub at gcc dot gnu.org 2011-03-28 
10:55:56 UTC ---
Created attachment 23790
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=23790
gcc47-pr48305.patch

Untested fix.


[Bug testsuite/48245] FAIL: gcc.dg/lto/pr46940 c_lto_pr46940_0.o assemble on *-apple-darwin*

2011-03-28 Thread ro at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48245

--- Comment #21 from Rainer Orth ro at gcc dot gnu.org 2011-03-28 11:07:02 
UTC ---
Author: ro
Date: Mon Mar 28 11:06:58 2011
New Revision: 171598

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171598
Log:
PR target/48245
* config/darwin.h (LINK_COMMAND_SPEC_A): Use LINK_PLUGIN_SPEC.

Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/darwin.h


[Bug testsuite/48245] FAIL: gcc.dg/lto/pr46940 c_lto_pr46940_0.o assemble on *-apple-darwin*

2011-03-28 Thread ro at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48245

Rainer Orth ro at gcc dot gnu.org changed:

   What|Removed |Added

 Status|NEW |RESOLVED
URL||http://gcc.gnu.org/ml/gcc-p
   ||atches/2011-03/msg01890.htm
   ||l
 CC||ro at gcc dot gnu.org
 Resolution||FIXED
 AssignedTo|unassigned at gcc dot   |ro at gcc dot gnu.org
   |gnu.org |
   Target Milestone|--- |4.7.0

--- Comment #22 from Rainer Orth ro at gcc dot gnu.org 2011-03-28 11:08:39 
UTC ---
Fixed for 4.7.0.


[Bug testsuite/48245] FAIL: gcc.dg/lto/pr46940 c_lto_pr46940_0.o assemble on *-apple-darwin*

2011-03-28 Thread ro at CeBiTec dot Uni-Bielefeld.DE
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48245

--- Comment #23 from ro at CeBiTec dot Uni-Bielefeld.DE ro at CeBiTec dot 
Uni-Bielefeld.DE 2011-03-28 11:11:09 UTC ---
 --- Comment #20 from Dominique d'Humieres dominiq at lps dot ens.fr 
 2011-03-24 18:46:41 UTC ---
 AFAICT, comment #12 is OK on *-darwin9 including cross-cris-elf.
 given that Mike has approved, 
 if someone could chip in with a test on x86-64-darwin10, I would think you
 could apply it.

 I have bootstrapped gcc on x86-64-darwin10 with the patch in comment #12 on 
 top
 of revision 171401 without failures for the tests ran by lto.exp (full test by
 tomorrow).

Thanks.  Based on Iain's and your testing and Mike's approval, I've
applied the patch (slightly adapted to match the gcc.c form).

 Now I wonder what are the tests

 gcc/testsuite/gcc.dg/lto/20100722-1_0.c
 gcc/testsuite/gcc.dg/lto/20110201-1_0.c
 gcc/testsuite/gcc.dg/lto/pr46940_0.c
 gcc/testsuite/gcc.dg/lto/pr47188_0.c
 gcc/testsuite/gcc.dg/pr43157.c

 supposed to test? pr46940_0.c fails because only weak aliases are supported
 on darwin and the other tests pass even without plugin support.

No idea.  You'll have to ask the patch authors.  This whole LTO and
lto-plugin business remains a mystery to me.

Rainer


[Bug testsuite/48245] FAIL: gcc.dg/lto/pr46940 c_lto_pr46940_0.o assemble on *-apple-darwin*

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48245

--- Comment #24 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
11:18:44 UTC ---
(In reply to comment #20)
  AFAICT, comment #12 is OK on *-darwin9 including cross-cris-elf.
  given that Mike has approved, 
  if someone could chip in with a test on x86-64-darwin10, I would think you
  could apply it.
 
 I have bootstrapped gcc on x86-64-darwin10 with the patch in comment #12 on 
 top
 of revision 171401 without failures for the tests ran by lto.exp (full test by
 tomorrow).
 
 Now I wonder what are the tests
 
 gcc/testsuite/gcc.dg/lto/20100722-1_0.c
 gcc/testsuite/gcc.dg/lto/20110201-1_0.c
 gcc/testsuite/gcc.dg/lto/pr46940_0.c
 gcc/testsuite/gcc.dg/lto/pr47188_0.c
 gcc/testsuite/gcc.dg/pr43157.c
 
 supposed to test? pr46940_0.c fails because only weak aliases are supported
 on darwin and the other tests pass even without plugin support.

They are various tests for previously existing bugs (mostly ICEs).  Of course
they now work.


[Bug middle-end/48310] ask a question about expand_used_vars in cfgexpand.c

2011-03-28 Thread zgss278 at 163 dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48310

--- Comment #2 from shushengyu zgss278 at 163 dot com 2011-03-28 11:20:03 UTC 
---
Oh,sorry!I am not know the rule well.
Can you introduce someone who would like to give me some help to me?
At 2011-03-28 17:47:06,rguenth at gcc dot gnu.org gcc-bugzi...@gcc.gnu.org
wrote:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48310

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||INVALID

--- Comment #1 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
09:47:01 UTC ---
Please ask questions on the GCC mailinglists, not via bugzilla.

-- 
Configure bugmail: http://gcc.gnu.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You reported the bug.


[Bug testsuite/48245] FAIL: gcc.dg/lto/pr46940 c_lto_pr46940_0.o assemble on *-apple-darwin*

2011-03-28 Thread ro at CeBiTec dot Uni-Bielefeld.DE
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48245

--- Comment #25 from ro at CeBiTec dot Uni-Bielefeld.DE ro at CeBiTec dot 
Uni-Bielefeld.DE 2011-03-28 11:21:20 UTC ---
 supposed to test? pr46940_0.c fails because only weak aliases are supported
 on darwin and the other tests pass even without plugin support.

 They are various tests for previously existing bugs (mostly ICEs).  Of course
 they now work.

But Dominique's point that all those tests have
dg-require-linker-plugin, but passed on Darwin even without the
lto-plugin.

Rainer


[Bug debug/48229] 4.5.x should produce unambiguous DW_AT_accessibility

2011-03-28 Thread jan.kratochvil at redhat dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48229

Jan Kratochvil jan.kratochvil at redhat dot com changed:

   What|Removed |Added

Summary|DW_TAG_type_unit has no |4.5.x should produce
   |DW_AT_producer  |unambiguous
   ||DW_AT_accessibility

--- Comment #7 from Jan Kratochvil jan.kratochvil at redhat dot com 
2011-03-28 11:21:41 UTC ---
In such case only the gcc-4.5.x branch should start to produce
DW_AT_accessibility unambiguously (explicitly) at least in the -gdwarf-4 mode.
This way it will not remain a long term regression testsuite problem.


[Bug libstdc++/48313] New: std::bind with template function

2011-03-28 Thread joerg.rich...@pdv-fs.de
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48313

   Summary: std::bind with template function
   Product: gcc
   Version: 4.6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: libstdc++
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: joerg.rich...@pdv-fs.de


$ cat  t.cc  EOF
#include functional

templateclass T void func( T )
{}

int main( int, char** )
{
  std::bind( funcint, 0 );
}
EOF

$ g++ t.cc -std=gnu++0x
t.cc: In function 'int main(int, char**)':
t.cc:8:27: error: cannot bind 'void(int)' lvalue to 'void ()(int)'
...

This is with GCC 4.6.0.  This works with GCC 4.5.2.


[Bug lto/48309] gcc -flto -fuse-linker-plugin generates crashing executables on MinGW

2011-03-28 Thread d.g.gorbachev at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48309

--- Comment #3 from Dmitry Gorbachev d.g.gorbachev at gmail dot com 
2011-03-28 11:35:37 UTC ---
(In reply to comment #2)

Gordon Magnusson wrote:
 C:\bugreportld -v
 GNU ld (GNU Binutils) 2.21.51.20110326


[Bug libobjc/48314] New: Make the new symbols weak symbols

2011-03-28 Thread js-gcc at webkeks dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48314

   Summary: Make the new symbols weak symbols
   Product: gcc
   Version: 4.6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: libobjc
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: js-...@webkeks.org


Hello,

gcc 4.6 introduces a lot of new symbols like objc_setProperty, objc_sync_enter
etc. Those are often already provided since they were always missing, but
support for e.g. @synchronized was always there. This creates conflicts now
when using gcc 4.6, thus I would suggest to make those weak symbols in 4.6.1.


[Bug middle-end/36043] gcc reads 8 bytes for a struct of size 6 which leads to sigsegv

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36043

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Target|x86_64-unknown-linux-gnu|x86_64-unknown-linux-gnu,
   ||i?86-*-*
  Component|target  |middle-end
  Known to fail||2.95.2

--- Comment #16 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
11:57:36 UTC ---
Also broken at least since GCC 2.95 on i?86 with

struct colour
{
  unsigned char red;
  unsigned char green;
  unsigned char blue;
};

void print_colour(struct colour col) __attribute__((regparm(3)));

void
foo(struct colour *c)
{
  print_colour(*c);
}


[Bug middle-end/36043] gcc reads 8 bytes for a struct of size 6 which leads to sigsegv

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36043

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Blocks||37954

--- Comment #17 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
11:58:50 UTC ---
PR37954 looks like a dup for arm.


[Bug c/42098] gcc does not honor alignment specification for qualified typedefs

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42098

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||DUPLICATE

--- Comment #4 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
12:02:40 UTC ---
dup.

*** This bug has been marked as a duplicate of bug 12742 ***


[Bug c/12742] Type alignment is lost if const is added to typedef

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12742

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 CC||jepler at unpythonic dot
   ||net

--- Comment #4 from Richard Guenther rguenth at gcc dot gnu.org 2011-03-28 
12:02:40 UTC ---
*** Bug 42098 has been marked as a duplicate of this bug. ***


[Bug libstdc++/48313] std::bind with template function

2011-03-28 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48313

Jonathan Wakely redi at gcc dot gnu.org changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2011.03.28 12:17:25
 Ever Confirmed|0   |1

--- Comment #1 from Jonathan Wakely redi at gcc dot gnu.org 2011-03-28 
12:17:25 UTC ---
The example should work. I'm travelling today but will check the functional
code later to see why the F constructor is being chosen instead of the const
F one.


[Bug fortran/48279] [4.6/4.7 Regression] segfault in gfc_check_vardef_context

2011-03-28 Thread jakub at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48279

Jakub Jelinek jakub at gcc dot gnu.org changed:

   What|Removed |Added

   Priority|P3  |P4
 CC||jakub at gcc dot gnu.org


[Bug libstdc++/48313] std::bind with template function

2011-03-28 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48313

--- Comment #2 from Jonathan Wakely redi at gcc dot gnu.org 2011-03-28 
12:24:23 UTC ---
The example can be modified to work by passing a pointer, so the template
argument isn't deduced as a function type:

  std::bind( funcint, 0 );


[Bug boehm-gc/48299] [4.7 Regression] FAIL: boehm-gc.c/thread_leak_test.c

2011-03-28 Thread hjl.tools at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48299

--- Comment #2 from H.J. Lu hjl.tools at gmail dot com 2011-03-28 12:31:35 
UTC ---
(In reply to comment #1)
 Could you please check if this test worked before my patch?  It may have
 been that the failure simply went unnoticed.
 

I don't think thread_leak_test.c was tested before.


[Bug target/48308] crosscompiling to arm fails with assembler: can't resolve '.LC4' {.rodata.str1.1 section} - '.LPIC4' {*UND* section}

2011-03-28 Thread dev-gcc-20110327-b588 at gheift dot de
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48308

--- Comment #2 from Gerhard Heift dev-gcc-20110327-b588 at gheift dot de 
2011-03-28 12:34:31 UTC ---
Created attachment 23791
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=23791
generated assembler

On line 114, the generates assembler code refers to .LPIC4, which does not
exists.


[Bug boehm-gc/48299] [4.7 Regression] FAIL: boehm-gc.c/thread_leak_test.c

2011-03-28 Thread ro at CeBiTec dot Uni-Bielefeld.DE
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48299

--- Comment #3 from ro at CeBiTec dot Uni-Bielefeld.DE ro at CeBiTec dot 
Uni-Bielefeld.DE 2011-03-28 12:40:06 UTC ---
 I don't think thread_leak_test.c was tested before.

In that case, please try to compile it with the same flags used for one
of the other tests (e.g, leak_test.c) to check if the problem is with my
dg conversion or elsewhere.

In any case, if this wasn't tested before, it's not a regression.

Thanks.
Rainer


[Bug libstdc++/48313] std::bind with template function

2011-03-28 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48313

--- Comment #3 from Jonathan Wakely redi at gcc dot gnu.org 2011-03-28 
12:43:12 UTC ---
It's not the _Bind constructor, it's the bind() call itself, this demonstrates
the problem:

templatetypename _Functor, typename... _ArgTypes
inline
void
bind(_Functor __f, _ArgTypes... __args) { }

templateclass T void func( T )
{}

int main( int, char** )
{
bind( funcint, 0 );
}


we might just need to overload std::bind for function types

std::bind() in 4.5 was defined differently as it didn't support rvalues
properly, so didn't show the problem


[Bug testsuite/48276] FAIL: gcc.target/i386/pr47502-2.c on x86_64-apple-darwin10.7.0 with -m32

2011-03-28 Thread hjl.tools at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48276

H.J. Lu hjl.tools at gmail dot com changed:

   What|Removed |Added

 CC|hjl at gcc dot gnu.org  |hjl.tools at gmail dot com

--- Comment #1 from H.J. Lu hjl.tools at gmail dot com 2011-03-28 12:44:50 
UTC ---
Please try

diff --git a/gcc/testsuite/gcc.target/i386/pr47502-2.c
b/gcc/testsuite/gcc.target/i386/pr47502-2.c
index 1f57ea0..a8dc1ca 100644
--- a/gcc/testsuite/gcc.target/i386/pr47502-2.c
+++ b/gcc/testsuite/gcc.target/i386/pr47502-2.c
@@ -1,5 +1,5 @@
 /* { dg-do compile } */
-/* { dg-options -O2 } */
+/* { dg-options -O2 -fno-pic } */

 int
 foo (int how, const void *set, void *oset)


[Bug testsuite/48276] FAIL: gcc.target/i386/pr47502-2.c on x86_64-apple-darwin10.7.0 with -m32

2011-03-28 Thread dominiq at lps dot ens.fr
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48276

--- Comment #2 from Dominique d'Humieres dominiq at lps dot ens.fr 2011-03-28 
12:52:43 UTC ---
 Please try

 ...
 -/* { dg-options -O2 } */
 +/* { dg-options -O2 -fno-pic } */
 ...

It does fix the failure, thanks.


[Bug target/48308] crosscompiling to arm fails with assembler: can't resolve '.LC4' {.rodata.str1.1 section} - '.LPIC4' {*UND* section}

2011-03-28 Thread mikpe at it dot uu.se
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48308

Mikael Pettersson mikpe at it dot uu.se changed:

   What|Removed |Added

 CC||mikpe at it dot uu.se

--- Comment #3 from Mikael Pettersson mikpe at it dot uu.se 2011-03-28 
13:09:15 UTC ---
(In reply to comment #2)
 Created attachment 23791 [details]
 generated assembler
 
 On line 114, the generates assembler code refers to .LPIC4, which does not
 exists.

Indeed.  If I compile with -mcpu=arm9tdmi as your assembly file indicates then
I lose several lines of code, including the .LPIC4 label and a strcmp() call,
but the reference to .LPIC4 remained.  Normally I have -march=armv5te
-mtune=xscale, and in that case the .LPIC4 label and surrounding code is not
lost.

Works(*) with gcc-4.4.5 and 4.5.2, so it's a regression.

(*) Had to eliminate some apparent C1X-isms from the test case though.


[Bug testsuite/48276] FAIL: gcc.target/i386/pr47502-2.c on x86_64-apple-darwin10.7.0 with -m32

2011-03-28 Thread hjl at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48276

--- Comment #3 from hjl at gcc dot gnu.org hjl at gcc dot gnu.org 2011-03-28 
13:14:56 UTC ---
Author: hjl
Date: Mon Mar 28 13:14:47 2011
New Revision: 171604

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171604
Log:
Add -fno-pic to gcc.target/i386/pr47502-2.c.

2011-03-28  H.J. Lu  hongjiu...@intel.com

PR testsuite/48276
* gcc.target/i386/pr47502-2.c: Add -fno-pic.

Modified:
trunk/gcc/testsuite/ChangeLog
trunk/gcc/testsuite/gcc.target/i386/pr47502-2.c


[Bug testsuite/48276] FAIL: gcc.target/i386/pr47502-2.c on x86_64-apple-darwin10.7.0 with -m32

2011-03-28 Thread hjl.tools at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48276

H.J. Lu hjl.tools at gmail dot com changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||FIXED
   Target Milestone|--- |4.7.0

--- Comment #4 from H.J. Lu hjl.tools at gmail dot com 2011-03-28 13:19:01 
UTC ---
Fixed.


[Bug fortran/48279] [4.6/4.7 Regression] segfault in gfc_check_vardef_context

2011-03-28 Thread burnus at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48279

--- Comment #6 from Tobias Burnus burnus at gcc dot gnu.org 2011-03-28 
13:21:30 UTC ---
==1823== Invalid read of size 1
==1823==at 0x4C32E7: gfc_check_vardef_context (expr.c:4377)
==1823==by 0x4CBC25: compare_actual_formal (interface.c:2291)
==1823==by 0x4CD48B: gfc_arglist_matches_symbol (interface.c:2813)
==1823==by 0x4CD6F4: gfc_search_interface (interface.c:2842)
==1823==by 0x50D2A2: resolve_call (resolve.c:3204)

The issue - or at least cause - for the segfault is the following code in
gfc_check_vardef_context:

  if (!pointer  e-expr_type == EXPR_FUNCTION
   e-symtree-n.sym-result-attr.pointer)

The problem is that e-symtree-n.sym-result == NULL. The symbol itself is
get_d_string. If one uses gdb's set e-symtree-n.sym-result =
e-symtree-n.sym and continues, one gets the expected error:

  Error: There is no specific subroutine for the generic 'set' at (1)

One problem seems to be that get_d_string is a generic interface - and not a
specific one:

(gdb) p e-symtree-n.sym-attr.generic
$1 = 1

The specific interface has properly the result variables set:
(gdb) p e-symtree-n.sym-generic-sym-name
$3 = 0x2e876280 get_d_string_p
(gdb) p e-symtree-n.sym-generic-sym-result
$4 = (struct gfc_symbol *) 0x1281280

Calling gfc_check_vardef_context for an generic interface seems to be
questionable.


[Bug debug/48315] New: ICE in mem_loc_descriptor, at dwarf2out.c:13899

2011-03-28 Thread danglin at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48315

   Summary: ICE in mem_loc_descriptor, at dwarf2out.c:13899
   Product: gcc
   Version: 4.7.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: debug
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: dang...@gcc.gnu.org
  Host: armv5tejl-unknown-linux-gnueabi
Target: armv5tejl-unknown-linux-gnueabi
 Build: armv5tejl-unknown-linux-gnueabi


Executing on host: /home/dave/gnu/gcc/objdir/gcc/xgcc
-B/home/dave/gnu/gcc/objdi
r/gcc/ /home/dave/gnu/gcc/gcc/libgomp/testsuite/libgomp.fortran/vla2.f90 
-B/hom
e/dave/gnu/gcc/objdir/armv5tejl-unknown-linux-gnueabi/./libgomp/
-B/home/dave/gn
u/gcc/objdir/armv5tejl-unknown-linux-gnueabi/./libgomp/.libs
-I/home/dave/gnu/gc
c/objdir/armv5tejl-unknown-linux-gnueabi/./libgomp
-I/home/dave/gnu/gcc/gcc/libg
omp/testsuite/.. -fmessage-length=0 -fopenmp  -O3 -g  
-B/home/dave/gnu/gcc/objd
ir/armv5tejl-unknown-linux-gnueabi/./libgomp/../libgfortran/.libs  
-L/home/dave
/gnu/gcc/objdir/armv5tejl-unknown-linux-gnueabi/./libgomp/.libs -lgomp
-L/home/d
ave/gnu/gcc/objdir/armv5tejl-unknown-linux-gnueabi/./libgomp/../libgfortran/.lib
s -lgfortran -lm   -o ./vla2.exe(timeout = 300)
/home/dave/gnu/gcc/gcc/libgomp/testsuite/libgomp.fortran/vla2.f90: In function
'
foo':
/home/dave/gnu/gcc/gcc/libgomp/testsuite/libgomp.fortran/vla2.f90:127:0:
interna
l compiler error: in mem_loc_descriptor, at dwarf2out.c:13899

FAIL: libgomp.fortran/vla2.f90  -O3 -g  (internal compiler error)
FAIL: libgomp.fortran/vla2.f90  -O3 -g  (test for excess errors)

-bash-3.2$ gcc/xgcc -Bgcc/ -v
Reading specs from gcc/specs
COLLECT_GCC=gcc/xgcc
COLLECT_LTO_WRAPPER=gcc/lto-wrapper
Target: armv5tejl-unknown-linux-gnueabi
Configured with: ../gcc/configure --host=armv5tejl-unknown-linux-gnueabi
--target=armv5tejl-unknown-linux-gnueabi
--build=armv5tejl-unknown-linux-gnueabi
--enable-languages=c,c++,fortran,objc,obj-c++ --enable-checking=release
--enable-shared --enable-threads --disable-multilib --disable-libmudflap
--disable-libssp --enable-symvers=gnu --enable-__cxa_atexit
--disable-libstdcxx-pch --prefix=/home/dave/opt/gnu/gcc/gcc-4.6.0
--with-gmp=/home/dave/opt/gnu --with-as=/home/dave/opt/gnu/bin/as
--with-ld=/home/dave/opt/gnu/bin/ld
Thread model: posix
gcc version 4.7.0 20110325 (experimental) [trunk revision 171528] (GCC)

Similar fails:

FAIL: libgomp.fortran/vla6.f90  -O3 -g  (internal compiler error)
FAIL: libgomp.fortran/vla6.f90  -O3 -g  (test for excess errors)
FAIL: libgomp.fortran/vla8.f90  -O3 -g  (internal compiler error)
FAIL: libgomp.fortran/vla8.f90  -O3 -g  (test for excess errors)


[Bug preprocessor/48248] [4.5/4.6/4.7 Regression] Wrong error message location when compiling preprocessed code

2011-03-28 Thread jakub at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48248

Jakub Jelinek jakub at gcc dot gnu.org changed:

   What|Removed |Added

 CC||jakub at gcc dot gnu.org

--- Comment #2 from Jakub Jelinek jakub at gcc dot gnu.org 2011-03-28 
13:47:05 UTC ---
Can't reproduce this, neither with g++ 4.5, nor trunk.


[Bug preprocessor/48248] [4.5/4.6/4.7 Regression] Wrong error message location when compiling preprocessed code

2011-03-28 Thread joerg.rich...@pdv-fs.de
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48248

--- Comment #3 from joerg.rich...@pdv-fs.de 2011-03-28 13:51:55 UTC ---
(In reply to comment #2)
 Can't reproduce this, neither with g++ 4.5, nor trunk.

Did you delete the empty lines?


[Bug tree-optimization/48316] New: missed CSE / reassoc with array offsets

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48316

   Summary: missed CSE / reassoc with array offsets
   Product: gcc
   Version: 4.7.0
Status: UNCONFIRMED
  Keywords: missed-optimization
  Severity: normal
  Priority: P3
 Component: tree-optimization
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: rgue...@gcc.gnu.org


int
foo (int *p, int i)
{
  int i1 = i + 1;
  int i2 = i + 2;
  return p[i1] + p[i2];
}

int
bar (int *p, unsigned long i)
{
  unsigned long i1 = i + 1;
  unsigned long i2 = i + 2;
  return p[i1] + p[i2];
}

For both testcases (the latter being the more optimal input due to
pointer-plus-expr constraints) we miss to CSE the multiplication
of i by 4 which makes the memory references not trivially independent
(based on the same pointer, offsetted by different constants).  Such
a case causes vectorization for alias checks being inserted for
gfortran.dg/reassoc_4.f with --param max-completely-peeled-insns=4000

IL on x86_64 is

bb 2:
  i1_2 = i_1(D) + 1;
  i2_3 = i_1(D) + 2;
  D.2702_4 = (long unsigned int) i1_2;
  D.2703_5 = D.2702_4 * 4;
  D.2704_7 = p_6(D) + D.2703_5;
  D.2705_8 = MEM[(int *)D.2704_7];
  D.2706_9 = (long unsigned int) i2_3;
  D.2707_10 = D.2706_9 * 4;
  D.2708_11 = p_6(D) + D.2707_10;
  D.2709_12 = MEM[(int *)D.2708_11];
  D.2701_13 = D.2705_8 + D.2709_12;
  return D.2701_13;

vs.

bb 2:
  i1_2 = i_1(D) + 1;
  i2_3 = i_1(D) + 2;
  D.2694_4 = i1_2 * 4;
  D.2695_6 = p_5(D) + D.2694_4;
  D.2696_7 = MEM[(int *)D.2695_6];
  D.2697_8 = i2_3 * 4;
  D.2698_9 = p_5(D) + D.2697_8;
  D.2699_10 = MEM[(int *)D.2698_9];
  D.2693_11 = D.2696_7 + D.2699_10;
  return D.2693_11;

For the reassoc_4.f testcase the question is whether either SCEV or
data-dependence can be enhanced to handle the cases (the multiplications
are in BB2, outside of any loop).


[Bug c/44384] builtin_object_size_ treatment of multidimensional arrays is unexpected

2011-03-28 Thread jakub at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44384

Jakub Jelinek jakub at gcc dot gnu.org changed:

   What|Removed |Added

 CC||jakub at gcc dot gnu.org

--- Comment #1 from Jakub Jelinek jakub at gcc dot gnu.org 2011-03-28 
14:05:34 UTC ---
__builtin_object_size is a builtin for -D_FORTIFY_SOURCE checking, it is not a
generic object size computation function, and for strcpy IMHO we don't want to
treat each dimension as a field separator.


[Bug libstdc++/48313] std::bind with template function

2011-03-28 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48313

--- Comment #4 from Jonathan Wakely redi at gcc dot gnu.org 2011-03-28 
14:26:35 UTC ---
slightly further reduced:


templatetypename Functor, typename ArgTypes
inline void
bind(Functor f, ArgTypes a) { }

templatetypename T
void func( T )
{}

int main( int, char** )
{
bind( funcint, 0 );
}

this is certainly not a libstdc++ bug (std::bind matches the signature require
by the C++0x draft)

I think the parameter is a non-deduced context, because the argument is an
overload set containing one or more function templates ([temp.deduct.call p6)

So I think this is actually invalid and G++ is right to reject it.


[Bug tree-optimization/48317] New: SCCVN does not handle vector constructors

2011-03-28 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48317

   Summary: SCCVN does not handle vector constructors
   Product: gcc
   Version: 4.7.0
Status: UNCONFIRMED
  Keywords: missed-optimization
  Severity: enhancement
  Priority: P3
 Component: tree-optimization
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: rgue...@gcc.gnu.org


SCCVN does not handle CONSTRUCTORs well (they simply get put into a
reference-kind
single operand).  This sucks for things like

  vect_cst_.239_4355 = {pretmp.88_1931, pretmp.88_1931};

which the vectorizer generates (or which can happen via intrinsics or
generic vector support even earlier).

Not sure how to handle this variable-size code though.


[Bug c++/48289] [4.5/4.6/4.7 regression] -pedantic breaks std::move

2011-03-28 Thread jason at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48289

--- Comment #3 from Jason Merrill jason at gcc dot gnu.org 2011-03-28 
15:06:32 UTC ---
Author: jason
Date: Mon Mar 28 15:06:28 2011
New Revision: 171607

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171607
Log:
Revert:
PR c++/48289
* pt.c (build_non_dependent_expr): Keep dereferences outside the
NON_DEPENDENT_EXPR.

Removed:
branches/gcc-4_5-branch/gcc/testsuite/g++.dg/cpp0x/move1.C
Modified:
branches/gcc-4_5-branch/gcc/cp/ChangeLog
branches/gcc-4_5-branch/gcc/cp/pt.c
branches/gcc-4_5-branch/gcc/testsuite/ChangeLog


[Bug tree-optimization/48195] ICE: vector VEC(ipa_node_params_t,base) index domain error, in ipa_analyze_node at ipa-prop.c:1525 with -flto --param partial-inlining-entry-probability=101

2011-03-28 Thread jamborm at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48195

Martin Jambor jamborm at gcc dot gnu.org changed:

   What|Removed |Added

 Status|NEW |ASSIGNED
 AssignedTo|unassigned at gcc dot   |jamborm at gcc dot gnu.org
   |gnu.org |

--- Comment #2 from Martin Jambor jamborm at gcc dot gnu.org 2011-03-28 
15:15:15 UTC ---
Mine.


[Bug go/48312] [4.7 regression] http, rpc, websocket tests hang on Solaris 2/x86

2011-03-28 Thread ian at airs dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48312

Ian Lance Taylor ian at airs dot com changed:

   What|Removed |Added

 Status|UNCONFIRMED |ASSIGNED
   Last reconfirmed||2011.03.28 15:51:34
 Ever Confirmed|0   |1

--- Comment #1 from Ian Lance Taylor ian at airs dot com 2011-03-28 15:51:34 
UTC ---
Sorry, I forgot about this issue when I updated the library.


[Bug other/48318] New: Memory access error by build/genhooks?

2011-03-28 Thread Markus.Elfring at web dot de
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48318

   Summary: Memory access error by build/genhooks?
   Product: gcc
   Version: 4.6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: other
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: markus.elfr...@web.de
  Host: x86_64-unknown-linux-gnu
Target: x86_64-unknown-linux-gnu
 Build: x86_64-unknown-linux-gnu


I try to generate the current GCC software for my openSUSE 11.4 system.
Unfortunately, I stumble on the following German message.

...
/bin/sh /home/elfring/Projekte/GNU/GCC/Quellen/4.6.0/gcc/../move-if-change
tmp-optionlist optionlist
echo timestamp  s-options
build/genhooks \
/home/elfring/Projekte/GNU/GCC/Quellen/4.6.0/gcc/doc/tm.texi.in 
tmp-tm.texi
gcc   -g -fkeep-inline-functions -DIN_GCC   -W -Wall -Wwrite-strings
-Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wmissing-format-attribute
-pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings
-Wold-style-definition -Wc++-compat -fno-common  -DHAVE_CONFIG_H
-DGENERATOR_FILE  -o build/genconstants \
build/genconstants.o build/read-md.o build/errors.o
../build-x86_64-unknown-linux-gnu/libiberty/libiberty.a
/bin/sh: Zeile 1: 29541 Speicherzugriffsfehler  build/genhooks
/home/elfring/Projekte/GNU/GCC/Quellen/4.6.0/gcc/doc/tm.texi.in  tmp-tm.texi
make[3]: *** [s-tm-texi] Fehler 139
make[3]: *** Warte auf noch nicht beendete Prozesse...
rm gcc.pod
make[3]: Leaving directory
`/home/elfring/Projekte/GNU/GCC/erzeugt/4.6.0/Auswahl/gcc'
make[2]: *** [all-stage1-gcc] Fehler 2
make[2]: Leaving directory
`/home/elfring/Projekte/GNU/GCC/erzeugt/4.6.0/Auswahl'
make[1]: *** [stage1-bubble] Fehler 2
make[1]: Leaving directory
`/home/elfring/Projekte/GNU/GCC/erzeugt/4.6.0/Auswahl'
make: *** [all] Fehler 2

How can this memory access error/segmentation fault be resolved?

I would like to use the configuration parameters
--enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr/local.


[Bug c++/48296] [C++0x] constexpr member function cannot use the class type it belongs as parameter type or return type

2011-03-28 Thread paolo.carlini at oracle dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48296

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

 CC||jason at gcc dot gnu.org
Summary|constexpr member function   |[C++0x] constexpr member
   |cannot use the class type   |function cannot use the
   |it belongs as parameter |class type it belongs as
   |type or return type |parameter type or return
   ||type

--- Comment #1 from Paolo Carlini paolo.carlini at oracle dot com 2011-03-28 
16:11:00 UTC ---
Adding Jason in CC.


[Bug other/48318] Memory access error by build/genhooks?

2011-03-28 Thread Markus.Elfring at web dot de
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48318

Markus Elfring Markus.Elfring at web dot de changed:

   What|Removed |Added

   Keywords||build

--- Comment #1 from Markus Elfring Markus.Elfring at web dot de 2011-03-28 
16:11:02 UTC ---
I assume that an output from the command dmesg like the following belongs to
the reported situation.

[37489.218661] genhooks[4926]: segfault at 60fa40 ip 0060fa40 sp
7fffd3ab7bc8 error 15 in genhooks[60c000+4000]


[Bug preprocessor/48248] [4.5/4.6/4.7 Regression] Wrong error message location when compiling preprocessed code

2011-03-28 Thread jakub at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48248

--- Comment #4 from Jakub Jelinek jakub at gcc dot gnu.org 2011-03-28 
16:15:52 UTC ---
Ah, I can reproduce with those lines.
Apparently caused by my PR41445 fix.

To fix this, I think we should remember not just src_line, but also filename
in print variable in c-ppoutput.c.  And, either we should avoid calling
do_line_change for avoid_paste resp. PREV_WHITE in scan_translation_unit if
file is different, or maybe_print_line should do the
if (src_line = print.src_line  src_line  print.src_line + 8)
optimization only if it is the same file.

As PR41445 has been in already in 4.5 and nobody complained about e.g.
# 1 pr48248-2.C
# 1 built-in
# 1 command-line
# 1 pr48248-2.C
# 1 pr48248.h 1
enum E { B };
# 2 pr48248-2.C 2
# 17 pr48248-2.C
void
foo ()
{
  (void)
# 3 pr48248.h
   B
# 20 pr48248-2.C
  ;
  a;
}

(where # 3 pr48248.h doesn't say that the header is being entered, just
temporarily jumps to it), I'd probably prefer the latter choice, as it gives
more correct locus info.


[Bug c++/48294] [C++0x] ICE in build_noexcept_spec, at cp/except.c:1217

2011-03-28 Thread paolo.carlini at oracle dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48294

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
  Known to work||4.6.1, 4.7.0
 Resolution||FIXED
Summary|internal compiler error: in |[C++0x] ICE in
   |build_noexcept_spec, at |build_noexcept_spec, at
   |cp/except.c:1217|cp/except.c:1217
  Known to fail||4.6.0

--- Comment #2 from Paolo Carlini paolo.carlini at oracle dot com 2011-03-28 
16:21:25 UTC ---
Fixed for trunk and 4.6.1 by this patch:

  http://gcc.gnu.org/ml/gcc-patches/2011-03/msg01913.html


[Bug c++/48292] [C++0x] sorry, unimplemented: use of 'type_pack_expansion' in template

2011-03-28 Thread paolo.carlini at oracle dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48292

--- Comment #3 from Paolo Carlini paolo.carlini at oracle dot com 2011-03-28 
16:27:43 UTC ---
CC-ing Jason about this one too. By the way, isn't the first time this sorry
message surfaces, eg, Comment #4 in PR44167.


[Bug testsuite/48238] FAIL: gcc.dg/debug/dwarf2/pr47939-0.c scan-assembler on *-apple-darwin*

2011-03-28 Thread ro at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48238

--- Comment #8 from Rainer Orth ro at gcc dot gnu.org 2011-03-28 16:39:44 UTC 
---
Author: ro
Date: Mon Mar 28 16:39:35 2011
New Revision: 171615

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171615
Log:
2011-03-26  Dominique d'Humieres  domi...@lps.ens.fr

PR testsuite/48238
* gcc.dg/debug/dwarf2/pr47939-1.c: Generalize scan-assembler regex.
* gcc.dg/debug/dwarf2/pr47939-2.c: Likewise.
* gcc.dg/debug/dwarf2/pr47939-3.c: Likewise.
* gcc.dg/debug/dwarf2/pr47939-4.c: Likewise.

Modified:
trunk/gcc/testsuite/ChangeLog
trunk/gcc/testsuite/gcc.dg/debug/dwarf2/pr47939-1.c
trunk/gcc/testsuite/gcc.dg/debug/dwarf2/pr47939-2.c
trunk/gcc/testsuite/gcc.dg/debug/dwarf2/pr47939-3.c
trunk/gcc/testsuite/gcc.dg/debug/dwarf2/pr47939-4.c


[Bug testsuite/48238] FAIL: gcc.dg/debug/dwarf2/pr47939-0.c scan-assembler on *-apple-darwin*

2011-03-28 Thread ro at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48238

Rainer Orth ro at gcc dot gnu.org changed:

   What|Removed |Added

 Status|NEW |RESOLVED
URL||http://gcc.gnu.org/ml/gcc-p
   ||atches/2011-03/msg01918
 Resolution||FIXED
 AssignedTo|unassigned at gcc dot   |ro at gcc dot gnu.org
   |gnu.org |
   Target Milestone|--- |4.7.0

--- Comment #9 from Rainer Orth ro at gcc dot gnu.org 2011-03-28 16:42:51 UTC 
---
Applied the patch after testing.

Thanks.
  Rainer


[Bug testsuite/48251] guality_check hangs indefinitely on Tru64 UNIX

2011-03-28 Thread ro at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48251

--- Comment #3 from Rainer Orth ro at gcc dot gnu.org 2011-03-28 16:46:33 UTC 
---
Author: ro
Date: Mon Mar 28 16:46:27 2011
New Revision: 171616

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171616
Log:
Backport from mainline:
2011-03-23  Rainer Orth  r...@cebitec.uni-bielefeld.de

PR testsuite/48251
* g++.dg/guality/guality.exp: Disable on alpha*-dec-osf*.

Modified:
branches/gcc-4_6-branch/gcc/testsuite/ChangeLog
branches/gcc-4_6-branch/gcc/testsuite/g++.dg/guality/guality.exp


[Bug c++/48313] [C++0] std::bind with template function

2011-03-28 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48313

Jonathan Wakely redi at gcc dot gnu.org changed:

   What|Removed |Added

 Status|NEW |UNCONFIRMED
 CC||jason at gcc dot gnu.org
  Component|libstdc++   |c++
Summary|std::bind with template |[C++0] std::bind with
   |function|template function
 Ever Confirmed|1   |0

--- Comment #5 from Jonathan Wakely redi at gcc dot gnu.org 2011-03-28 
17:02:14 UTC ---
Actually no, that paragraph doesn't apply because P is a reference type not
function type.

Jason should the call to f(hint) be accepted here?

templatetypename F
void f(F) { }

void g() { }

templatetypename T void h() { }

int main()
{
  f( g );   // OK
  void (p)() = hint;
  f( p );   // OK
  f( hint );  // ???
}


[Bug lto/48309] gcc -flto -fuse-linker-plugin generates crashing executables on MinGW

2011-03-28 Thread pinskia at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48309

Andrew Pinski pinskia at gcc dot gnu.org changed:

   What|Removed |Added

 Status|WAITING |RESOLVED
 Resolution||DUPLICATE

--- Comment #4 from Andrew Pinski pinskia at gcc dot gnu.org 2011-03-28 
17:03:25 UTC ---


*** This bug has been marked as a duplicate of bug 47891 ***


[Bug lto/47891] GCC 4.6/4.7 LTO not worked reliable on Windows target

2011-03-28 Thread pinskia at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47891

Andrew Pinski pinskia at gcc dot gnu.org changed:

   What|Removed |Added

 CC||gordon.magnusson at gmail
   ||dot com

--- Comment #8 from Andrew Pinski pinskia at gcc dot gnu.org 2011-03-28 
17:03:25 UTC ---
*** Bug 48309 has been marked as a duplicate of this bug. ***


[Bug bootstrap/48135] build fails on Solaris2.8 due to Glob.pm not found within /usr/perl5

2011-03-28 Thread ro at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48135

--- Comment #25 from Rainer Orth ro at gcc dot gnu.org 2011-03-28 17:09:34 
UTC ---
Author: ro
Date: Mon Mar 28 17:09:27 2011
New Revision: 171617

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171617
Log:
libgfortran:
backport from mainline:
2011-03-21  Rainer Orth  r...@cebitec.uni-bielefeld.de
PR bootstrap/48135
* configure.ac (gfortran_use_symver): Handle --disable-symvers.
* configure: Regenerate.

libgomp:
backport from mainline:
2011-03-21  Rainer Orth  r...@cebitec.uni-bielefeld.de
PR bootstrap/48135
* acinclude.m4 (enable_symvers): Handle --disable-symvers.
* configure: Regenerate.

libjava:
backport from mainline:
2011-03-21  Rainer Orth  r...@cebitec.uni-bielefeld.de
PR bootstrap/48135
* configure.ac (libjava_cv_anon_version_script): Handle
--disable-symvers.
* configure: Regenerate.

libquadmath:
backport from mainline:
2011-03-21  Rainer Orth  r...@cebitec.uni-bielefeld.de
PR bootstrap/48135
* configure.ac (quadmath_use_symver): Handle --disable-symvers.
* configure: Regenerate.

libssp:
backport from mainline:
2011-03-21  Rainer Orth  r...@cebitec.uni-bielefeld.de
PR bootstrap/48135
* configure.ac (ssp_use_symver): Handle --disable-symvers.
* configure: Regenerate.

Modified:
branches/gcc-4_6-branch/libgfortran/ChangeLog
branches/gcc-4_6-branch/libgfortran/configure
branches/gcc-4_6-branch/libgfortran/configure.ac
branches/gcc-4_6-branch/libgomp/ChangeLog
branches/gcc-4_6-branch/libgomp/acinclude.m4
branches/gcc-4_6-branch/libgomp/configure
branches/gcc-4_6-branch/libjava/ChangeLog
branches/gcc-4_6-branch/libjava/configure
branches/gcc-4_6-branch/libjava/configure.ac
branches/gcc-4_6-branch/libquadmath/ChangeLog
branches/gcc-4_6-branch/libquadmath/configure
branches/gcc-4_6-branch/libquadmath/configure.ac
branches/gcc-4_6-branch/libssp/ChangeLog
branches/gcc-4_6-branch/libssp/configure
branches/gcc-4_6-branch/libssp/configure.ac


[Bug middle-end/43631] var-tracking inserts notes with non-NULL BLOCK_FOR_INSN in between basic blocks

2011-03-28 Thread steven at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43631

--- Comment #3 from Steven Bosscher steven at gcc dot gnu.org 2011-03-28 
17:18:25 UTC ---
Jakub, please do not forget about this one for stage1 GCC 4.7.


[Bug target/48301] Xcode 4.0's llvm-gcc can't bootstrap gcc 4.6.0 or trunk

2011-03-28 Thread mikestump at comcast dot net
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48301

--- Comment #4 from Mike Stump mikestump at comcast dot net 2011-03-28 
17:41:36 UTC ---
If there is an easy work around in gcc to avoid the problem, we could entertain
that, but, generally, I'd be more interested in clang failures going forward. 
llvm-gcc is old and getting older every day.  The dragon egg bits are newer and
more compelling.


[Bug c++/48319] New: Segmentation fault in instantiation of std::is_constructibleint

2011-03-28 Thread gintensubaru at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48319

   Summary: Segmentation fault in instantiation of
std::is_constructibleint
   Product: gcc
   Version: 4.6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: gintensub...@gmail.com


Source file (bug.cc):

#include type_traits

int main() {
  static_assert( std::is_constructibleint::value,  );
}


Message:

In file included from bug.cc:1:0:
/usr/local/gcc-4.6.0/lib/gcc/x86_64-unknown-linux-gnu/4.6.0/../../../../include/c++/4.6.0/type_traits:
In instantiation of ‘const bool
std::__is_constructible_helperint::__value’:
/usr/local/gcc-4.6.0/lib/gcc/x86_64-unknown-linux-gnu/4.6.0/../../../../include/c++/4.6.0/type_traits:683:12:
  instantiated from ‘std::is_constructibleint’
bug.cc:7:42:   instantiated from here
/usr/local/gcc-4.6.0/lib/gcc/x86_64-unknown-linux-gnu/4.6.0/../../../../include/c++/4.6.0/type_traits:661:71:
internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See http://gcc.gnu.org/bugs.html for instructions.


[Bug target/48288] [4.7 Regression] ld: Unsatisfied symbol __iordi3 in file /test/gnu/gcc/objdir/./gcc/libgcc_eh.a

2011-03-28 Thread danglin at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48288

John David Anglin danglin at gcc dot gnu.org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED

--- Comment #6 from John David Anglin danglin at gcc dot gnu.org 2011-03-28 
17:45:39 UTC ---
Fixed on trunk.


[Bug c++/48319] [4.6/4.7 Regression] [C++0x] Segmentation fault in instantiation of std::is_constructibleint

2011-03-28 Thread paolo.carlini at oracle dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48319

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

 CC||jason at gcc dot gnu.org
Summary|Segmentation fault in   |[4.6/4.7 Regression]
   |instantiation of|[C++0x] Segmentation fault
   |std::is_constructibleint  |in instantiation of
   ||std::is_constructibleint

--- Comment #1 from Paolo Carlini paolo.carlini at oracle dot com 2011-03-28 
17:58:08 UTC ---
Looks like a regression. Note, in any case std::is_constructible itself didn't
change lately.


[Bug tree-optimization/48290] FAIL: gcc.dg/vect/pr38529.c, ICE in vect_get_vec_def_for_operand, at tree-vect-stmts.c:1072

2011-03-28 Thread dominiq at lps dot ens.fr
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48290

--- Comment #5 from Dominique d'Humieres dominiq at lps dot ens.fr 2011-03-28 
18:26:52 UTC ---
The patch in comment #3 fixes the ICE, but the test still fails:

FAIL: gcc.dg/vect/pr38529.c scan-tree-dump-times vect OUTER LOOP VECTORIZED 1

Compiling with -Ofast -ftree-vectorizer-verbose=2 I get

/opt/gcc/_clean/gcc/testsuite/gcc.dg/vect/pr38529.c:11: note: not vectorized:
unsupported data-type
/opt/gcc/_clean/gcc/testsuite/gcc.dg/vect/pr38529.c:6: note: vectorized 0 loops
in function.

With revision 171398 I get

/opt/gcc/_clean/gcc/testsuite/gcc.dg/vect/pr38529.c:10: note: LOOP VECTORIZED.
/opt/gcc/_clean/gcc/testsuite/gcc.dg/vect/pr38529.c:10: note: OUTER LOOP
VECTORIZED.
/opt/gcc/_clean/gcc/testsuite/gcc.dg/vect/pr38529.c:6: note: vectorized 1 loops
in function.

No other test fails in gcc/testsuite/*/vect/* (full test for tonight).


[Bug regression/48320] New: [C++0x] cannot expand template parameter pack in Default template arguments

2011-03-28 Thread gintensubaru at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48320

   Summary: [C++0x] cannot expand template parameter pack in
Default template arguments
   Product: gcc
   Version: 4.6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: regression
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: gintensub...@gmail.com


Source File (bug.cc):

#include tuple
#include type_traits
#include utility

template std::size_t... Indices 
struct indices {};

template class Tuple, std::size_t... Indices,
  class Result = std::tuple
typename std::tuple_element
  Indices, typename std::decayTuple::type
::type...
  

Result f( Tuple  t, indicesIndices... )
{
  return Result(
std::forwardtypename std::tuple_elementIndices, Tuple::type(
  std::getIndices(t)
)...
  );
}

#include cassert

int main()
{
  auto t = f( std::make_tuple( 1, 2, 3 ), indices2, 1, 0() );

  assert( std::get0(t) == 3 );
  assert( std::get1(t) == 2 );
  assert( std::get2(t) == 1 );
}


Message:

compiling and running file 'bug.cc'...
bug.cc: In function ‘int main()’:
bug.cc:28:62: error: no matching function for call to ‘f(std::tupleint, int,
int, indices2u, 1u, 0u)’
bug.cc:28:62: note: candidate is:
bug.cc:15:43: note: templateclass Tuple, unsigned int ...Indices, class
Result Result f(Tuple, indicesIndices ...)
bug.cc:28:62: error: unable to deduce ‘auto’ from ‘expression error’



Note:

#include tuple
#include type_traits
#include utility

template std::size_t... Indices 
struct indices {};

template class Tuple, std::size_t... Indices 
std::tuple
  typename std::tuple_element
Indices, typename std::decayTuple::type
  ::type...

f( Tuple  t, indicesIndices... )
{
  typedef std::tuple
typename std::tuple_element
  Indices, typename std::decayTuple::type
::type...
   Result;

  return Result(
std::forwardtypename std::tuple_elementIndices, Tuple::type(
  std::getIndices(t)
)...
  );
}

#include cassert

int main()
{
  auto t = f( std::make_tuple( 1, 2, 3 ), indices2, 1, 0() );

  assert( std::get0(t) == 3 );
  assert( std::get1(t) == 2 );
  assert( std::get2(t) == 1 );
}

is OK.


[Bug go/48312] [4.7 regression] http, rpc, websocket tests hang on Solaris 2/x86

2011-03-28 Thread ian at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48312

--- Comment #2 from ian at gcc dot gnu.org ian at gcc dot gnu.org 2011-03-28 
18:35:56 UTC ---
Author: ian
Date: Mon Mar 28 18:35:53 2011
New Revision: 171623

URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=171623
Log:
PR go/48312
Fix fd_select.go for changes in FD handling.

We have to wake up the goroutine waiting in select each time
we change the set of descriptors we are waiting for, unlike
epoll.

Modified:
trunk/libgo/go/net/fd.go
trunk/libgo/go/net/fd_linux.go
trunk/libgo/go/net/fd_select.go
trunk/libgo/go/net/newpollserver.go
trunk/libgo/go/net/newpollserver_rtems.go


[Bug go/48312] [4.7 regression] http, rpc, websocket tests hang on Solaris 2/x86

2011-03-28 Thread ian at airs dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48312

Ian Lance Taylor ian at airs dot com changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED

--- Comment #3 from Ian Lance Taylor ian at airs dot com 2011-03-28 18:36:37 
UTC ---
Fixed.


[Bug c++/48319] [4.6/4.7 Regression] [C++0x] Segmentation fault in instantiation of std::is_constructibleint

2011-03-28 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48319

--- Comment #2 from Jonathan Wakely redi at gcc dot gnu.org 2011-03-28 
18:38:37 UTC ---
reduced

  templatetypename Tp Tp declval() noexcept; 

  templatetypename _Tp
class __is_constructible_helper
{
  typedef char __one;
  typedef struct { char __arr[2]; } __two;

  templatetypename _Tp1, typename... _Args1
static decltype(_Tp1(declval_Args1()...), __one()) __test(int);

  templatetypename, typename...
static __two __test(...);

public:
  static const bool __value = sizeof(__test_Tp(0)) == 1;
};

  int main() {
return __is_constructible_helperint::__value;
  }


[Bug tree-optimization/48321] New: gcc.dg/graphite/id-pr46845.c FAILs on IRIX 6.5: ICE in commit_one_edge_insertion, at cfgrtl.c:1566

2011-03-28 Thread ro at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48321

   Summary: gcc.dg/graphite/id-pr46845.c FAILs on IRIX 6.5: ICE in
commit_one_edge_insertion, at cfgrtl.c:1566
   Product: gcc
   Version: 4.7.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: tree-optimization
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: r...@gcc.gnu.org
CC: s...@gcc.gnu.org
  Host: mips-sgi-irix6.5
Target: mips-sgi-irix6.5
 Build: mips-sgi-irix6.5


The new gcc.dg/graphite/id-pr46845.c causes an ICE on IRIX 6.5:

/vol/gcc/src/hg/trunk/local/gcc/testsuite/gcc.dg/graphite/id-pr46845.c: In
funct
ion 'foo':
/vol/gcc/src/hg/trunk/local/gcc/testsuite/gcc.dg/graphite/id-pr46845.c:17:1:
int
ernal compiler error: in commit_one_edge_insertion, at cfgrtl.c:1566


[Bug preprocessor/48248] [4.5/4.6/4.7 Regression] Wrong error message location when compiling preprocessed code

2011-03-28 Thread jakub at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48248

Jakub Jelinek jakub at gcc dot gnu.org changed:

   What|Removed |Added

 Status|NEW |ASSIGNED
 AssignedTo|unassigned at gcc dot   |jakub at gcc dot gnu.org
   |gnu.org |

--- Comment #5 from Jakub Jelinek jakub at gcc dot gnu.org 2011-03-28 
18:49:06 UTC ---
Created attachment 23792
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=23792
gcc46-pr48248.patch

Untested fix (the second alternative).


[Bug c++/48322] New: [C++0x] Plural parameter packs are not expanded well

2011-03-28 Thread gintensubaru at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48322

   Summary: [C++0x] Plural parameter packs are not expanded well
   Product: gcc
   Version: 4.6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: gintensub...@gmail.com


Source Code (bug.cc):


#include typeinfo
#include cxxabi.h
#include cstdlib
#include iostream

templateclass T
void print_typename()
{
  int status = 0;
  char* const name = abi::__cxa_demangle( typeid(T).name(), 0, 0, status );
  std::cout  name  std::endl;
  std::free( name );
}

#include type_traits
#include utility
#include tuple

templateclass... Ts
struct X
{
  template class... Us,
class Tuple = std::tuple
  std::pairTs, Us...

  
  static void test( Us... ) {
print_typenameTuple();
  }

};

int main()
{
 // expected
  X::test();   // std::tuple
  Xint::test(1);   // std::tuplestd::pairint, int
  Xint::test(1.0); // std::tuplestd::pairint, double

  X::test(1);  // no matching function
  Xint::test();// no matching function
}



Output:

std::tuple
std::tuplestd::pairint, int 
std::tuplestd::pairdouble, double 
std::tuplestd::pairint, int 
std::tuple


  1   2   >