Re: [PATCH] LoongArch: Remove redundant barrier instructions before LL-SC loops

2023-11-13 Thread Xi Ruoyao
On Wed, 2023-11-08 at 16:27 +0800, Xi Ruoyao wrote: > On Wed, 2023-11-08 at 09:49 +0800, chenglulu wrote: > > > > 在 2023/11/6 下午7:36, Xi Ruoyao 写道: > > > This is isomorphic to the LLVM changes [1-2]. > > > > > > On LoongArch, the LL and SC instructions has memory barrier semantics: > > > > > > -

Re: [PATCH] LoongArch: Remove redundant barrier instructions before LL-SC loops

2023-11-08 Thread Xi Ruoyao
On Wed, 2023-11-08 at 09:49 +0800, chenglulu wrote: > > 在 2023/11/6 下午7:36, Xi Ruoyao 写道: > > This is isomorphic to the LLVM changes [1-2]. > > > > On LoongArch, the LL and SC instructions has memory barrier semantics: > > > > - LL: + > > - SC: + > > > > But the compare and swap operation i

Re: [PATCH] LoongArch: Remove redundant barrier instructions before LL-SC loops

2023-11-07 Thread chenglulu
在 2023/11/6 下午7:36, Xi Ruoyao 写道: This is isomorphic to the LLVM changes [1-2]. On LoongArch, the LL and SC instructions has memory barrier semantics: - LL: + - SC: + But the compare and swap operation is allowed to fail, and if it fails the SC instruction is not executed, thus the guara

[PATCH] LoongArch: Remove redundant barrier instructions before LL-SC loops

2023-11-06 Thread Xi Ruoyao
This is isomorphic to the LLVM changes [1-2]. On LoongArch, the LL and SC instructions has memory barrier semantics: - LL: + - SC: + But the compare and swap operation is allowed to fail, and if it fails the SC instruction is not executed, thus the guarantee of acquiring semantics cannot be