Skip to content

Commit

Permalink
fix fn attr 1.11 (#2114)
Browse files Browse the repository at this point in the history
  • Loading branch information
wsmoses authored Nov 21, 2024
1 parent 4f0f333 commit 5c373fb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/compiler/validation.jl
Original file line number Diff line number Diff line change
Expand Up @@ -577,6 +577,9 @@ function check_ir!(job, errors, imported, f::LLVM.Function, deletedfns)

newf, _ = get_function!(mod, fused_name, FT)

while isa(newf, LLVM.ConstantExpr)
newf = operands(newf)
end
push!(function_attributes(newf), StringAttribute("enzyme_math", fname))
# TODO we can make this relocatable if desired by having restore lookups re-create this got initializer/etc
# metadata(newf)["enzymejl_flib"] = flib
Expand Down

0 comments on commit 5c373fb

Please sign in to comment.