-
Notifications
You must be signed in to change notification settings - Fork 14
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
Precompile times seem long #180
Comments
Honestly, I've noticed this recently as well. The relative precompilation times have exploded. I don't have the bandwidth to track this down, but it would be nice to get it under control. We really shouldn't be longer than Makie. @chrstphrbrns any thoughts? |
What does the "precompilation helper" code do? When I remove it, precompilation drops from 40s to 5s |
It's meant to speed up Time to First X, which in the case of TiffImages is the time to load the first image. Julia has to JIT the code the first time it's run and the "precompilation helper" code is meant to shift that to precompile time. Does the initial cold load time slow down if you remove it? |
For one particular image, load goes from 3s to 4s without the helper code |
I measured precompilation, using, and TTFX times for TiffImages v0.10.2, v0.11.3, and "dev" that is v0.11.3 without precompilation helper https://github.com/tlnagy/TiffImages.jl/blob/master/src/TiffImages.jl#L43-L59. Julia versions v1.8.5, v1.9.4, v1.10.8, v1.11.3. Format of results is
Higher the Julia version number, bigger the size of compiled files on disk. Julia v1.10.8 seems fastest. I would prefer fast precompilation times for TiffImages as I rarely encounter the format, but I do see often the precompilation of TiffImages spinning and spinning on the screen.
|
Thanks @jaakkor2 for the thorough testing. Yeah, it's unfortunate, but a tripling in time to first image (2.7x slower in your I could be open to reducing the number of branches that we precompile and only prepare for the simple Gray+N0f8, N0f16 images and we can let the rest be JITed when needed. |
This is admittedly a low-effort issue as I don't use TiffImages and have not tested it locally, but I noticed today that this package needs a sizable chunk of CI time of AlgebraOfGraphics.jl for precompilation. Here's a couple of entries from the log for comparison:
It surprises me that the package needs more precompilation time than Makie :) Maybe something could be optimized there given that this package appears as a dep in a few image-related packages?
The text was updated successfully, but these errors were encountered: