Skip to content

Julia 1.9 pkgimages disabled by default #82

Open
@fonsp

Description

@fonsp

Hi all!

I found out that julia-runtest disables Julia's pkgimages feature by default on Julia 1.9. You can test this by adding @test Base.JLOptions().use_pkgimages == 1 to one of your tests.

I think this because of this logic in Julia:

https://github.com/JuliaLang/julia/blob/8fbef6e3fc7b3b8a95dc44d0a0181d967219ddd5/src/jloptions.c#L824-L830

And in julia-runtest, we enable the --code-coverage flag by default.

I think this is actually a good default: disabling pkgimages is faster if you only run an environment once after compilation (The increase in precompilation time caused by generating the .so files is generally higher than the decrease in import Example.) This is the case for running tests once, and then discarding the worker, so it's good! This might change in a future Julia release, and enabling pkgimages might be the faster option for a one-off run. 🤞

Just wanted to share this discovery! It might be nice to document this, and/or to make this a flag that people can set.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions