Commit 2ad6627
Fixup measurement for --trace-compile-timing w/ nested compilations. (#59363)
Use a separate inference_start and compilation_start, where
compilation_start does not do anything special for reentrancy.
Here is an example which has a quick-to-compile nested dynamic dispatch,
but that nested function runs for a long time:
```julia
./julia --startup=no --trace-compile=stderr --trace-compile-timing -e '
Base.@assume_effects :foldable function nested1(x)
sum(collect(x for _ in 1:1000_000_000))
end
f1(x) = nested1(sizeof(x)) + x
f1(2)'
#= 12.7 ms =# precompile(Tuple{typeof(Main.nested1), Int64})
#= 3809.3 ms =# precompile(Tuple{typeof(Main.f1), Int64})
```
This fixes a small issue introduced here:
https://github.com/JuliaLang/julia/pull/59220/files#r2292021838
(cherry picked from commit be59100)1 parent 63f7c79 commit 2ad6627
1 file changed
+6
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3483 | 3483 | | |
3484 | 3484 | | |
3485 | 3485 | | |
3486 | | - | |
| 3486 | + | |
| 3487 | + | |
3487 | 3488 | | |
3488 | 3489 | | |
3489 | 3490 | | |
| |||
3510 | 3511 | | |
3511 | 3512 | | |
3512 | 3513 | | |
3513 | | - | |
| 3514 | + | |
3514 | 3515 | | |
3515 | 3516 | | |
3516 | 3517 | | |
3517 | 3518 | | |
3518 | 3519 | | |
3519 | 3520 | | |
3520 | | - | |
| 3521 | + | |
3521 | 3522 | | |
3522 | 3523 | | |
3523 | 3524 | | |
| |||
3547 | 3548 | | |
3548 | 3549 | | |
3549 | 3550 | | |
3550 | | - | |
| 3551 | + | |
3551 | 3552 | | |
3552 | 3553 | | |
3553 | 3554 | | |
| |||
3565 | 3566 | | |
3566 | 3567 | | |
3567 | 3568 | | |
3568 | | - | |
| 3569 | + | |
3569 | 3570 | | |
3570 | 3571 | | |
3571 | 3572 | | |
| |||
0 commit comments