C++ Logo


Advanced search

Re: [wg14/wg21 liaison] Rebasing C++ to C23

From: Ville Voutilainen <ville.voutilainen_at_[hidden]>
Date: Thu, 2 May 2024 21:19:38 +0300
On Thu, 2 May 2024 at 21:16, Martin Uecker <ma.uecker_at_[hidden]> wrote:

> > That's a separable problem (because we have a separate proposal for an
> > optimization barrier),
> > but if it's a volatile write, it's an optimization barrier because the
> > volatile write is an observable effect.
> > So I don't think this is a problem.
> If UB makes a program have no semantics at all, it is impossible
> to define a barrier.
> If one accepts that UB can not affect previous observable behavior,
> then all is well, but the C++ standard states the opposite last
> time I checked.

That's why https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2021/p1494r2.html
changes those statements.

Received on 2024-05-02 18:19:52