Skip to content
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

Backports for 1.8-rc2/1.8.0 #45491

Merged
merged 40 commits into from
Jul 6, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
63e5553
Make `isdispatchtuple` consistent for `typeof(Union{})` (#45348)
Keno May 22, 2022
25122e4
Do not set MCPU on Apple Silicon (#45409)
fxcoudert May 21, 2022
0769bb5
Update LibCURL to 7.83.1 (#45443)
fxcoudert May 29, 2022
bde7223
Revert "fix #45440, improve the robustness of concrete-evaled callsit…
aviatesk May 30, 2022
801458d
follow #45440, add assertion to check concrete-eval call is compileable
aviatesk May 27, 2022
8f1a4ce
tweak NEWS.md
aviatesk May 31, 2022
32106ab
note `@inline` inside body usage (#45531)
Moelf Jun 1, 2022
4c65dce
rename `Base.@assume_effects :total_may_throw` setting to `:foldable`…
aviatesk Jun 1, 2022
ba72387
also set the version in `pkgorigins` (#44318)
KristofferC Feb 24, 2022
9e17fb6
Make llvmunwind depend on llvm (#45380)
fxcoudert May 29, 2022
b6e47d4
csl.mk: use libgcc_s 1.1 on aarch64-darwin (#45504)
fxcoudert May 29, 2022
d6bbed6
Fix zero-length array concatenation validation (#45383)
BioTurboNick Jun 1, 2022
a004142
Fix segfault in `Diagonal` * `OffsetMatrix` (#45548)
jishnub Jun 2, 2022
6f0bfc2
bump Pkg version to latest 1.8
Jun 8, 2022
087ba27
[Profile] `threads` here is wrong to use `nthreads` (#45547)
vtjnash Jun 2, 2022
43df1f4
rename `is_concrete_eval_eligible` utility query to `is_foldable` (#4…
aviatesk Jun 9, 2022
3a2eb39
Revert "codegen: explicitly handle Float16 intrinsics (#45249)" (#45627)
KristofferC Jun 13, 2022
8fd0b2a
AMD Zen 3 CPU support (Fixes #45657) (#45663) (#45667)
LebedevRI Jun 14, 2022
8b2e406
update `@assume_effects`
aviatesk Jun 15, 2022
38b836a
Update LLVM to 13.0.1+1
vchuravy Jun 19, 2022
4acdabe
fixup! Update LLVM to 13.0.1+1
vchuravy Jun 20, 2022
853dff9
fixup! fixup! Update LLVM to 13.0.1+1
vchuravy Jun 20, 2022
67f365c
Improve inference in typejoin (#44390)
timholy Mar 3, 2022
f83a9b3
[1.8] Update LLVM to 13.0.2-2 (#45917)
vchuravy Jul 4, 2022
b97d34a
Report any recompilation in time macro (#45015)
IanButterworth Apr 20, 2022
ad61d03
Add compilation & recompilation time to time_imports macro (#45064)
IanButterworth Apr 28, 2022
0646ce7
loading: prevent module replacement during precompile
vtjnash Jun 30, 2022
89cb6df
loading: add missing deadlock causing #45704
vtjnash Jun 29, 2022
73b37b2
loading: validate all cache files before loading any
vtjnash Jun 29, 2022
0ce21a6
loading: stop corrupting memory all over the place
vtjnash Jun 29, 2022
11cfa4e
Fix llvm powi intrinsic calls in fastmath.jl (#44580)
pchintalapudi Mar 12, 2022
8fcc2dd
fix `tuple_tfunc` on `Union` containing `Type{...}` (#44725)
aviatesk Mar 30, 2022
97c17e0
inference: don't widen `DataType`/`UninAll` to `Type` within `tuple_t…
aviatesk Apr 11, 2022
fbae62d
Pass along backlog keyword argument in Sockets.listen (#45737)
quinnj Jun 19, 2022
0559fa6
Use https for downloading of unicode data from unicode.org (#45750)
ViralBShah Jun 19, 2022
929c48a
Fix libblastrampoline full source build to install into the right loc…
ViralBShah Jun 19, 2022
14be137
Document file descriptors in `run` (#45710)
oscardssmith Jun 21, 2022
5894899
fix obvious_subtype bug with egal objects (#45771)
JeffBezanson Jun 27, 2022
2b6c746
Remove duplicate definition of jl_gc_safepoint (#45120)
fingolfin Jul 1, 2022
7a23871
Backport #45727 and a patch to make it work (#45938)
kpamnany Jul 5, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add compilation & recompilation time to time_imports macro (#45064)
(cherry picked from commit 9320fba)
  • Loading branch information
IanButterworth authored and KristofferC committed Jul 4, 2022
commit ad61d037ddc492621a8535381b67ce9bac0f14df
24 changes: 21 additions & 3 deletions base/loading.jl
Original file line number Diff line number Diff line change
Expand Up @@ -895,7 +895,13 @@ const TIMING_IMPORTS = Threads.Atomic{Int}(0)
# returns `false` if the module isn't known to be precompilable
# returns the set of modules restored if the cache load succeeded
@constprop :none function _require_search_from_serialized(pkg::PkgId, sourcepath::String, depth::Int = 0)
t_before = time_ns()
timing_imports = TIMING_IMPORTS[] > 0
try
if timing_imports
t_before = time_ns()
cumulative_compile_timing(true)
t_comp_before = cumulative_compile_time_ns()
end
paths = find_all_in_cache_path(pkg)
for path_to_try in paths::Vector{String}
staledeps = stale_cachefile(sourcepath, path_to_try)
Expand Down Expand Up @@ -927,17 +933,29 @@ const TIMING_IMPORTS = Threads.Atomic{Int}(0)
if isa(restored, Exception)
@debug "Deserialization checks failed while attempting to load cache from $path_to_try" exception=restored
else
if TIMING_IMPORTS[] > 0
if timing_imports
elapsed = round((time_ns() - t_before) / 1e6, digits = 1)
comp_time, recomp_time = cumulative_compile_time_ns() .- t_comp_before
tree_prefix = depth == 0 ? "" : " "^(depth-1)*"┌ "
print(lpad(elapsed, 9), " ms ")
printstyled(tree_prefix, color = :light_black)
println(pkg.name)
print(pkg.name)
if comp_time > 0
printstyled(" ", Ryu.writefixed(Float64(100 * comp_time / (elapsed * 1e6)), 2), "% compilation time", color = Base.info_color())
end
if recomp_time > 0
perc = Float64(100 * recomp_time / comp_time)
printstyled(" (", perc < 1 ? "<1" : Ryu.writefixed(perc, 0), "% recompilation)", color = Base.warn_color())
end
println()
end
return restored
end
end
return !isempty(paths)
finally
timing_imports && cumulative_compile_timing(false)
end
end

# to synchronize multiple tasks trying to import/using something
Expand Down
32 changes: 21 additions & 11 deletions stdlib/InteractiveUtils/src/macros.jl
Original file line number Diff line number Diff line change
Expand Up @@ -354,24 +354,34 @@ See also: [`code_native`](@ref), [`@code_llvm`](@ref), [`@code_typed`](@ref) and
@time_imports

A macro to execute an expression and produce a report of any time spent importing packages and their
dependencies.
dependencies. Any compilation time will be reported as a percentage, and how much of which was recompilation, if any.

If a package's dependencies have already been imported either globally or by another dependency they will
not appear under that package and the package will accurately report a faster load time than if it were to
be loaded in isolation.

!!! compat "Julia 1.9"
Reporting of any compilation and recompilation time was added in Julia 1.9

```julia-repl
julia> @time_imports using CSV
3.5 ms ┌ IteratorInterfaceExtensions
27.4 ms ┌ TableTraits
614.0 ms ┌ SentinelArrays
138.6 ms ┌ Parsers
2.7 ms ┌ DataValueInterfaces
3.4 ms ┌ DataAPI
59.0 ms ┌ WeakRefStrings
35.4 ms ┌ Tables
49.5 ms ┌ PooledArrays
972.1 ms CSV
0.4 ms ┌ IteratorInterfaceExtensions
11.1 ms ┌ TableTraits 84.88% compilation time
145.4 ms ┌ SentinelArrays 66.73% compilation time
42.3 ms ┌ Parsers 19.66% compilation time
4.1 ms ┌ Compat
8.2 ms ┌ OrderedCollections
1.4 ms ┌ Zlib_jll
2.3 ms ┌ TranscodingStreams
6.1 ms ┌ CodecZlib
0.3 ms ┌ DataValueInterfaces
15.2 ms ┌ FilePathsBase 30.06% compilation time
9.3 ms ┌ InlineStrings
1.5 ms ┌ DataAPI
31.4 ms ┌ WeakRefStrings
14.8 ms ┌ Tables
24.2 ms ┌ PooledArrays
2002.4 ms CSV 83.49% compilation time
```

!!! note
Expand Down
2 changes: 1 addition & 1 deletion stdlib/InteractiveUtils/test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -641,7 +641,7 @@ end
buf = read(fname)
rm(fname)

@test occursin("ms Foo3242\n", String(buf))
@test occursin("ms Foo3242", String(buf))

finally
filter!((≠)(dir), LOAD_PATH)
Expand Down