This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
bfd cache control
- To: binutils at sources dot redhat dot com
- Subject: bfd cache control
- From: "Frank Ch. Eigler" <fche at redhat dot com>
- Date: Tue, 24 Apr 2001 12:13:14 -0400
Hi -
On some hosts, there is a need to occasionally force the flushing
of the bfd file-descriptor cache. An example is a long-running
interactive program like gdb or a simulator operating on a given
executable. These programs don't constantly need to make bfd
calls after an initialization stage, but hang on to a bfd*
anyway. During extended periods, the bfd file-descriptor cache
can keep unused open file descriptors on these files.
Other than resource conservation, this has some other problems.
e.g., on Windows keeping files open can lock them against writes
by other programs.
gdbtk uses calls to the bfd_cache_close() internal routine to
close some file handles fairly frequently. It looks like we need
to do the same thing in simulators. Can we export this function
properly, or else make a new broader "bfd_cache_flush()" call?
Any other suggestions (short of getting the bfd apps to stop
hanging on to bfd* for so long)?
- FChE
PGP signature