[clang] [Clang] Add support for scoped atomic thread fence (PR #115545)
via cfe-commits
cfe-commits at lists.llvm.org
Fri Nov 8 13:48:27 PST 2024
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff a9cd941f392dbf99ddfcde9721bd5c485823bdf0 5b5806d9e9b516cb74d75237e493941d5bab8128 --extensions c,cpp -- clang/test/CodeGen/scoped-fence-ops.c clang/lib/CodeGen/CGBuiltin.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/clang/lib/CodeGen/CGBuiltin.cpp b/clang/lib/CodeGen/CGBuiltin.cpp
index 2ec3770ecd..4d22390c21 100644
--- a/clang/lib/CodeGen/CGBuiltin.cpp
+++ b/clang/lib/CodeGen/CGBuiltin.cpp
@@ -5191,8 +5191,8 @@ RValue CodeGenFunction::EmitBuiltinExpr(const GlobalDecl GD, unsigned BuiltinID,
default: // invalid order
ContBB->eraseFromParent();
return RValue::get(nullptr);
- case 1: // memory_order_consume
- case 2: // memory_order_acquire
+ case 1: // memory_order_consume
+ case 2: // memory_order_acquire
OrderBBs[Builder.GetInsertBlock()] = llvm::AtomicOrdering::Acquire;
break;
case 3: // memory_order_release
``````````
</details>
https://github.com/llvm/llvm-project/pull/115545
More information about the cfe-commits
mailing list