aboutsummaryrefslogtreecommitdiff
path: root/gcc/varasm.c
diff options
context:
space:
mode:
authorGeoffrey Keating <geoffk@apple.com>2004-09-10 18:54:31 +0000
committerGeoffrey Keating <geoffk@gcc.gnu.org>2004-09-10 18:54:31 +0000
commit5f11bc8b45cd3beac4fa60f5bad0ee43dde266af (patch)
treec363eda5a0c61f70b16243aa8b145619b2546b91 /gcc/varasm.c
parent18b3a02a1c6aa1d0b11547650b267d91813b6f5c (diff)
downloadgcc-5f11bc8b45cd3beac4fa60f5bad0ee43dde266af.zip
gcc-5f11bc8b45cd3beac4fa60f5bad0ee43dde266af.tar.gz
gcc-5f11bc8b45cd3beac4fa60f5bad0ee43dde266af.tar.bz2
output.h (unlikely_section_label): Delete declaration.
* output.h (unlikely_section_label): Delete declaration. (unlikely_text_section_name): Likewise. * varasm.c (unlikely_section_label_printed): Make static. (unlikely_section_label): Likewise. (unlikely_text_section_name): Likewise. From-SVN: r87313
Diffstat (limited to 'gcc/varasm.c')
-rw-r--r--gcc/varasm.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/gcc/varasm.c b/gcc/varasm.c
index 37996c0..1561dc7 100644
--- a/gcc/varasm.c
+++ b/gcc/varasm.c
@@ -104,19 +104,19 @@ tree last_assemble_variable_decl;
partitions hot and cold basic blocks into separate sections of the .o
file. */
-bool unlikely_section_label_printed = false;
+static bool unlikely_section_label_printed = false;
/* The following global variable indicates the label name to be put at
the start of the first cold section within each function, when
partitioning basic blocks into hot and cold sections. */
-char *unlikely_section_label = NULL;
+static char *unlikely_section_label = NULL;
/* The following global variable indicates the section name to be used
for the current cold section, when partitioning hot and cold basic
blocks into separate sections. */
-char *unlikely_text_section_name = NULL;
+static char *unlikely_text_section_name = NULL;
/* We give all constants their own alias set. Perhaps redundant with
MEM_READONLY_P, but pre-dates it. */
@@ -1187,10 +1187,8 @@ assemble_start_function (tree decl, const char *fnname)
unlikely_section_label_printed = false;
unlikely_text_section_name = NULL;
- if (unlikely_section_label)
- free (unlikely_section_label);
- unlikely_section_label = xmalloc ((strlen (fnname) + 18) * sizeof (char));
- sprintf (unlikely_section_label, "%s_unlikely_section", fnname);
+ unlikely_section_label = reconcat (unlikely_section_label,
+ fnname, ".unlikely_section", NULL);
/* The following code does not need preprocessing in the assembler. */