[Bug preprocessor/42014] Inconsistent column number display for "In file incuded from"

2016-06-03 Thread marbacz at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=42014

Marcin Baczyński  changed:

   What|Removed |Added

 CC||marbacz at gmail dot com

--- Comment #5 from Marcin Baczyński  ---
Patch against the current trunk
https://gcc.gnu.org/ml/gcc-patches/2016-06/msg00272.html

[Bug c/48116] -Wreturn-type does not work as advertised

2016-06-01 Thread marbacz at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=48116

Marcin Baczyński  changed:

   What|Removed |Added

 CC||marbacz at gmail dot com

--- Comment #10 from Marcin Baczyński  ---
Proposed patch: https://gcc.gnu.org/ml/gcc-patches/2016-06/msg00032.html

[Bug c++/65720] New: ICE with g++ 4.9.2 -frepo

2015-04-09 Thread marbacz at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65720

Bug ID: 65720
   Summary: ICE with g++ 4.9.2 -frepo
   Product: gcc
   Version: 4.9.2
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: marbacz at gmail dot com
  Host: x86_64-pc-linux-gnu
Target: x86_64-pc-linux-gnu
 Build: x86_64-pc-linux-gnu

Created attachment 35279
  -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=35279action=edit
code giving the ice on 4.9.2

 g++-4.9.2 -std=c++11 -c -frepo x.cc
x.cc: In instantiation of ‘constexpr std::tuple_T1, _T2::tuple() [with _T1 =
Acl*; _T2 = std::default_deleteAcl]’:
x.cc:50:25:   required from ‘std::unique_ptr_Tp, _Dp::unique_ptr() [with _Tp
= Acl; _Dp = std::default_deleteAcl]’
x.cc:57:42:   required from ‘typename std::_MakeUniq_Tp::__single_object
std::make_unique(_Args ...) [with _Tp = Acl; _Args = {}; typename
std::_MakeUniq_Tp::__single_object = std::unique_ptrAcl,
std::default_deleteAcl ]’
x.cc:60:34:   required from here
x.cc:36:13: internal compiler error: in repo_emit_p, at cp/repo.c:296
   constexpr default_delete() noexcept = default;
 ^
Please submit a full bug report,
with preprocessed source if appropriate.
See https://bugs.gentoo.org/ for instructions.


 g++-4.8.4 -std=c++11 -c -frepo x.cc  echo OK
OK


 g++-4.9.2 -v
Using built-in specs.
COLLECT_GCC=g++-4.9.2
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-pc-linux-gnu/4.9.2/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: /var/tmp/portage/sys-devel/gcc-4.9.2/work/gcc-4.9.2/configure
--host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --prefix=/usr
--bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.9.2
--includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.9.2/include
--datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.9.2
--mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.9.2/man
--infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.9.2/info
--with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.9.2/include/g++-v4
--with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/4.9.2/python
--enable-languages=c,c++,go,fortran --enable-obsolete --enable-secureplt
--disable-werror --with-system-zlib --enable-nls --without-included-gettext
--enable-checking=release --with-bugurl=https://bugs.gentoo.org/
--with-pkgversion='Gentoo Hardened 4.9.2 p1.2, pie-0.6.2' --enable-esp
--enable-libstdcxx-time --enable-shared --enable-threads=posix
--enable-__cxa_atexit --enable-clocale=gnu --enable-multilib
--with-multilib-list=m32,m64 --disable-altivec --disable-fixed-point
--enable-targets=all --disable-libgcj --enable-libgomp --disable-libmudflap
--disable-libssp --disable-libcilkrts --enable-lto --without-cloog
--enable-libsanitizer --enable-checking=yes
Thread model: posix
gcc version 4.9.2 (Gentoo Hardened 4.9.2 p1.2, pie-0.6.2)

[Bug c++/52035] internal compiler error: tree code ‘template_type_parm’ is not supported in LTO streams

2012-02-01 Thread marbacz at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52035

Marcin Baczyński marbacz at gmail dot com changed:

   What|Removed |Added

  Known to work||4.6.2

--- Comment #4 from Marcin Baczyński marbacz at gmail dot com 2012-02-01 
23:39:38 UTC ---
I think this should be marked as a 4.7 regression. I just tested 4.6.2 and it
works.

gcc version 4.6.2 (Gentoo 4.6.2 p1.3, pie-0.5.0)


[Bug c++/52035] New: internal compiler error: tree code ‘template_type_parm’ is not supported in LTO streams

2012-01-28 Thread marbacz at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52035

 Bug #: 52035
   Summary: internal compiler error: tree code
