Index: lib/Transforms/NaCl/PNaClABISimplify.cpp |
diff --git a/lib/Transforms/NaCl/PNaClABISimplify.cpp b/lib/Transforms/NaCl/PNaClABISimplify.cpp |
index f8f78135a8b4ce8c9e02f950e36d74da74968b86..189d87f2cbdc20b77f25b6ed4828e630ab5a5bf4 100644 |
--- a/lib/Transforms/NaCl/PNaClABISimplify.cpp |
+++ b/lib/Transforms/NaCl/PNaClABISimplify.cpp |
@@ -94,6 +94,8 @@ void llvm::PNaClABISimplifyAddPostOptPasses(PassManager &PM) { |
// ExpandGetElementPtr must follow ExpandConstantExpr to expand the |
// getelementptr instructions it creates. |
PM.add(createExpandGetElementPtrPass()); |
+ // Rewrite atomic and volatile instructions with intrinsic calls. |
+ PM.add(createRewriteAtomicsPass()); |
// ReplacePtrsWithInts assumes that getelementptr instructions and |
// ConstantExprs have already been expanded out. |
PM.add(createReplacePtrsWithIntsPass()); |