-
Notifications
You must be signed in to change notification settings - Fork 35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Missing GC.@preserve
s?
#100
Comments
Last time I looked into this, I understood that function arguments are safe from GC collection because they can't be freed in the calling scope until after the function returns. Has this changed? |
Even if that's the case (I personally haven't read that anywhere) https://github.com/JuliaOpt/Cbc.jl/blob/master/src/CbcCInterface.jl#L77 may be called. |
Sorry, I didn't fully parse your message.
This is definitely not true anymore in >0.6. |
Maybe you read https://discourse.julialang.org/t/julia-v0-6-vs-v0-7-gc-behaviour/10002/6, but if that's still accurate, it's precedented on Edit: and see also https://discourse.julialang.org/t/julia-v0-6-vs-v0-7-gc-behaviour/10002/8. |
Ok, I understand why function arguments wouldn't be special if the function is inlined. Thanks for the links. |
I have not read all the links completely, but are you worried that |
A problem is that |
Thanks for the clarification. I still can not imagine a scenario where this reference to |
Cbc.jl doesn't have a single
GC.@preserve
statement, but post-0.6, I really think it should. What's preventingprob
from being garbage collected in calls likehttps://github.com/JuliaOpt/Cbc.jl/blob/220f0fa5d94a4382261e76fc473ec494dd85382a/src/CbcCInterface.jl#L270
?
The text was updated successfully, but these errors were encountered: