This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch][plugins] Provide unique names to all compiler passes


plugins refer to passes by their name, hence all compiler passes need
a unique name:

    * passes with NULL name should get a new unique name;
    * passes which had duplicate names should be disambiguated by
changing at least one name to achieve uniqueness.

The pass (re)naming policy implemented in this patch is:

    * passes with NULL names are named after their opt_pass data
structure with the prefix "pass_" stripped;

    * when a GIMPLE pass and an RTL pass have the same name ("eh",
"dce"), the RTL pass name is modified while the name of the GIMPLE
pass is left
unchanged; Rationale: GIMPLE is there to stay, and GIMPLE  pass names
are extensively used as dump names in the testsuite;

    * when two passes have the same name ("mudflap1", "mudflap2",
"postreload"), the names are adjusted to reflect the names of pass

Regression-tested on x86_64-unknown-linux-gnu.

All the best,


2009-06-15  Zbigniew Chamski  <>

        * cfgrtl.c (pass_free_cfg): Add pass name.
        * cgraphbuild.c (pass_build_cgraph_edges,
        pass_rebuild_cgraph_edges, pass_remove_cgraph_callee_edges):
        * dce.c (pass_ud_rtl_dce, pass_fast_rtl_dce): Change pass name.
        * df-core.c (pass_df_initialize_no_opt): Likewise.
        * except.c (pass_rtl_eh): Likewise.
        * final.c (pass_final, pass_clean_state): Add pass name.
        * function.c (pass_init_function, pass_leaf_regs): Likewise.
        * gcse.c (pass_rtl_pre): Change pass name.
        * passes.c (pass_rest_of_compilation, pass_postreload): Add pass
        * postreload.c (pass_postreload_cse): Change pass name.
        * predict.c (pass_strip_predict_hints): Add pass name.
        * reg-stack.c (pass_stack_regs): Likewise.
        * stack-ptr-mod.c (pass_stack_ptr_mod): Likewise.
        * tree-cfg.c (pass_warn_function_return,
        pass_warn_function_noreturn): Add pass name.
        * tree-dfa.c (pass_referenced_vars): Likewise.
        * tree-nomudflap (pass_mudflap_1, pass_mudflap_2): Change pass name.
        * tree-optimize.c (pass_all_optimizations): Add pass name.
        (pass_cleanup_cfg_post_optimizing): Fix whitespace before comment.
        (pass_fixup_cfg): Add pass name, fix whitespace before comment.
        (pass_init_datastructures): Add pass name.
        * tree-ssa-loop.c (pass_record_bounds): Likewise.
        * tree-ssa.c (pass_early_warn_uninitialized,
        pass_late_warn_uninitialized): Likewise.

Attachment: unique-pass-names.patch
Description: Binary data

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]