Skip to content
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

Fix a few allocation/inference issues #885

Merged
merged 1 commit into from
Sep 8, 2021
Merged

Fix a few allocation/inference issues #885

merged 1 commit into from
Sep 8, 2021

Conversation

quinnj
Copy link
Member

@quinnj quinnj commented Sep 8, 2021

This was from an effort to play around with precompilation some more.
There's a tricky balance where if we precompile too much of CSV.File,
then we run into the Base bug where there are Base methods missing and
cause painful allocations via invoke
(JuliaLang/julia#35972). The state of
precompilation for CSV.jl is thus pretty disappointing: precompiling
currently takes ~7.5s (which is fine, this is the number we're fine to
have keep growing), loading CSV.jl precompiled takes ~2.5s (seems a
little high, but not terrible), but the first call to CSV.File takes
~6.5s :sad_face:. At this point, I've spent too much time and don't
understand the ins and outs of precompilation interactions with later
runtime code to debug further, but hopefully we can recruit help from
some experts to take CSV.jl precompilation to the next level. As-is,
it's workable, so let's go with this for now and get this darn release
out.

This was from an effort to play around with precompilation some more.
There's a tricky balance where if we precompile too much of `CSV.File`,
then we run into the Base bug where there are Base methods missing and
cause painful allocations via invoke
(JuliaLang/julia#35972). The state of
precompilation for CSV.jl is thus pretty disappointing: precompiling
currently takes ~7.5s (which is fine, this is the number we're fine to
have keep growing), loading CSV.jl precompiled takes ~2.5s (seems a
little high, but not terrible), but the first call to `CSV.File` takes
~6.5s :sad_face:. At this point, I've spent too much time and don't
understand the ins and outs of precompilation interactions with later
runtime code to debug further, but hopefully we can recruit help from
some experts to take CSV.jl precompilation to the next level. As-is,
it's workable, so let's go with this for now and get this darn release
out.
@codecov
Copy link

codecov bot commented Sep 8, 2021

Codecov Report

Merging #885 (9b9b031) into main (9d8da50) will decrease coverage by 0.17%.
The diff coverage is 83.33%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #885      +/-   ##
==========================================
- Coverage   90.83%   90.66%   -0.18%     
==========================================
  Files           9        9              
  Lines        2139     2142       +3     
==========================================
- Hits         1943     1942       -1     
- Misses        196      200       +4     
Impacted Files Coverage Δ
src/precompile.jl 50.00% <66.66%> (ø)
src/CSV.jl 80.00% <100.00%> (ø)
src/context.jl 88.29% <100.00%> (+0.03%) ⬆️
src/file.jl 95.80% <100.00%> (ø)
src/detection.jl 95.90% <0.00%> (-0.49%) ⬇️
src/utils.jl 85.26% <0.00%> (-0.36%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 9d8da50...9b9b031. Read the comment docs.

@quinnj quinnj merged commit 8cb5893 into main Sep 8, 2021
@quinnj quinnj deleted the jq/precompile3 branch September 8, 2021 04:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant