This is the mail archive of the gdb@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: gdb for target mn10300 not working


Dany Ravikovitch wrote:

> GNU gdb 5.0
> Copyright 2000 Free Software Foundation, Inc.
> GDB is free software, covered by the GNU General Public License, and you
> 
> are
> welcome to change it and/or distribute copies of it under certain
> conditions.
> Type "show copying" to see the conditions.
> There is absolutely no warranty for GDB.  Type "show warranty" for
> details.
> This GDB was configured as "--host=i386-cygwin32
> --target=mn10300-elf"...
> (gdb) msim
> Undefined command: "msim".  Try "help".
> (gdb) target sim
> Connected to the simulator.

Try:

(gdb) target sim --trace

also try:

(gdb) target sim --board=stdeval1

I'm not sure where your program comes from but it may assume that the
system is emulating a generic hardware platform.

> (gdb) load
> Loading section .rom_vectors, size 0xc0 lma 0x40000000
> Loading section .text, size 0x2ffa lma 0x400000c0
> Loading section .rodata, size 0x432 lma 0x400030ba
> Loading section .data, size 0x18c lma 0x400034ec
> Start address 0x40000000
> Transfer rate: 111552 bits in <1 sec.
> (gdb) run
> Starting program: /D/Program Files/Cygnus
> Solutions/eCos_121/prebuilt/v1_2_1/mn1
> 0300-stdeval1-rom/tests/kernel/thread_gdb.exe
> mn10300-core: 2 byte write to unmapped address 0x32000020 at 0x400000c3
> mn10300-core: 4 byte write to unmapped address 0xfffffffc at 0x400000c3
> ERROR: recursion in program_interrupt during software exception
> dispatch.
> Program received signal SIGSEGV, Segmentation fault.
> 0x400000c3 in start ()
> (gdb)

Set a breakpoint at _start:

	(gdb) break *_start

and then stepi from there.    I think it is doing something illegal,
generating a trap and then the trap handler is traping in turn.

	Andrew

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]