From a0ecdbfbfe57a57ab33bdb5e1de4d5dfa8407dbb Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Tue, 15 Oct 2024 16:57:09 -0700 Subject: Remove "simple" flag from forwarded ICs I don't think we should ever consider forwarded IC's to be "simple". Previously, the "simple" flag would be copied to the derived IC and this happened to cause struct set / get iseqs to write an invalid CC fastpath: https://github.com/tenderlove/ruby/blob/f45eb3dcb9c7d849064cb802953f37e1cf9f3996/vm_insnhelper.c#L4726-L4729 [Bug #20799] --- vm_args.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'vm_args.c') diff --git a/vm_args.c b/vm_args.c index 0ecdc31a31..28f685d7dd 100644 --- a/vm_args.c +++ b/vm_args.c @@ -1177,7 +1177,7 @@ vm_caller_setup_fwd_args(const rb_execution_context_t *ec, rb_control_frame_t *r *adjusted_ci = VM_CI_ON_STACK( site_mid, - (caller_flag | (site_flag & (VM_CALL_FCALL | VM_CALL_FORWARDING))), + ((caller_flag & ~VM_CALL_ARGS_SIMPLE) | (site_flag & (VM_CALL_FCALL | VM_CALL_FORWARDING))), site_argc + caller_argc, kw ); -- cgit v1.2.3