Project

General

Profile

« Previous | Next » 

Revision 04c5adf8

Added by alanwu (Alan Wu) over 2 years ago

YJIT: Fix staying in invalidated code after proc calls

Previously, there is no instruction boundary patch point after
the call to a non-leaf C function we generate for
OPTIMIZED_METHOD_TYPE_CALL. This meant that if code GC is triggered
while inside the C function, we would keep running invalidated code when
we return from the C function. This had the effect of running
stale branch stubs, jumping to bad code, etc.

Use jit_prepare_routine_call() to make sure we exit from the invalidated
region as soon as possible after the C call in case of invalidation.