tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: __{read,write}_once



On 06.11.2019 16:44, Kamil Rytarowski wrote:
> On 06.11.2019 15:57, Jason Thorpe wrote:
>>
>>
>>> On Nov 6, 2019, at 5:41 AM, Kamil Rytarowski <n54%gmx.com@localhost> wrote:
>>>
>>> On 06.11.2019 14:37, Jason Thorpe wrote:
>>>>
>>>>
>>>>> On Nov 6, 2019, at 4:45 AM, Kamil Rytarowski <n54%gmx.com@localhost> wrote:
>>>>>
>>>>> I propose __write_relaxed() / __read_relaxed().
>>>>
>>>> ...except that seems to imply the opposite of what these do.
>>>>
>>>> -- thorpej
>>>>
>>>
>>> Rationale?
>>>
>>> This matches atomic_load_relaxed() / atomic_write_relaxed(), but we do
>>> not deal with atomics here.
>>
>> Fair enough.  To me, the names suggest "compiler is allowed to apply relaxed constraints and tear the access if it wants".... But apparently the common meaning is "relax, bro, I know what I'm doing".  If that's the case, I can roll with it.
>>
>> -- thorpej
>>
> 
> Unless I mean something this is exactly about relaxed constraints.

miss*

> 
> "Relaxed operation: there are no synchronization or ordering constraints
> imposed on other reads or writes" and without "operation's atomicity is
> guaranteed".
> 
> This is also similar to what suggested Google to apply to NetBSD in our
> internal thread, but with a bit different naming.
> 

Adding Marco to this thread.

Attachment: signature.asc
Description: OpenPGP digital signature



Home | Main Index | Thread Index | Old Index