public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug lto/55902] New: lto1 SIGSEGV
@ 2013-01-07 19:50 vhaisman at gmail dot com
  2013-01-07 19:54 ` [Bug lto/55902] " vhaisman at gmail dot com
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: vhaisman at gmail dot com @ 2013-01-07 19:50 UTC (permalink / raw)
  To: gcc-bugs


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

             Bug #: 55902
           Summary: lto1 SIGSEGV
    Classification: Unclassified
           Product: gcc
           Version: 4.6.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: lto
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: vhaisman@gmail.com


During compilation of log4cplus using Linux-x-Ming-w64 cross compiler, I am
seeing a SIGSEGV in lto1 executable. The command line to reproduce is the
following:

/usr/lib/gcc/i686-w64-mingw32/4.6/lto1 -march=amdfam10 -mcx16 -msahf -mno-movbe
-mno-aes -mno-pclmul -mpopcnt -mabm -mno-lwp -mno-fma -mno-fma4 -mno-xop
-mno-bmi -mno-tbm -mno-avx -mno-sse4.2 -mno-sse4.1 -mno-rdrnd -mno-f16c
-mno-fsgsbase --param l1-cache-size=64 --param l1-cache-line-size=64 --param
l2-cache-size=512 -mtune=amdfam10 -quiet -dumpdir ./ -dumpbase
appender_test.exe -auxbase-strip /tmp/ccyNkt1q.lto.o -g -g3 -ggdb -O2 -Wall
-Wextra -pedantic -Wstrict-aliasing -Wstrict-overflow -Woverloaded-virtual
-Wc++0x-compat -Wundef -Wshadow -Wformat -Wsuggest-attribute=noreturn
-Wno-variadic-macros -version -fverbose-asm -fvisibility=hidden
-flto-partition=none -fuse-linker-plugin -fresolution=appender_test.res
@./ccxMMj8q -o /tmp/ccyNkt1q.lto.s

Use the attached tarball to get the necessary files.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug lto/55902] lto1 SIGSEGV
  2013-01-07 19:50 [Bug lto/55902] New: lto1 SIGSEGV vhaisman at gmail dot com
@ 2013-01-07 19:54 ` vhaisman at gmail dot com
  2013-01-07 20:19 ` vhaisman at gmail dot com
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: vhaisman at gmail dot com @ 2013-01-07 19:54 UTC (permalink / raw)
  To: gcc-bugs


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

--- Comment #1 from Václav Zeman <vhaisman at gmail dot com> 2013-01-07 19:53:51 UTC ---
Attachment upload did not work. The following link should work:
https://docs.google.com/open?id=0B-WkLJEfYmSEVHVmUzR3NDAxTFE


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug lto/55902] lto1 SIGSEGV
  2013-01-07 19:50 [Bug lto/55902] New: lto1 SIGSEGV vhaisman at gmail dot com
  2013-01-07 19:54 ` [Bug lto/55902] " vhaisman at gmail dot com
@ 2013-01-07 20:19 ` vhaisman at gmail dot com
  2013-01-08  9:49 ` rguenth at gcc dot gnu.org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: vhaisman at gmail dot com @ 2013-01-07 20:19 UTC (permalink / raw)
  To: gcc-bugs


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

--- Comment #2 from Václav Zeman <vhaisman at gmail dot com> 2013-01-07 20:19:11 UTC ---
HTH:

