Skip to content

Commit

Permalink
WIP: Improve 1.11 support (#1963)
Browse files Browse the repository at this point in the history
* WIP: Improve 1.11 support

* fix

* fix
  • Loading branch information
wsmoses authored Oct 15, 2024
1 parent 1bbcaa9 commit 2a1f213
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 1 addition & 3 deletions src/compiler.jl
Original file line number Diff line number Diff line change
Expand Up @@ -5384,10 +5384,8 @@ function create_abi_wrapper(
end
end

cf = nested_codegen!(Mode, mod, add_one_in_place, Tuple{Any}, world)
push!(function_attributes(cf), EnumAttribute("alwaysinline", 0))
for shadowv in shadows
c = call!(builder, LLVM.function_type(cf), cf, [shadowv])
c = emit_apply_generic!(builder, [unsafe_to_llvm(builder, add_one_in_place), shadowv])
if get_subprogram(llvm_f) !== nothing
metadata(c)[LLVM.MD_dbg] =
DILocation(0, 0, get_subprogram(llvm_f))
Expand Down
6 changes: 4 additions & 2 deletions src/compiler/optimize.jl
Original file line number Diff line number Diff line change
Expand Up @@ -791,8 +791,10 @@ function nodecayed_phis!(mod::LLVM.Module)
if addr == 13 && hasload && addrspace(value_type(v)) == 10
return v, offset, hasload
end
if addr == 13 && isa(v, LLVM.LoadInst) && !hasload
return getparent(operands(v)[1], offset, true)
if addr == 13 && !hasload
if isa(v, LLVM.LoadInst)
return getparent(operands(v)[1], offset, true)
end
end

if addr == 13 && isa(v, LLVM.ConstantExpr)
Expand Down

0 comments on commit 2a1f213

Please sign in to comment.