Messages in this thread | | | Date | Tue, 20 Aug 2019 15:56:12 +0200 | From | Peter Zijlstra <> | Subject | Re: [PATCH 1/1] Fix: trace sched switch start/stop racy updates |
| |
On Sat, Aug 17, 2019 at 01:08:02AM -0700, Linus Torvalds wrote:
> The data tearing issue is almost a non-issue. We're not going to add > WRITE_ONCE() to these kinds of places for no good reason.
Paulmck actually has an example of that somewhere; ISTR that particular case actually got fixed by GCC, but I'd really _love_ for some compiler people (both GCC and LLVM) to state that their respective compilers will not do load/store tearing for machine word sized load/stores.
Without this written guarantee (which supposedly was in older GCC manuals but has since gone missing), I'm loathe to rely on it.
Yes, it is very rare, but it is a massive royal pain to debug if/when it does do happen.
| |