Port-sparc64 archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Using %stick where available



Hello,

On Nov 7, 2012, at 4:29 PM, Takeshi Nakayama wrote:

+       struct cpu_info *ci = curcpu();

Replace the following curcpu()s with ci.

Done.

Thanks, but there are some left.

Oops, fixed.

Index: sparc64/locore.s
===================================================================
RCS file: /cvsroot/src/sys/arch/sparc64/sparc64/locore.s,v
retrieving revision 1.341
diff -u -w -r1.341 locore.s
--- sparc64/locore.s    17 Mar 2012 22:19:53 -0000      1.341
+++ sparc64/locore.s    7 Nov 2012 17:26:59 -0000
@@ -3270,13 +3270,18 @@
        wrpr    %g0, PSTATE_KERN|PSTATE_IG, %pstate     ! DEBUG
#endif
        /*
-        * If this is a %tick softint, clear it then call interrupt_vector.
+        * If this is a %tick or %stick softint, clear it then call
+ * interrupt_vector. Only one of them should be enabled at any given
+        * time.
         */
        rd      SOFTINT, %g1
-       btst    1, %g1
+       mov     1, %g5
+       sllx    %g5, 16, %g3
+       or      %g5, %g3, %g5

Only "set 0x1001, %g5" is faster.

fixed that too.

Revised patch is attached.

have fun
Michael

Attachment: stick_3.patch
Description: Binary data


Attachment: PGP.sig
Description: This is a digitally signed message part



Home | Main Index | Thread Index | Old Index