Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 29 Nov 1997 12:36:19 +1100
From:      David Dawes <dawes@rf900.physics.usyd.edu.au>
To:        hackers@FreeBSD.ORG
Subject:   Re: Shared Libraries and debugging
Message-ID:  <19971129123619.61979@rf900.physics.usyd.edu.au>
In-Reply-To: <Pine.BSF.3.96.971127163806.28870A-100000@darkstar.home>; from Charles Mott on Thu, Nov 27, 1997 at 04:40:35PM -0700
References:  <199711272255.OAA18209@austin.polstra.com> <Pine.BSF.3.96.971127163806.28870A-100000@darkstar.home>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Nov 27, 1997 at 04:40:35PM -0700, Charles Mott wrote:
>On Thu, 27 Nov 1997, John Polstra wrote:
>> Judging by the cause of the problem, I doubt that it ever worked.  In
>> order to examine shared libraries, gdb needs to look at the dynamic
>> linker's table which records where they were loaded into memory.  The
>> dynamic linker has always recorded this information in a MAP_ANON
>> region way up high in the address space.  But such regions are not
>> written to the core file when a core dump occurs.  So gdb has not been
>> able to get the information it needs.
>
>So memory allocated with mmap() is not dumped in a core file?  Is this not
>possible or just not desirable?

Linux seems to (but then it uses ELF).  I've seen an unfortunate
side-effect of this on Linux when reading the mmapped MMIO area from a
Millennium while dumping an Xserver core file.  The result was a machine
lockup because reads from a part of the MMIO area can initiate a graphics
command.  We worked around this by unmapping when receiving a trapped
signal, but that doesn't help when signal trapping is turned off.

David



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19971129123619.61979>