@@ -4670,17 +4670,17 @@ HOT_FUNC int scheduler_entry_point(GlobalContext *glb)
46704670 DECODE_LITERAL (live , pc );
46714671 term slots_term ;
46724672 DECODE_COMPACT_TERM (slots_term , pc );
4673- DEST_REGISTER (dreg );
4674- DECODE_DEST_REGISTER (dreg , pc );
4673+ GC_SAFE_DEST_REGISTER (dreg );
4674+ DECODE_DEST_REGISTER_GC_SAFE (dreg , pc );
46754675
46764676 #ifdef IMPL_CODE_LOADER
46774677 TRACE ("bs_start_match2/5\n" );
46784678 #endif
46794679
46804680 #ifdef IMPL_EXECUTE_LOOP
4681- TRACE ("bs_start_match2/5, fail=%i src=0x%lx live=%u arg3=0x%lx dreg=%c%i\n" , fail , src , (unsigned ) live , slots_term , T_DEST_REG (dreg ));
4681+ TRACE ("bs_start_match2/5, fail=%i src=0x%lx live=%u arg3=0x%lx dreg=%c%i\n" , fail , src , (unsigned ) live , slots_term , T_DEST_REG_GC_SAFE (dreg ));
46824682 if (!(term_is_binary (src ) || term_is_match_state (src ))) {
4683- WRITE_REGISTER (dreg , src );
4683+ WRITE_REGISTER_GC_SAFE (dreg , src );
46844684 pc = mod -> labels [fail ];
46854685 } else {
46864686 int slots = term_to_int (slots_term );
@@ -4695,7 +4695,7 @@ HOT_FUNC int scheduler_entry_point(GlobalContext *glb)
46954695
46964696 term match_state = term_alloc_bin_match_state (src , slots , & ctx -> heap );
46974697
4698- WRITE_REGISTER (dreg , match_state );
4698+ WRITE_REGISTER_GC_SAFE (dreg , match_state );
46994699 }
47004700 #endif
47014701 break ;
@@ -6459,15 +6459,15 @@ HOT_FUNC int scheduler_entry_point(GlobalContext *glb)
64596459 DECODE_LITERAL (live , pc );
64606460 term src ;
64616461 DECODE_COMPACT_TERM (src , pc );
6462- DEST_REGISTER (dreg );
6463- DECODE_DEST_REGISTER (dreg , pc );
6462+ GC_SAFE_DEST_REGISTER (dreg );
6463+ DECODE_DEST_REGISTER_GC_SAFE (dreg , pc );
64646464
64656465 #ifdef IMPL_CODE_LOADER
64666466 TRACE ("bs_start_match4/4\n" );
64676467 #endif
64686468
64696469 #ifdef IMPL_EXECUTE_LOOP
6470- TRACE ("bs_start_match4/4, fail_atom=%u fail_label=%u live=%u src=%p dreg=%c%i\n" , (unsigned ) fail_atom , (unsigned ) fail_label , (unsigned ) live , (void * ) src , T_DEST_REG (dreg ));
6470+ TRACE ("bs_start_match4/4, fail_atom=%u fail_label=%u live=%u src=%p dreg=%c%i\n" , (unsigned ) fail_atom , (unsigned ) fail_label , (unsigned ) live , (void * ) src , T_DEST_REG_GC_SAFE (dreg ));
64716471
64726472 // no_fail: we know it's a binary or a match_state
64736473 // resume: we know it's a match_state
@@ -6485,7 +6485,7 @@ HOT_FUNC int scheduler_entry_point(GlobalContext *glb)
64856485 src = x_regs [live ];
64866486 term match_state = term_alloc_bin_match_state (src , 0 , & ctx -> heap );
64876487
6488- WRITE_REGISTER (dreg , match_state );
6488+ WRITE_REGISTER_GC_SAFE (dreg , match_state );
64896489 }
64906490 #endif
64916491 break ;
0 commit comments