Re: [PATCH 11/18] seqcount: Introduce raw_write_seqcount_barrier()
From: Peter Zijlstra
Date: Wed Jun 17 2015 - 12:58:22 EST
On Wed, Jun 17, 2015 at 08:42:45AM -0700, Paul E. McKenney wrote:
> > I would very much prefer a compiler switch that instructs the compiler
> > to not do bloody stupid things like this instead of marking every other
> > load/store in the kernel with volatile.
> I would of course be good with such a compiler switch, though my earlier
> attempts to negotiate one were unsuccessful. But I don't believe that we
> discussed a switch to specifically prohibit only use of to-be-stored-into
> variables as temporary scratch space. The trick is finding restrictions
> that are useful, but that don't imply -O0.
I would request on that disables all the 'stores from thin air'
'optimizations'. IOW assume everything is shared memory and concurrent
unless you can prove its not so. For example a local stack variable that
does not escape scope.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/