diff options
Diffstat (limited to 'src/binary-writer.cc')
-rw-r--r-- | src/binary-writer.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/binary-writer.cc b/src/binary-writer.cc index e5c9c4d2..03ee2147 100644 --- a/src/binary-writer.cc +++ b/src/binary-writer.cc @@ -406,6 +406,13 @@ void BinaryWriter::WriteExpr(const Func* func, const Expr* expr) { case ExprType::AtomicWait: WriteLoadStoreExpr<AtomicWaitExpr>(func, expr, "memory offset"); break; + case ExprType::AtomicFence: { + auto* fence_expr = cast<AtomicFenceExpr>(expr); + WriteOpcode(stream_, Opcode::AtomicFence); + WriteU32Leb128(stream_, fence_expr->consistency_model, + "consistency model"); + break; + } case ExprType::AtomicNotify: WriteLoadStoreExpr<AtomicNotifyExpr>(func, expr, "memory offset"); break; |