diff mbox

[committed] TILE-Gx/TILEPro: define PROFILE_BEFORE_PROLOGUE

Message ID 201303260701.r2Q71oIS017859@farm-0001.internal.tilera.com
State New
Headers show

Commit Message

Walter Lee March 26, 2013, 7:01 a.m. UTC
This patch puts profiling code before the prologue, to avoid
clobbering used registers.  Backported to 4.7 and 4.8.

	* config/tilegx/tilegx.h (PROFILE_BEFORE_PROLOGUE): Define.
	* config/tilegx/tilepro.h (PROFILE_BEFORE_PROLOGUE): Define.
diff mbox

Patch

Index: gcc/config/tilegx/tilegx.h
===================================================================
--- gcc/config/tilegx/tilegx.h	(revision 197083)
+++ gcc/config/tilegx/tilegx.h	(working copy)
@@ -287,6 +287,8 @@  enum reg_class
 #define INITIAL_ELIMINATION_OFFSET(FROM, TO, OFFSET) \
   ((OFFSET) = tilegx_initial_elimination_offset((FROM),(TO)))
 
+#define PROFILE_BEFORE_PROLOGUE 1
+
 #define FUNCTION_PROFILER(FILE, LABELNO) \
   tilegx_function_profiler (FILE, LABELNO)
 
Index: gcc/config/tilepro/tilepro.h
===================================================================
--- gcc/config/tilepro/tilepro.h	(revision 197083)
+++ gcc/config/tilepro/tilepro.h	(working copy)
@@ -268,6 +268,8 @@  enum reg_class
 #define INITIAL_ELIMINATION_OFFSET(FROM, TO, OFFSET) \
   ((OFFSET) = tilepro_initial_elimination_offset((FROM),(TO)))
 
+#define PROFILE_BEFORE_PROLOGUE 1
+
 #define FUNCTION_PROFILER(FILE, LABELNO) \
   tilepro_function_profiler (FILE, LABELNO)