[Bug target/55316] gcc/libsanitizer/asan/asan_linux.cc:70:3: error: #error "Unsupported arch"

2012-11-17 Thread hp at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55316



Hans-Peter Nilsson  changed:



   What|Removed |Added



 CC||hp at gcc dot gnu.org



--- Comment #1 from Hans-Peter Nilsson  2012-11-17 
08:01:42 UTC ---

This should be fixed now by the general disabling of libsanitizer.


[Bug debug/54693] VTA guality issues with loops

2012-11-17 Thread andreast at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54693



Andreas Tobler  changed:



   What|Removed |Added



 CC||andreast at gcc dot gnu.org



--- Comment #19 from Andreas Tobler  2012-11-17 
10:01:05 UTC ---

The commit r193139, comment #14, breaks bootstrap on powerpc64-*-* with

--disabled-checking.



Seen here on powerpc64-unknown-freebsd10.0 and Peter Bergner confirmed the same

break on powerp64-*-linux*.



Bootstrap comparison failure!

gcc/tree-ssa-forwprop.o differs



<._ZL33ssa_forward_propagate_and_combinev+0x2548>

-9658:e8 89 00 09 ldu r4,8(r9)

-965c:39 08 00 01 addir8,r8,1

+9658:39 08 00 01 addir8,r8,1

+965c:e8 89 00 09 ldu r4,8(r9)

 9660:4b ff ff d0 b   9630


[Bug ada/55243] STAMP variable is not defined in t-avr

2012-11-17 Thread rolf.ebert.gcc at gmx dot de


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55243



--- Comment #5 from Rolf Ebert  2012-11-17 
10:02:49 UTC ---

STAMP isn't set by configure. It is rather hardcoded in gcc/Makefile.in



Correspondignly it has to be set in gnattools/Makefile.in, too:



--- gnattools/Makefile.in~2011-10-13 00:41:57 +0200

+++ gnattools/Makefile.in2012-11-16 20:50:48 +0100

@@ -111,6 +111,7 @@

 "GNATMAKE=gnatmake" \

 "GNATLINK=gnatlink" \

 "GNATBIND=gnatbind" \

+"STAMP=echo timestamp >" \

 "TOOLSCASE=cross" \

 "LIBGNAT="


[Bug bootstrap/54283] [4.8 regression] build tools don't run after cxx-conversion merge

2012-11-17 Thread ebotcazou at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54283



Eric Botcazou  changed:



   What|Removed |Added



 Status|UNCONFIRMED |NEW

   Last reconfirmed||2012-11-17

 CC||ebotcazou at gcc dot

   ||gnu.org

 Ever Confirmed|0   |1



--- Comment #5 from Eric Botcazou  2012-11-17 
10:20:30 UTC ---

Does it happen with a recent bootstrap compiler, i.e. for which

-static-libstdc++ is implemented, if you don't set --with-host-libstdcxx?  I

think it's 4.6 and above for Solaris.



Note that --with-boot-ldflags should be superfluous since -static-libstdc++'

-static-libgcc are automatically passed during stage 2 & 3.


[Bug rtl-optimization/55315] comparing address to constant is folded in cse

2012-11-17 Thread vries at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55315



--- Comment #1 from vries at gcc dot gnu.org 2012-11-17 10:32:43 UTC ---

Submitted patch: http://gcc.gnu.org/ml/gcc-patches/2012-11/msg01438.html


[Bug fortran/55362] New: [4.6/4.7/4.8 Regression] ICE with size() on character pointer

2012-11-17 Thread dominiq at lps dot ens.fr


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55362



 Bug #: 55362

   Summary: [4.6/4.7/4.8 Regression] ICE with size() on character

pointer

Classification: Unclassified

   Product: gcc

   Version: 4.8.0

Status: UNCONFIRMED

  Severity: normal

  Priority: P3

 Component: fortran

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: domi...@lps.ens.fr





>From http://gcc.gnu.org/ml/fortran/2012-11/msg00034.html

the following test



program ice_test

  implicit none

  write(*,*) 'message: ', size(Error_Msg),Error_Msg()

contains

  function Error_Msg() result(ErrorMsg)

character, dimension(:), pointer :: ErrorMsg

character, dimension(1), target :: str = '!'

ErrorMsg => str

  end function Error_Msg

end program ice_test



gives an ICE when compiled with 4.6.3, 4.7.2



error_msg.f90:3:0: internal compiler error: in gfc_conv_intrinsic_size, at

fortran/trans-intrinsic.c:4427 (4.6) or 5059 (4.7)



and trunk (r193382)



error_msg.f90:3:0: internal compiler error: in gfc_conv_expr_descriptor, at

fortran/trans-array.c:6417

   write(*,*) 'message: ', size(Error_Msg),Error_Msg()



while 4.5.3 gives an error



error_msg.f90:3.31:



  write(*,*) 'message: ', size(Error_Msg),Error_Msg()

   1

Error: Internal procedure 'error_msg' is not allowed as an actual argument at

(1)



In all cases the ICE occurs in gfc_conv_intrinsic_size (4.6/4.7) or

gfc_conv_expr_descriptor (4.8) at



  gcc_assert (ss != gfc_ss_terminator);



Revision 163532 (2010-08-24) gives the error; revision 163841 (2010-09-03)

gives the ICE (a lot of changes in this range: f2008 intrinsics and float_128).



The backtrace for 4.6 revision 182981 is



#1  0x0001000e62f6 in gfc_conv_intrinsic_function (se=0x7fff5fbfd2a0,

expr=0x141d0d870) at ../../p6_work/gcc/fortran/trans-intrinsic.c:4427

#2  0x0001000d7043 in gfc_conv_function_expr (se=0x7fff5fbfd2a0,

expr=) at ../../p6_work/gcc/fortran/trans-expr.c:4064

#3  0x0001000d1b33 in gfc_conv_expr_reference (se=0x7fff5fbfd2a0,

expr=) at ../../p6_work/gcc/fortran/trans-expr.c:4889

#4  0x0001000eabcf in gfc_trans_transfer (code=0x141d0dba0) at

../../p6_work/gcc/fortran/trans-io.c:2314

#5  0x0001000b01e8 in trans_code (code=0x141d0dba0, cond=0x141c61498) at

../../p6_work/gcc/fortran/trans.c:1382

#6  0x0001000e8896 in build_dt (function=0x141ef8800, code=0x141d0df60) at

../../p6_work/gcc/fortran/trans-io.c:1838

#7  0x0001000b0228 in trans_code (code=0x141d0df60, cond=0x0) at

../../p6_work/gcc/fortran/trans.c:1354

#8  0x0001000caa81 in gfc_generate_function_code (ns=)

at ../../p6_work/gcc/fortran/trans-decl.c:4827

#9  0x00010006ff1c in gfc_parse_file () at

../../p6_work/gcc/fortran/parse.c:4265

#10 0x0001000aba36 in gfc_be_parse_file () at

../../p6_work/gcc/fortran/f95-lang.c:250

#11 0x000100626b3e in toplev_main (argc=2, argv=0x7fff5fbfd7a8) at

../../p6_work/gcc/toplev.c:579



and for trunk revision 193329



#12 0x0001000d9162 in gfc_conv_expr_descriptor (se=,

expr=)

at ../../p_work/gcc/fortran/trans-array.c:6417

#13 0x0001000f827d in gfc_conv_intrinsic_size (se=,

expr=)

at ../../p_work/gcc/fortran/trans-intrinsic.c:5052

#14 0x000100104ee6 in gfc_conv_intrinsic_function (se=, expr=)

at ../../p_work/gcc/fortran/trans-intrinsic.c:6763

#15 0x0001000eff59 in gfc_conv_expr (se=, expr=) at ../../p_work/gcc/fortran/trans-expr.c:5408

#16 0x0001000f4226 in gfc_conv_expr_reference (se=,

expr=)

at ../../p_work/gcc/fortran/trans-expr.c:6244

#17 0x00010010b890 in gfc_trans_transfer (code=0x141514b00) at

../../p_work/gcc/fortran/trans-io.c:2307

#18 0x0001000c7d88 in trans_code (code=0x141514b00, cond=0x141b0ee88) at

../../p_work/gcc/fortran/trans.c:1510

#19 0x000100109666 in build_dt (function=0x141b09e00, code=0x141514ec0) at

../../p_work/gcc/fortran/trans-io.c:1831

#20 0x0001000c7da8 in trans_code (code=0x141514ec0, cond=0x0) at

../../p_work/gcc/fortran/trans.c:1482

#21 0x0001000e6b14 in gfc_generate_function_code (ns=)

at ../../p_work/gcc/fortran/trans-decl.c:5349

#22 0x00010008435c in gfc_parse_file () at

../../p_work/gcc/fortran/parse.c:4467

#23 0x0001000c3e86 in gfc_be_parse_file () at

../../p_work/gcc/fortran/f95-lang.c:191

#24 0x000100669989 in compile_file () at ../../p_work/gcc/toplev.c:544

#25 0x00010066b7e9 in toplev_main(int, char**) (argc=2,

argv=0x7fff5fbfd780) at ../../p_work/gcc/toplev.c:1797

#26 0x0001a7c4 in start (pc=, bases=0x0) at

../../../p_work/libgcc/config/unwind-dw2-fde-darwin.c:271


[Bug fortran/55362] [4.6/4.7/4.8 Regression] ICE with size() on character pointer

2012-11-17 Thread dominiq at lps dot ens.fr


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55362



Dominique d'Humieres  changed:



   What|Removed |Added



   Priority|P3  |P4

 Status|UNCONFIRMED |NEW

   Last reconfirmed||2012-11-17

  Known to work||4.5.3

 Ever Confirmed|0   |1

  Known to fail||4.6.3, 4.7.2, 4.8.0



--- Comment #1 from Dominique d'Humieres  2012-11-17 
10:39:09 UTC ---

Marked as NEW.


[Bug libstdc++/55363] New: tuple_size is not a class template

2012-11-17 Thread pluto at agmk dot net


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55363



 Bug #: 55363

   Summary: tuple_size is not a class template

