aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJan Hubicka <jh@suse.cz>2002-10-03 21:43:00 +0200
committerJan Hubicka <hubicka@gcc.gnu.org>2002-10-03 19:43:00 +0000
commitc07f146f074b93fa33272cb47040d8394739865d (patch)
treeef10f6d6952f059b9d8fb6642af9a15d6198b8d8 /gcc
parentaba8a49486bd9e4af0d052cb621c20d37bbe7340 (diff)
downloadgcc-c07f146f074b93fa33272cb47040d8394739865d.zip
gcc-c07f146f074b93fa33272cb47040d8394739865d.tar.gz
gcc-c07f146f074b93fa33272cb47040d8394739865d.tar.bz2
* predict.c (choose_function_section): Avoid choice for linkonce functions.
From-SVN: r57785
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog4
-rw-r--r--gcc/predict.c7
2 files changed, 10 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 947fccc..1ad35bd 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,7 @@
+Thu Oct 3 21:42:20 CEST 2002 Jan Hubicka <jh@suse.cz>
+
+ * predict.c (choose_function_section): Avoid choice for linkonce functions.
+
Thu Oct 3 15:15:00 CEST 2002 Jan Hubicka <jh@suse.cz>
* i386.md (lea to mul peep2): Fix condition.
diff --git a/gcc/predict.c b/gcc/predict.c
index 7d94dea..844366a 100644
--- a/gcc/predict.c
+++ b/gcc/predict.c
@@ -1247,7 +1247,12 @@ static void
choose_function_section ()
{
if (DECL_SECTION_NAME (current_function_decl)
- || !targetm.have_named_sections)
+ || !targetm.have_named_sections
+ /* Theoretically we can split the gnu.linkonce text section too,
+ but this requires more work as the frequency needs to match
+ for all generated objects so we need to merge the frequency
+ of all instances. For now just never set frequency for these. */
+ || !DECL_ONE_ONLY (current_function_decl))
return;
if (cfun->function_frequency == FUNCTION_FREQUENCY_HOT)
DECL_SECTION_NAME (current_function_decl) =