Skip to content

Display pre-test time#86

Merged
giordano merged 7 commits into
JuliaTesting:mainfrom
christiangnrd:total_time
Mar 13, 2026
Merged

Display pre-test time#86
giordano merged 7 commits into
JuliaTesting:mainfrom
christiangnrd:total_time

Conversation

@christiangnrd

@christiangnrd christiangnrd commented Feb 7, 2026

Copy link
Copy Markdown
Contributor

Adds --debug-stats flag. This adds a printout of available memory as used by PTR to make runner # decisions before tests, a column that displays how long it took between worker running and testset starting, and on 1.11+, % of time spent in Julia precompilation.

Example:

julia> Pkg.test("Metal"; test_args=`--debug-stats --jobs=1 mtl`)
...
<Stuff>
...
Running 1 tests in parallel. If this is too many, specify the `--jobs=N` argument to the tests, or set the `JULIA_CPU_THREADS` environment variable.
Available memory: 24.014 GiB
                │   Test   │   Init   │ Compile │ ──────────────── CPU ──────────────── │
Test   (Worker) │ time (s) │ time (s) │   (%)   │ GC (s) │ GC % │ Alloc (MB) │ RSS (MB) │
mtl/metal   (1) │     4.62 │     6.17 │   88.00 │   0.18 │  3.9 │     779.42 │   952.48 │
mtl/size    (1) │     0.06 │     0.21 │   72.99 │   0.00 │  0.0 │       3.12 │   954.42 │

Test Summary: | Pass  Total   Time
  Overall     |  221    221  13.2s
    SUCCESS
     Testing Metal tests passed

Close #99

@maleadt

maleadt commented Feb 8, 2026

Copy link
Copy Markdown
Collaborator

I'm not sure that's worth an additional entry in the table. Maybe in verbose/debug mode?

@christiangnrd

Copy link
Copy Markdown
Contributor Author

I'm not sure that's worth an additional entry in the table. Maybe in verbose/debug mode?

Yes if I do ever end up taking the time to turn this into a full PR I'd make it show up in either verbose or a debug mode.

@christiangnrd christiangnrd force-pushed the total_time branch 9 times, most recently from 83446ee to 4c2b761 Compare February 12, 2026 18:54
@christiangnrd christiangnrd force-pushed the total_time branch 2 times, most recently from d924b08 to e48c1f6 Compare March 5, 2026 16:18
@christiangnrd christiangnrd marked this pull request as ready for review March 5, 2026 16:39
@giordano

giordano commented Mar 8, 2026

Copy link
Copy Markdown
Collaborator

I'm overall ok with this change, but I wonder whether this could be folded in --verbose instead of adding yet another flag to "get more information".

@christiangnrd

christiangnrd commented Mar 8, 2026

Copy link
Copy Markdown
Contributor Author

I'm overall ok with this change, but I wonder whether this could be folded in --verbose instead of adding yet another flag to "get more information".

I would prefer merging into one flag. I originally added it as a separate flag because I didn't know if so much new output would be welcome as part of --verbose flag.

@giordano

giordano commented Mar 8, 2026

Copy link
Copy Markdown
Collaborator

I would prefer this.

"this" being what exactly?

I originally added it as a separate flag because I didn't know if so much new output would be welcome as part of --verbose flag.

Maybe it's just me, but I read --verbose as "give me more output", and having a separate flag for "give me some other output, but not everything" feels a bit weird, because then both --verbose and --debug-stats separately are somewhat "verbose", just in different ways (one is "horizontally verbose", the other is "vertically verbose").

@christiangnrd

christiangnrd commented Mar 8, 2026

Copy link
Copy Markdown
Contributor Author

"this" being what exactly?

I clarified (only --verbose) the original comment.

I've merged them and I can revert if desired

@giordano giordano merged commit 9bc0209 into JuliaTesting:main Mar 13, 2026
22 checks passed
@christiangnrd christiangnrd deleted the total_time branch March 13, 2026 23:56
@giordano

Copy link
Copy Markdown
Collaborator
image

I feel like I was living better when I didn't know how much time was spent in compilation in the tests 😂

@christiangnrd

christiangnrd commented Mar 14, 2026

Copy link
Copy Markdown
Contributor Author

I feel like I was living better when I didn't know how much time was spent in compilation in the tests 😂

Don’t look at the GPUArrays tests 😬

Also I suspect that the GPU testsuites aren’t all at 99% because the gpu kernel compilation isn’t included in that compilation percentage.

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.

[Feature request] Display compilation time

3 participants