------- Comment #9 from ubizjak at gmail dot com 2009-04-27 18:21 -------
Following patch should fix the performance hit with -O1:
--cut here--
Index: ira-conflicts.c
===================================================================
--- ira-conflicts.c (revision 146825)
+++ ira-conflicts.c (working copy)
@@ -806,7 +806,7 @@ ira_build_conflicts (void)
if ((! flag_caller_saves && ALLOCNO_CALLS_CROSSED_NUM (a) != 0)
/* For debugging purposes don't put user defined variables in
callee-clobbered registers. */
- || (optimize <= 1
+ || (optimize == 0
&& (attrs = REG_ATTRS (regno_reg_rtx [ALLOCNO_REGNO (a)])) !=
NULL
&& (decl = attrs->decl) != NULL
&& VAR_OR_FUNCTION_DECL_P (decl)
--cut here--
IMO, such a performance hit is not acceptable with -O1, we want to _optimize_
the code, we have -O0 to achieve full debug functionality.
--
ubizjak at gmail dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
BugsThisDependsOn| |39432
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2009-04-27 18:21:04
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39914