Classification: Unclassified

   Product: gcc

   Version: 4.8.0

Status: UNCONFIRMED

  Severity: normal

  Priority: P3

 Component: libstdc++

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: pl...@agmk.net





gcc configured with --enable-symvers=gnu-versioned-namespace doesn't build.





tested on git revision a4c4abc (svn trunk 193583).



(...)

libtool: compile:  /home/users/pluto/src/gcc.builddir/./gcc/xgcc -shared-libgcc

-B/home/users/pluto/src/gcc.builddir/./gcc -nostdinc++

-L/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/src

-L/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs

-B/opt/gcc48/x86_64-unknown-linux-gnu/bin/

-B/opt/gcc48/x86_64-unknown-linux-gnu/lib/ -isystem

/opt/gcc48/x86_64-unknown-linux-gnu/include -isystem

/opt/gcc48/x86_64-unknown-linux-gnu/sys-include

-I/home/users/pluto/src/gcc.git/libstdc++-v3/../libgcc

-I/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/x86_64-unknown-linux-gnu

-I/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include

-I/home/users/pluto/src/gcc.git/libstdc++-v3/libsupc++ -std=gnu++11

-D_GLIBCXX_SHARED -fno-implicit-templates -Wall -Wextra -Wwrite-strings

-Wcast-qual -Wabi -fdiagnostics-show-location=once -ffunction-sections

-fdata-sections -frandom-seed=condition_variable.lo -O1 -gdwarf-4 -g1

-fno-debug-types-section -pipe -O1 -gdwarf-4 -g1 -fno-debug-types-section -pipe

-c /home/users/pluto/src/gcc.git/libstdc++-v3/src/c++11/condition_variable.cc 

-fPIC -DPIC -D_GLIBCXX_SHARED -o condition_variable.o

In file included from

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/tuple:39:0,

 from

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/mutex:38,

 from

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/condition_variable:39,

 from

/home/users/pluto/src/gcc.git/libstdc++-v3/src/c++11/condition_variable.cc:25:

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/array:273:12:

error: 'tuple_size' is not a class template

 struct tuple_size>

^

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/array:273:37:

error: redeclared with 2 template parameters

 struct tuple_size>

 ^

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/array:270:11:

note: previous declaration 'template class std::tuple_size' used 1

template parameter

 class tuple_size;

   ^

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/array:281:12:

error: 'tuple_element' is not a class template

 struct tuple_element<_Int, array<_Tp, _Nm>>

^

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/array:281:46:

error: redeclared with 3 template parameters

 struct tuple_element<_Int, array<_Tp, _Nm>>

  ^

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/array:278:11:

note: previous declaration 'template class

std::tuple_element' used 2 template parameters

 class tuple_element;

   ^

In file included from

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/mutex:38:0,

 from

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/condition_variable:39,

 from

/home/users/pluto/src/gcc.git/libstdc++-v3/src/c++11/condition_variable.cc:25:

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/tuple:917:49:

error: template argument 2 is invalid

  typename std::tuple_element<_Idx, _Tuple>::type>, _Tuple, _Nm>::__type

 ^

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/tuple:917:63:

error: template argument 2 is invalid

  typename std::tuple_element<_Idx, _Tuple>::type>, _Tuple, _Nm>::__type

   ^

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/tuple:930:62:

error: template argument 4 is invalid

std::tuple_size<_Tuple>::value>

  ^

/home/users/pluto/src/gcc.builddir/x86_64-unknown-linux-gnu/libstdc++-v3/include/tuple:986:51:

error: template argument 1 is invalid

  typename std::remove_reference<_Tp>::type>::value>::__type __type;

   ^

/home/users/pluto/sr

[Bug fortran/55352] Erroneous gfortran warning of unused module variable when variable is only used in namelist

2012-11-17 Thread janus at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55352



janus at gcc dot gnu.org changed:



   What|Removed |Added



 Status|NEW |ASSIGNED

 AssignedTo|unassigned at gcc dot   |janus at gcc dot gnu.org

   |gnu.org |



--- Comment #4 from janus at gcc dot gnu.org 2012-11-17 10:55:13 UTC ---

(In reply to comment #3)

> Proposed patch:



... regtests cleanly.


[Bug debug/55364] New: ICE: in remove_addr_table_entry, at dwarf2out.c:4201 with -O -gsplit-dwarf

2012-11-17 Thread zsojka at seznam dot cz


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55364



 Bug #: 55364

   Summary: ICE: in remove_addr_table_entry, at dwarf2out.c:4201

with -O -gsplit-dwarf

Classification: Unclassified

   Product: gcc

   Version: 4.8.0

Status: UNCONFIRMED

  Severity: normal

  Priority: P3

 Component: debug

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: zso...@seznam.cz





Created attachment 28714

  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28714

reduced testcase



Compiler output:

$ gcc -O -gsplit-dwarf testcase.c 

testcase.c:13:1: internal compiler error: in remove_addr_table_entry, at

dwarf2out.c:4201

 }

 ^

0x70f423 remove_addr_table_entry

/mnt/svn/gcc-trunk/gcc/dwarf2out.c:4201

0x70f453 remove_loc_list_addr_table_entries

/mnt/svn/gcc-trunk/gcc/dwarf2out.c:4215

0x730930 resolve_addr

/mnt/svn/gcc-trunk/gcc/dwarf2out.c:22639

0x730960 resolve_addr

/mnt/svn/gcc-trunk/gcc/dwarf2out.c:22687

0x7458aa dwarf2out_finish

/mnt/svn/gcc-trunk/gcc/dwarf2out.c:23309

Please submit a full bug report,

with preprocessed source if appropriate.

Please include the complete backtrace with any bug report.

See  for instructions.



Tested revisions:

r193581 - crash


[Bug libstdc++/55363] tuple_size is not a class template

2012-11-17 Thread paolo.carlini at oracle dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55363



Paolo Carlini  changed:



   What|Removed |Added



 Status|UNCONFIRMED |ASSIGNED

   Last reconfirmed||2012-11-17

 AssignedTo|unassigned at gcc dot   |paolo.carlini at oracle dot

   |gnu.org |com

 Ever Confirmed|0   |1



--- Comment #1 from Paolo Carlini  2012-11-17 
11:18:01 UTC ---

My fault, will fix momentarily.


[Bug libstdc++/55363] tuple_size is not a class template

2012-11-17 Thread paolo at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55363



--- Comment #2 from paolo at gcc dot gnu.org  
2012-11-17 12:10:08 UTC ---

Author: paolo

Date: Sat Nov 17 12:09:58 2012

New Revision: 193584



URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=193584

Log:

2012-11-17  Paolo Carlini  



PR libstdc++/55363

* include/std/array (tuple_size, tuple_element): Move out

NAMESPACE_CONTAINER.

* testsuite/23_containers/array/tuple_interface/get_neg.cc: Adjust

dg-error line numbers.

* testsuite/23_containers/array/tuple_interface/tuple_element_neg.cc:

Likewise.



Modified:

trunk/libstdc++-v3/ChangeLog

trunk/libstdc++-v3/include/std/array

trunk/libstdc++-v3/testsuite/23_containers/array/tuple_interface/get_neg.cc

   

trunk/libstdc++-v3/testsuite/23_containers/array/tuple_interface/tuple_element_neg.cc


[Bug libstdc++/55363] tuple_size is not a class template

2012-11-17 Thread paolo.carlini at oracle dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55363



Paolo Carlini  changed:



   What|Removed |Added



 Status|ASSIGNED|RESOLVED

 Resolution||FIXED

 AssignedTo|paolo.carlini at oracle dot |unassigned at gcc dot

   |com |gnu.org

   Target Milestone|--- |4.8.0



--- Comment #3 from Paolo Carlini  2012-11-17 
12:11:08 UTC ---

Done.


[Bug fortran/55341] address-sanitizer and Fortran

2012-11-17 Thread janus at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55341



--- Comment #5 from janus at gcc dot gnu.org 2012-11-17 12:15:45 UTC ---

