* RE: Determining base address of shared library from core file
@ 2004-07-26 21:15 Bloch, Jack
2004-07-27 22:06 ` Kevin Buettner
0 siblings, 1 reply; 10+ messages in thread
From: Bloch, Jack @ 2004-07-26 21:15 UTC (permalink / raw)
To: 'Kevin Buettner'; +Cc: gdb
BTW, if I run readelf -d on my executable, it show a debug segment with a
0x0. I don't have to load the executable into memory somehow do I?
-----Original Message-----
From: Kevin Buettner [mailto:kevinb@redhat.com]
Sent: Wednesday, July 21, 2004 1:53 PM
To: Bloch, Jack
Cc: gdb@sources.redhat.com
Subject: Re: Determining base address of shared library from core file
On Mon, 19 Jul 2004 07:51:31 -0700
"Bloch, Jack" <Jack.Bloch@icn.siemens.com> wrote:
> Is there an easy way to determine the base address of a shared library
from
> a core file?
It depends upon what you mean by "easy".
For an SVR4-like system (which includes Linux), you have to traverse
the dynamic section to find the address of the r_debug struct. Once
that is done, you still have to traverse the link_map structs to find
the desired address. See solib-svr4.c for the gory details.
(IMO, this isn't very easy.)
Kevin
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Determining base address of shared library from core file
2004-07-26 21:15 Determining base address of shared library from core file Bloch, Jack
@ 2004-07-27 22:06 ` Kevin Buettner
2004-08-11 0:02 ` internal-error: arm_elf_osabi_sniffer Nagender Telkar
0 siblings, 1 reply; 10+ messages in thread
From: Kevin Buettner @ 2004-07-27 22:06 UTC (permalink / raw)
To: Bloch, Jack; +Cc: gdb
On Mon, 26 Jul 2004 14:13:40 -0700
"Bloch, Jack" <jack.bloch@siemens.com> wrote:
> BTW, if I run readelf -d on my executable, it show a debug segment with a
> 0x0. I don't have to load the executable into memory somehow do I?
Yes, you have to fetch the dynamic section from the loaded process and
scan it instead of the contents of the executable. The dynamic linker
will have adjusted the in-memory copy of the dynamic section to contain
values relevant to the running process.
Kevin
^ permalink raw reply [flat|nested] 10+ messages in thread
* internal-error: arm_elf_osabi_sniffer
2004-07-27 22:06 ` Kevin Buettner
@ 2004-08-11 0:02 ` Nagender Telkar
2004-08-11 7:38 ` Monika Chaddha
0 siblings, 1 reply; 10+ messages in thread
From: Nagender Telkar @ 2004-08-11 0:02 UTC (permalink / raw)
To: gdb
Hello All,
When I try to run arm-elf-gdb on an elf file, I get the following
error message. Can someone tell me where do I start looking into to
solve the problem.
Thank you,
Nagender
GNU gdb 6.0
Copyright 2003 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=i686-pc-cygwin --target=arm-elf"...
../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error: arm_elf_osabi_sniffer
: Unknown ARM EABI version 0x4000000
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Quit this debugging session? (y or n) y
../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error: arm_elf_osabi_sniffer
: Unknown ARM EABI version 0x4000000
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Create a core file of GDB? (y or n) y
Aborted (core dumped)
^ permalink raw reply [flat|nested] 10+ messages in thread
* RE: internal-error: arm_elf_osabi_sniffer
2004-08-11 0:02 ` internal-error: arm_elf_osabi_sniffer Nagender Telkar
@ 2004-08-11 7:38 ` Monika Chaddha
2004-08-11 20:45 ` Nagender Telkar
0 siblings, 1 reply; 10+ messages in thread
From: Monika Chaddha @ 2004-08-11 7:38 UTC (permalink / raw)
To: 'Nagender Telkar'; +Cc: gdb
It's already showing the line no as
>../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error:
Also Search the error messages in source you are getting and find out
the reason of printing of these error messages.
I hope this approach will help u...
Monika
>-----Original Message-----
>From: gdb-owner@sources.redhat.com
[mailto:gdb-owner@sources.redhat.com] On
>Behalf Of Nagender Telkar
>Sent: Wednesday, August 11, 2004 5:32 AM
>To: gdb@sources.redhat.com
>Subject: internal-error: arm_elf_osabi_sniffer
>
>Hello All,
>
>When I try to run arm-elf-gdb on an elf file, I get the following
>error message. Can someone tell me where do I start looking into to
>solve the problem.
>
>Thank you,
>Nagender
>
>GNU gdb 6.0
>Copyright 2003 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=i686-pc-cygwin --target=arm-elf"...
>../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error:
>arm_elf_osabi_sniffer
>: Unknown ARM EABI version 0x4000000
>A problem internal to GDB has been detected,
>further debugging may prove unreliable.
>Quit this debugging session? (y or n) y
>
>../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error:
>arm_elf_osabi_sniffer
>: Unknown ARM EABI version 0x4000000
>A problem internal to GDB has been detected,
>further debugging may prove unreliable.
>Create a core file of GDB? (y or n) y
>Aborted (core dumped)
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: internal-error: arm_elf_osabi_sniffer
2004-08-11 7:38 ` Monika Chaddha
@ 2004-08-11 20:45 ` Nagender Telkar
2004-08-11 21:45 ` Richard Earnshaw
0 siblings, 1 reply; 10+ messages in thread
From: Nagender Telkar @ 2004-08-11 20:45 UTC (permalink / raw)
To: gdb; +Cc: Monika Chaddha
Hello,
I am working on gdb 6.0.
When I do an
gdb> arm-elf-gdb helloworld.elf
I get the following error.
../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error: arm_elf_osabi_sniffer
: Unknown ARM EABI version 0x4000000
I looked into the arm-tdep file in the gdb, it seems to be failing at
the function
static enum gdb_osabi arm_elf_osabi_sniffer (bfd *abfd)
where it gets
unsgined int elfosabi = elf_elfheader (abfd)->e_ident[EI_OSABI];
The elfosabi is getting set to ELFOSABI_NONE.
Then it tries to get the eflags as
eflags = EF_ARM_EABI_VERSION(elf_elfheader(abfd)->e_flags);
eflags is not getting set to EF_ARM_EABI_VER1, EF_ARM_EABI_VER2 or
EF_ARM_EABI_UNKNOWN.
I think that is the problem. Thats the reason it gets to the internal error.
Can anyone throw some light on the issue.
Thank you,
Nagender
On Wed, 11 Aug 2004 13:01:17 +0530, Monika Chaddha <monika@acmet.com> wrote:
> It's already showing the line no as
>
> >../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error:
>
> Also Search the error messages in source you are getting and find out
> the reason of printing of these error messages.
>
> I hope this approach will help u...
>
> Monika
>
>
>
> >-----Original Message-----
> >From: gdb-owner@sources.redhat.com
> [mailto:gdb-owner@sources.redhat.com] On
> >Behalf Of Nagender Telkar
> >Sent: Wednesday, August 11, 2004 5:32 AM
> >To: gdb@sources.redhat.com
> >Subject: internal-error: arm_elf_osabi_sniffer
> >
> >Hello All,
> >
> >When I try to run arm-elf-gdb on an elf file, I get the following
> >error message. Can someone tell me where do I start looking into to
> >solve the problem.
> >
> >Thank you,
> >Nagender
> >
> >GNU gdb 6.0
> >Copyright 2003 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=i686-pc-cygwin --target=arm-elf"...
> >../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error:
> >arm_elf_osabi_sniffer
> >: Unknown ARM EABI version 0x4000000
> >A problem internal to GDB has been detected,
> >further debugging may prove unreliable.
> >Quit this debugging session? (y or n) y
> >
> >../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error:
> >arm_elf_osabi_sniffer
> >: Unknown ARM EABI version 0x4000000
> >A problem internal to GDB has been detected,
> >further debugging may prove unreliable.
> >Create a core file of GDB? (y or n) y
> >Aborted (core dumped)
>
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: internal-error: arm_elf_osabi_sniffer
2004-08-11 20:45 ` Nagender Telkar
@ 2004-08-11 21:45 ` Richard Earnshaw
2004-08-11 21:50 ` Nagender Telkar
0 siblings, 1 reply; 10+ messages in thread
From: Richard Earnshaw @ 2004-08-11 21:45 UTC (permalink / raw)
To: Nagender Telkar; +Cc: gdb, Monika Chaddha
On Wed, 2004-08-11 at 21:45, Nagender Telkar wrote:
> Hello,
>
> I am working on gdb 6.0.
>
> When I do an
>
> gdb> arm-elf-gdb helloworld.elf
>
> I get the following error.
>
> ../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error: arm_elf_osabi_sniffer
> : Unknown ARM EABI version 0x4000000
>
You don't say so, but I guess you are compiling your code with ARM's
RVDS compiler...
> I looked into the arm-tdep file in the gdb, it seems to be failing at
> the function
>
> static enum gdb_osabi arm_elf_osabi_sniffer (bfd *abfd)
>
> where it gets
>
> unsgined int elfosabi = elf_elfheader (abfd)->e_ident[EI_OSABI];
>
> The elfosabi is getting set to ELFOSABI_NONE.
>
> Then it tries to get the eflags as
>
> eflags = EF_ARM_EABI_VERSION(elf_elfheader(abfd)->e_flags);
>
> eflags is not getting set to EF_ARM_EABI_VER1, EF_ARM_EABI_VER2 or
> EF_ARM_EABI_UNKNOWN.
>
> I think that is the problem. Thats the reason it gets to the internal error.
Yep. GDB doesn't understand the EABI yet (even gdb 6.2 -- gdb 6.0
predates the EABI, so has no chance). Even if it got past this point
you'd run into further problems.
R.
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: internal-error: arm_elf_osabi_sniffer
2004-08-11 21:45 ` Richard Earnshaw
@ 2004-08-11 21:50 ` Nagender Telkar
2004-08-11 21:54 ` Richard Earnshaw
0 siblings, 1 reply; 10+ messages in thread
From: Nagender Telkar @ 2004-08-11 21:50 UTC (permalink / raw)
To: Richard Earnshaw; +Cc: gdb, Monika Chaddha
Hello
I was compiling my code with RVCT compiler from ARM. I had my debugger
working at assembly level with ADS1.2. Now, I want it to do the same
for RVCT compiled code.
Can it not happen?
Thank you,
Nagender
On Wed, 11 Aug 2004 22:43:12 +0100, Richard Earnshaw
<rearnsha@gcc.gnu.org> wrote:
> On Wed, 2004-08-11 at 21:45, Nagender Telkar wrote:
> > Hello,
> >
> > I am working on gdb 6.0.
> >
> > When I do an
> >
> > gdb> arm-elf-gdb helloworld.elf
> >
> > I get the following error.
> >
> > ../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error: arm_elf_osabi_sniffer
> > : Unknown ARM EABI version 0x4000000
> >
> You don't say so, but I guess you are compiling your code with ARM's
> RVDS compiler...
>
> > I looked into the arm-tdep file in the gdb, it seems to be failing at
> > the function
> >
> > static enum gdb_osabi arm_elf_osabi_sniffer (bfd *abfd)
> >
> > where it gets
> >
> > unsgined int elfosabi = elf_elfheader (abfd)->e_ident[EI_OSABI];
> >
> > The elfosabi is getting set to ELFOSABI_NONE.
> >
> > Then it tries to get the eflags as
> >
> > eflags = EF_ARM_EABI_VERSION(elf_elfheader(abfd)->e_flags);
> >
> > eflags is not getting set to EF_ARM_EABI_VER1, EF_ARM_EABI_VER2 or
> > EF_ARM_EABI_UNKNOWN.
> >
> > I think that is the problem. Thats the reason it gets to the internal error.
>
> Yep. GDB doesn't understand the EABI yet (even gdb 6.2 -- gdb 6.0
> predates the EABI, so has no chance). Even if it got past this point
> you'd run into further problems.
>
> R.
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: internal-error: arm_elf_osabi_sniffer
2004-08-11 21:50 ` Nagender Telkar
@ 2004-08-11 21:54 ` Richard Earnshaw
2004-08-11 22:19 ` Nagender Telkar
0 siblings, 1 reply; 10+ messages in thread
From: Richard Earnshaw @ 2004-08-11 21:54 UTC (permalink / raw)
To: Nagender Telkar; +Cc: gdb, Monika Chaddha
On Wed, 2004-08-11 at 22:50, Nagender Telkar wrote:
> Hello
>
> I was compiling my code with RVCT compiler from ARM. I had my debugger
> working at assembly level with ADS1.2. Now, I want it to do the same
> for RVCT compiled code.
>
> Can it not happen?
>
Not yet. Somebody's got to add support for the new ABI, and until GCC
has it (that' getting there) there isn't as much pressure for updating
GDB.
GDB is primarily a debugger for debugging GCC generated code, support
for other compilers tends to come second.
R.
> Thank you,
> Nagender
>
> On Wed, 11 Aug 2004 22:43:12 +0100, Richard Earnshaw
> <rearnsha@gcc.gnu.org> wrote:
> > On Wed, 2004-08-11 at 21:45, Nagender Telkar wrote:
> > > Hello,
> > >
> > > I am working on gdb 6.0.
> > >
> > > When I do an
> > >
> > > gdb> arm-elf-gdb helloworld.elf
> > >
> > > I get the following error.
> > >
> > > ../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error: arm_elf_osabi_sniffer
> > > : Unknown ARM EABI version 0x4000000
> > >
> > You don't say so, but I guess you are compiling your code with ARM's
> > RVDS compiler...
> >
> > > I looked into the arm-tdep file in the gdb, it seems to be failing at
> > > the function
> > >
> > > static enum gdb_osabi arm_elf_osabi_sniffer (bfd *abfd)
> > >
> > > where it gets
> > >
> > > unsgined int elfosabi = elf_elfheader (abfd)->e_ident[EI_OSABI];
> > >
> > > The elfosabi is getting set to ELFOSABI_NONE.
> > >
> > > Then it tries to get the eflags as
> > >
> > > eflags = EF_ARM_EABI_VERSION(elf_elfheader(abfd)->e_flags);
> > >
> > > eflags is not getting set to EF_ARM_EABI_VER1, EF_ARM_EABI_VER2 or
> > > EF_ARM_EABI_UNKNOWN.
> > >
> > > I think that is the problem. Thats the reason it gets to the internal error.
> >
> > Yep. GDB doesn't understand the EABI yet (even gdb 6.2 -- gdb 6.0
> > predates the EABI, so has no chance). Even if it got past this point
> > you'd run into further problems.
> >
> > R.
> >
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: internal-error: arm_elf_osabi_sniffer
2004-08-11 21:54 ` Richard Earnshaw
@ 2004-08-11 22:19 ` Nagender Telkar
2004-08-11 22:32 ` Richard Earnshaw
0 siblings, 1 reply; 10+ messages in thread
From: Nagender Telkar @ 2004-08-11 22:19 UTC (permalink / raw)
To: Richard Earnshaw; +Cc: gdb
Where can I get more information about what ABI stuff is all about,
and why was the ADS1.2 compiled code working with the gdb and RVCT
compiled code not.
Thank you,
Nagender
On Wed, 11 Aug 2004 22:54:13 +0100, Richard Earnshaw
<rearnsha@gcc.gnu.org> wrote:
> On Wed, 2004-08-11 at 22:50, Nagender Telkar wrote:
> > Hello
> >
> > I was compiling my code with RVCT compiler from ARM. I had my debugger
> > working at assembly level with ADS1.2. Now, I want it to do the same
> > for RVCT compiled code.
> >
> > Can it not happen?
> >
>
> Not yet. Somebody's got to add support for the new ABI, and until GCC
> has it (that' getting there) there isn't as much pressure for updating
> GDB.
>
> GDB is primarily a debugger for debugging GCC generated code, support
> for other compilers tends to come second.
>
> R.
>
>
> > Thank you,
> > Nagender
> >
> > On Wed, 11 Aug 2004 22:43:12 +0100, Richard Earnshaw
> > <rearnsha@gcc.gnu.org> wrote:
> > > On Wed, 2004-08-11 at 21:45, Nagender Telkar wrote:
> > > > Hello,
> > > >
> > > > I am working on gdb 6.0.
> > > >
> > > > When I do an
> > > >
> > > > gdb> arm-elf-gdb helloworld.elf
> > > >
> > > > I get the following error.
> > > >
> > > > ../../insight-6.0.ori/gdb/arm-tdep.c:2747: internal-error: arm_elf_osabi_sniffer
> > > > : Unknown ARM EABI version 0x4000000
> > > >
> > > You don't say so, but I guess you are compiling your code with ARM's
> > > RVDS compiler...
> > >
> > > > I looked into the arm-tdep file in the gdb, it seems to be failing at
> > > > the function
> > > >
> > > > static enum gdb_osabi arm_elf_osabi_sniffer (bfd *abfd)
> > > >
> > > > where it gets
> > > >
> > > > unsgined int elfosabi = elf_elfheader (abfd)->e_ident[EI_OSABI];
> > > >
> > > > The elfosabi is getting set to ELFOSABI_NONE.
> > > >
> > > > Then it tries to get the eflags as
> > > >
> > > > eflags = EF_ARM_EABI_VERSION(elf_elfheader(abfd)->e_flags);
> > > >
> > > > eflags is not getting set to EF_ARM_EABI_VER1, EF_ARM_EABI_VER2 or
> > > > EF_ARM_EABI_UNKNOWN.
> > > >
> > > > I think that is the problem. Thats the reason it gets to the internal error.
> > >
> > > Yep. GDB doesn't understand the EABI yet (even gdb 6.2 -- gdb 6.0
> > > predates the EABI, so has no chance). Even if it got past this point
> > > you'd run into further problems.
> > >
> > > R.
> > >
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: internal-error: arm_elf_osabi_sniffer
2004-08-11 22:19 ` Nagender Telkar
@ 2004-08-11 22:32 ` Richard Earnshaw
0 siblings, 0 replies; 10+ messages in thread
From: Richard Earnshaw @ 2004-08-11 22:32 UTC (permalink / raw)
To: Nagender Telkar; +Cc: gdb
On Wed, 2004-08-11 at 23:19, Nagender Telkar wrote:
> Where can I get more information about what ABI stuff is all about,
> and why was the ADS1.2 compiled code working with the gdb and RVCT
> compiled code not.
>
http://www.arm.com/products/DevTools/ABI.html
Describes the AAPCS implemented by RVCT.
Other documents on the Net describe the ATPCS as implemented by ADS1.2
R.
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2004-08-11 22:32 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-07-26 21:15 Determining base address of shared library from core file Bloch, Jack
2004-07-27 22:06 ` Kevin Buettner
2004-08-11 0:02 ` internal-error: arm_elf_osabi_sniffer Nagender Telkar
2004-08-11 7:38 ` Monika Chaddha
2004-08-11 20:45 ` Nagender Telkar
2004-08-11 21:45 ` Richard Earnshaw
2004-08-11 21:50 ` Nagender Telkar
2004-08-11 21:54 ` Richard Earnshaw
2004-08-11 22:19 ` Nagender Telkar
2004-08-11 22:32 ` Richard Earnshaw
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).