objfile-flags.h 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. /* Definition of objfile flags.
  2. Copyright (C) 1992-2022 Free Software Foundation, Inc.
  3. This file is part of GDB.
  4. This program is free software; you can redistribute it and/or modify
  5. it under the terms of the GNU General Public License as published by
  6. the Free Software Foundation; either version 3 of the License, or
  7. (at your option) any later version.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. GNU General Public License for more details.
  12. You should have received a copy of the GNU General Public License
  13. along with this program. If not, see <http://www.gnu.org/licenses/>. */
  14. #if !defined (OBJFILE_FLAGS_H)
  15. #define OBJFILE_FLAGS_H
  16. #include "gdbsupport/enum-flags.h"
  17. /* Defines for the objfile flags field. Defined in a separate file to
  18. break circular header dependencies. */
  19. enum objfile_flag : unsigned
  20. {
  21. /* When an object file has its functions reordered (currently
  22. Irix-5.2 shared libraries exhibit this behaviour), we will need
  23. an expensive algorithm to locate a partial symtab or symtab via
  24. an address. To avoid this penalty for normal object files, we
  25. use this flag, whose setting is determined upon symbol table
  26. read in. */
  27. OBJF_REORDERED = 1 << 0, /* Functions are reordered */
  28. /* Distinguish between an objfile for a shared library and a
  29. "vanilla" objfile. This may come from a target's
  30. implementation of the solib interface, from add-symbol-file, or
  31. any other mechanism that loads dynamic objects. */
  32. OBJF_SHARED = 1 << 1, /* From a shared library */
  33. /* User requested that this objfile be read in it's entirety. */
  34. OBJF_READNOW = 1 << 2, /* Immediate full read */
  35. /* This objfile was created because the user explicitly caused it
  36. (e.g., used the add-symbol-file command). This bit offers a
  37. way for run_command to remove old objfile entries which are no
  38. longer valid (i.e., are associated with an old inferior), but
  39. to preserve ones that the user explicitly loaded via the
  40. add-symbol-file command. */
  41. OBJF_USERLOADED = 1 << 3, /* User loaded */
  42. /* Set if we have tried to read partial symtabs for this objfile.
  43. This is used to allow lazy reading of partial symtabs. */
  44. OBJF_PSYMTABS_READ = 1 << 4,
  45. /* Set if this is the main symbol file (as opposed to symbol file
  46. for dynamically loaded code). */
  47. OBJF_MAINLINE = 1 << 5,
  48. /* ORIGINAL_NAME and OBFD->FILENAME correspond to text description
  49. unrelated to filesystem names. It can be for example
  50. "<image in memory>". */
  51. OBJF_NOT_FILENAME = 1 << 6,
  52. /* User requested that we do not read this objfile's symbolic
  53. information. */
  54. OBJF_READNEVER = 1 << 7,
  55. };
  56. DEF_ENUM_FLAGS_TYPE (enum objfile_flag, objfile_flags);
  57. #endif /* !defined (OBJFILE_FLAGS_H) */