@@ -1078,7 +1078,7 @@ function set_module_types!(mod::LLVM.Module, primalf::Union{Nothing, LLVM.Functi
10781078
10791079 byref = arg. cc
10801080
1081- rest = copy (typetree ( arg. typ, ctx, dl))
1081+ rest = copy (typetree_total (job, typetree, arg. typ, ctx, dl))
10821082
10831083 if byref == GPUCompiler. BITS_REF || byref == GPUCompiler. MUT_REF
10841084 # adjust first path to size of type since if arg.typ is {[-1]:Int}, that doesn't mean the broader
@@ -1103,7 +1103,7 @@ function set_module_types!(mod::LLVM.Module, primalf::Union{Nothing, LLVM.Functi
11031103 if sret != = nothing
11041104 idx = 0
11051105 if ! in (0 , parmsRemoved)
1106- rest = typetree ( sret, ctx, dl)
1106+ rest = typetree_total (job, sret, ctx, dl)
11071107 push! (
11081108 parameter_attributes (f, idx + 1 ),
11091109 StringAttribute (" enzyme_type" , string (rest)),
@@ -1125,12 +1125,12 @@ function set_module_types!(mod::LLVM.Module, primalf::Union{Nothing, LLVM.Functi
11251125 LLVM. return_type (LLVM. function_type (f)) != LLVM. VoidType ()
11261126 @assert ! retRemoved
11271127 rest = if llRT == Ptr{RT}
1128- typeTree = copy (typetree ( RT, ctx, dl))
1128+ typeTree = copy (typetree_total (job, RT, ctx, dl))
11291129 merge! (typeTree, TypeTree (API. DT_Pointer, ctx))
11301130 only! (typeTree, - 1 )
11311131 typeTree
11321132 else
1133- typetree ( RT, ctx, dl)
1133+ typetree_total (job, RT, ctx, dl)
11341134 end
11351135 push! (return_attributes (f), StringAttribute (" enzyme_type" , string (rest)))
11361136 end
0 commit comments