Skip to content

Commit 1fbe3bc

Browse files
authored
[release-1.11] Fix missing CodeInstance owner lookup in _jl_invoke (#59558)
Fixed on main as 92fc06f, but not fixed in earlier Julia versions
1 parent 788c31a commit 1fbe3bc

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/gf.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2925,7 +2925,8 @@ STATIC_INLINE jl_value_t *_jl_invoke(jl_value_t *F, jl_value_t **args, uint32_t
29252925
// manually inlined copy of jl_method_compiled
29262926
jl_code_instance_t *codeinst = jl_atomic_load_relaxed(&mfunc->cache);
29272927
while (codeinst) {
2928-
if (jl_atomic_load_relaxed(&codeinst->min_world) <= world && world <= jl_atomic_load_relaxed(&codeinst->max_world)) {
2928+
if (jl_atomic_load_relaxed(&codeinst->min_world) <= world && world <= jl_atomic_load_relaxed(&codeinst->max_world)
2929+
&& codeinst->owner == jl_nothing) {
29292930
jl_callptr_t invoke = jl_atomic_load_acquire(&codeinst->invoke);
29302931
if (invoke != NULL) {
29312932
jl_value_t *res = invoke(F, args, nargs, codeinst);

0 commit comments

Comments
 (0)