[llvm-branch-commits] [clang] [KeyInstr][Clang] Coerced store atoms (PR #134653)

via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Mon Apr 7 06:55:52 PDT 2025


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 e5b6141602a80a402afca6c88c275ea71edff6f5 e5779b993f4f2d5e2c1b84562f5f80adfa73f4df --extensions cpp,c -- clang/test/KeyInstructions/coerced-packed.c clang/test/KeyInstructions/coerced-ptr.c clang/test/KeyInstructions/coerced-through-memory.c clang/test/KeyInstructions/coerced.c clang/lib/CodeGen/CGCall.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/clang/lib/CodeGen/CGCall.cpp b/clang/lib/CodeGen/CGCall.cpp
index a794b884a6..2263ef7a0e 100644
--- a/clang/lib/CodeGen/CGCall.cpp
+++ b/clang/lib/CodeGen/CGCall.cpp
@@ -1413,14 +1413,16 @@ void CodeGenFunction::CreateCoercedStore(llvm::Value *Src, Address Dst,
         addInstToCurrentSourceAtom(I, Elt);
       }
     } else {
-      auto * I = Builder.CreateStore(Src, Dst.withElementType(SrcTy), DstIsVolatile);
+      auto *I =
+          Builder.CreateStore(Src, Dst.withElementType(SrcTy), DstIsVolatile);
       addInstToCurrentSourceAtom(I, Src);
     }
   } else if (SrcTy->isIntegerTy()) {
     // If the source is a simple integer, coerce it directly.
     llvm::Type *DstIntTy = Builder.getIntNTy(DstSize.getFixedValue() * 8);
     Src = CoerceIntOrPtrToIntOrPtr(Src, DstIntTy, *this);
-    auto *I = Builder.CreateStore(Src, Dst.withElementType(DstIntTy), DstIsVolatile);
+    auto *I =
+        Builder.CreateStore(Src, Dst.withElementType(DstIntTy), DstIsVolatile);
     addInstToCurrentSourceAtom(I, Src);
   } else {
     // Otherwise do coercion through memory. This is stupid, but

``````````

</details>


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


More information about the llvm-branch-commits mailing list