‘template_type_parm’ is not supported in LTO streams
Classification: Unclassified
   Product: gcc
   Version: 4.7.0
Status: UNCONFIRMED
  Severity: major
  Priority: P3
 Component: c++
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: marb...@gmail.com


Using GCC from svn (183666) I get an ICE while compiling QtCore with -flto:

~ # g++ -flto bug.ii
bug.ii:44:1: internal compiler error: tree code ‘template_type_parm’ is not
supported in LTO streams
Please submit a full bug report,
with preprocessed source if appropriate.
See http://gcc.gnu.org/bugs.html for instructions.


~ # g++ --version
g++ (svn 183666-20120128) 4.7.0 20120128 (experimental)


[Bug c++/52035] internal compiler error: tree code ‘template_type_parm’ is not supported in LTO streams

2012-01-28 Thread marbacz at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52035

--- Comment #1 from Marcin Baczyński marbacz at gmail dot com 2012-01-29 
00:46:58 UTC ---
Created attachment 26497
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=26497
Reduced test case.


[Bug lto/51992] New: internal compiler error: tree code ‘target_expr’ is not supported in LTO streams

2012-01-25 Thread marbacz at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51992

 Bug #: 51992
   Summary: internal compiler error: tree code ‘target_expr’ is
not supported in LTO streams
Classification: Unclassified
   Product: gcc
   Version: 4.7.0
Status: UNCONFIRMED
  Severity: major
  Priority: P3
 Component: lto
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: marb...@gmail.com


Created attachment 26456
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=26456
Reduced test case.

Using GCC from SVN (183488) I get an ICE while compiling kdelibs with -flto:

~ # g++ -flto -c ksharedconfig.cpp
ksharedconfig.cpp:50:1: internal compiler error: tree code ‘target_expr’ is not
supported in LTO streams
Please submit a full bug report,
with preprocessed source if appropriate.
See http://gcc.gnu.org/bugs.html for instructions.


~ # gcc -v
Using built-in specs.
COLLECT_GCC=/usr/x86_64-pc-linux-gnu/gcc-bin/4.7.0-svn-183488-20120124/gcc
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-pc-linux-gnu/4.7.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../gcc-trunk/configure --prefix=/usr
--bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.7.0-svn-183488-20120124
--includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124/include
--datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124
--mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124/man
--infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124/info
--with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124/include/g++-v4
--host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --disable-altivec
--disable-fixed-point --with-ppl --with-cloog --disable-ppl-version-check
--with-cloog-include=/usr/include/cloog-ppl --enable-lto --enable-nls
--without-included-gettext --with-system-zlib --disable-werror
--enable-secureplt --disable-multilib --enable-libmudflap --enable-libssp
--enable-libgomp
--with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124/python
--enable-checking=assert,fold,gc,misc,rtlflag,runtime,tree --disable-libgcj
--disable-libquadmath --enable-languages=c,c++ --enable-shared
--enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu
--enable-targets=all --with-pkgversion='svn 183488-20120124'
--enable-build-with-cxx
Thread model: posix
gcc version 4.7.0 20120124 (experimental) (svn 183488-20120124)


[Bug rtl-optimization/52004] New: bad asm generated with -O2 -finline-functions (and maybe -ftracer)

2012-01-25 Thread marbacz at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52004

 Bug #: 52004
   Summary: bad asm generated with -O2 -finline-functions (and
maybe -ftracer)
Classification: Unclassified
   Product: gcc
   Version: 4.7.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: rtl-optimization
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: marb...@gmail.com


Created attachment 26469
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=26469
Test case from GDB.

Compiling attached file (from GDB 7.4) generates assembly that chokes the
assembler. I'm attaching original and reduced testcases. I'm not sure whether
the reduced one is still valid C but on that one you don't need -ftracer (-O2
-finline-functions is enough for the assembler to fail).

