plugin.def 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. /* This file contains the definitions for plugin events in GCC.
  2. Copyright (C) 2009-2019 Free Software Foundation, Inc.
  3. This file is part of GCC.
  4. GCC is free software; you can redistribute it and/or modify it under
  5. the terms of the GNU General Public License as published by the Free
  6. Software Foundation; either version 3, or (at your option) any later
  7. version.
  8. GCC is distributed in the hope that it will be useful, but WITHOUT ANY
  9. WARRANTY; without even the implied warranty of MERCHANTABILITY or
  10. FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
  11. for more details.
  12. You should have received a copy of the GNU General Public License
  13. along with GCC; see the file COPYING3. If not see
  14. <http://www.gnu.org/licenses/>. */
  15. /* Called before parsing the body of a function. */
  16. DEFEVENT (PLUGIN_START_PARSE_FUNCTION)
  17. /* After finishing parsing a function. */
  18. DEFEVENT (PLUGIN_FINISH_PARSE_FUNCTION)
  19. /* To hook into pass manager. */
  20. DEFEVENT (PLUGIN_PASS_MANAGER_SETUP)
  21. /* After finishing parsing a type. */
  22. DEFEVENT (PLUGIN_FINISH_TYPE)
  23. /* After finishing parsing a declaration. */
  24. DEFEVENT (PLUGIN_FINISH_DECL)
  25. /* Useful for summary processing. */
  26. DEFEVENT (PLUGIN_FINISH_UNIT)
  27. /* Allows to see low level AST in C and C++ frontends. */
  28. DEFEVENT (PLUGIN_PRE_GENERICIZE)
  29. /* Called before GCC exits. */
  30. DEFEVENT (PLUGIN_FINISH)
  31. /* Information about the plugin. */
  32. DEFEVENT (PLUGIN_INFO)
  33. /* Called at start of GCC Garbage Collection. */
  34. DEFEVENT (PLUGIN_GGC_START)
  35. /* Extend the GGC marking. */
  36. DEFEVENT (PLUGIN_GGC_MARKING)
  37. /* Called at end of GGC. */
  38. DEFEVENT (PLUGIN_GGC_END)
  39. /* Register an extra GGC root table. */
  40. DEFEVENT (PLUGIN_REGISTER_GGC_ROOTS)
  41. /* Called during attribute registration. */
  42. DEFEVENT (PLUGIN_ATTRIBUTES)
  43. /* Called before processing a translation unit. */
  44. DEFEVENT (PLUGIN_START_UNIT)
  45. /* Called during pragma registration. */
  46. DEFEVENT (PLUGIN_PRAGMAS)
  47. /* Called before first pass from all_passes. */
  48. DEFEVENT (PLUGIN_ALL_PASSES_START)
  49. /* Called after last pass from all_passes. */
  50. DEFEVENT (PLUGIN_ALL_PASSES_END)
  51. /* Called before first ipa pass. */
  52. DEFEVENT (PLUGIN_ALL_IPA_PASSES_START)
  53. /* Called after last ipa pass. */
  54. DEFEVENT (PLUGIN_ALL_IPA_PASSES_END)
  55. /* Allows to override pass gate decision for current_pass. */
  56. DEFEVENT (PLUGIN_OVERRIDE_GATE)
  57. /* Called before executing a pass. */
  58. DEFEVENT (PLUGIN_PASS_EXECUTION)
  59. /* Called before executing subpasses of a GIMPLE_PASS in
  60. execute_ipa_pass_list. */
  61. DEFEVENT (PLUGIN_EARLY_GIMPLE_PASSES_START)
  62. /* Called after executing subpasses of a GIMPLE_PASS in
  63. execute_ipa_pass_list. */
  64. DEFEVENT (PLUGIN_EARLY_GIMPLE_PASSES_END)
  65. /* Called when a pass is first instantiated. */
  66. DEFEVENT (PLUGIN_NEW_PASS)
  67. /* Called when a file is #include-d or given via the #line directive.
  68. this could happen many times. The event data is the included file path,
  69. as a const char* pointer. */
  70. DEFEVENT (PLUGIN_INCLUDE_FILE)
  71. /* When adding a new hard-coded plugin event, don't forget to edit in
  72. file plugin.c the functions register_callback and
  73. invoke_plugin_callbacks_full accordingly! */
  74. /* After the hard-coded events above, plugins can dynamically allocate events
  75. at run time.
  76. PLUGIN_EVENT_FIRST_DYNAMIC only appears as last enum element. */