Re:获得原子参考计数的障碍 [英] Re: acquire barrier for atomic reference counting

查看:62
本文介绍了Re:获得原子参考计数的障碍的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

On16íáê,21:41,Dmitriy V''jukov < dvyu ... @ gmail.comwrote:

On 16 íáê, 21:41, "Dmitriy V''jukov" <dvyu...@gmail.comwrote:


你能否澄清一下atomic_global_fence_compatibility。


1.10 / 7(N2521 )

"对对象M执行释放操作的评估A

与执行获取操作的评估B同步

on M并在发布中读取由任何副作用写入的值
以B为首的
序列。


发布操作在''obj->上执行;''std :: atomic_global_fence_compatibility''对rc''和获取操作进行了
。那么为什么

前者''与'后者'同步?
Can you clarify about atomic_global_fence_compatibility.

1.10/7 (N2521)
"An evaluation A that performs a release operation on an object M
synchronizes with an evaluation B that performs an acquire operation
on M and reads a value written by any side effect in the release
sequence headed by A."

Release operation is performed on ''obj->rc'' and acquire operation is
performed on ''std::atomic_global_fence_compatibility''. So why the
former ''synchronizes with'' the latter?



根据定义,

''std :: atomic_global_fence_compatibility''的发布操作只能''与''/'同步>
获取''std :: atomic_global_fence_compatibility''的操作。

Imho,这有点无意义。我想我错过了什么。可以

有人澄清一下std :: atomic_global_fence_compatibility?

Dmitriy V''jukov


According to definition, release operation on
''std::atomic_global_fence_compatibility'' can only ''synchronize with''
acquire operation on ''std::atomic_global_fence_compatibility''.
Imho, it''s a bit senseless. I think that I miss something. Can
somebody clarify about std::atomic_global_fence_compatibility?
Dmitriy V''jukov

推荐答案

5月17日下午4:07,Dmitriy V''jukov < dvyu ... @ gmail.comwrote:
On May 17, 4:07 pm, "Dmitriy V''jukov" <dvyu...@gmail.comwrote:

On16íáê,21:41,Dmitriy V''jukov < dvyu ... @ gmail.comwrote:
On 16 íáê, 21:41, "Dmitriy V''jukov" <dvyu...@gmail.comwrote:

你能否澄清一下atomic_global_fence_compatibility。
Can you clarify about atomic_global_fence_compatibility.


1.10 / 7(N2521)

"评估A对对象M执行释放操作/>
与在M上执行获取操作的评估B同步

并且在发布中读取由任何副作用写入的值
以b为首的
序列"
1.10/7 (N2521)
"An evaluation A that performs a release operation on an object M
synchronizes with an evaluation B that performs an acquire operation
on M and reads a value written by any side effect in the release
sequence headed by A."


发布操作在''obj-> rc''上进行,获取操作是在''
上执行''的std :: atomic_global_fence_compatibility'。那么为什么

前者''与'后者'同步?
Release operation is performed on ''obj->rc'' and acquire operation is
performed on ''std::atomic_global_fence_compatibility''. So why the
former ''synchronizes with'' the latter?



根据定义,

''std :: atomic_global_fence_compatibility''的发布操作只能''与''/'同步>
获取''std :: atomic_global_fence_compatibility''的操作。

Imho,这有点无意义。我想我错过了什么。可以

有人澄清一下std :: atomic_global_fence_compatibility吗?


According to definition, release operation on
''std::atomic_global_fence_compatibility'' can only ''synchronize with''
acquire operation on ''std::atomic_global_fence_compatibility''.
Imho, it''s a bit senseless. I think that I miss something. Can
somebody clarify about std::atomic_global_fence_compatibility?



这是一个全球范围(见N2588中的29.3p11)。如果那还不清楚,那么

这是一个缺陷。


Anthony

It''s a global fence (see 29.3p11 in N2588). If that''s not clear, then
that''s a defect.

Anthony


Dmitriy V''jukov < dv ***** @ gmail.comwrites:
"Dmitriy V''jukov" <dv*****@gmail.comwrites:

我目前的理解是:

1. atomic_global_fence_compatibility必须有一些特殊的治疗

来自语言。



2.它没用。
My current understanding is that:
1. atomic_global_fence_compatibility must have some special treatment
from language.
or
2. it''s useless.



我的理解是#1:它有特殊待遇。使用此变量

作为围栏相当于全局围栏指令。


Anthony

-

Anthony Williams | Just Software Solutions Ltd

定制软件开发| http://www.justsoftwaresolutions.co.uk

在英格兰注册,公司编号5478976.

注册办事处:15 Carrallack Mews,St Just,Cornwall,TR19 7UL

My understanding is #1: it has special treatment. Use of this variable
for a fence is equivalent to a global fence instruction.

Anthony
--
Anthony Williams | Just Software Solutions Ltd
Custom Software Development | http://www.justsoftwaresolutions.co.uk
Registered in England, Company Number 5478976.
Registered Office: 15 Carrallack Mews, St Just, Cornwall, TR19 7UL


5月20日,下午6:15,Dmitriy V''jukov < dvyu ... @ gmail.comwrote:
On May 20, 6:15 pm, "Dmitriy V''jukov" <dvyu...@gmail.comwrote:

2.获取操作必须读取发布''release-sequence''中的值

操作。什么价值读取 fence()函数?由于fence()是RMW

原子操作,它必须读取一些价值。但是我如何能够找到

它读取的价值是多少?
2. Acquire operation must read value in ''release-sequence'' of release
operation. What value "reads" fence() function? Since fence() is RMW
atomic operation, it must "read" some value. But how can I find out
what value it reads?



顺便说一下,这一般适用于atomic_fence()函数 - 什么值

它读取?

如果我不知道它读的是什么价值,那么我就不能确定

与''同步'的东西。


Dmitriy V'''jukov

Btw, this applies to atomic_fence() function in general - what value
it "reads"?
If I don''t know what value it reads then I can''t be sure that
something ''synchronized-with''.

Dmitriy V''jukov


这篇关于Re:获得原子参考计数的障碍的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