gcc -O2 -finline-functions -ftracer -c linux-x86-low.c 
linux-x86-low.c: Assembler messages:
linux-x86-low.c:2570: Error: symbol `start_i386_reg_a' is already defined
linux-x86-low.c:2572: Error: symbol `end_i386_reg_a' is already defined
linux-x86-low.c:2579: Error: symbol `start_i386_reg_b' is already defined
linux-x86-low.c:2583: Error: symbol `end_i386_reg_b' is already defined
linux-x86-low.c:2584: Error: symbol `start_i386_reg_c' is already defined
linux-x86-low.c:2587: Error: symbol `end_i386_reg_c' is already defined
linux-x86-low.c:2694: Error: symbol `start_i386_void_call_2_a' is already
defined
linux-x86-low.c:2699: Error: symbol `end_i386_void_call_2_a' is already defined
linux-x86-low.c:2715: Error: symbol `start_i386_void_call_2_b' is already
defined
linux-x86-low.c:2718: Error: symbol `end_i386_void_call_2_b' is already defined
linux-x86-low.c:2666: Error: symbol `start_i386_int_call_1_a' is already
defined
linux-x86-low.c:2668: Error: symbol `end_i386_int_call_1_a' is already defined
linux-x86-low.c:2680: Error: symbol `start_i386_int_call_1_c' is already
defined
linux-x86-low.c:2683: Error: symbol `end_i386_int_call_1_c' is already defined
linux-x86-low.c:2081: Error: symbol `start_amd64_void_call_2_b' is already
defined
linux-x86-low.c:2082: Error: symbol `end_amd64_void_call_2_b' is already
defined
linux-x86-low.c:2075: Error: symbol `start_amd64_void_call_2_a' is already
defined
linux-x86-low.c:2077: Error: symbol `end_amd64_void_call_2_a' is already
defined


~ # gcc -v
Using built-in specs.
COLLECT_GCC=/usr/x86_64-pc-linux-gnu/gcc-bin/4.7.0-svn-183541-20120125/gcc
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-pc-linux-gnu/4.7.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../gcc-trunk/configure --prefix=/usr
--bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.7.0-svn-183541-20120125
--includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.0-svn-183541-20120125/include
--datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183541-20120125
--mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183541-20120125/man
--infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183541-20120125/info
--with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.0-svn-183541-20120125/include/g++-v4
--host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --disable-altivec
--disable-fixed-point --with-ppl --with-cloog --disable-ppl-version-check
--with-cloog-include=/usr/include/cloog-ppl --enable-lto --enable-nls
--without-included-gettext --with-system-zlib --disable-werror
--enable-secureplt --disable-multilib --enable-libmudflap --enable-libssp
--enable-libgomp
--with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183541-20120125/python
--enable-checking=assert,fold,gc,misc,rtlflag,runtime,tree --disable-libgcj
--disable-libquadmath --enable-languages=c,c++ --enable-shared
--enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu
--enable-targets=all --with-pkgversion='svn 183541-20120125'
--enable-build-with-cxx
Thread model: posix
gcc version 4.7.0 20120125 (experimental) (svn 183541-20120125)


[Bug rtl-optimization/52004] bad asm generated with -O2 -finline-functions (and maybe -ftracer)

2012-01-25 Thread marbacz at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52004

--- Comment #1 from Marcin Baczynski marbacz at gmail dot com 2012-01-26 
00:37:21 UTC ---
Created attachment 26470
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=26470
Reduced test case.


[Bug middle-end/51984] New: ICE: SIGSEGV with -O2 -fgraphite-identity

2012-01-24 Thread marbacz at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51984

 Bug #: 51984
   Summary: ICE: SIGSEGV with -O2 -fgraphite-identity
Classification: Unclassified
   Product: gcc
   Version: 4.7.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: middle-end
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: marb...@gmail.com


With SVN rev 183488 I get the following ICE on attached code:

~ # LC_ALL=C gcc -O2 -fgraphite-identity -c ~/bug.c -o /tmp/bug.o
/root/bug.c: In function 'pack_states':
/root/bug.c:8:1: 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.


~ # gcc -v
Using built-in specs.
COLLECT_GCC=/usr/x86_64-pc-linux-gnu/gcc-bin/4.7.0-svn-183488-20120124/gcc
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-pc-linux-gnu/4.7.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../gcc-trunk/configure --prefix=/usr
--bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.7.0-svn-183488-20120124
--includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124/include
--datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124
--mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124/man
--infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124/info
--with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124/include/g++-v4
--host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --disable-altivec
--disable-fixed-point --with-ppl --with-cloog --disable-ppl-version-check
--with-cloog-include=/usr/include/cloog-ppl --enable-lto --enable-nls
--without-included-gettext --with-system-zlib --disable-werror
--enable-secureplt --disable-multilib --enable-libmudflap --enable-libssp
--enable-libgomp
--with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-svn-183488-20120124/python
--enable-checking=assert,fold,gc,misc,rtlflag,runtime,tree --disable-libgcj
--disable-libquadmath --enable-languages=c,c++ --enable-shared
--enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu
--enable-targets=all --with-pkgversion='svn 183488-20120124'
--enable-build-with-cxx
Thread model: posix


