Enzyme.jl
Enzyme.jl copied to clipboard
Better error for `Active{Vector{Float64}}`
~/.julia/packages/GPUCompiler/XyxTy/src/utils.jl:35
ERROR: LoadError: Conversion of boxed type Vector{Float64} is not allowed
Stacktrace:
[1] error(s::String)
@ Base ./error.jl:33
[2] convert(::Type{LLVM.LLVMType}, typ::Type; ctx::LLVM.Context, allow_boxed::Bool)
@ LLVM.Interop ~/.julia/packages/LLVM/szqwr/src/interop/base.jl:92
[3] create_abi_wrapper(enzymefn::LLVM.Function, F::Type, argtypes::Vector{DataType}, rettype::Type, actualRetType::Type, Mode::Enzyme.API.CDerivativeMode, augmented::Nothing, dupClosure::Bool, width::Int64)
@ Enzyme.Compiler ~/.julia/packages/Enzyme/aFZx5/src/compiler.jl:3234
[4] enzyme!(job::GPUCompiler.CompilerJob{Enzyme.Compiler.EnzymeTarget, Enzyme.Compiler.EnzymeCompilerParams, GPUCompiler.FunctionSpec{typeof(loss), Tuple{Vector{Float64}, Vector{Vector{Float64}}, Vector{Vector{Float64}}, Vector{Vector{Float64}}, Vector{Vector{Float64}}, Matrix{Float64}, Matrix{Float64}, Matrix{Float64}}}}, mod::LLVM.Module, primalf::LLVM.Function, adjoint::GPUCompiler.FunctionSpec{typeof(loss), Tuple{Active{Vector{Float64}}, Const{Vector{Vector{Float64}}}, Const{Vector{Vector{Float64}}}, Const{Vector{Vector{Float64}}}, Const{Vector{Vector{Float64}}}, Const{Matrix{Float64}}, Const{Matrix{Float64}}, Const{Matrix{Float64}}}}, mode::Enzyme.API.CDerivativeMode, width::Int64, parallel::Bool, actualRetType::Type, dupClosure::Bool, wrap::Bool, modifiedBetween::Bool)
found by @dallasfoster