amber2::wilx:~/log4cplus-bzr/work-trunk/objdir-mingw64-w32/bug> gdb
/usr/lib/gcc/i686-w64-mingw32/4.6/lto1
GNU gdb (GDB) 7.5-ubuntu
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/lib/gcc/i686-w64-mingw32/4.6/lto1...(no debugging
symbols found)...done.
(gdb) r -march=amdfam10 -mcx16 -msahf -mno-movbe -mno-aes -mno-pclmul -mpopcnt
-mabm -mno-lwp -mno-fma -mno-fma4 -mno-xop -mno-bmi -mno-tbm -mno-avx
-mno-sse4.2 -mno-sse4.1 -mno-rdrnd -mno-f16c -mno-fsgsbase --param
l1-cache-size=64 --param l1-cache-line-size=64 --param l2-cache-size=512
-mtune=amdfam10 -quiet -dumpdir ./ -dumpbase appender_test.exe -auxbase-strip
/tmp/ccyNkt1q.lto.o -g -g3 -ggdb -O2 -Wall -Wextra -pedantic -Wstrict-aliasing
-Wstrict-overflow -Woverloaded-virtual -Wc++0x-compat -Wundef -Wshadow -Wformat
-Wsuggest-attribute=noreturn -Wno-variadic-macros -version -fverbose-asm
-fvisibility=hidden -flto-partition=none -fuse-linker-plugin
-fresolution=appender_test.res @./ccxMMj8q -o /tmp/ccyNkt1q.lto.s
Starting program: /usr/lib/gcc/i686-w64-mingw32/4.6/lto1 -march=amdfam10 -mcx16
-msahf -mno-movbe -mno-aes -mno-pclmul -mpopcnt -mabm -mno-lwp -mno-fma
-mno-fma4 -mno-xop -mno-bmi -mno-tbm -mno-avx -mno-sse4.2 -mno-sse4.1
-mno-rdrnd -mno-f16c -mno-fsgsbase --param l1-cache-size=64 --param
l1-cache-line-size=64 --param l2-cache-size=512 -mtune=amdfam10 -quiet -dumpdir
./ -dumpbase appender_test.exe -auxbase-strip /tmp/ccyNkt1q.lto.o -g -g3 -ggdb
-O2 -Wall -Wextra -pedantic -Wstrict-aliasing -Wstrict-overflow
-Woverloaded-virtual -Wc++0x-compat -Wundef -Wshadow -Wformat
-Wsuggest-attribute=noreturn -Wno-variadic-macros -version -fverbose-asm
-fvisibility=hidden -flto-partition=none -fuse-linker-plugin
-fresolution=appender_test.res @./ccxMMj8q -o /tmp/ccyNkt1q.lto.s
GNU GIMPLE (GCC) version 4.6.3 (i686-w64-mingw32)
    compiled by GNU C version 4.6.3 20120624 (prerelease), GMP version 5.0.2,
MPFR version 3.1.0-p3, MPC version 0.9
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
GNU GIMPLE (GCC) version 4.6.3 (i686-w64-mingw32)
    compiled by GNU C version 4.6.3 20120624 (prerelease), GMP version 5.0.2,
MPFR version 3.1.0-p3, MPC version 0.9
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072

Program received signal SIGSEGV, Segmentation fault.
0x00000000004a68b0 in bitmap_bit_p ()
(gdb) bt
#0  0x00000000004a68b0 in bitmap_bit_p ()
#1  0x000000000084a6b3 in ?? ()
#2  0x000000000084587c in ?? ()
#3  0x00000000008459f0 in ?? ()
#4  0x0000000000632e8b in execute_one_pass ()
#5  0x0000000000633145 in execute_pass_list ()
#6  0x000000000083ca80 in cgraph_process_new_functions ()
#7  0x00000000006330f5 in execute_one_pass ()
#8  0x000000000063353a in execute_ipa_pass_list ()
#9  0x000000000083e4b1 in cgraph_optimize ()
#10 0x000000000049d279 in lto_main ()
#11 0x00000000006c6de9 in toplev_main ()
#12 0x00007ffff6f4176d in __libc_start_main (main=0x485ea0 <main>, argc=60,
ubp_av=0x7fffffffe088, init=<optimized out>, fini=<optimized out>,
rtld_fini=<optimized out>, stack_end=0x7fffffffe078)
    at libc-start.c:226
#13 0x0000000000485f09 in _start ()


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug lto/55902] lto1 SIGSEGV
  2013-01-07 19:50 [Bug lto/55902] New: lto1 SIGSEGV vhaisman at gmail dot com
  2013-01-07 19:54 ` [Bug lto/55902] " vhaisman at gmail dot com
  2013-01-07 20:19 ` vhaisman at gmail dot com
@ 2013-01-08  9:49 ` rguenth at gcc dot gnu.org
  2013-01-08 15:00 ` vhaisman at gmail dot com
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu.org @ 2013-01-08  9:49 UTC (permalink / raw)
  To: gcc-bugs


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

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |WAITING
   Last reconfirmed|                            |2013-01-08
     Ever Confirmed|0                           |1

--- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> 2013-01-08 09:48:55 UTC ---
I stronly suggest you try GCC 4.7.2 (that is, the latest available release)
when you run into LTO issues as well as recent binutils releases (what's
your binutils version? do you use gold?).

Does it only reproduce with -flto-partition=none?  Can you try to reduce
the set of input source files by using partial linking (-r -nostdlib)?
Usually this reduces the set of input sources to two.

