public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/38269]  New: Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions
@ 2008-11-25 21:56 hackbunny at reactos dot com
  2008-11-25 21:57 ` [Bug c/38269] " hackbunny at reactos dot com
                   ` (5 more replies)
  0 siblings, 6 replies; 8+ messages in thread
From: hackbunny at reactos dot com @ 2008-11-25 21:56 UTC (permalink / raw)
  To: gcc-bugs

Save the attachments (pin.c and ntoskrnl.h) to the same directory. Then run the
following commands:

gcc -o ntoskrnl.h.gch -I. -fno-unit-at-a-time -Os ntoskrnl.h
gcc -v -o pin.o -I. -fno-unit-at-a-time -Os -c pin.c

The latter will print the following:

Using built-in specs.
Target: mingw32
Configured with: ../gcc-4.1.3/configure --prefix=/gcc-4.1.3 --with-gcc
--with-gnu-ld --with-gnu-as --host=mingw32 --target=mingw32 --build=mingw32
--enable-languages=c,c++ --enable-checking=release --enable-threads=win32
--disable-win32-registry --disable-nls --disable-shared
Thread model: win32
gcc version 4.1.3 20071015 (prerelease)
 c:/users/hyperion/rosbe/4.1.3/bin/../libexec/gcc/mingw32/4.1.3/cc1.exe -quiet
-v -I. -iprefix c:\users\hyperion\rosbe\4.1.3\bin\../lib/gcc/mingw32/4.1.3/
pin.c -quiet -dumpbase pin.c -auxbase-strip pin.o -Os -version
-fno-unit-at-a-time -o C:\Users\Hyperion\AppData\Local\Temp/ccphrNAF.s
ignoring nonexistent directory "C:/MSYS/gcc-4.1.3/include"
ignoring nonexistent directory "/gcc-4.1.3/include"
ignoring nonexistent directory
"C:/MSYS/gcc-4.1.3/lib/gcc/mingw32/4.1.3/include"
ignoring nonexistent directory "C:/MSYS/gcc-4.1.3/mingw32/include"
ignoring nonexistent directory "/mingw/include"
#include "..." search starts here:
#include <...> search starts here:
 .
 C:/Users/Hyperion/RosBE/4.1.3/include
 C:/Users/Hyperion/RosBE/4.1.3/lib/gcc/mingw32/4.1.3/include
 c:/users/hyperion/rosbe/4.1.3/bin/../lib/gcc/mingw32/4.1.3/include
End of search list.
GNU C version 4.1.3 20071015 (prerelease) (mingw32)
        compiled by GNU C version 4.1.3 20071015 (prerelease).
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: 3f527ff7c87fdc28aecf612037bc62b2


Very often (but not always), when executing the second command line, cc1.exe
will ICE with the following message:

ntoskrnl.h: In function 'ExAllocateFromNPagedLookasideList':
ntoskrnl.h:56: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.

I attached a debugger to cc1.exe, and resolved the symbols by hand to the
following call stack:

143e04  _main_block_label
143fa1  _cleanup_dead_labels
124461  _execute_cleanup_cfg_post_optimizing
11ed04  _execute_one_pass
11ee3b  _execute_pass_list
11ee4f  _execute_pass_list
1245fe  _tree_rest_of_compilation
09194   _c_expand_body
4eecb   _cgraph_expand_function
4efa9   _cgraph_assemble_pending_functions
50125   _cgraph_finalize_function
09573   _finish_function
3fd4e   _c_parser_declaration_or_fndef
4132e   _c_parser_external_declaration
41f1d   _c_gimplify_expr
305c4   _c_common_post_options
f84bc   _toplev_main
461f7   _main
0124b   ___mingw_CRTStartup
01298   _mainCRTStartup


Note that I'm forced to use -fno-unit-at-a-time because of an issue related to
PR 17982 and PR 38054


-- 
           Summary: Segmentation fault in main_block_label when using -fno-
                    unit-at-a-time and precompiled headers containing inline
                    functions
           Product: gcc
           Version: 4.1.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: hackbunny at reactos dot com
 GCC build triplet: mingw32
  GCC host triplet: mingw32
GCC target triplet: mingw32


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


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

