-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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 release 1.11 #53790
Backports release 1.11 #53790
Commits on Mar 20, 2024
-
Add an IndexStyle example to the diagind docstring (#53757)
Also, simplifies the docstring by splitting the usage into two lines. (cherry picked from commit 0b1587c)
Configuration menu - View commit details
-
Copy full SHA for 9b14cc4 - Browse repository at this point
Copy the full SHA 9b14cc4View commit details -
remove dllexport
jl_arraylen
which no longer exists (#53765)(cherry picked from commit 1d532f4)
Configuration menu - View commit details
-
Copy full SHA for 005ac6d - Browse repository at this point
Copy the full SHA 005ac6dView commit details -
Remove some duplicates from emitted compilation traces for Julia 1.10 (…
Configuration menu - View commit details
-
Copy full SHA for a579dab - Browse repository at this point
Copy the full SHA a579dabView commit details
Commits on Mar 27, 2024
-
Add missing GC_POP() in emit_cfunction (#53809)
~~Apparently somewhere in codegen inside `emit_codeinst`some piece of code is relying on the implicit try catch gcstack restoring. I haven't got the analyzer working on that file yet (it has hundreds of issues and it doesn't like C++ code that much + the file is tens of thousands of lines after includes so it struggles).~~ This fixes the compileall segfault in apple-aarch64 ci. #53811 (cherry picked from commit 52fc796)
Configuration menu - View commit details
-
Copy full SHA for 0a7a95c - Browse repository at this point
Copy the full SHA 0a7a95cView commit details -
Configuration menu - View commit details
-
Copy full SHA for 6f6cae8 - Browse repository at this point
Copy the full SHA 6f6cae8View commit details -
precompilepkgs: simplify custom config printing if only one (#53805)
Currently it's a bit excessive in the `Pkg.test` precompile job ![Screenshot 2024-03-20 at 12 04 03 PM](https://github.com/JuliaLang/julia/assets/1694067/7600f0b8-6e4b-43b2-9c42-c8d5d16b8d57) This PR ``` Precompiling project for configuration --code-coverage=none --color=yes --check-bounds=yes --warn-overwrite=yes --depwarn=yes --inline=yes --startup-file=no --track-allocation=none... 354.9 ms ✓ RFFT 1 dependency successfully precompiled in 1 seconds. 38 already precompiled. ``` Pkg could also just set the non-default flags to minimize the list. (cherry picked from commit 9291845)
Configuration menu - View commit details
-
Copy full SHA for a414011 - Browse repository at this point
Copy the full SHA a414011View commit details -
Fixes JuliaDebug/Cthulhu.jl#541 by picking up libuv/libuv@3ecce91. (cherry picked from commit 5ed51d3)
Configuration menu - View commit details
-
Copy full SHA for ce13c35 - Browse repository at this point
Copy the full SHA ce13c35View commit details -
MPFR 4.2.1 was released on 22 August 2023. It contains bugfixes. (cherry picked from commit 61caaa8)
Configuration menu - View commit details
-
Copy full SHA for 3cc6c5c - Browse repository at this point
Copy the full SHA 3cc6c5cView commit details -
precompilepkgs: fix error reporting (#53862)
(cherry picked from commit fc2d3af)
Configuration menu - View commit details
-
Copy full SHA for 08c4987 - Browse repository at this point
Copy the full SHA 08c4987View commit details -
Add
_unsetindex!
methods forSubArray
s andCartesianIndex
es (#5……3383) With this, the following (and equivalent calls) work: ```julia julia> copyto!(view(zeros(BigInt, 2), 1:2), Vector{BigInt}(undef,2)) 2-element view(::Vector{BigInt}, 1:2) with eltype BigInt: #undef #undef julia> copyto!(view(zeros(BigInt, 2), 1:2), view(Vector{BigInt}(undef,2), 1:2)) 2-element view(::Vector{BigInt}, 1:2) with eltype BigInt: #undef #undef ``` Close #53098. With this, all the `_unsetindex!` branches in `copyto_unaliased!` work for `Array`-views, and this makes certain indexing operations vectorize and speed-up: ```julia julia> using BenchmarkTools julia> a = view(rand(100,100), 1:100, 1:100); b = view(similar(a), axes(a)...); julia> @Btime copyto!($b, $a); 16.427 μs (0 allocations: 0 bytes) # master 2.308 μs (0 allocations: 0 bytes) # PR ``` Improves (but doesn't resolve) #40962 and #53158 ```julia julia> a = rand(40,40); b = rand(40,40); julia> @Btime $a[1:end,1:end] .= $b; 5.383 μs (0 allocations: 0 bytes) # v"1.12.0-DEV.16" 3.194 μs (0 allocations: 0 bytes) # PR ``` ƒ Co-authored-by: Jameson Nash <[email protected]> (cherry picked from commit 1a90409)
Configuration menu - View commit details
-
Copy full SHA for 121226b - Browse repository at this point
Copy the full SHA 121226bView commit details -
Fix boundscheck in unsetindex for SubArrays (#53475)
These had been copy-pasted incorrectly, and should throw an error if the indices are out of bounds. (cherry picked from commit 98b3f72)
Configuration menu - View commit details
-
Copy full SHA for cd297c7 - Browse repository at this point
Copy the full SHA cd297c7View commit details -
Configuration menu - View commit details
-
Copy full SHA for c356e60 - Browse repository at this point
Copy the full SHA c356e60View commit details
Commits on Apr 8, 2024
-
fix typos in codegen.cpp (#53888)
Not sure why this typo didn't mess up the CI, but it looks like a clear problem, let's correct it. I'd appreciate any idea on how to exercise this change. - fixes JuliaDebug/JuliaInterpreter.jl#621
Configuration menu - View commit details
-
Copy full SHA for 6c6097c - Browse repository at this point
Copy the full SHA 6c6097cView commit details
Commits on Apr 9, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 6f8e78d - Browse repository at this point
Copy the full SHA 6f8e78dView commit details -
Add
Base.isrelocatable(pkg)
(#53906)This PR adds a utility function `isrelocatable(pkg)` that can be used to check if `pkg` is already precompiled and if the associated cachefile is relocatable. The reason to implicitly perform the `isprecompiled` check is that the exact same computation needs to be done to find the right `.ji`. A `pkg` is said to be relocatable if 1. all `include()` paths are relocatable (they start with `@depot`), 2. all `include_dependency()` paths are relocatable (they start with `@depot` and `track_content=true` was used to include them). (cherry picked from commit e9d25ca)
Configuration menu - View commit details
-
Copy full SHA for 9afd069 - Browse repository at this point
Copy the full SHA 9afd069View commit details -
Profile: make heap snapshots viewable in vscode viewer (#53833)
(cherry picked from commit 57bbff6)
Configuration menu - View commit details
-
Copy full SHA for bfac67b - Browse repository at this point
Copy the full SHA bfac67bView commit details -
LazyString
inLinearAlgebra.checksquare
error message (#53961)This reduces dynamic dispatch and makes JET happier. Testing on v1.11: ```julia julia> import LinearAlgebra: checksquare julia> using JET julia> @report_opt checksquare(rand(2,2), rand(2,2)) ═════ 4 possible errors found ═════ ┌ checksquare(::Matrix{Float64}, ::Matrix{Float64}) @ LinearAlgebra /cache/build/builder-amdci4-1/julialang/julia-release-1-dot-11/usr/share/julia/stdlib/v1.11/LinearAlgebra/src/LinearAlgebra.jl:307 │┌ string(::String, ::Tuple{Int64, Int64}) @ Base ./strings/io.jl:189 ││┌ print_to_string(::String, ::Tuple{Int64, Int64}) @ Base ./strings/io.jl:150 │││┌ _unsafe_take!(io::IOBuffer) @ Base ./iobuffer.jl:494 ││││┌ wrap(::Type{Array}, m::MemoryRef{UInt8}, l::Int64) @ Base ./array.jl:3101 │││││ failed to optimize due to recursion: wrap(::Type{Array}, ::MemoryRef{UInt8}, ::Int64) ││││└──────────────────── │││┌ print_to_string(::String, ::Vararg{Any}) @ Base ./strings/io.jl:143 ││││ runtime dispatch detected: Base._str_sizehint(%17::Any)::Int64 │││└──────────────────── │││┌ print_to_string(::String, ::Vararg{Any}) @ Base ./strings/io.jl:148 ││││ runtime dispatch detected: print(%59::IOBuffer, %97::Any)::Any │││└──────────────────── │││┌ string(::String, ::Int64, ::String, ::Tuple{Int64}, ::String, ::Int64, ::String, ::Int64, ::String) @ Base ./strings/io.jl:189 ││││ failed to optimize due to recursion: string(::String, ::Int64, ::String, ::Tuple{Int64}, ::String, ::Int64, ::String, ::Int64, ::String) │││└──────────────────── julia> function checksquare(A...) # This PR sizes = Int[] for a in A size(a,1)==size(a,2) || throw(DimensionMismatch(lazy"matrix is not square: dimensions are $(size(a))")) push!(sizes, size(a,1)) end return sizes end checksquare (generic function with 2 methods) julia> @report_opt checksquare(rand(2,2), rand(2,2)) No errors detected ``` (cherry picked from commit d505c8c)
Configuration menu - View commit details
-
Copy full SHA for ec16401 - Browse repository at this point
Copy the full SHA ec16401View commit details -
Use StringMemory instead of StringVector where possible (#53962)
On `1.11.0-alpha2` Old: ```julia @benchmark Base.dec($0x1, $0, $false) BenchmarkTools.Trial: 10000 samples with 994 evaluations. Range (min … max): 33.702 ns … 4.242 μs ┊ GC (min … max): 0.00% … 97.61% Time (median): 37.626 ns ┊ GC (median): 0.00% Time (mean ± σ): 45.787 ns ± 147.794 ns ┊ GC (mean ± σ): 14.53% ± 4.47% ▄▅▆▇█▇▇▅▃▃▂▂▂▁ ▁▂▁▁▁ ▁▁ ▁ ▂ ▄▇███████████████▇▇██████▇█▆▆▄▄▃▄▅▄▆▇████████▆▅▅▇▆▅▆▄▄▅▄▄▄▁▅ █ 33.7 ns Histogram: log(frequency) by time 67.5 ns < Memory estimate: 88 bytes, allocs estimate: 3. ``` New: ```julia BenchmarkTools.Trial: 10000 samples with 995 evaluations. Range (min … max): 27.538 ns … 3.397 μs ┊ GC (min … max): 0.00% … 97.86% Time (median): 30.151 ns ┊ GC (median): 0.00% Time (mean ± σ): 34.547 ns ± 105.101 ns ┊ GC (mean ± σ): 10.37% ± 3.39% ▁ █▆▃ ▁ ▂▂▃▃▅█████▆████▆▄▄▃▃▃▃▃▃▂▂▂▂▂▂▂▂▂▂▂▂▂▂▂▂▁▂▂▂▂▂▁▂▂▂▂▂▂▂▂▂▂▂▂▂ ▃ 27.5 ns Histogram: frequency by time 43.8 ns < Memory estimate: 56 bytes, allocs estimate: 2. ``` Fixes #53950, actually now even faster than `1.10.2`. It doesn't look like the length is ever changed and we don't return these `StringMemory`s so this change should be fine. (cherry picked from commit 0e59c9e)
Configuration menu - View commit details
-
Copy full SHA for df60193 - Browse repository at this point
Copy the full SHA df60193View commit details -
profile: doc: update the
Allocs.@profile
doc string (#53825)(cherry picked from commit d963a34)
Configuration menu - View commit details
-
Copy full SHA for 25c1c87 - Browse repository at this point
Copy the full SHA 25c1c87View commit details -
LazyString
inDimensionMismatch
error messages in broadcasting (#…Configuration menu - View commit details
-
Copy full SHA for b0d7ee4 - Browse repository at this point
Copy the full SHA b0d7ee4View commit details -
Avoid repeated precompilation when loading from non-relocatable cache…
…files (#53905) Fixes #53859 (comment), which was actually fixed before in #52346, but #52750 undid that fix. This PR does not directly address #53859, because I can not reproduce it atm. --- The `@depot` resolution logic for `include()` files is adjusted as follows: 1. (new behavior) If the cache is not relocatable because of an absolute path, we ignore that path for the depot search. Recompilation will be triggered by `stale_cachefile()` if that absolute path does not exist. Previously this caused any `@depot` tags to be not resolved and so trigger recompilation. 2. (new behavior) If we can't find a depot for a relocatable path, we still replace it with the depot we found from other files. Recompilation will be triggered by `stale_cachefile()` because the resolved path does not exist. 3. (this behavior is kept) We require that relocatable paths all resolve to the same depot. 4. (new behavior) We no longer use the first matching depot for replacement, but instead we explicitly check that all resolve to the same depot. This has two reasons: - We want to scan all source files anyways in order to provide logs for 1. and 2. above, so the check is free. - It is possible that a depot might be missing source files. Assume that we have two depots on `DEPOT_PATH`, `depot_complete` and `depot_incomplete`. If `DEPOT_PATH=["depot_complete","depot_incomplete"]` then no recompilation shall happen, because `depot_complete` will be picked. If `DEPOT_PATH=["depot_incomplete","depot_complete"]` we trigger recompilation and hopefully a meaningful error about missing files is thrown. If we were to just select the first depot we find, then whether recompilation happens would depend on whether the first relocatable file resolves to `depot_complete` or `depot_incomplete`. (cherry picked from commit d8d3842)
Configuration menu - View commit details
-
Copy full SHA for 967e2f0 - Browse repository at this point
Copy the full SHA 967e2f0View commit details -
Make reshape and view on Memory produce Arrays and delete wrap (#53896)
- Make reshape and view with one based indexing on Memory produce Arrays - delete wrap Implements #53552 (comment) --------- Co-authored-by: Jameson Nash <[email protected]> (cherry picked from commit 273d91e)
Configuration menu - View commit details
-
Copy full SHA for 146a7db - Browse repository at this point
Copy the full SHA 146a7dbView commit details -
Test and fix non-int-length bug in `view(::Memory, ::Union{UnitRange,…
Configuration menu - View commit details
-
Copy full SHA for eb96c07 - Browse repository at this point
Copy the full SHA eb96c07View commit details