[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v5 (PR #108636)

via cfe-commits cfe-commits at lists.llvm.org
Thu Sep 19 06:52:13 PDT 2024


4ast wrote:

> lock *(u64 *)(r1 + 0x0) = r2 release
> lock r2 = *(u64 *)(r1 + 0x0) acquire

tbh I don't like such syntax. It's harder to read comparing to what the patch does:
r0 = load_acquire((u64 *)(r1 + 0))
store_release((u8 *)(r1 + 0x0), w2)

"lock" part doesn't fit here either. "lock" is x86 specific.

https://github.com/llvm/llvm-project/pull/108636


More information about the cfe-commits mailing list