debugging internal compiler errors ...
kevin diggs
diggskevin38@gmail.com
Sat Apr 16 20:32:00 GMT 2011
Hi,
Using:
gdb --args ../..//gcc/cc1 -fpreprocessed libgcc2.i -dumpbase libgcc2.c
-m68020 -auxbase-strip _fixunsxfdi.o -g -O1 -W -Wall -Wwrite-strings
-Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition
-version -fomit-frame-pointer -fPIC -fvisibility=hidden -o libgcc2.s
where gives:
(gdb) where
#0 0x08174348 in assign_temp ()
#1 0x09a6ef9d in ?? ()
#2 0xb7370ca0 in ?? ()
#3 0xbf900f98 in ?? ()
#4 0x08344bcc in assemble_name_raw ()
#5 0xb745f200 in ?? ()
#6 0x00000004 in ?? ()
#7 0xb745f240 in ?? ()
#8 0x08143d0c in emit_push_insn ()
#9 0x00000007 in ?? ()
#10 0x099f0fb8 in ?? ()
#11 0x00000007 in ?? ()
#12 0x0834739a in default_globalize_label ()
#13 0x09a6ef9d in ?? ()
#14 0x00000008 in ?? ()
#15 0x099f0fb8 in ?? ()
#16 0x00000010 in ?? ()
#17 0x00000010 in ?? ()
#18 0x00000001 in ?? ()
#19 0x0822d5fc in default_external_libcall ()
#20 0x00000001 in ?? ()
#21 0x09a6ef9d in ?? ()
#22 0x00000000 in ?? ()
I was kinda hoping for ... more help from gdb???
Unless someone tells me to be quiet, I'm gonna post what I find out so
that someone who like, ya know, knows what they are doing can provide
some tips.
This is usually a problem in the machine description ... right?
I built the compiler with -O1. Why can't gdb find the source? What did
I mess up?
Thanks!
(gdb) run
Starting program: /home/kevdig/projects/GCC/obj-gcc-4.3.5-m68k/gcc/cc1
-fpreprocessed libgcc2.i -dumpbase libgcc2.c -m68020 -auxbase-strip
_fixunsxfdi.o -g -O1 -W -Wall -Wwrite-strings -Wstrict-prototypes
-Wmissing-prototypes -Wold-style-definition -version
-fomit-frame-pointer -fPIC -fvisibility=hidden -o libgcc2.s
Breakpoint 1, 0x080a43f0 in main ()
Current language: auto; currently asm
(gdb) cont
Continuing.
GNU C (GCC) version 4.3.5 (m68k-netbsdelf1.6.1)
compiled by GNU C version 4.3.2, GMP version 4.3.2, MPFR version 2.4.2.
warning: GMP header version 4.3.2 differs from library version 4.2.2.
warning: MPFR header version 2.4.2 differs from library version 2.3.1.
GGC heuristics: --param ggc-min-expand=42 --param ggc-min-heapsize=23783
options passed: -fpreprocessed libgcc2.i -m68020 -auxbase-strip
_fixunsxfdi.o -g -O1 -W -Wall -Wwrite-strings -Wstrict-prototypes
-Wmissing-prototypes -Wold-style-definition -fomit-frame-pointer -fPIC
-fvisibility=hidden
options enabled: -fPIC -falign-loops -fargument-alias -fauto-inc-dec
-fbranch-count-reg -fcommon -fcprop-registers -fdefer-pop -fearly-inlining
-feliminate-unused-debug-types -fgcse-lm -fguess-branch-probability
-fident -fif-conversion -fif-conversion2 -finline-functions-called-once
-fipa-pure-const -fipa-reference -fivopts -fkeep-static-consts
-fleading-underscore -fmath-errno -fmerge-constants -fmerge-debug-strings
-fmove-loop-invariants -fomit-frame-pointer -fpcc-struct-return -fpeephole
-fsched-interblock -fsched-spec -fsched-stalled-insns-dep -fsigned-zeros
-fsplit-ivs-in-unroller -fsplit-wide-types -ftoplevel-reorder
-ftrapping-math -ftree-ccp -ftree-ch -ftree-copy-prop -ftree-copyrename
-ftree-cselim -ftree-dce -ftree-dominator-opts -ftree-dse -ftree-fre
-ftree-loop-im -ftree-loop-ivcanon -ftree-loop-optimize
-ftree-parallelize-loops= -ftree-reassoc -ftree-salias -ftree-scev-cprop
-ftree-sink -ftree-sra -ftree-ter -ftree-vect-loop-version
-funit-at-a-time -fvar-tracking -fzero-initialized-in-bss -mbitfield
-mstrict-align
Compiler executable checksum: 42170c5b540153f5417c72cb34ea4001
__sputc __byte_swap_word __byte_swap_long __fixunsxfdi
Analyzing compilation unit
Performing interprocedural optimizations
<visibility> <early_local_cleanups> <inline> <static-var>
<pure-const>Assembling functions:
__fixunsxfdi
Program received signal SIGSEGV, Segmentation fault.
0x08174348 in assign_temp ()
More information about the Gcc-help
mailing list