xref: /dflybsd-src/contrib/gdb-7/gdb/xcoffsolib.h (revision de8e141f24382815c10a4012d209bbbf7abf1112)
15796c8dcSSimon Schubert /* Data structures for RS/6000 shared libraries, for GDB.
2*ef5ccd6cSJohn Marino    Copyright (C) 1991-2013 Free Software Foundation, Inc.
35796c8dcSSimon Schubert 
45796c8dcSSimon Schubert    This file is part of GDB.
55796c8dcSSimon Schubert 
65796c8dcSSimon Schubert    This program is free software; you can redistribute it and/or modify
75796c8dcSSimon Schubert    it under the terms of the GNU General Public License as published by
85796c8dcSSimon Schubert    the Free Software Foundation; either version 3 of the License, or
95796c8dcSSimon Schubert    (at your option) any later version.
105796c8dcSSimon Schubert 
115796c8dcSSimon Schubert    This program is distributed in the hope that it will be useful,
125796c8dcSSimon Schubert    but WITHOUT ANY WARRANTY; without even the implied warranty of
135796c8dcSSimon Schubert    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
145796c8dcSSimon Schubert    GNU General Public License for more details.
155796c8dcSSimon Schubert 
165796c8dcSSimon Schubert    You should have received a copy of the GNU General Public License
175796c8dcSSimon Schubert    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
185796c8dcSSimon Schubert 
195796c8dcSSimon Schubert /* The vmap struct is used to describe the virtual address space of
205796c8dcSSimon Schubert    the target we are manipulating.  The first entry is always the "exec"
215796c8dcSSimon Schubert    file.  Subsequent entries correspond to other objects that are
225796c8dcSSimon Schubert    mapped into the address space of a process created from the "exec" file.
235796c8dcSSimon Schubert    These are either in response to exec()ing the file, in which case all
245796c8dcSSimon Schubert    shared libraries are loaded, or a "load" system call, followed by the
255796c8dcSSimon Schubert    user's issuance of a "load" command.  */
265796c8dcSSimon Schubert 
275796c8dcSSimon Schubert #ifndef XCOFFSOLIB_H
285796c8dcSSimon Schubert #define XCOFFSOLIB_H
295796c8dcSSimon Schubert 
305796c8dcSSimon Schubert struct vmap
315796c8dcSSimon Schubert   {
325796c8dcSSimon Schubert     struct vmap *nxt;		/* ptr to next in chain                 */
335796c8dcSSimon Schubert     bfd *bfd;			/* BFD for mappable object library      */
345796c8dcSSimon Schubert     char *name;			/* ptr to object file name              */
355796c8dcSSimon Schubert     char *member;		/* ptr to member name                   */
365796c8dcSSimon Schubert     CORE_ADDR tstart;		/* virtual addr where member is mapped  */
375796c8dcSSimon Schubert     CORE_ADDR tend;		/* virtual upper bound of member        */
38c50c785cSJohn Marino     CORE_ADDR tvma;		/* virtual addr of text section in
39c50c785cSJohn Marino 				   object file */
405796c8dcSSimon Schubert     CORE_ADDR toffs;		/* offset of text section in object file */
415796c8dcSSimon Schubert     CORE_ADDR dstart;		/* virtual address of data start        */
425796c8dcSSimon Schubert     CORE_ADDR dend;		/* virtual address of data end          */
43c50c785cSJohn Marino     CORE_ADDR dvma;		/* virtual addr of data section in
44c50c785cSJohn Marino 				   object file */
455796c8dcSSimon Schubert 
465796c8dcSSimon Schubert     /* This is NULL for the exec-file.  */
475796c8dcSSimon Schubert     struct objfile *objfile;
485796c8dcSSimon Schubert 
495796c8dcSSimon Schubert     unsigned loaded:1;		/* True if symbols are loaded           */
505796c8dcSSimon Schubert     unsigned padding:15;
515796c8dcSSimon Schubert   };
525796c8dcSSimon Schubert 
535796c8dcSSimon Schubert 
545796c8dcSSimon Schubert struct vmap_and_bfd
555796c8dcSSimon Schubert   {
565796c8dcSSimon Schubert     bfd *pbfd;
575796c8dcSSimon Schubert     struct vmap *pvmap;
585796c8dcSSimon Schubert   };
595796c8dcSSimon Schubert 
605796c8dcSSimon Schubert extern struct vmap *vmap;
615796c8dcSSimon Schubert 
625796c8dcSSimon Schubert /* Add symbols for a vmap.  */
635796c8dcSSimon Schubert extern int vmap_add_symbols (struct vmap *vp);
645796c8dcSSimon Schubert 
655796c8dcSSimon Schubert #endif
66