[Bug middle-end/51984] ICE: SIGSEGV with -O2 -fgraphite-identity

2012-01-24 Thread marbacz at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51984

--- Comment #1 from Marcin Baczynski marbacz at gmail dot com 2012-01-24 
22:00:18 UTC ---
Created attachment 26447
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=26447
Reduced test case.


[Bug middle-end/51939] New: ICE: in compute_affine_dependence, at tree-data-ref.c:4103

2012-01-21 Thread marbacz at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51939

 Bug #: 51939
   Summary: ICE: in compute_affine_dependence, at
tree-data-ref.c:4103
Classification: Unclassified
   Product: gcc
   Version: 4.7.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: middle-end
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: marb...@gmail.com


Created attachment 26408
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=26408
Reduced test case

This fails with gcc-4.7.0-alpha20120114, works with gcc-4.5.3.
Reduced test case attached.


x86_64-pc-linux-gnu-gcc-4.7.0-alpha20120114 -O1 -fcheck-data-deps
-D_LARGEFILE64_SOURCE=1 -c bug.c 

(Number of distance vectors differ: Banerjee has 3, Omega has 2.
Banerjee dist vectors:
  0   0 
  0   1 
  1   0 
Omega dist vectors:
  0   0 
  1   0 
data dependence relation:
(Data Dep: 
#(Data Ref: 
#  bb: 9 
#  stmt: D.1732_13 = s_4(D)-strstart;
#  ref: s_4(D)-strstart;
#  base_object: s_4(D)-strstart;
#)
#(Data Ref: 
#  bb: 9 
#  stmt: s_4(D)-strstart = D.1733_14;
#  ref: s_4(D)-strstart;
#  base_object: s_4(D)-strstart;
#)
  inner loop index: 0
  loop nest: (1 2 )
  distance_vector:   0   0 
  distance_vector:   1   0 
  direction_vector: ==
  direction_vector: +=
)
)
bug.c: In function ‘deflate’:
bug.c:14:5: internal compiler error: in compute_affine_dependence, at
tree-data-ref.c:4103
Please submit a full bug report,
with preprocessed source if appropriate.



x86_64-pc-linux-gnu-gcc-4.7.0-alpha20120114 -v
Using built-in specs.
COLLECT_GCC=x86_64-pc-linux-gnu-gcc-4.7.0-alpha20120114
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-pc-linux-gnu/4.7.0-alpha20120114/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with:
/var/tmp/portage/sys-devel/gcc-4.7.0_alpha20120114/work/gcc-4.7-20120114/configure
--prefix=/usr --bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.7.0-alpha20120114
--includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.0-alpha20120114/include
--datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-alpha20120114
--mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-alpha20120114/man
--infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-alpha20120114/info
--with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.0-alpha20120114/include/g++-v4
--host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --disable-altivec
--disable-fixed-point --with-ppl --with-cloog --disable-ppl-version-check
--with-cloog-include=/usr/include/cloog-ppl --enable-lto --enable-nls
--without-included-gettext --with-system-zlib --disable-werror
--enable-secureplt --disable-multilib --enable-libmudflap --disable-libssp
--enable-libgomp
--with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/4.7.0-alpha20120114/python
--enable-checking=yes --disable-libgcj --disable-libquadmath
--enable-languages=c,c++ --enable-shared --enable-threads=posix
--enable-__cxa_atexit --enable-clocale=gnu --enable-targets=all
--with-bugurl=http://bugs.gentoo.org/ --with-pkgversion='Gentoo
4.7.0_alpha20120114'
Thread model: posix
gcc version 4.7.0-alpha20120114 20120114 (experimental) (Gentoo
4.7.0_alpha20120114)


[Bug lto/43455] New: Compiler hang with -O2 -flto

2010-03-20 Thread marbacz at gmail dot com
gcc -O2 -flto 1.c 2.c hangs.
-O1 or without -flto compiles and links just fine.

1.c:
struct bar {int x;};
extern struct bar foo(void);
int main()
{
struct bar x=foo();
return 0;
}

2.c:
typedef struct{int x;} bar;
bar foo (void)
{
bar x;
return x;
}

