http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52999
Bug #: 52999
Summary: [4.7, 4.8 Regression] ICE, segmentation fault in
c_tree_printer
Classification: Unclassified
Product: gcc
Version: 4.8.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: other
AssignedTo: [email protected]
ReportedBy: [email protected]
Host: hppa-unknown-linux-gnu
Target: hppa-unknown-linux-gnu
Build: hppa-unknown-linux-gnu
Created attachment 27162
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=27162
Compressed rtld.i file
(gdb) r
Starting program: /home/dave/gnu/gcc/objdir/gcc/cc1 -fpreprocessed rtld.i
-quiet -dumpbase rtld.i -auxbase rtld -O2 -Wall -Winline -Wwrite-strings
-Wstrict-prototypes -std=gnu99 -version -fgnu89-inline -fmerge-all-constants
-fno-stack-protector -fPIC -o xx.s
GNU C (GCC) version 4.8.0 20120412 (experimental) [trunk revision 186378]
(hppa-linux-gnu)
compiled by GNU C version 4.8.0 20120412 (experimental) [trunk revision
186378], GMP version 5.0.4, MPFR version 3.1.0-p3, MPC version 0.9
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
GNU C (GCC) version 4.8.0 20120412 (experimental) [trunk revision 186378]
(hppa-linux-gnu)
compiled by GNU C version 4.8.0 20120412 (experimental) [trunk revision
186378], GMP version 5.0.4, MPFR version 3.1.0-p3, MPC version 0.9
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
Compiler executable checksum: d431a91d532955514383649751f02954
rtld.c: In function ‘dl_main’:
rtld.c:937:3: warning: implicit declaration of function
‘__canonicalize_funcptr_for_compare’ [-Wimplicit-function-declaration]
Program received signal SIGSEGV, Segmentation fault.
c_tree_printer (hash=false, set_locus=false, spec=0xa919b0 "D",
text=0xfdf02608, pp=0xab7228, precision=<optimized out>,
wide=<optimized out>) at ../../gcc/gcc/c-objc-common.c:116
116 if (DECL_DEBUG_EXPR_IS_FROM (t) && DECL_DEBUG_EXPR (t))
(gdb) bt
#0 c_tree_printer (hash=false, set_locus=false, spec=0xa919b0 "D",
text=0xfdf02608, pp=0xab7228, precision=<optimized out>,
wide=<optimized out>) at ../../gcc/gcc/c-objc-common.c:116
#1 c_tree_printer (pp=0xab7228, text=0xfdf02608, spec=0xa919b0 "D",
precision=0, wide=false, set_locus=false, hash=false)
at ../../gcc/gcc/c-objc-common.c:89
#2 0x0089b42c in pp_base_format (pp=0xab7228, text=0xfdf02608)
at ../../gcc/gcc/pretty-print.c:509
#3 0x00899730 in diagnostic_report_diagnostic (context=0xa917b4,
diagnostic=0xfdf02708) at ../../gcc/gcc/diagnostic.c:644
#4 0x00899ba0 in error (gmsgid=<optimized out>)
at ../../gcc/gcc/diagnostic.c:857
#5 0x0075b994 in get_section (name=0xa919b0 "D", flags=<optimized out>,
decl=<optimized out>) at ../../gcc/gcc/varasm.c:318
#6 0x0076fbf4 in varpool_assemble_pending_decls ()
at ../../gcc/gcc/varpool.c:653
#7 varpool_assemble_pending_decls () at ../../gcc/gcc/varpool.c:638
#8 0x001e6464 in cgraph_optimize () at ../../gcc/gcc/cgraphunit.c:2637
#9 0x001e6b20 in cgraph_finalize_compilation_unit ()
at ../../gcc/gcc/cgraphunit.c:2720
#10 0x000be150 in c_write_global_declarations ()
at ../../gcc/gcc/c-decl.c:10053
#11 0x0050fdec in compile_file () at ../../gcc/gcc/toplev.c:572
(gdb) p t
$1 = (tree) 0x0
4.6 successfully generates section conflict error message.