Skip to content

Commit 6ec844b

Browse files
Update src/gf.c
Co-authored-by: Jameson Nash <vtjnash@gmail.com>
1 parent 36b79eb commit 6ec844b

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

src/gf.c

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2867,8 +2867,12 @@ jl_code_instance_t *jl_compile_method_internal(jl_method_instance_t *mi, size_t
28672867
// Is a recompile if there is cached code, and it was compiled (not only inferred) before
28682868
int is_recompile = 0;
28692869
jl_code_instance_t *codeinst_old = jl_atomic_load_relaxed(&mi->cache);
2870-
if ((codeinst_old != NULL) && (jl_atomic_load_relaxed(&codeinst_old->invoke) != NULL)) {
2871-
is_recompile = 1;
2870+
while (codeinst_old != NULL) {
2871+
if (jl_atomic_load_relaxed(&codeinst_old->invoke) != NULL) {
2872+
is_recompile = 1;
2873+
break;
2874+
}
2875+
codeinst_old = jl_atomic_load_relaxed(&codeinst_old->next);
28722876
}
28732877

28742878
// This codeinst hasn't been previously inferred do that now

0 commit comments

Comments
 (0)