gcc -v:
Using built-in specs.
COLLECT_GCC=/usr/x86_64-pc-linux-gnu/gcc-bin/4.5.0-alpha20100318/gcc
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-pc-linux-gnu/4.5.0-alpha20100318/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with:
/var/tmp/portage/sys-devel/gcc-4.5.0_alpha20100318/work/gcc-4.5-20100318/configure
--prefix=/usr --bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.5.0-alpha20100318
--includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.5.0-alpha20100318/include
--datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.5.0-alpha20100318
--mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.5.0-alpha20100318/man
--infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.5.0-alpha20100318/info
--with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.5.0-alpha20100318/include/g++-v4
--host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --disable-altivec
--disable-fixed-point --with-ppl --with-cloog --enable-nls
--without-included-gettext --with-system-zlib --disable-checking
--disable-werror --enable-secureplt --enable-multilib --enable-libmudflap
--disable-libssp --enable-libgomp --enable-cld
--with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/4.5.0-alpha20100318/python
--disable-libgcj --enable-languages=c,c++ --enable-shared
--enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu
--with-bugurl=http://bugs.gentoo.org/ --with-pkgversion='Gentoo
4.5.0_alpha20100318' --enable-lto
Thread model: posix
gcc version 4.5.0-alpha20100318 20100318 (experimental) (Gentoo
4.5.0_alpha20100318)


-- 
   Summary: Compiler hang with -O2 -flto
   Product: gcc
   Version: 4.5.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: lto
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: marbacz at gmail dot com


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



[Bug lto/43455] Compiler hang with -O2 -flto

2010-03-20 Thread marbacz at gmail dot com


--- Comment #2 from marbacz at gmail dot com  2010-03-20 22:25 ---
Passing -m32 make the hang disappear.

Below is slightly less reduced version of previous test case. It comes from gnu
bc.

It causes ICE. Uncommenting declarations changes ICE into hang. ICE doesn't go
away with -m32.

gcc -O2 -flto numeric.c eval.c 
===
In file included from eval.c:28:0,
 from numeric.c:19,
 from :0:
eval.c: In function 'dc_evalstr':
eval.c:30:10: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See http://bugs.gentoo.org/ for instructions.
lto-wrapper: /usr/x86_64-pc-linux-gnu/gcc-bin/4.5.0-alpha20100318/gcc returned
1 exit status
collect2: lto-wrapper returned 1 exit status
===

eval.c:

typedef enum {DC_UNINITIALIZED, DC_NUMBER, DC_STRING} dc_value_type;
typedef struct dc_number *dc_num;
typedef struct dc_string *dc_str;
typedef struct {
dc_value_type dc_type;
union { dc_num number; dc_str string; } v;
} dc_data;

const char *progname;

int main()
{
return 0;
}
/*
int dc_func(int a, int b, int c);
void dc_push(dc_data);
dc_data dc_getnum(int a, int b, int c);
*/
static const char *input_str_string;

int
dc_evalstr (dc_data *string)
{
const char *s;
int peekc;
switch (dc_func(0, 0, 0)){
case 0:
input_str_string = s - 1;
dc_push(dc_getnum(0, 0, 0));
s = input_str_string;
if (peekc != -1)
--s;
break;
}
return 0;
}
===

numeric.c 
===
typedef enum {DC_UNINITIALIZED, DC_NUMBER, DC_STRING} dc_value_type;
typedef struct bc_struct *dc_num;
typedef struct dc_string *dc_str;
typedef struct {
dc_value_type dc_type;
union {
dc_num number;
dc_str string;
} v;
} dc_data;

dc_data dc_getnum(int input, int ibase, int readahead)
{
dc_data x;
return x;
}

int dc_func(int a, int b, int c){return 0;}
void dc_push(dc_data a){}


-- 


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



[Bug middle-end/43323] New: Wrong code with bitfields and type casting.

2010-03-10 Thread marbacz at gmail dot com
When compiled with gcc 4.4.[34] The following code prints fe 01, while it
should fe ff. Current svn trunk produces correct results.
No flags needed to reproduce.

extern int printf(const char * __restrict, ...);
int main()
{
struct { unsigned bar:1; } foo;
foo.bar = 0x1;
printf(%02x\n, (unsigned char)(foo.bar * 0xfe));
printf(%02x\n, (unsigned char)(foo.bar * 0xff));
return 0;
}

gcc -v:

Using built-in specs.
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-svn/configure --enable-stage1-languages-c
--enable-languages=c,c++
Thread model: posix
gcc version 4.4.4 20100309 (prerelease) (GCC)


-- 
   Summary: Wrong code with bitfields and type casting.
   Product: gcc
   Version: 4.4.4
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: middle-end
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: marbacz at gmail dot com
 GCC build triplet: x86_64-linux-gnu
  GCC host triplet: x86_64-linux-gnu
GCC target triplet: x86_64-linux-gnu


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