Really fix emit_small_memcpy this time!

This commit is contained in:
bjorn3
2019-01-11 13:45:10 +01:00
committed by Dan Gohman
parent 3809e7252d
commit 2f0e0dd995

View File

@@ -612,7 +612,7 @@ impl<'a> FunctionBuilder<'a> {
"`size` is smaller than `dest` and `src`'s alignment value."
);
let (access_size, int_type) = if access_size > 8 {
let (access_size, int_type) = if access_size <= 8 {
(access_size, Type::int((access_size * 8) as u16).unwrap())
} else {
(8, types::I64)
@@ -693,7 +693,7 @@ impl<'a> FunctionBuilder<'a> {
"`size` is smaller than `dest` and `src`'s alignment value."
);
let (access_size, int_type) = if access_size > 8 {
let (access_size, int_type) = if access_size <= 8 {
(access_size, Type::int((access_size * 8) as u16).unwrap())
} else {
(8, types::I64)