You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ JULIA_DEBUG=all JULIA_LOAD_PATH="@::." jj test.jl
┌ Debug: Precompiling Bug [top-level]
└ @ Base loading.jl:1186
Body::Any
1 ─ %1 = Base.llvmcall::Core.Compiler.Const(llvmcall, false)
│ %2 = (%1)(Ptr{Nothing} @0x0000000000000000, Bug.Any, Tuple{Any}, x)::Any
└── return %2
julia: /home/tbesard/Julia/julia-dev/deps/srccache/llvm-6.0.1/include/llvm/Support/Casting.h:106: static bool llvm::isa_impl_cl<llvm::GlobalVariable, const llvm::GlobalValue *>::doit(const From *) [To = llvm::GlobalVariable, From = const llvm::GlobalValue *]: Assertion `Val && "isa<> used on a null pointer"' failed.
A NULL function handle obviously crashes immediately, so the exact backtrace isn't interesting. Reproduces on both 1.0 and master. Looks like #25041 but the handle really is a literal here.
Ref JuliaGPU/CUDAnative.jl#303
The text was updated successfully, but these errors were encountered:
Uh, of course, not sure what I was thinking. Would it make sense to prevent precompilation of methods with llvmcall, in the meantime? No since the literal Function* is a precompiled global const.
Which works, because the Function* is looked up as part of the @generated function, so it isn't precompiled. However, during some unrelated other change I introduced a global call to return_types, which now causes the function containing the llvmcall to be precompiled:
Bug.jl
:main.jl
:Crashes depending on precompilation:
A
NULL
function handle obviously crashes immediately, so the exact backtrace isn't interesting. Reproduces on both 1.0 and master. Looks like #25041 but the handle really is a literal here.Ref JuliaGPU/CUDAnative.jl#303
The text was updated successfully, but these errors were encountered: