This commit was generated by cvs2svn to track changes on a CVS vendor
[external/binutils.git] / bfd / TODO
1 Things that still need to be handled: -*- Text -*-
2
3  o - check all the swapping code.
4  o - change the memory usage to reflect the message which follows the
5      page break.
6  o - implement bfd_abort, which should close the bfd but not alter the
7      filesystem.
8  o - remove the following obsolete functions:
9          bfd_symbol_value
10          bfd_symbol_name
11          bfd_get_first_symbol
12          bfd_get_next_symbol
13          bfd_classify_symbol
14          bfd_symbol_hasclass
15  o - update the bfd doc; write a how-to-write-a-backend doc.
16  o - change reloc handling as per Steve's suggestion.
17
18 \f
19 Changing the way bfd uses memory.  The new convention is simple: 
20
21  o - bfd will never write into user-supplied memory, nor attempt to
22      free it.
23  o - closing a bfd may reclaim all bfd-allocated memory associated
24      with that bfd.
25  - - bfd_target_list will be the one exception; you must reclaim the
26      returned vector yourself.
27
28 Interface implications are minor (get_symcount_upper_bound will go
29 away; bfd_cannicalize_symtab will allocate its own memory, etc).
30
31 Certain operations consume a lot of memory; for them manual
32 reclaimation is available:
33
34  o - bfd_canonicalize_symtab will return a pointer to a
35      null-terminated vector of symbols.  Subsequent calls may or may
36      not return the same pointer.
37      bfd_canonicalize_relocs will do the same; returning a pointer to
38      an array of arelocs.  Calling this function will read symbols in
39      too.
40
41  o - bfd_reclaim_relocs will free the memory used by these relocs.
42      the symbols will be untouched.
43      bfd_reclaim_symtab (ne bfd_reclaim_symbol_table) will free the
44      memory allocated by canonialize_symtab.  
45      Since relocations point to symbols, any relocations obtained by a
46      call to bfd_canonicalize_relocs will be reclaimed as well.
47
48  o - if you don't call the reclaim_ functions, the memory will be
49      reclaimed at bfd_close time.