2009-06-30 23:19:33

by Anton Blanchard

[permalink] [raw]
Subject: [patch 7/8] powerpc: Cleanup PCL output by hiding and adding symbols

A lot of hits in "setup" doesn't make much sense, so hide this symbol and
allow all the hits to end up in copy_4k_page.

Also add some dummy symbols for the branches at 0xf00, 0xf20 and 0xf40,
otherwise hits end up in trap_0e which is confusing.

Signed-off-by: Anton Blanchard <[email protected]>
---

Index: linux-2.6-tip/arch/powerpc/lib/copypage_64.S
===================================================================
--- linux-2.6-tip.orig/arch/powerpc/lib/copypage_64.S 2009-07-01 08:21:12.000000000 +1000
+++ linux-2.6-tip/arch/powerpc/lib/copypage_64.S 2009-07-01 08:21:50.000000000 +1000
@@ -26,11 +26,11 @@
srd r8,r5,r11

mtctr r8
-setup:
+.Lsetup:
dcbt r9,r4
dcbz r9,r3
add r9,r9,r12
- bdnz setup
+ bdnz .Lsetup
END_FTR_SECTION_IFSET(CPU_FTR_CP_USE_DCBTZ)
addi r3,r3,-8
srdi r8,r5,7 /* page is copied in 128 byte strides */
Index: linux-2.6-tip/arch/powerpc/kernel/exceptions-64s.S
===================================================================
--- linux-2.6-tip.orig/arch/powerpc/kernel/exceptions-64s.S 2009-07-01 08:21:12.000000000 +1000
+++ linux-2.6-tip/arch/powerpc/kernel/exceptions-64s.S 2009-07-01 08:21:50.000000000 +1000
@@ -185,12 +185,15 @@
* prolog code of the PerformanceMonitor one. A little
* trickery is thus necessary
*/
+performance_monitor_pSeries_1:
. = 0xf00
b performance_monitor_pSeries

+altivec_unavailable_pSeries_1:
. = 0xf20
b altivec_unavailable_pSeries

+vsx_unavailable_pSeries_1:
. = 0xf40
b vsx_unavailable_pSeries


--


2009-06-30 23:23:13

by Ingo Molnar

[permalink] [raw]
Subject: Re: [patch 7/8] powerpc: Cleanup PCL output by hiding and adding symbols


* Anton Blanchard <[email protected]> wrote:

> A lot of hits in "setup" doesn't make much sense, so hide this symbol and
> allow all the hits to end up in copy_4k_page.
>
> Also add some dummy symbols for the branches at 0xf00, 0xf20 and 0xf40,
> otherwise hits end up in trap_0e which is confusing.
>
> Signed-off-by: Anton Blanchard <[email protected]>

looks good (we have similar fixes for x86 too), but i think this one
should go via BenH (Cc:-ed) as it affects generic PowerPC code.

Ingo