x64: Ensure that constants are always 16 bytes for XmmMem (#4790)
Ensure that constants generated for the memory case of XmmMem values are always 16 bytes, ensuring that we don't accidantally perform an unaligned load. Fixes #4761
This commit is contained in:
@@ -804,6 +804,12 @@ macro_rules! isle_prelude_methods {
|
||||
self.lower_ctx.use_constant(data)
|
||||
}
|
||||
|
||||
#[inline]
|
||||
fn emit_u128_le_const(&mut self, value: u128) -> VCodeConstant {
|
||||
let data = VCodeConstantData::Generated(value.to_le_bytes().as_slice().into());
|
||||
self.lower_ctx.use_constant(data)
|
||||
}
|
||||
|
||||
#[inline]
|
||||
fn const_to_vconst(&mut self, constant: Constant) -> VCodeConstant {
|
||||
self.lower_ctx.use_constant(VCodeConstantData::Pool(
|
||||
|
||||
Reference in New Issue
Block a user