Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions datafusion/core/src/scalar.rs
Original file line number Diff line number Diff line change
Expand Up @@ -374,11 +374,16 @@ mod tests {
// Since ScalarValues are used in a non trivial number of places,
// making it larger means significant more memory consumption
// per distinct value.
#[cfg(target_arch = "aarch64")]
assert_eq!(std::mem::size_of::<ScalarValue>(), 64);
//
// The alignment requirements differ across architectures and
// thus the size of the enum appears to as as well

#[cfg(target_arch = "amd64")]
assert_eq!(std::mem::size_of::<ScalarValue>(), 48);
let expected = match cfg!(target_arch = "aarch64") {
true => 64,
false => 48,
};

assert_eq!(std::mem::size_of::<ScalarValue>(), expected);
}

#[test]
Expand Down