From c70f753a51a1785013a56a75f55f08f7df74b8a4 Mon Sep 17 00:00:00 2001 From: Laurence Tratt Date: Fri, 10 Jan 2025 21:06:41 +0000 Subject: [PATCH] The 16 byte case here can't possibly be correct in general. I'm not sure why we ever ended up with this: I don't see anything that triggers it. If there is something that relies on it, it surely only works by accident, and we're better hitting the `todo` and then fixing this properly. --- ykrt/src/compile/jitc_yk/codegen/x64/deopt.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ykrt/src/compile/jitc_yk/codegen/x64/deopt.rs b/ykrt/src/compile/jitc_yk/codegen/x64/deopt.rs index 592d4beea..769063907 100644 --- a/ykrt/src/compile/jitc_yk/codegen/x64/deopt.rs +++ b/ykrt/src/compile/jitc_yk/codegen/x64/deopt.rs @@ -267,8 +267,7 @@ pub(crate) extern "C" fn __yk_deopt( unsafe { rbp.offset(isize::from(*extra)) } }; match size { - // FIXME: Check that 16-byte writes are for float registers only. - 16 | 8 => unsafe { ptr::write::(temp as *mut u64, jitval) }, + 8 => unsafe { ptr::write::(temp as *mut u64, jitval) }, 4 => unsafe { ptr::write::(temp as *mut u32, jitval as u32) }, 2 => unsafe { ptr::write::(temp as *mut u16, jitval as u16) }, _ => todo!("{}", size),