Skip to content

Commit f61ac03

Browse files
rossbergstevenfontanella
authored andcommitted
Update interpreter/valid/valid.ml
1 parent a0647a8 commit f61ac03

1 file changed

Lines changed: 8 additions & 6 deletions

File tree

interpreter/valid/valid.ml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -199,12 +199,14 @@ let check_memop (mode : mem_mode) (c : context) (memop : ('t, 's) memop) ty_size
199199
| Some sz ->
200200
check_pack sz (ty_size memop.ty) at;
201201
packed_size sz
202-
in match mode with
203-
| NonAtomic ->
204-
require (1 lsl memop.align <= size) at
205-
"alignment must not be larger than natural";
206-
| Atomic ->
207-
require (1 lsl memop.align == size) at "atomic memory instruction's alignment must equal the instruction's natural alignment"
202+
in
203+
match mode with
204+
| NonAtomic ->
205+
require (1 lsl memop.align <= size) at
206+
"alignment must not be larger than natural";
207+
| Atomic ->
208+
require (1 lsl memop.align = size) at
209+
"atomic alignment must be natural"
208210

209211

210212
(*

0 commit comments

Comments
 (0)