mirror of
https://github.com/LuaJIT/LuaJIT.git
synced 2025-02-07 15:14:08 +00:00
Preserve snapshot #0 PC for root traces.
This commit is contained in:
parent
e6bcb545f8
commit
f3197046b8
@ -136,6 +136,11 @@ void lj_snap_add(jit_State *J)
|
||||
/* Merge if no ins. inbetween or if requested and no guard inbetween. */
|
||||
if (J->mergesnap ? !irt_isguard(J->guardemit) :
|
||||
(nsnap > 0 && J->cur.snap[nsnap-1].ref == J->cur.nins)) {
|
||||
if (nsnap == 1 && J->parent == 0) {
|
||||
/* But preserve snap #0 PC for root traces. */
|
||||
J->mergesnap = 0;
|
||||
return;
|
||||
}
|
||||
nsnapmap = J->cur.snap[--nsnap].mapofs;
|
||||
} else {
|
||||
lj_snap_grow_buf(J, nsnap+1);
|
||||
|
Loading…
Reference in New Issue
Block a user