Skip to content

Commit

Permalink
Don't interpret Base.load_state_acquire
Browse files Browse the repository at this point in the history
This has an llvmcall doing an atomic operation...just avoid the hassle
and call it directly.

Fixes #354
  • Loading branch information
timholy committed Dec 17, 2020
1 parent fb0c899 commit 08246dd
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions src/packagedef.jl
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,11 @@ function set_compiled_methods()
end
end

# Does an atomic operation via llvmcall (this fixes #354)
for m in methods(Base.load_state_acquire)
push!(compiled_methods, m)
end

###########
# Modules #
###########
Expand Down
4 changes: 2 additions & 2 deletions test/interpret.jl
Original file line number Diff line number Diff line change
Expand Up @@ -229,10 +229,10 @@ using PyCall
let np = pyimport("numpy")
@test @interpret(PyCall.pystring_query(np.zeros)) === Union{}
end
# Issue #354 (partial fix)
# Issue #354
using HTTP
headers = Dict("User-Agent" => "Debugger.jl")
@test_broken @interpret(HTTP.request("GET", "https://api.github.com/", headers))
@test @interpret(HTTP.request("GET", "https://api.github.com/", headers))

# "correct" line numbers
defline = @__LINE__() + 1
Expand Down

0 comments on commit 08246dd

Please sign in to comment.