Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 22 Aug 2015 00:53:15 +0800
From:      Julian Elischer <julian@freebsd.org>
To:        Ian Lepore <ian@freebsd.org>
Cc:        Adrian Chadd <adrian@freebsd.org>, freebsd-current <freebsd-current@freebsd.org>
Subject:   Re: freebsd-head: suddenly NMI panics lead to ddb being unable to stop CPUs?
Message-ID:  <55D7577B.8090000@freebsd.org>
In-Reply-To: <1440174193.242.279.camel@freebsd.org>
References:  <CAJ-VmomvqULP--v47qKJisQkf8VQNvxEhXK=HXEtv9MuLz4D1g@mail.gmail.com> <CAFMmRNw6tWMQ-pfXzSpEM7kRgKafB9KnK-oUhWw2_E-P91drLw@mail.gmail.com> <55D74193.4020008@FreeBSD.org> <CAJ-Vmon6xXBSMPWgNhg-RZKLuuMDP1hvXG%2BDdZ3fZdvFnan06g@mail.gmail.com> <55D74402.70104@freebsd.org> <1440174193.242.279.camel@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 8/22/15 12:23 AM, Ian Lepore wrote:
> On Fri, 2015-08-21 at 23:30 +0800, Julian Elischer wrote:
>> On 8/21/15 11:25 PM, Adrian Chadd wrote:
>>> Ah, cool. I'll give it a whirl.
>>>
>>> I'm a little worried about having all of the other cores spinning in
>>> this case (mostly thermal; the machines get VERY LOUD when the CPUs
>>> are spinning..)
>>>
>> make each spin with the pause instruction.. and for N seconds (N being
>> the CPU ID) or something
> cpu_spinwait() is defined as ia32_pause() on i386 and amd64.
>
> The problem is that ONLY x86 arches benefit from cpu_spinwait(), it's
> just a nop on other arches, which turn into little radiant heaters for
> long spins (like while waiting for APs to be released).

remind me again why it cant spin with a 'halt' instruction?

>
> On ARM we have a really nice wait-for-event/signal-event pair of
> instructions, where WFE would be a natural for cpu_spinwait(), but would
> require a matching cpu_spinwake() type call to be sprinkled around to do
> the matching SEV instruction.
>
> -- Ian
>
>
>




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?55D7577B.8090000>