To speed up file loading, and reduce memory usage, gdb will
bfd objects used to track open files. See BFD. The following commands
allow visibility and control of the caching behavior.
maint info bfds
bfdobject that is known to gdb.
maint set bfd-sharing
maint show bfd-sharing
bfdobjects can be shared. When sharing is enabled gdb reuses already open
bfdobjects rather than reopening the same file. Turning sharing off does not cause already shared
bfdobjects to be unshared, but all future files that are opened will create a new
bfdobject. Similarly, re-enabling sharing does not cause multiple existing
bfdobjects to be collapsed into a single shared
set debug bfd-cachelevel
show debug bfd-cache