Conversation
With this PR: ``` (ChainRulesCore) pkg> precompile Precompiling project... 1 dependency successfully precompiled in 2 seconds (1 already precompiled) julia> @time using ChainRulesCore 0.082255 seconds (157.13 k allocations: 9.737 MiB, 5.59% compilation time) ``` Before: ``` julia> @time using ChainRulesCore 0.111551 seconds (443.47 k allocations: 25.618 MiB, 3.87% compilation time) ``` Removing the hook alltogether: ``` julia> @time using ChainRulesCore 0.033357 seconds (36.37 k allocations: 2.399 MiB, 17.75% compilation time) ``` That's still more overhead than I'd like, so we should still discuss whether we could avoid these hooks, but it does at least improve the current situation somewhat. Ref #340
Codecov Report
@@ Coverage Diff @@
## master #341 +/- ##
==========================================
+ Coverage 90.00% 90.01% +0.01%
==========================================
Files 14 14
Lines 540 541 +1
==========================================
+ Hits 486 487 +1
Misses 54 54
Continue to review full report at Codecov.
|
|
Nice. But for now this seems good |
oxinabox
left a comment
There was a problem hiding this comment.
Don't for get to bump the version and tag a release
src/ruleset_loading.jl
Outdated
| end | ||
| end | ||
|
|
||
| precompile(_package_hook, (Base.PkgId,)) |
There was a problem hiding this comment.
Can we put this in a seperate file?
precompile.jl
We should probably be precompiling a bunch of things
|
What's the timing on putting these stuff inside its own module and setting |
So it takes a little longer than with this PR, but allocations go down. |
|
Hm, I wonder what still takes so much time... |
|
Not sure, profiling wasn't very conclusive to me. I am going to merge this for now, since it's a definite improvement over the current state. |
With this PR:
Before:
Removing the hook alltogether:
That's still more overhead than I'd like, so we should still discuss
whether we could avoid these hooks, but it does at least improve the current
situation somewhat.
Ref #340