(In reply to comment #4)

> Untested fix.  memcpy's last argument is size_type_node, i.e. unsigned C

> size_t, while in several places the FE was calling memcpy with a signed type 
> of

> the argument instead.



This fixes the ICE and regtests cleanly on x86_64-unknown-linux-gnu. Looks good

to me!


[Bug debug/54693] VTA guality issues with loops

2012-11-17 Thread andreast at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54693



--- Comment #20 from Andreas Tobler  2012-11-17 
12:36:16 UTC ---

Just for clarification, the following commits (after #14) in this PR did not

resolve the bootstrap issue. I was on r193501 when I first encountered the

comparison failure and then I went back until the comparison failure went away.


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2012-11-17 Thread jamborm at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55260



--- Comment #4 from Martin Jambor  2012-11-17 
12:45:05 UTC ---

Even though they both lead to the same ICE, the testcase in the

summary and the one from comment #2 are actually caused by different

bugs in ipa-cp.c.



I have just submitted the summary testcase fix to the mailing list:

http://gcc.gnu.org/ml/gcc-patches/2012-11/msg01443.html



I'll deal with the other issue next week.


[Bug fortran/55341] address-sanitizer and Fortran

2012-11-17 Thread jakub at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55341



--- Comment #6 from Jakub Jelinek  2012-11-17 
13:03:01 UTC ---

Author: jakub

Date: Sat Nov 17 13:02:56 2012

New Revision: 193585



URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=193585

Log:

PR fortran/55341

* trans-intrinsic.c (gfc_conv_intrinsic_transfer): Convert last

argument to memcpy to size_type_node type.

* trans-stmt.c (gfc_conv_elemental_dependencies): Likewise.

* trasn-array.c (duplicate_allocatable): Likewise.



Modified:

trunk/gcc/fortran/ChangeLog

trunk/gcc/fortran/trans-array.c

trunk/gcc/fortran/trans-intrinsic.c

trunk/gcc/fortran/trans-stmt.c


[Bug libstdc++/55041] prettyprinting/shared_ptr & cxx11 fails on some platforms

2012-11-17 Thread mark at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55041



--- Comment #14 from Mark Wielaard  2012-11-17 
13:27:03 UTC ---

>> dwarf2out.c: For DWARF 4+, output DW_AT_high_pc as constant offset.

>> 

>> 

>> This required a gdb change.

>

> Ah, that should be in http://gcc.gnu.org/gcc-4.8/changes.html then. Mark?



How about something like:



diff -u -r1.57 changes.html

--- htdocs/gcc-4.8/changes.html14 Nov 2012 04:45:41 -1.57

+++ htdocs/gcc-4.8/changes.html17 Nov 2012 13:24:24 -

@@ -53,6 +53,14 @@

 General Optimizer Improvements (and Changes)



   

+DWARF4 is now the default when generating DWARF debug information.

+  When -g is used on a platform that uses DWARF debugging information,

+  GCC will now default to -gdwarf-4 -fno-debug-types-section.

+  GDB 7.5, Valgrind 3.8.0 and elfutils 0.154 debug information consumers

+  support DWARF4 by default. Before GCC 4.8 the default version used

+  was DWARF2. To make gcc 4.8 generate an older DWARF version use -g

+  together with -gdwarf-2 or -gdwarf-3.

+

 A new general optimization level, -Og, has been

   introduced.  It addresses the need for fast compilation and a

   superior debugging experience while providing a reasonable level



On which list should website changes be proposed?


[Bug tree-optimization/55286] [4.7/4.8 Regression] Bytemark ASSIGNMENT 4% - 10% slower

2012-11-17 Thread wbrana at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55286



--- Comment #6 from wbrana  2012-11-17 14:24:44 UTC ---

Created attachment 28715

  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28715

Gentoo patches 1


[Bug tree-optimization/55286] [4.7/4.8 Regression] Bytemark ASSIGNMENT 4% - 10% slower

2012-11-17 Thread wbrana at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55286



--- Comment #7 from wbrana  2012-11-17 14:25:23 UTC ---

Created attachment 28716

  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28716

Gentoo patches 2


[Bug tree-optimization/55286] [4.7/4.8 Regression] Bytemark ASSIGNMENT 4% - 10% slower

2012-11-17 Thread wbrana at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55286



--- Comment #8 from wbrana  2012-11-17 14:26:18 UTC ---

Created attachment 28717

  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28717

Gentoo patches 3


[Bug tree-optimization/55286] [4.7/4.8 Regression] Bytemark ASSIGNMENT 4% - 10% slower

2012-11-17 Thread wbrana at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55286



--- Comment #9 from wbrana  2012-11-17 14:29:20 UTC ---

Created attachment 28718

  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28718

build log from non-broken gcc


[Bug tree-optimization/55286] [4.7/4.8 Regression] Bytemark ASSIGNMENT 4% - 10% slower

2012-11-17 Thread wbrana at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55286



--- Comment #10 from wbrana  2012-11-17 14:30:22 UTC 
---

Created attachment 28719

  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28719

build log from broken gcc


[Bug tree-optimization/55286] [4.7/4.8 Regression] Bytemark ASSIGNMENT 4% - 10% slower

2012-11-17 Thread wbrana at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55286



--- Comment #11 from wbrana  2012-11-17 14:52:44 UTC 
---

It seems I was wrong. Reverting 175752 doesn't fix performance.

I used also Gentoo patches with patch which reverts 175752. 

I thought that it isn't possible, but it seems some of Gentoo patches fixes

performance. Any idea which?



CPU Sandy Bridge

CFLAGS = -fomit-frame-pointer -Wall -O3 -funroll-loops -g0  -march=native

-ffast-math -fno-PIE -fno-exceptions -fno-stack-protector -static



There is almost no difference in run time between Gentoo patched and vanilla

gcc with self-contained testcase.


[Bug tree-optimization/55286] [4.7/4.8 Regression] Bytemark ASSIGNMENT 4% - 10% slower

2012-11-17 Thread wbrana at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55286



--- Comment #12 from wbrana  2012-11-17 15:01:34 UTC 
---

more exact CFLAGS

-fomit-frame-pointer -Wall -O3 -funroll-loops -g0  -march=corei7

-ffast-math -fno-PIE -fno-exceptions -fno-stack-protector -static


[Bug c++/55365] New: internal compiler error: in process_init_constructor_union, at cp/typeck2.c:1335; internal compiler error: in lookup_field_1, at cp/search.c:387; internal compiler error: in proce

2012-11-17 Thread jasongross9+bugzilla at gmail dot com

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55365

 Bug #: 55365
   Summary: internal compiler error: in
process_init_constructor_union, at cp/typeck2.c:1335;
internal compiler error: in lookup_field_1, at
cp/search.c:387; internal compiler error: in
process_init_constructor_record, at cp/typeck2.c:1189
Classification: Unclassified
   Product: gcc
   Version: 4.8.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: jasongross9+bugzi...@gmail.com


$ /afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/g++ -std=c++11 -c
free_list.cpp  -v -save-temps
Using built-in specs.
COLLECT_GCC=/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/g++
Target: x86_64-unknown-linux-gnu
Configured with: ./configure
--prefix=/afs/csail/proj/courses/6.172/gcc-cilkplus --enable-languages=c,c++
Thread model: posix
gcc version 4.8.0 20120618 (experimental) (GCC)
COLLECT_GCC_OPTIONS='-std=c++11' '-c' '-v' '-save-temps' '-shared-libgcc'
'-mtune=generic' '-march=x86-64'

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.8.0/cc1plus
-E -quiet -v -iprefix
/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/
-D_GNU_SOURCE free_list.cpp -mtune=generic -march=x86-64 -std=c++11
-fpch-preprocess -o free_list.ii
ignoring nonexistent directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../x86_64-unknown-linux-gnu/include"
ignoring duplicate directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0"
ignoring duplicate directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0/x86_64-unknown-linux-gnu"
ignoring duplicate directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0/backward"
ignoring duplicate directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/include"
ignoring duplicate directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/include-fixed"
ignoring nonexistent directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../x86_64-unknown-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
 /opt/intel/composer_xe_2013.0.079/mkl/include
 /opt/intel/composer_xe_2013.0.079/tbb/include

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0/x86_64-unknown-linux-gnu

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0/backward

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/include

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/include-fixed
 /usr/local/include

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../include
 /usr/include
End of search list.
COLLECT_GCC_OPTIONS='-std=c++11' '-c' '-v' '-save-temps' '-shared-libgcc'
'-mtune=generic' '-march=x86-64'

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.8.0/cc1plus
-fpreprocessed free_list.ii -quiet -dumpbase free_list.cpp -mtune=generic
-march=x86-64 -auxbase free_list -std=c++11 -version -o free_list.s
GNU C++ (GCC) version 4.8.0 20120618 (experimental) (x86_64-unknown-linux-gnu)
compiled by GNU C version 4.8.0 20120618 (experimental), GMP version
5.0.2, MPFR version 3.1.0, MPC version 0.9
warning: GMP header version 5.0.2 differs from library version 4.3.2.
warning: MPFR header version 3.1.0 differs from library version 3.0.0-p3.
warning: MPC header version 0.9 differs from library version 0.8.2.
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
GNU C++ (GCC) version 4.8.0 20120618 (experimental) (x86_64-unknown-linux-gnu)
compiled by GNU C version 4.8.0 20120618 (experimental), GMP version
5.0.2, MPFR version 3.1.0, MPC version 0.9
warning: GMP header version 5.0.2 differs from library version 4.3.2.
warning: MPFR header version 3.1.0 differs from library version 3.0.0-p3.
warning: MPC header version 0.9 differs from library version 0.8.2.
GGC heuristics: --param ggc-min-expand=30 --param ggc-min

[Bug c++/55366] New: g++ segfault; see also Bug 55365

2012-11-17 Thread jasongross9+bugzilla at gmail dot com

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55366

 Bug #: 55366
   Summary: g++ segfault; see also Bug 55365
Classification: Unclassified
   Product: gcc
   Version: 4.8.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: jasongross9+bugzi...@gmail.com


A slight modification of the code of Bug 55365 causes g++ to segfault:

$ /afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/g++ -std=c++11 -c
free_list.cpp  -v -save-temps
Using built-in specs.
COLLECT_GCC=/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/g++
Target: x86_64-unknown-linux-gnu
Configured with: ./configure
--prefix=/afs/csail/proj/courses/6.172/gcc-cilkplus --enable-languages=c,c++
Thread model: posix
gcc version 4.8.0 20120618 (experimental) (GCC)
COLLECT_GCC_OPTIONS='-std=c++11' '-c' '-v' '-save-temps' '-shared-libgcc'
'-mtune=generic' '-march=x86-64'

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.8.0/cc1plus
-E -quiet -v -iprefix
/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/
-D_GNU_SOURCE free_list.cpp -mtune=generic -march=x86-64 -std=c++11
-fpch-preprocess -o free_list.ii
ignoring nonexistent directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../x86_64-unknown-linux-gnu/include"
ignoring duplicate directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0"
ignoring duplicate directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0/x86_64-unknown-linux-gnu"
ignoring duplicate directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0/backward"
ignoring duplicate directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/include"
ignoring duplicate directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/include-fixed"
ignoring nonexistent directory
"/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../x86_64-unknown-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
 /opt/intel/composer_xe_2013.0.079/mkl/include
 /opt/intel/composer_xe_2013.0.079/tbb/include

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0/x86_64-unknown-linux-gnu

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/../../../../include/c++/4.8.0/backward

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/include

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.0/include-fixed
 /usr/local/include

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../lib/gcc/../../include
 /usr/include
End of search list.
COLLECT_GCC_OPTIONS='-std=c++11' '-c' '-v' '-save-temps' '-shared-libgcc'
'-mtune=generic' '-march=x86-64'

/afs/csail.mit.edu/proj/courses/6.172/gcc-cilkplus/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.8.0/cc1plus
-fpreprocessed free_list.ii -quiet -dumpbase free_list.cpp -mtune=generic
-march=x86-64 -auxbase free_list -std=c++11 -version -o free_list.s
GNU C++ (GCC) version 4.8.0 20120618 (experimental) (x86_64-unknown-linux-gnu)
compiled by GNU C version 4.8.0 20120618 (experimental), GMP version
5.0.2, MPFR version 3.1.0, MPC version 0.9
warning: GMP header version 5.0.2 differs from library version 4.3.2.
warning: MPFR header version 3.1.0 differs from library version 3.0.0-p3.
warning: MPC header version 0.9 differs from library version 0.8.2.
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
GNU C++ (GCC) version 4.8.0 20120618 (experimental) (x86_64-unknown-linux-gnu)
compiled by GNU C version 4.8.0 20120618 (experimental), GMP version
5.0.2, MPFR version 3.1.0, MPC version 0.9
warning: GMP header version 5.0.2 differs from library version 4.3.2.
warning: MPFR header version 3.1.0 differs from library version 3.0.0-p3.
warning: MPC header version 0.9 differs from library version 0.8.2.
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
Compiler executable checksum: 9140df29c77763bd28b47359117a6952
free_list.cpp:6:9: error: field ‘b’ has incomplete type
 Bar b;
 ^
‘
In constructor ‘Foo::Foo(Bar&&)’:
Segmentati

[Bug bootstrap/54795] [4.8 Regression] Random profiledbootstrap failure with LTO

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54795



--- Comment #6 from H.J. Lu  2012-11-17 15:47:56 
UTC ---

[hjl@gnu-mic-2 gcc]$ cat /tmp/x.c

int

main ()

{

}

[hjl@gnu-mic-2 gcc]$ ./xgcc -B./ -c -flto /tmp/x.c

==17373== Invalid read of size 8

==17373==at 0x8E3FE6: streamer_pack_tree_bitfields(output_block*,

bitpack_d*, tree_node*) (tree-streamer-out.c:263)

==17373==by 0x71FA5F: lto_output_tree(output_block*, tree_node*, bool,

bool) (lto-streamer-out.c:316)

==17373==by 0x71F06B: write_global_stream(output_block*,

lto_tree_ref_encoder*) (lto-streamer-out.c:1057)

==17373==by 0x721798: produce_asm_for_decls() (lto-streamer-out.c:1101)

==17373==by 0x74A477: ipa_write_summaries_2(opt_pass*, lto_out_decl_state*)

(passes.c:2430)

==17373==by 0x74B34D: ipa_write_summaries() (passes.c:2460)

==17373==by 0x5ACA9B: compile() (cgraphunit.c:1908)

==17373==by 0x5ACBA9: finalize_compilation_unit() (cgraphunit.c:2122)

==17373==by 0x4E47DF: c_write_global_declarations() (c-decl.c:10128)

==17373==by 0x7D7F4C: compile_file() (toplev.c:559)

==17373==by 0x7D9AA7: toplev_main(int, char**) (toplev.c:1881)

==17373==by 0x38F3A21674: (below main) (in /usr/lib64/libc-2.15.so)

==17373==  Address 0xb57c9da is not stack'd, malloc'd or (recently) free'd

==17373== 

==17373== Invalid read of size 8

==17373==at 0x8E4103: streamer_pack_tree_bitfields(output_block*,

bitpack_d*, tree_node*) (tree-streamer-out.c:271)

==17373==by 0x71FA5F: lto_output_tree(output_block*, tree_node*, bool,

bool) (lto-streamer-out.c:316)

==17373==by 0x71F06B: write_global_stream(output_block*,

lto_tree_ref_encoder*) (lto-streamer-out.c:1057)

==17373==by 0x721798: produce_asm_for_decls() (lto-streamer-out.c:1101)

==17373==by 0x74A477: ipa_write_summaries_2(opt_pass*, lto_out_decl_state*)

(passes.c:2430)

==17373==by 0x74B34D: ipa_write_summaries() (passes.c:2460)

==17373==by 0x5ACA9B: compile() (cgraphunit.c:1908)

==17373==by 0x5ACBA9: finalize_compilation_unit() (cgraphunit.c:2122)

==17373==by 0x4E47DF: c_write_global_declarations() (c-decl.c:10128)

==17373==by 0x7D7F4C: compile_file() (toplev.c:559)

==17373==by 0x7D9AA7: toplev_main(int, char**) (toplev.c:1881)

==17373==by 0x38F3A21674: (below main) (in /usr/lib64/libc-2.15.so)

==17373==  Address 0xb57c9db is not stack'd, malloc'd or (recently) free'd

==17373== 

[hjl@gnu-mic-2 gcc]$


[Bug c++/55365] internal compiler error: in process_init_constructor_union, at cp/typeck2.c:1335; internal compiler error: in lookup_field_1, at cp/search.c:387; internal compiler error: in process_in

2012-11-17 Thread jasongross9+bugzilla at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55365



--- Comment #1 from Jason  2012-11-17 
16:04:49 UTC ---

Note that icpc gives me the error message "error: a designator into a

template-dependent type is not allowed" on code similar to this, which seems

like it might be related.



The code snipped (inside the Foo class) that icpc gives me this error message

on is

 static constexpr arr_or_b make_init_data(T &&c) {

return { .b = c };

  }


[Bug c++/55365] internal compiler error: in process_init_constructor_union, at cp/typeck2.c:1335; internal compiler error: in lookup_field_1, at cp/search.c:387; internal compiler error: in process_in

2012-11-17 Thread jasongross9+bugzilla at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55365



--- Comment #2 from Jason  2012-11-17 
16:10:21 UTC ---

And, indeed, here's a somewhat smaller working example, which g++ says

"internal compiler error: in lookup_field_1, at cp/search.c:387", and icpc says

"error: a designator into a template-dependent type is not allowed"





template

union u {

  T a;

  char b;

};



template

u make_u(T t) {

  return { .a = t };

}



int main() {

  return make_u(1).a;

}


[Bug bootstrap/54795] [4.8 Regression] Random profiledbootstrap failure with LTO

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54795



--- Comment #7 from H.J. Lu  2012-11-17 16:15:50 
UTC ---

When I add --db-attach=yes, valgrind doesn't report any

error.


[Bug c++/55367] New: Probably problem with c++ vptr under templates and multiple ihenritance

2012-11-17 Thread wriabi at email dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55367



 Bug #: 55367

   Summary: Probably problem with c++ vptr under templates and

multiple ihenritance

Classification: Unclassified

   Product: gcc

   Version: 4.7.2

Status: UNCONFIRMED

  Severity: critical

  Priority: P3

 Component: c++

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: wri...@email.com





Created attachment 28720

  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28720

code snippet



Hello,

I have some code that compile and work fine in gcc 4.6.2 (without tne new

keyword "override" ) but in version 4.7.2 it complie generate access violation

runtime. under windows platform.



So, i need some help, thank you very much:



#include 

using namespace std;



struct Entity {

//~Entity() = default; //work fine

~Entity() {} //when i specified my destructor this compile but generate

runtime access viloation

};



template

struct IRepository { virtual T g() = 0; };



struct OtherInterface{ virtual void y() = 0; };



struct IEntityRepository : public virtual IRepository{ };



template

struct RepositoryBase : public virtual IRepository, public OtherInterface{

virtual void y()  override { cout << "y() override called" << endl; }

};



template

struct DataRepository : public RepositoryBase{

virtual T f() { cout << "f() called" << endl; this->y(); T t; return t; }

T g() override {

cout << "g() override called" << endl;

when i specified my destructor for class Entity this compile but

generate runtime access viloation here : on this: probably problem with vptr

return this->f(); }

};



struct EffectiveEntityRepository : public DataRepository, public

IEntityRepository{

};



int main() {

IEntityRepository* var = new EffectiveEntityRepository();

var->g();

return 1;

}


[Bug bootstrap/54795] [4.8 Regression] Random profiledbootstrap failure with LTO

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54795



--- Comment #8 from H.J. Lu  2012-11-17 16:30:20 
UTC ---

==17631== Invalid read of size 8

==17631==at 0x6B2522: output_symtab() (lto-cgraph.c:589)

==17631==by 0x6B87B5: lto_output() (lto-streamer-out.c:1000)

==17631==by 0x6E2307: ipa_write_optimization_summaries_1(opt_pass*,

lto_out_decl_state*) (passes.c:2542)

==17631==by 0x6E3257:

ipa_write_optimization_summaries(lto_symtab_encoder_d*) (passes.c:2589)

==17631==by 0x4EA5AA: lto_main() (lto.c:2693)

==17631==by 0x76FC45: compile_file() (toplev.c:545)

==17631==by 0x7717E7: toplev_main(int, char**) (toplev.c:1881)

==17631==by 0x38F3A21674: (below main) (in /usr/lib64/libc-2.15.so)

==17631==  Address 0xb5caccc is not stack'd, malloc'd or (recently) free'd

==17631== 

==17631== Invalid read of size 8

==17631==at 0x87BDA6: streamer_pack_tree_bitfields(output_block*,

bitpack_d*, tree_node*) (tree-streamer-out.c:263)

==17631==by 0x6B779F: lto_output_tree(output_block*, tree_node*, bool,

bool) (lto-streamer-out.c:316)

==17631==by 0x6B6DAB: write_global_stream(output_block*,

lto_tree_ref_encoder*) (lto-streamer-out.c:1057)

==17631==by 0x6B94D8: produce_asm_for_decls() (lto-streamer-out.c:1101)

==17631==by 0x6E2307: ipa_write_optimization_summaries_1(opt_pass*,

lto_out_decl_state*) (passes.c:2542)

==17631==by 0x6E3257:

ipa_write_optimization_summaries(lto_symtab_encoder_d*) (passes.c:2589)

==17631==by 0x4EA5AA: lto_main() (lto.c:2693)

==17631==by 0x76FC45: compile_file() (toplev.c:545)

==17631==by 0x7717E7: toplev_main(int, char**) (toplev.c:1881)

==17631==by 0x38F3A21674: (below main) (in /usr/lib64/libc-2.15.so)

==17631==  Address 0xb5afeda is not stack'd, malloc'd or (recently) free'd

==17631== 

==17631== Invalid read of size 8

==17631==at 0x87BEC3: streamer_pack_tree_bitfields(output_block*,

bitpack_d*, tree_node*) (tree-streamer-out.c:271)

==17631==by 0x6B779F: lto_output_tree(output_block*, tree_node*, bool,

bool) (lto-streamer-out.c:316)

==17631==by 0x6B6DAB: write_global_stream(output_block*,

lto_tree_ref_encoder*) (lto-streamer-out.c:1057)

==17631==by 0x6B94D8: produce_asm_for_decls() (lto-streamer-out.c:1101)

==17631==by 0x6E2307: ipa_write_optimization_summaries_1(opt_pass*,

lto_out_decl_state*) (passes.c:2542)

==17631==by 0x6E3257:

ipa_write_optimization_summaries(lto_symtab_encoder_d*) (passes.c:2589)

==17631==by 0x4EA5AA: lto_main() (lto.c:2693)

==17631==by 0x76FC45: compile_file() (toplev.c:545)

==17631==by 0x7717E7: toplev_main(int, char**) (toplev.c:1881)

==17631==by 0x38F3A21674: (below main) (in /usr/lib64/libc-2.15.so)

==17631==  Address 0xb5afedb is not stack'd, malloc'd or (recently) free'd

==17631== 

==17631== Invalid read of size 8

==17631==at 0x87BFFE: streamer_pack_tree_bitfields(output_block*,

bitpack_d*, tree_node*) (tree-streamer-out.c:230)

==17631==by 0x6B779F: lto_output_tree(output_block*, tree_node*, bool,

bool) (lto-streamer-out.c:316)

==17631==by 0x6B6DAB: write_global_stream(output_block*,

lto_tree_ref_encoder*) (lto-streamer-out.c:1057)

==17631==by 0x6B94D8: produce_asm_for_decls() (lto-streamer-out.c:1101)

==17631==by 0x6E2307: ipa_write_optimization_summaries_1(opt_pass*,

lto_out_decl_state*) (passes.c:2542)

==17631==by 0x6E3257:

ipa_write_optimization_summaries(lto_symtab_encoder_d*) (passes.c:2589)

==17631==by 0x4EA5AA: lto_main() (lto.c:2693)

==17631==by 0x76FC45: compile_file() (toplev.c:545)

==17631==by 0x7717E7: toplev_main(int, char**) (toplev.c:1881)

==17631==by 0x38F3A21674: (below main) (in /usr/lib64/libc-2.15.so)

==17631==  Address 0xb5c8f69 is not stack'd, malloc'd or (recently) free'd

==17631== 

==17631== Invalid read of size 8

==17631==at 0x87BDA6: streamer_pack_tree_bitfields(output_block*,

bitpack_d*, tree_node*) (tree-streamer-out.c:263)

==17631==by 0x6B779F: lto_output_tree(output_block*, tree_node*, bool,

bool) (lto-streamer-out.c:316)

==17631==by 0x6B6DAB: write_global_stream(output_block*,

lto_tree_ref_encoder*) (lto-streamer-out.c:1057)

==17631==by 0x6B951F: produce_asm_for_decls() (lto-streamer-out.c:1101)

==17631==by 0x6E2307: ipa_write_optimization_summaries_1(opt_pass*,

lto_out_decl_state*) (passes.c:2542)

==17631==by 0x6E3257:

ipa_write_optimization_summaries(lto_symtab_encoder_d*) (passes.c:2589)

==17631==by 0x4EA5AA: lto_main() (lto.c:2693)

==17631==by 0x76FC45: compile_file() (toplev.c:545)

==17631==by 0x7717E7: toplev_main(int, char**) (toplev.c:1881)

==17631==by 0x38F3A21674: (below main) (in /usr/lib64/libc-2.15.so)

==17631==  Address 0xb5c55da is not stack'd, malloc'd or (recently) free'd

==17631== 

==17631== Invalid read of size 8

==17631==at 0x87BEC3: streamer_pack_tree_bitfields(output_block*,

bitpack_d*, tree_node*) (tree-streamer-out.c:271)

==17631==by

[Bug c++/55368] New: Comma before semicolon in struct definition is not rejected

2012-11-17 Thread joerg at netbsd dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55368



 Bug #: 55368

   Summary: Comma before semicolon in struct definition is not

rejected

Classification: Unclassified

   Product: gcc

   Version: 4.7.2

Status: UNCONFIRMED

  Severity: normal

  Priority: P3

 Component: c++

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: jo...@netbsd.org





Test case:



struct A { struct B *C,; };


[Bug bootstrap/54795] [4.8 Regression] Random profiledbootstrap failure with LTO

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54795



H.J. Lu  changed:



   What|Removed |Added



 CC||hubicka at gcc dot gnu.org



--- Comment #9 from H.J. Lu  2012-11-17 16:47:54 
UTC ---

==17715== Invalid read of size 8

==17715==at 0x6B2522: output_symtab() (lto-cgraph.c:589)

==17715==by 0x6B87B5: lto_output() (lto-streamer-out.c:1000)

==17715==by 0x6E2307: ipa_write_optimization_summaries_1(opt_pass*,

lto_out_decl_state*) (passes.c:2542)

==17715==by 0x6E3257:

ipa_write_optimization_summaries(lto_symtab_encoder_d*) (passes.c:2589)

==17715==by 0x4EA5AA: lto_main() (lto.c:2693)

==17715==by 0x76FC45: compile_file() (toplev.c:545)

==17715==by 0x7717E7: toplev_main(int, char**) (toplev.c:1881)

==17715==by 0x38F3A21674: (below main) (in /usr/lib64/libc-2.15.so)

==17715==  Address 0xb5caccc is not stack'd, malloc'd or (recently) free'd



 588   bp = bitpack_create (ob->main_stream);

 589   bp_pack_value (&bp, ref->use, 2);

 590   streamer_write_bitpack (&bp);

 591   nref = lto_symtab_encoder_lookup (encoder, ref->referred);

 592   gcc_assert (nref != LCC_NOT_FOUND);

 593   streamer_write_hwi_stream (ob->main_stream, nref);



(gdb) p ref

$1 = (ipa_ref *) 0xb5cacb0

(gdb) p ref->use

$2 = IPA_REF_LOAD

(gdb) p &ref->use

$3 = (ipa_ref_use *) 0xb5caccc

(gdb)


[Bug bootstrap/54795] [4.8 Regression] Random profiledbootstrap failure with LTO

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54795



--- Comment #10 from H.J. Lu  2012-11-17 17:20:19 
UTC ---

There is a bad memory access in LTO.


[Bug bootstrap/54795] [4.8 Regression] Random profiledbootstrap failure with LTO

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54795



--- Comment #11 from H.J. Lu  2012-11-17 17:30:25 
UTC ---

It can be reproduced with LTO bootstrap on hjl/valgrind branch at



http://gcc.gnu.org/git/?p=gcc.git;a=summary



with --enable-checking=valgrind.


[Bug rtl-optimization/55342] [4.8 Regression] [LRA,x86] Non-optimal code for simple loop with LRA

2012-11-17 Thread vmakarov at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55342



--- Comment #1 from Vladimir Makarov  2012-11-17 
17:59:41 UTC ---

Author: vmakarov

Date: Sat Nov 17 17:59:35 2012

New Revision: 193588



URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=193588

Log:

2012-11-17  Vladimir Makarov  



PR rtl-optimization/55342

* lra-assigns.c (spill_for): Try to allocate other reload pseudos

before and after spilling.





Modified:

trunk/gcc/ChangeLog

trunk/gcc/lra-assigns.c


[Bug middle-end/55369] New: expmed.c is miscompiled in stage1 bootstrap at -O1

2012-11-17 Thread danglin at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55369



 Bug #: 55369

   Summary: expmed.c is miscompiled in stage1 bootstrap at -O1

Classification: Unclassified

   Product: gcc

   Version: 4.7.2

Status: UNCONFIRMED

  Severity: normal

  Priority: P3

 Component: middle-end

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: dang...@gcc.gnu.org

  Host: hppa64-hp-hpux11.11

Target: hppa64-hp-hpux11.11

 Build: hppa64-hp-hpux11.11





Created attachment 28721

  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28721

Preprocessed source



I have seen the following ICE with 4.4.7, 4.6.3 and 4.7.2:



libtool: compile:  /test/gnu/gcc/objdir/./gcc/xgcc -shared-libgcc

-B/test/gnu/gc

c/objdir/./gcc -nostdinc++

-L/test/gnu/gcc/objdir/hppa64-hp-hpux11.11/libstdc++-v3/src

-L/test/gnu/gcc/objdir/hppa64-hp-hpux11.11/libstdc++-v3/src/.libs -B/opt/

gnu64/gcc/gcc-4.8/hppa64-hp-hpux11.11/bin/

-B/opt/gnu64/gcc/gcc-4.8/hppa64-hp-hp

ux11.11/lib/ -isystem /opt/gnu64/gcc/gcc-4.8/hppa64-hp-hpux11.11/include

-isystem /opt/gnu64/gcc/gcc-4.8/hppa64-hp-hpux11.11/sys-include

-I/test/gnu/gcc/gcc/lib

stdc++-v3/../libgcc

-I/test/gnu/gcc/objdir/hppa64-hp-hpux11.11/libstdc++-v3/incl

ude/hppa64-hp-hpux11.11

-I/test/gnu/gcc/objdir/hppa64-hp-hpux11.11/libstdc++-v3/include

-I/test/gnu/gcc/gcc/libstdc++-v3/libsupc++ -D_GLIBCXX_SHARED -Wall -Wext

ra -Wwrite-strings -Wcast-qual -Wabi -fdiagnostics-show-location=once

-ffunction

-sections -fdata-sections -frandom-seed=eh_alloc.lo -g -O2 -c

../../../../gcc/li

bstdc++-v3/libsupc++/eh_alloc.cc  -DPIC -D_GLIBCXX_SHARED -o eh_alloc.o

../../../../gcc/libstdc++-v3/libsupc++/eh_alloc.cc: In function 'void

__cxxabiv1

::__cxa_free_dependent_exception(__cxxabiv1::__cxa_dependent_exception*)':

../../../../gcc/libstdc++-v3/libsupc++/eh_alloc.cc:213:28: internal compiler

err

or: in expand_divmod, at expmed.c:4103

  = (unsigned) (ptr - base) / sizeof (__cxa_dependent_exception);

^



../../../../gcc/libstdc++-v3/libsupc++/eh_alloc.cc:213:28: internal compiler

error: Aborted

xgcc: internal compiler error: Aborted (program cc1plus)

../libtool[11]: 22165 Abort(coredump)

make[5]: *** [eh_alloc.lo] Error 1



This is with the following make command:

make STAGE1_CFLAGS="-g -O1" -j2 bootstrap



The ICE appears to be caused by the bootstrap compiler miscompiling

choose_multiplier.  In particular, this hunk is incorrectly compiled:



  /* Reduce to lowest terms.  */

  for (post_shift = lgup; post_shift > 0; post_shift--)

{

  int shft = HOST_BITS_PER_WIDE_INT - 1;

  unsigned HOST_WIDE_INT ml_lo = (mlow.high << shft) | (mlow.low >> 1);

  unsigned HOST_WIDE_INT mh_lo = (mhigh.high << shft) | (mhigh.low >> 1);

  if (ml_lo >= mh_lo)

break;



  mlow = double_int::from_uhwi (ml_lo);

  mhigh = double_int::from_uhwi (mh_lo);

}



The combine pass drops the or of "(mhigh.high << shft)" into mh_lo.

Strangely, the same doesn't happen for ml_lo.  As a result, ml_lo is

greater than mh_lo and the reduction fails.



L$BB3244:

; ../../gcc/gcc/expmed.c:3349

L$M1779:

ldd -256(%r30),%r31

depd,z %r31,0,1,%r31

ldd -264(%r30),%r28

extrd,u %r28,62,63,%r28

or %r31,%r28,%r31

L$VL1332:

; ../../gcc/gcc/expmed.c:3350

L$M1780:

extrd,u %r6,62,63,%r6

L$VL1333:

; ../../gcc/gcc/expmed.c:3351

L$M1781:

cmpb,*>> %r6,%r31,L$0883

copy %r9,%r28

; basic block 17

; ../../gcc/gcc/expmed.c:3358



Before combine, we have:



(insn 243 242 244 16 (set (reg:DI 182)

(ashift:DI (reg:DI 103 [ mhigh$high ])

(const_int 63 [0x3f]))) ../../gcc/gcc/expmed.c:3350 228

{*pa.md:6415

}

 (nil))



(insn 244 243 245 16 (set (reg:DI 183)

(lshiftrt:DI (reg:DI 155)

(const_int 1 [0x1]))) ../../gcc/gcc/expmed.c:3350 238 {lshrdi3}

 (expr_list:REG_DEAD (reg:DI 155)

(nil)))



(insn 245 244 246 16 (set (reg/v:DI 107 [ mh_lo ])

(ior:DI (reg:DI 182)

(reg:DI 183))) ../../gcc/gcc/expmed.c:3350 182 {*pa.md:5716}

 (expr_list:REG_DEAD (reg:DI 183)

(expr_list:REG_DEAD (reg:DI 182)

(nil

(debug_insn 246 245 22 16 (var_location:DI mh_lo (reg/v:DI 107 [ mh_lo ]))

../..

/gcc/gcc/expmed.c:3350 -1

 (nil))



After combine,



(note 243 242 244 16 NOTE_INSN_DELETED)



(note 244 243 245 16 NOTE_INSN_DELETED)



(insn 245 244 246 16 (set (reg/v:DI 107 [ mh_lo ])

(lshiftrt:DI (reg:DI 155)

(const_int 1 [0x1]))) ../../gcc/gcc/expmed.c:3350 238 {lshrdi3}

 (expr_list:REG_DEAD (reg:DI 155)

(nil)))



(debug_insn 246 245 22 16 (var_location:DI mh_lo (reg/v:DI 107 [ mh_lo ]))

../..

/gcc/gcc/expmed.c:3350 -1

 (nil))



Trying 243 -> 245:

Successfully matched this instruction:

(set

[Bug other/55354] [asan] by default, the asan run-time should be linked statically, not dynamically

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55354



--- Comment #7 from H.J. Lu  2012-11-17 20:35:57 
UTC ---

(In reply to comment #6)

> Answering my own question: we can get static linking with 

>  -Wl,-Bstatic -lasan -Wl,-Bdynamic -ldl -lpthread 

> 



The -static-libasan option was added by



http://gcc.gnu.org/ml/gcc-cvs/2012-11/msg00536.html


[Bug other/55354] [asan] by default, the asan run-time should be linked statically, not dynamically

2012-11-17 Thread markus at trippelsdorf dot de


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55354



Markus Trippelsdorf  changed:



   What|Removed |Added



 CC||markus at trippelsdorf dot

   ||de



--- Comment #8 from Markus Trippelsdorf  
2012-11-17 21:08:21 UTC ---

(In reply to comment #7)

> (In reply to comment #6)

> > Answering my own question: we can get static linking with 

> >  -Wl,-Bstatic -lasan -Wl,-Bdynamic -ldl -lpthread 

> > 

> 

> The -static-libasan option was added by

> 

> http://gcc.gnu.org/ml/gcc-cvs/2012-11/msg00536.html



Can you please add "-ldl -lpthread" to it?

Otherwise the user has to set this by hand:



markus@x4 ~ % g++ -faddress-sanitizer -static-libasan -g test.cpp

/home/markus/gcc/libsanitizer/sanitizer_common/sanitizer_linux.cc:135: error:

undefined reference to 'pthread_getattr_np'

/home/markus/gcc/libsanitizer/sanitizer_common/sanitizer_linux.cc:138: error:

undefined reference to 'pthread_attr_getstack'

/home/markus/gcc/libsanitizer/asan/asan_posix.cc:103: error: undefined

reference to 'pthread_key_create'

/home/markus/gcc/libsanitizer/asan/asan_posix.cc:108: error: undefined

reference to 'pthread_getspecific'

/home/markus/gcc/libsanitizer/asan/asan_posix.cc:113: error: undefined

reference to 'pthread_setspecific'

/home/markus/gcc/libsanitizer/interception/interception_linux.cc:22: error:

undefined reference to 'dlsym'

collect2: error: ld returned 1 exit status


[Bug testsuite/55188] [4.8 regression] FAIL: gcc.dg/pr19105.c scan-tree-dump-times reassoc1 "Optimizing range tests v_[0-9]*.D. -.2, 2. and -.3, 4.[\n\r]* into" 1

2012-11-17 Thread jakub at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55188



--- Comment #3 from Jakub Jelinek  2012-11-17 
21:58:49 UTC ---

Author: jakub

Date: Sat Nov 17 21:58:44 2012

New Revision: 193590



URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=193590

Log:

PR testsuite/55188

* gcc.dg/pr19105.c: Accept also optimizing

-[2, 2] and -[3, 3] and -[4, 4] range tests together.



Modified:

trunk/gcc/testsuite/ChangeLog

trunk/gcc/testsuite/gcc.dg/pr19105.c


[Bug tree-optimization/55236] [4.8 Regression] gcc.c-torture/execute/pr22493-1.c FAILs with -fPIC

2012-11-17 Thread jakub at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55236



--- Comment #2 from Jakub Jelinek  2012-11-17 
22:00:37 UTC ---

Author: jakub

Date: Sat Nov 17 22:00:32 2012

New Revision: 193591



URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=193591

Log:

PR tree-optimization/55236

* fold-const.c (make_range_step) : For -fwrapv

and signed ARG0_TYPE, force low and high to be non-NULL.



* gcc.dg/pr55236.c: New test.



Added:

trunk/gcc/testsuite/gcc.dg/pr55236.c

Modified:

trunk/gcc/ChangeLog

trunk/gcc/fold-const.c

trunk/gcc/testsuite/ChangeLog


[Bug bootstrap/55370] New: [4.8 Regression] Bad libgcc.map

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55370



 Bug #: 55370

   Summary: [4.8 Regression] Bad libgcc.map

Classification: Unclassified

   Product: gcc

   Version: 4.8.0

Status: UNCONFIRMED

  Severity: normal

  Priority: P3

 Component: bootstrap

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: hjl.to...@gmail.com





On Linux/x86-64, I got



/usr/local/bin/ld: warning: wildcard match appears in both version 'GCC_3.0'

and 'GCC_4.8.0' in script



libgcc.map has



GCC_3.0 {

  global:

...

  local:

*;

};

...

GCC_4.8.0 {

  global:

__cpu_model;

__cpu_indicator_init;



  local:

*;

};


[Bug bootstrap/55370] [4.8 Regression] Bad libgcc.map

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55370



H.J. Lu  changed:



   What|Removed |Added



   Target Milestone|--- |4.8.0


[Bug c++/55366] g++ segfault; see also Bug 55365

2012-11-17 Thread paolo.carlini at oracle dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55366



Paolo Carlini  changed:



   What|Removed |Added



 Status|UNCONFIRMED |RESOLVED

 CC|jasongross9+bugzilla at |

   |gmail dot com   |

 Resolution||DUPLICATE



--- Comment #1 from Paolo Carlini  2012-11-17 
23:17:59 UTC ---

It's the same issue.



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


[Bug c++/55365] internal compiler error: in process_init_constructor_union, at cp/typeck2.c:1335; internal compiler error: in lookup_field_1, at cp/search.c:387; internal compiler error: in process_in

2012-11-17 Thread paolo.carlini at oracle dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55365



--- Comment #3 from Paolo Carlini  2012-11-17 
23:17:59 UTC ---

*** Bug 55366 has been marked as a duplicate of this bug. ***


[Bug c++/55367] Probably problem with c++ vptr under templates and multiple inheritance

2012-11-17 Thread paolo.carlini at oracle dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55367



Paolo Carlini  changed:



   What|Removed |Added



   Severity|critical|normal


[Bug bootstrap/54283] [4.8 regression] build tools don't run after cxx-conversion merge

2012-11-17 Thread ebotcazou at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54283



--- Comment #6 from Eric Botcazou  2012-11-17 
23:31:22 UTC ---

> Does it happen with a recent bootstrap compiler, i.e. for which

> -static-libstdc++ is implemented, if you don't set --with-host-libstdcxx?  I

> think it's 4.6 and above for Solaris.



Replying to myself: no, this works (tested with 4.7.x).  So it's possible to

bootstrap without any special configure options if you have a recent compiler.

Which could mean that using --with-stage1-ldflags would work for the others.


[Bug middle-end/55371] New: [asan] False -Werror=uninitialized

2012-11-17 Thread hjl.tools at gmail dot com

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55371

 Bug #: 55371
   Summary: [asan] False -Werror=uninitialized
Classification: Unclassified
   Product: gcc
   Version: 4.8.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: middle-end
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: hjl.to...@gmail.com


[hjl@gnu-tools-1 gcc]$
/export/build/gnu/gcc-asan/build-x86_64-linux/./prev-gcc/g++
-B/export/build/gnu/gcc-asan/build-x86_64-linux/./prev-gcc/
-B/usr/gcc-4.8.0/x86_64-unknown-linux-gnu/bin/ -nostdinc++
-B/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs
-B/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/libsupc++/.libs
-B/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libsanitizer/asan/.libs
-I/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/include/x86_64-unknown-linux-gnu
-I/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/include
-I/export/gnu/import/git/sources/gcc/libstdc++-v3/libsupc++
-L/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs
-L/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/libsupc++/.libs
-c   -g -O2 -faddress-sanitizer -DIN_GCC   -fno-exceptions -fno-rtti
-fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings
-Wcast-qual -Wmissing-format-attribute -pedantic -Wno-long-long
-Wno-variadic-macros -Wno-overlength-strings -Werror -fno-common 
-DHAVE_CONFIG_H -I. -I. -I/export/gnu/import/git/sources/gcc/gcc
-I/export/gnu/import/git/sources/gcc/gcc/.
-I/export/gnu/import/git/sources/gcc/gcc/../include
-I/export/gnu/import/git/sources/gcc/gcc/../libcpp/include 
-I/export/gnu/import/git/sources/gcc/gcc/../libdecnumber
-I/export/gnu/import/git/sources/gcc/gcc/../libdecnumber/bid -I../libdecnumber
-I/export/gnu/import/git/sources/gcc/gcc/../libbacktrace   
/export/gnu/import/git/sources/gcc/gcc/explow.c -o explow.o
/export/gnu/import/git/sources/gcc/gcc/explow.c: In function ‘rtx_def*
plus_constant(machine_mode, rtx, long int)’:
/export/gnu/import/git/sources/gcc/gcc/explow.c:84:7: error: ‘y’ may be used
uninitialized in this function [-Werror=uninitialized]
   rtx y;
   ^
cc1plus: all warnings being treated as errors
[hjl@gnu-tools-1 gcc]$
/export/build/gnu/gcc-asan/build-x86_64-linux/./prev-gcc/g++
-B/export/build/gnu/gcc-asan/build-x86_64-linux/./prev-gcc/
-B/usr/gcc-4.8.0/x86_64-unknown-linux-gnu/bin/ -nostdinc++
-B/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs
-B/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/libsupc++/.libs
-B/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libsanitizer/asan/.libs
-I/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/include/x86_64-unknown-linux-gnu
-I/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/include
-I/export/gnu/import/git/sources/gcc/libstdc++-v3/libsupc++
-L/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs
-L/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/libsupc++/.libs
-c   -g -O2  -DIN_GCC   -fno-exceptions -fno-rtti -fasynchronous-unwind-tables
-W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing-format-attribute
-pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -Werror
-fno-common  -DHAVE_CONFIG_H -I. -I. -I/export/gnu/import/git/sources/gcc/gcc
-I/export/gnu/import/git/sources/gcc/gcc/.
-I/export/gnu/import/git/sources/gcc/gcc/../include
-I/export/gnu/import/git/sources/gcc/gcc/../libcpp/include 
-I/export/gnu/import/git/sources/gcc/gcc/../libdecnumber
-I/export/gnu/import/git/sources/gcc/gcc/../libdecnumber/bid -I../libdecnumber
-I/export/gnu/import/git/sources/gcc/gcc/../libbacktrace   
/export/gnu/import/git/sources/gcc/gcc/explow.c -o explow.o
[hjl@gnu-tools-1 gcc]$


[Bug target/55372] New: MIPS: Loading integer constants to floating-pointer registers generates suboptimal code

2012-11-17 Thread stevenbaker94 at rocketmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55372



 Bug #: 55372

   Summary: MIPS: Loading integer constants to floating-pointer

registers generates suboptimal code

Classification: Unclassified

   Product: gcc

   Version: 4.7.2

Status: UNCONFIRMED

  Severity: enhancement

  Priority: P3

 Component: target

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: stevenbake...@rocketmail.com





When loading an integer constant (e.g. 100) into a floating-point variable, the

compiler unconditionally creates a .rodata entry. However, integer constants

that are to be used in floating-point registers always have the lower 16 bits

set to 0, so it is better to use the combination lui+mtc1 rather than lui+lwc1

and a .data entry. (In other words, we save both a word of memory in .data and

one memory fetch for this word.)



As a workaround, I provide a function f() that "converts" a const float into

float using the right instruction sequence (beware that it silently discards

any fractional bits, however):



extern void foo(float x);



static inline float f(const float f)

{

union {

float f;

unsigned int i;

} x;



x.f = f;



unsigned int r;

float f_out;

asm ("lui %0, %1"

: "=d" (r)

: "I" (x.i >> 16));

asm ("mtc1 %1, %0"

: "=f" (f_out)

: "d" (r));

return f_out;

}



void bar()

{

#if 1 /* Workaround */

foo(f(100.0f));

#else /* Native GCC */

foo(100.0f);

#endif

}



The difference:



ORIGINAL:



Contents of section .rodata.cst4:

  42c8 B...



 :

   0:   3c02lui v0,0x0

   4:   0800j   0 

   8:   c44clwc1$f12,0(v0)



WORKAROUND/PROPOSED IMPROVEMENT:



 :

   0:   3c0242c8lui v0,0x42c8

   4:   0800j   0 

   8:   44826000mtc1v0,$f12


[Bug c++/55373] New: Partial ordering of variadic function template

2012-11-17 Thread zeratul976 at hotmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55373



 Bug #: 55373

   Summary: Partial ordering of variadic function template

Classification: Unclassified

   Product: gcc

   Version: 4.8.0

Status: UNCONFIRMED

  Severity: normal

  Priority: P3

 Component: c++

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: zeratul...@hotmail.com





According to the last example in temp.func.order (14.5.6.2), the call to f

below should be ambiguous, but GCC compiles the code and the calls #2:





template  void f(T, U...);// #1

template  void f(T);  // #2



void h(int i)

{

f(&i);  // should be ambiguous, but calls #2

}


[Bug other/55374] New: [asan] Can't link static libasan with static libstdc++

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55374



 Bug #: 55374

   Summary: [asan] Can't link static libasan with static libstdc++

Classification: Unclassified

   Product: gcc

   Version: 4.8.0

Status: UNCONFIRMED

  Severity: normal

  Priority: P3

 Component: other

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: hjl.to...@gmail.com





On hjl/asan git branch, under Linux/x86-64, configured with



--enable-clocale=gnu --with-system-zlib --with-demangler-in-ld

--enable-languages=c,c++  --prefix=/usr/gcc-4.8.0

--with-local-prefix=/usr/local --enable-gnu-indirect-function --disable-werror

--with-build-config=bootstrap-asan --with-fpmath=sse



I got



/export/build/gnu/gcc-asan/build-x86_64-linux/./prev-gcc/g++

-B/export/build/gnu/gcc-asan/build-x86_64-linux/./prev-gcc/

-B/usr/gcc-4.8.0/x86_64-unknown-linux-gnu/bin/ -nostdinc++

-B/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs

-B/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/libsupc++/.libs

-B/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libsanitizer/asan/.libs

-I/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/include/x86_64-unknown-linux-gnu

-I/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/include

-I/export/gnu/import/git/sources/gcc/libstdc++-v3/libsupc++

-L/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs

-L/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/libsupc++/.libs

  -g -O2 -faddress-sanitizer -DIN_GCC   -fno-exceptions -fno-rtti

-fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings

-Wcast-qual -Wmissing-format-attribute -pedantic -Wno-long-long

-Wno-variadic-macros -Wno-overlength-strings -fno-common  -DHAVE_CONFIG_H

-static-libstdc++ -static-libgcc -faddress-sanitizer -static-libasan  -o cc1

c/c-lang.o c-family/stub-objc.o attribs.o c/c-errors.o c/c-decl.o c/c-typeck.o

c/c-convert.o c/c-aux-info.o c/c-objc-common.o c/c-parser.o c-family/c-common.o

c-family/c-cppbuiltin.o c-family/c-dump.o c-family/c-format.o

c-family/c-gimplify.o c-family/c-lex.o c-family/c-omp.o c-family/c-opts.o

c-family/c-pch.o c-family/c-ppoutput.o c-family/c-pragma.o

c-family/c-pretty-print.o c-family/c-semantics.o c-family/c-ada-spec.o

tree-mudflap.o i386-c.o glibc-c.o \

  cc1-checksum.o libbackend.a main.o tree-browser.o libcommon-target.a

libcommon.a ../libcpp/libcpp.a ../libdecnumber/libdecnumber.a libcommon.a

../libcpp/libcpp.a   ../libbacktrace/.libs/libbacktrace.a

../libiberty/libiberty.a ../libdecnumber/libdecnumber.a   -lmpc -lmpfr -lgmp

-rdynamic  -lz

/usr/local/bin/ld: error:

/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libsanitizer/asan/.libs/libasan.a(asan_new_delete.o):

multiple definition of 'operator delete(void*)'

/usr/local/bin/ld:

/export/build/gnu/gcc-asan/build-x86_64-linux/prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs/libstdc++.a(del_op.o):

previous definition here

collect2: error: ld returned 1 exit status


[Bug other/55374] [asan] Can't link static libasan with static libstdc++

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55374



--- Comment #1 from H.J. Lu  2012-11-18 01:18:07 
UTC ---

-Bstatic -lasan -Bdynamic must be placed before -Bstatic -lstdc++ -Bdynamic.


[Bug other/55375] New: libsanitizer license incomplete

2012-11-17 Thread doko at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55375



 Bug #: 55375

   Summary: libsanitizer license incomplete

Classification: Unclassified

   Product: gcc

   Version: 4.8.0

Status: UNCONFIRMED

  Severity: normal

  Priority: P3

 Component: other

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: d...@gcc.gnu.org





libsanitizer/LICENSE.TXT:



Copyright (c) 2009-2012 by the contributors listed in CREDITS.TXT



however this file isn't included in GCC.



I think the contributors should be listed explicitly instead of bloating the

list of contributors by this general file.


[Bug other/55375] libsanitizer license incomplete

2012-11-17 Thread doko at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55375



Matthias Klose  changed:



   What|Removed |Added



   Priority|P3  |P1

   Target Milestone|--- |4.8.0

   Severity|normal  |major


[Bug other/55374] [asan] Can't link static libasan with static libstdc++

2012-11-17 Thread hjl.tools at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55374



--- Comment #2 from H.J. Lu  2012-11-18 01:29:57 
UTC ---

Even without -static-libasan, shouldn't -lasan be placed before

-lstdc++?



[hjl@gnu-tools-1 prev-gcc]$ ./g++ -B./  -faddress-sanitizer x.o

-B../prev-x86_64-unknown-linux-gnu/libsanitizer/asan/.libs/

-B../prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs/ -v

Reading specs from ./specs

COLLECT_GCC=./g++

COLLECT_LTO_WRAPPER=./lto-wrapper

Target: x86_64-unknown-linux-gnu

Configured with: /export/gnu/import/git/sources/gcc/configure

--enable-clocale=gnu --with-system-zlib --with-demangler-in-ld

--enable-languages=c,c++ --prefix=/usr/gcc-4.8.0 --with-local-prefix=/usr/local

--enable-gnu-indirect-function --disable-werror

--with-build-config=bootstrap-asan --with-fpmath=sse

Thread model: posix

gcc version 4.8.0 20121117 (experimental) (GCC) 

COMPILER_PATH=./:../prev-x86_64-unknown-linux-gnu/libsanitizer/asan/.libs/:../prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs/

LIBRARY_PATH=./:../prev-x86_64-unknown-linux-gnu/libsanitizer/asan/.libs/:../prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs/:/lib/../lib64/:/usr/lib/../lib64/:/lib/:/usr/lib/

COLLECT_GCC_OPTIONS='-B' './' '-faddress-sanitizer' '-B'

'../prev-x86_64-unknown-linux-gnu/libsanitizer/asan/.libs/' '-B'

'../prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs/' '-v'

'-shared-libgcc' '-mtune=generic' '-march=x86-64'

 ./collect2 --eh-frame-hdr -m elf_x86_64 -dynamic-linker

/lib64/ld-linux-x86-64.so.2 /lib/../lib64/crt1.o /lib/../lib64/crti.o

./crtbegin.o -L. -L../prev-x86_64-unknown-linux-gnu/libsanitizer/asan/.libs

-L../prev-x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs -L/lib/../lib64

-L/usr/lib/../lib64 x.o -lstdc++ -lm -lasan -lgcc_s -lgcc -lc -lgcc_s -lgcc

./crtend.o /lib/../lib64/crtn.o

[hjl@gnu-tools-1 prev-gcc]$


[Bug other/55375] libsanitizer license incomplete

2012-11-17 Thread doko at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55375



--- Comment #1 from Matthias Klose  2012-11-18 
01:31:45 UTC ---

and this should be removed:



Copyrights and Licenses for Third Party Software Distributed with LLVM:



not included in GCC.


[Bug debug/54693] VTA guality issues with loops

2012-11-17 Thread aoliva at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54693



--- Comment #21 from Alexandre Oliva  2012-11-18 
01:56:04 UTC ---

This doesn't look like something the bugfix may have caused, but rather as some

latent bug exposed by that patch, like the latent bug fixed in comment 7. 

Anyway, a preprocessed code that would enable me to look into this with a cross

compiler would be appreciated.  TIA,


[Bug other/55376] New: [asan] libsanitizer/README.gcc must contain the exact steps to do code changes and to port code from upstream

2012-11-17 Thread konstantin.s.serebryany at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55376



 Bug #: 55376

   Summary: [asan] libsanitizer/README.gcc must contain the exact

steps to do code changes and to port code from

upstream

Classification: Unclassified

   Product: gcc

   Version: unknown

Status: UNCONFIRMED

  Severity: normal

  Priority: P3

 Component: other

AssignedTo: unassig...@gcc.gnu.org

ReportedBy: konstantin.s.serebry...@gmail.com

CC: dseke...@redhat.com, dvyu...@google.com,

ja...@redhat.com, w...@gcc.gnu.org





We need to document the libsanitizer update process in libsanitizer/README.gcc



Few things to cover:



- The changes need to be approved by one of the maintainers (or is it obvious)?

- Except for *really* trivial changes all patches should go through the

upstream tree first. 

- When updating from upstream, the comment header should be tampered with (oh,

my)

- Ideally, we need to have a fully automated script to grab the upstream

changes (including new/deleted/moved files, etc). Suggestions here? 

- What is the testing procedure when updating from upstream? (e.g. how do we

avoid regressions on the platforms to which the maintainers have no access?)


[Bug debug/51358] [4.8 Regression] incorrect/missing location for function arg, -O0, without VTA

2012-11-17 Thread pinskia at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51358



Andrew Pinski  changed:



   What|Removed |Added



   Target Milestone|--- |4.8.0

Summary|incorrect/missing location  |[4.8 Regression]

   |for function arg, -O0,  |incorrect/missing location

   |without VTA |for function arg, -O0,

   ||without VTA



--- Comment #8 from Andrew Pinski  2012-11-18 
04:13:17 UTC ---

This has now become an user visible regression as dwarf4 is now default.


[Bug other/55376] [asan] libsanitizer/README.gcc must contain the exact steps to do code changes and to port code from upstream

2012-11-17 Thread xinliangli at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55376



davidxl  changed:



   What|Removed |Added



 CC||xinliangli at gmail dot com



--- Comment #1 from davidxl  2012-11-18 05:18:11 
UTC ---

(In reply to comment #0)

> We need to document the libsanitizer update process in libsanitizer/README.gcc

> 

> Few things to cover:

> 

> - The changes need to be approved by one of the maintainers (or is it 
> obvious)?

> - Except for *really* trivial changes all patches should go through the

> upstream tree first. 

> - When updating from upstream, the comment header should be tampered with (oh,

> my)

> - Ideally, we need to have a fully automated script to grab the upstream

> changes (including new/deleted/moved files, etc). Suggestions here? 

> - What is the testing procedure when updating from upstream? (e.g. how do we

> avoid regressions on the platforms to which the maintainers have no access?)



Are all upstream changes considered reviewed and automatically approved for gcc

repo? If yes, then this should be automated (including gcc build and libasan

testing).


[Bug target/41202] -mno-mmx doesn't turn off sse*

2012-11-17 Thread kl4yfd at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41202



kl4yfd at gmail dot com changed:



   What|Removed |Added



 CC||kl4yfd at gmail dot com



--- Comment #1 from kl4yfd at gmail dot com 2012-11-18 07:50:27 UTC ---

(In reply to comment #0)

> But this last one doesn't seem sensible:

> 

> $ /usr/local/gcc-4.4.1/bin/gcc -m32 -march=core2 -mno-mmx -E -dM -x c 
> /dev/null

> | grep "\(MMX\|SSE\)"

> #define __SSE2__ 1

> #define __SSSE3__ 1

> #define __SSE__ 1

> #define __SSE3__ 1

> 



This one is sensible.

SSE is actually not dependent on MMX, even though gcc is setup that way. :-)

Setting MMX as a dependency to SSE_MATH just a trick to prevent those registers

in the CPU and the extra processing power from being wasted when the 387 is not

in use (as 387 and MMX share those registers... poorly)

Will double-check if -mfpumath=sse (SSE_MATH) sets MMX with -m32 in gcc 4.7.2







> I can repeat these last few tests using the default 64-bit configuration:

> 

> $ /usr/local/gcc-4.4.1/bin/gcc -E -dM -x c /dev/null | grep

> "\(MMX\|SSE\)"#define __MMX__ 1

> #define __SSE2_MATH__ 1

> #define __SSE_MATH__ 1

> #define __SSE2__ 1

> #define __SSE__ 1

> $ /usr/local/gcc-4.4.1/bin/gcc -mno-sse2 -E -dM -x c /dev/null | grep

> "\(MMX\|SSE\)"

> #define __MMX__ 1

> #define __SSE_MATH__ 1

> #define __SSE__ 1

> $ /usr/local/gcc-4.4.1/bin/gcc -mno-sse -E -dM -x c /dev/null | grep

> "\(MMX\|SSE\)"

> #define __MMX__ 1



This one needs a look.

On first example, SSE_MATH is enabled but MMX is not auto-enabled <-- ?

On last example, when compiled with -mno-sse (and therefore no SSE_MATH..) MMX

was on by default. <-- ?

 - for this example, FPU math is being done in the 387, but MMX is also on.

  - Should this unsafe behavior be the default ?

== Will check if persists in 4.7.2