Re: Using %stick where available
Takeshi Nakayama <[email protected]>
| Newsgroups | gmane.os.netbsd.ports.sparc64 |
|---|---|
| Message-ID | <[email protected]> |
>>> Michael <[email protected]> wrote > 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. Thanks, it looks ok to me. -- Takeshi Nakayama