* [Bug c/38269] Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions
  2008-11-25 21:56 [Bug c/38269] New: Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions hackbunny at reactos dot com
  2008-11-25 21:57 ` [Bug c/38269] " hackbunny at reactos dot com
@ 2008-11-25 21:57 ` hackbunny at reactos dot com
  2008-11-25 22:06 ` [Bug target/38269] " pinskia at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: hackbunny at reactos dot com @ 2008-11-25 21:57 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from hackbunny at reactos dot com  2008-11-25 21:56 -------
Created an attachment (id=16770)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16770&action=view)
test case (1 of 2)


-- 


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


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

* [Bug c/38269] Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions
  2008-11-25 21:56 [Bug c/38269] New: Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions hackbunny at reactos dot com
@ 2008-11-25 21:57 ` hackbunny at reactos dot com
  2008-11-25 21:57 ` hackbunny at reactos dot com
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: hackbunny at reactos dot com @ 2008-11-25 21:57 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from hackbunny at reactos dot com  2008-11-25 21:56 -------
Created an attachment (id=16771)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16771&action=view)
test case (2 of 2)


-- 


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


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

* [Bug target/38269] Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions
  2008-11-25 21:56 [Bug c/38269] New: Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions hackbunny at reactos dot com
  2008-11-25 21:57 ` [Bug c/38269] " hackbunny at reactos dot com
  2008-11-25 21:57 ` hackbunny at reactos dot com
@ 2008-11-25 22:06 ` pinskia at gcc dot gnu dot org
  2008-11-25 22:13 ` hackbunny at reactos dot com
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-11-25 22:06 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from pinskia at gcc dot gnu dot org  2008-11-25 22:04 -------
4.1.3 is old and no longer being maintained.  So can you try 4.2.3 or better
yet 4.3.2?


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |pinskia at gcc dot gnu dot
                   |                            |org
          Component|c                           |target


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


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

* [Bug target/38269] Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions
  2008-11-25 21:56 [Bug c/38269] New: Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions hackbunny at reactos dot com
                   ` (2 preceding siblings ...)
  2008-11-25 22:06 ` [Bug target/38269] " pinskia at gcc dot gnu dot org
@ 2008-11-25 22:13 ` hackbunny at reactos dot com
  2008-11-25 22:39 ` rguenth at gcc dot gnu dot org
  2008-11-26  0:01 ` d dot g dot gorbachev at gmail dot com
  5 siblings, 0 replies; 8+ messages in thread
From: hackbunny at reactos dot com @ 2008-11-25 22:13 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from hackbunny at reactos dot com  2008-11-25 22:12 -------
Yes and no, we are resisting upgrading due to PR 31707 (which we are attempting
to workaround, and the workaround led to this bug...). I will try ASAP anyway


-- 


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


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

* [Bug target/38269] Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions
  2008-11-25 21:56 [Bug c/38269] New: Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions hackbunny at reactos dot com
                   ` (3 preceding siblings ...)
  2008-11-25 22:13 ` hackbunny at reactos dot com
@ 2008-11-25 22:39 ` rguenth at gcc dot gnu dot org
  2008-11-26  0:01 ` d dot g dot gorbachev at gmail dot com
  5 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2008-11-25 22:39 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from rguenth at gcc dot gnu dot org  2008-11-25 22:38 -------
Then do not use PCH.  Seriously, this is not going to be fixed unless you
provide a patch ;)  Rather I hope we will end up removing the current PCH
implementation.


-- 


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


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

* [Bug target/38269] Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions
  2008-11-25 21:56 [Bug c/38269] New: Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions hackbunny at reactos dot com
                   ` (4 preceding siblings ...)
  2008-11-25 22:39 ` rguenth at gcc dot gnu dot org
@ 2008-11-26  0:01 ` d dot g dot gorbachev at gmail dot com
  5 siblings, 0 replies; 8+ messages in thread
From: d dot g dot gorbachev at gmail dot com @ 2008-11-26  0:01 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from d dot g dot gorbachev at gmail dot com  2008-11-26 00:00 -------
GCC 4.3.2 failed to compile the testcase with "internal compiler error: in
copy_phis_for_bb, at tree-inline.c:1227" or "internal compiler error: in
gimplify_expr, at gimplify.c:6146" message.

GCC 4.4.0 works.


-- 


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


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

* [Bug target/38269] Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions
       [not found] <bug-38269-4@http.gcc.gnu.org/bugzilla/>
@ 2012-12-10 11:32 ` ktietz at gcc dot gnu.org
  0 siblings, 0 replies; 8+ messages in thread
From: ktietz at gcc dot gnu.org @ 2012-12-10 11:32 UTC (permalink / raw)
  To: gcc-bugs


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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |WONTFIX
      Known to fail|                            |

--- Comment #7 from Kai Tietz <ktietz at gcc dot gnu.org> 2012-12-10 11:31:19 UTC ---
The 4.3 gcc version is no longer maintained.  As this issue was fixed already
with 4.4 I close this bug as wontfix


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

end of thread, other threads:[~2012-12-10 11:32 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-11-25 21:56 [Bug c/38269] New: Segmentation fault in main_block_label when using -fno-unit-at-a-time and precompiled headers containing inline functions hackbunny at reactos dot com
2008-11-25 21:57 ` [Bug c/38269] " hackbunny at reactos dot com
2008-11-25 21:57 ` hackbunny at reactos dot com
2008-11-25 22:06 ` [Bug target/38269] " pinskia at gcc dot gnu dot org
2008-11-25 22:13 ` hackbunny at reactos dot com
2008-11-25 22:39 ` rguenth at gcc dot gnu dot org
2008-11-26  0:01 ` d dot g dot gorbachev at gmail dot com
     [not found] <bug-38269-4@http.gcc.gnu.org/bugzilla/>
2012-12-10 11:32 ` ktietz 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).