Skip to content

Commit f5cd786

Browse files
duc-nxsjudson
authored andcommitted
Set the MemAccessSize enum to actual size (#338)
Summary: Originally, the MemAccessSize value is `n - 1` for short masking code, turn out we didn't use, let's revert it back to original size. Test Plan: Co-authored-by: duc-nx <>
1 parent b57d9db commit f5cd786

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

common/src/memory/traits.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,10 @@ use std::collections::HashSet;
44

55
#[derive(Debug, Clone, Copy, Eq, PartialEq, Hash, Serialize, Deserialize)]
66
/// Represents the size of memory access operations.
7-
/// The value of enum is for efficient masking purpose.
87
pub enum MemAccessSize {
9-
Byte = 0,
10-
HalfWord = 1,
11-
Word = 3,
8+
Byte = 1,
9+
HalfWord = 2,
10+
Word = 4,
1211
}
1312

1413
impl MemAccessSize {

0 commit comments

Comments
 (0)