+extern struct opt_pass *all_passes, *all_small_ipa_passes, *all_lowering_passes,
+ *all_regular_ipa_passes, *all_lto_gen_passes;
+
+/* Define a list of pass lists so that both passes.c and plugins can easily
+ find all the pass lists. */
+#define GCC_PASS_LISTS \
+ DEF_PASS_LIST (all_lowering_passes) \
+ DEF_PASS_LIST (all_small_ipa_passes) \
+ DEF_PASS_LIST (all_regular_ipa_passes) \
+ DEF_PASS_LIST (all_lto_gen_passes) \
+ DEF_PASS_LIST (all_passes)
+
+#define DEF_PASS_LIST(LIST) PASS_LIST_NO_##LIST,
+enum
+{
+ GCC_PASS_LISTS
+ PASS_LIST_NUM
+};
+#undef DEF_PASS_LIST
+
+/* This is used by plugins, and should also be used in
+ passes.c:register_pass. */
+extern struct opt_pass **gcc_pass_lists[];