aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorMichael Meissner <meissner@gcc.gnu.org>1993-10-07 21:35:28 +0000
committerMichael Meissner <meissner@gcc.gnu.org>1993-10-07 21:35:28 +0000
commit638b724c5f6a875f384226036191a490eb961cfc (patch)
tree7972a0de0c2857a725f6d6fe3564defb11740114 /gcc
parent8d4750f117cc0116d72a1614b6613f49ec634363 (diff)
downloadgcc-638b724c5f6a875f384226036191a490eb961cfc.zip
gcc-638b724c5f6a875f384226036191a490eb961cfc.tar.gz
gcc-638b724c5f6a875f384226036191a490eb961cfc.tar.bz2
Add FINALIZE_PIC to indicate %ebx needs to be set up if profiling.
From-SVN: r5664
Diffstat (limited to 'gcc')
-rw-r--r--gcc/config/i386/i386.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/gcc/config/i386/i386.h b/gcc/config/i386/i386.h
index 9bcbe14..fcfc2df 100644
--- a/gcc/config/i386/i386.h
+++ b/gcc/config/i386/i386.h
@@ -1117,6 +1117,23 @@ while (0)
functions. */
#define INIT_EXPANDERS clear_386_stack_locals ()
+
+/* The `FINALIZE_PIC' macro serves as a hook to emit these special
+ codes once the function is being compiled into assembly code, but
+ not before. (It is not done before, because in the case of
+ compiling an inline function, it would lead to multiple PIC
+ prologues being included in functions which used inline functions
+ and were compiled to assembly language.) */
+
+#define FINALIZE_PIC \
+do \
+ { \
+ extern int current_function_uses_pic_offset_table; \
+ \
+ current_function_uses_pic_offset_table |= profile_flag | profile_block_flag; \
+ } \
+while (0)
+
/* Specify the machine mode that this machine uses
for the index in the tablejump instruction. */