The google doc is not accessible for me.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug lto/55902] lto1 SIGSEGV
  2013-01-07 19:50 [Bug lto/55902] New: lto1 SIGSEGV vhaisman at gmail dot com
                   ` (2 preceding siblings ...)
  2013-01-08  9:49 ` rguenth at gcc dot gnu.org
@ 2013-01-08 15:00 ` vhaisman at gmail dot com
  2013-01-08 18:27 ` vhaisman at gmail dot com
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: vhaisman at gmail dot com @ 2013-01-08 15:00 UTC (permalink / raw)
  To: gcc-bugs


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

--- Comment #4 from Václav Zeman <vhaisman at gmail dot com> 2013-01-08 15:00:09 UTC ---
I have fixed the Google doc sharing. It should be accessible now.

I am not sure if I can check GCC 4.7.2, I am using what Ubuntu provides as
package. I believe that MinGW cross compiler suite does not use the gold
linker.

As for the source reduction and flags, I will try those.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug lto/55902] lto1 SIGSEGV
  2013-01-07 19:50 [Bug lto/55902] New: lto1 SIGSEGV vhaisman at gmail dot com
                   ` (3 preceding siblings ...)
  2013-01-08 15:00 ` vhaisman at gmail dot com
@ 2013-01-08 18:27 ` vhaisman at gmail dot com
  2013-11-25 21:24 ` ktietz at gcc dot gnu.org
  2022-01-09  4:35 ` pinskia at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: vhaisman at gmail dot com @ 2013-01-08 18:27 UTC (permalink / raw)
  To: gcc-bugs


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

--- Comment #5 from Václav Zeman <vhaisman at gmail dot com> 2013-01-08 18:26:47 UTC ---
(In reply to comment #3)
> Does it only reproduce with -flto-partition=none?
Yes. Changing either the LTO partitioning algorithm or adding -r or -nostdlib
makes the error go away.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug lto/55902] lto1 SIGSEGV
  2013-01-07 19:50 [Bug lto/55902] New: lto1 SIGSEGV vhaisman at gmail dot com
                   ` (4 preceding siblings ...)
  2013-01-08 18:27 ` vhaisman at gmail dot com
@ 2013-11-25 21:24 ` ktietz at gcc dot gnu.org
  2022-01-09  4:35 ` pinskia at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: ktietz at gcc dot gnu.org @ 2013-11-25 21:24 UTC (permalink / raw)
  To: gcc-bugs

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

Kai Tietz <ktietz at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ktietz at gcc dot gnu.org

--- Comment #6 from Kai Tietz <ktietz at gcc dot gnu.org> ---
Gold isn't available for pe-coff targets.  Gold is ELF only.
You might want to check if you have same issues with HJ's *special* ld version.
 HJ's patched variant never got into upstream (AFAIK), but resolves a lot of
such issues.  Biggest problem here is mainly that LTO doesn't handle
object-files proper in linker.  By this crt-objects (startup and co) might
cause issues.
I learned that in some cases it was helpful to build mingw-w64's
startup-libraries with enabled -flto.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug lto/55902] lto1 SIGSEGV
  2013-01-07 19:50 [Bug lto/55902] New: lto1 SIGSEGV vhaisman at gmail dot com
                   ` (5 preceding siblings ...)
  2013-11-25 21:24 ` ktietz at gcc dot gnu.org
@ 2022-01-09  4:35 ` pinskia at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-01-09  4:35 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55902

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |INVALID
               Host|i686-w64-mingw32            |
             Status|WAITING                     |RESOLVED
              Build|x86_64-linux-gnu            |

--- Comment #7 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
The google drive link does not work any more. Plus there has been many
improvements to both ld and GCC with respect to LTO even for mingw. So closing
as invalid. Plus there is no way to test almost 9 year old bug.

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2022-01-09  4:35 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-01-07 19:50 [Bug lto/55902] New: lto1 SIGSEGV vhaisman at gmail dot com
2013-01-07 19:54 ` [Bug lto/55902] " vhaisman at gmail dot com
2013-01-07 20:19 ` vhaisman at gmail dot com
2013-01-08  9:49 ` rguenth at gcc dot gnu.org
2013-01-08 15:00 ` vhaisman at gmail dot com
2013-01-08 18:27 ` vhaisman at gmail dot com
2013-11-25 21:24 ` ktietz at gcc dot gnu.org
2022-01-09  4:35 ` pinskia at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).