This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[3.3/mainline] cleanup cfg only once when not optimizing
- From: Jan Hubicka <jh at suse dot cz>
- To: gcc-patches at gcc dot gnu dot org, rth at cygnus dot com
- Date: Fri, 28 Feb 2003 11:28:19 +0100
- Subject: [3.3/mainline] cleanup cfg only once when not optimizing
Hi,
currently we call cleanup_cfg 4 times...
Honza
Fri Feb 28 11:26:54 CET 2003 Jan Hubicka <jh at suse dot cz>
* toplev.c (rest_of_compilation): Avoid cfg_cleanup calls when not
optimizing.
Index: toplev.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/toplev.c,v
retrieving revision 1.723
diff -c -3 -p -r1.723 toplev.c
*** toplev.c 28 Feb 2003 10:11:47 -0000 1.723
--- toplev.c 28 Feb 2003 10:26:50 -0000
*************** rest_of_compilation (decl)
*** 2802,2808 ****
}
timevar_push (TV_JUMP);
! cleanup_cfg (optimize ? CLEANUP_EXPENSIVE | CLEANUP_PRE_LOOP: 0);
/* Try to identify useless null pointer tests and delete them. */
if (flag_delete_null_pointer_checks)
--- 2802,2809 ----
}
timevar_push (TV_JUMP);
! if (optimize)
! cleanup_cfg (CLEANUP_EXPENSIVE | CLEANUP_PRE_LOOP);
/* Try to identify useless null pointer tests and delete them. */
if (flag_delete_null_pointer_checks)
*************** rest_of_compilation (decl)
*** 3033,3040 ****
open_dump_file (DFI_cfg, decl);
if (rtl_dump_file)
dump_flow_info (rtl_dump_file);
! cleanup_cfg ((optimize ? CLEANUP_EXPENSIVE : 0)
! | (flag_thread_jumps ? CLEANUP_THREADING : 0));
/* It may make more sense to mark constant functions after dead code is
eliminated by life_analysis, but we need to do it early, as -fprofile-arcs
--- 3034,3042 ----
open_dump_file (DFI_cfg, decl);
if (rtl_dump_file)
dump_flow_info (rtl_dump_file);
! if (optimize)
! cleanup_cfg (CLEANUP_EXPENSIVE
! | (flag_thread_jumps ? CLEANUP_THREADING : 0));
/* It may make more sense to mark constant functions after dead code is
eliminated by life_analysis, but we need to do it early, as -fprofile-arcs
*************** rest_of_compilation (decl)
*** 3463,3469 ****
#endif
split_all_insns (0);
! cleanup_cfg (optimize ? CLEANUP_EXPENSIVE : 0);
/* On some machines, the prologue and epilogue code, or parts thereof,
can be represented as RTL. Doing so lets us schedule insns between
--- 3465,3472 ----
#endif
split_all_insns (0);
! if (optimize)
! cleanup_cfg (CLEANUP_EXPENSIVE);
/* On some machines, the prologue and epilogue code, or parts thereof,
can be represented as RTL. Doing so lets us schedule insns between