[llvm] [IR] Add elementwise modifier to atomic loads (PR #204556)

Yonah Goldberg via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 25 14:50:33 PDT 2026


================
@@ -3565,6 +3565,8 @@ void ModuleBitcodeWriter::writeInstruction(const Instruction &I,
     if (cast<LoadInst>(I).isAtomic()) {
       Vals.push_back(getEncodedOrdering(cast<LoadInst>(I).getOrdering()));
       Vals.push_back(getEncodedSyncScopeID(cast<LoadInst>(I).getSyncScopeID()));
+      if (cast<LoadInst>(I).isElementwise())
----------------
YonahGoldberg wrote:

Nit: Maybe use one cast at the top of the case

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


More information about the llvm-commits mailing list