diff options
author | Richard Kenner <kenner@gcc.gnu.org> | 1993-01-01 17:50:33 -0500 |
---|---|---|
committer | Richard Kenner <kenner@gcc.gnu.org> | 1993-01-01 17:50:33 -0500 |
commit | b4d6689b3ecdaf8d6d7a2048d0aea48e7c7ade2e (patch) | |
tree | f2c0f59a5513e0b1f4ee0149ba2aa6775c12aa66 /gcc | |
parent | b7a4467dcdf2022c51a892223fcc24aec3689b9f (diff) | |
download | gcc-b4d6689b3ecdaf8d6d7a2048d0aea48e7c7ade2e.zip gcc-b4d6689b3ecdaf8d6d7a2048d0aea48e7c7ade2e.tar.gz gcc-b4d6689b3ecdaf8d6d7a2048d0aea48e7c7ade2e.tar.bz2 |
(ASM_FILE_START): Switch to text section at end.
Output declaration for .mcount when profiling.
From-SVN: r3044
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/config/rs6000/rs6000.h | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/gcc/config/rs6000/rs6000.h b/gcc/config/rs6000/rs6000.h index 20bc635..c17ac54 100644 --- a/gcc/config/rs6000/rs6000.h +++ b/gcc/config/rs6000/rs6000.h @@ -35,7 +35,8 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ Don't do this until the fixed IBM assembler is more generally available. When this becomes permanently defined, the ASM_OUTPUT_EXTERNAL, ASM_OUTPUT_EXTERNAL_LIBCALL, and RS6000_OUTPUT_BASENAME macros will no - longer be needed. */ + longer be needed. Also, the extern declaration of mcount in ASM_FILE_START + will no longer be needed. */ /* #define ASM_SPEC "-u" */ @@ -1319,13 +1320,16 @@ extern int rs6000_trunc_used; /* Output at beginning of assembler file. - On the RS/6000, we want to go into the TOC section so at least one - .toc will be emitted. - - Also initialize the section names for the RS/6000 at this point. + Initialize the section names for the RS/6000 at this point. + We want to go into the TOC section so at least one .toc will be emitted. Also, in order to output proper .bs/.es pairs, we need at least one static - [RW] section emitted. */ + [RW] section emitted. + + We then switch back to text to force the gcc2_compiled. label and the space + allocated after it (when profiling) into the text section. + + Finally, declare mcount when profiling to make the assembler happy. */ #define ASM_FILE_START(FILE) \ { \ @@ -1339,6 +1343,9 @@ extern int rs6000_trunc_used; toc_section (); \ if (write_symbols != NO_DEBUG) \ private_data_section (); \ + text_section (); \ + if (profile_flag) \ + fprintf (FILE, "\t.extern .mcount\n"); \ } /* Output at end of assembler file. |