-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
Backports for Julia 1.10.11 #58889
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
Draft
KristofferC
wants to merge
24
commits into
release-1.10
Choose a base branch
from
backports-release-1.10
base: release-1.10
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Backports for Julia 1.10.11 #58889
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…n-link-local IPv4 address (#58895) This is a manual backport of JuliaLang/Distributed.jl#137 to Julia 1.10.x. Targets `backports-release-1.10` (#58889). This is a bugfix, and thus it is eligible to be backported.
Skip setName on folded inputs, and ensure the correct pointer address space is used. (cherry picked from commit baca8ba)
…54840) Like #54671, but for `speccache_eq`. Saw another segfault with this in the stack trace, hence this fix. I also looked for other uses of `jl_smallintset_lookup` and there's one in `idset.c`. That doesn't appear to be racy but I'm not familiar with the code, so maybe you can take a look at it in case we need to push a fix for that one too @gbaraldi or @vtjnash? (cherry picked from commit dd1ed17)
Closes #57376 Closes #34037 - Adds a lock in `SimpleLogger` and `ConsoleLogger` for use on maxlog tracking and stream writes to improve threadsafety. Closely similar to #54497 - Turns the internal `_min_enabled_level` into a `Threads.Atomic`. There are [some direct interactions](https://juliahub.com/ui/Search?type=code&q=_min_enabled_level&w=true) to this internal in the ecosystem, but they should still work ``` julia> Base.CoreLogging._min_enabled_level[] = Logging.Info+1 LogLevel(1) ``` - Brings tests over from #57448 Performance seems highly similar: ### Master ``` julia> @time for i in 1:10000 @info "foo" maxlog=10000000 end [ Info: foo ... 0.481446 seconds (1.33 M allocations: 89.226 MiB, 0.49% gc time) ``` ### This PR ``` 0.477235 seconds (1.31 M allocations: 79.002 MiB, 1.77% gc time) ``` (cherry picked from commit 9af9650)
(cherry picked from commit 088bb90)
(cherry picked from commit f5e983e)
When this API was added, this function inlined, which is important, because the API relies on the allocation of the `Ref` being elided. At some point (I went back to 1.8) this regressed. For example, it is currently responsible for substantially all non-Expr allocations in JuliaParser. Before (parsing all of Base with JuliaParser): ``` │ Memory estimate: 76.93 MiB, allocs estimate: 719922. ``` After: ``` │ Memory estimate: 53.31 MiB, allocs estimate: 156. ``` Also add a test to make sure this doesn't regress again. (cherry picked from commit d6294ba)
(cherry picked from commit 8567a3a)
(cherry picked from commit 7b6065e)
Currently, `similar(::CodeUnits)` works as expected by going through the generic `AbstractArray` method. However, the fallback method hit by `similar(::Type{<:CodeUnits}, dims)` does not work, as it assumes the existence of a constructor that accepts an `UndefInitializer`. This can be made to work by defining a corresponding `similar` method that returns an `Array`. One could make a case that this is a bugfix since it was arguably a bug that this method didn't work given that `CodeUnits` is an `AbstractArray` subtype and the other `similar` methods work. If anybody buys that argument, it could be nice to backport this; it came up in some internal code that uses Arrow.jl and JSON3.jl together. (cherry picked from commit 8e524c7)
(cherry picked from commit 2349f43)
(cherry picked from commit 1f6eff1)
[The "parsing" section of the "eval" dev docs page](https://docs.julialang.org/en/v1/devdocs/eval/#dev-parsing) was not updated when JuliaSyntax.jl was adopted in 1.10. This updates the text to reflect that it is the default parser and briefly mentions how to switch back. (cherry picked from commit ec27274)
Two open PRs to this branch currently: |
This updates 1.10 to contain two new OpenBLAS patches that come from upstream (they are included in newer OpenBLAS versions already). Specifically the patches do: * Use AVX512 kernels on modern processors * Fix incorrect CASUM computation in fallback kernel This fixes the reported linear algebra issue: JuliaLang/LinearAlgebra.jl#1406. I believe I updated all the checksums/files to make this work, specifically I did * Updated version number in `stdlib/OpenBLAS_jll/Project.toml` * Updated version number and sha in `deps/openblas.version` * Refresh checksums by running` make -f contrib/refresh_checksums.mk -j openblas` cc @giordano, @ViralBShah
This was originally added as a workaround for the behavior of sh to try to become the terminal process group leader, but no longer relevant since #25006 removed that flag again: ``` julia> run(detach(`bash -i -c "sleep 0"`)) bash: cannot set terminal process group (-1): Inappropriate ioctl for device bash: no job control in this shell Process(`bash -i -c 'sleep 0'`, ProcessExited(0)) ``` Long explanation: Julia recieves SIGTTOU when a process like "sh -i -c" exits (at least for bash and zsh, but not dash, ksh, or csh), since "sh -i" sometimes takes over the controlling terminal, causing julia to stop once the bash process exits. This can be quite annoying, but julia goes through some pains (in libuv) to ensure it doesn't steal the controlling terminal from the parent, and apparently bash is not so careful about it. However, since PR #25006, julia hasn't needed this workaround for this issue, so we can now follow the intended behavior when the child is in the same session group and steals the controlling terminal from the parent. Even if such behavior seems odd, this seems to be the intended behavior per posix design implementation that it gets SIGTTOU when julia later tries to change mode (from cooked -> raw after printing the prompt): http://curiousthing.org/sigttin-sigttou-deep-dive-linux. For some background on why this is a useful signal and behavior and should not be just blocked, see nodejs/node#35536. According to glibc, there's a half page of code for how to correctly implement a REPL mode change call: https://www.gnu.org/software/libc/manual/html_node/Initializing-the-Shell.html ``` $ ./julia -q shell> bash -i -c "sleep 1" [1]+ Stopped ./julia julia> run(`zsh -i -c "sleep 0"`) Process(`zsh -i -c 'sleep 0'`, ProcessExited(0)) julia> [1]+ Stopped ./julia ``` (cherry picked from commit 0cbe466)
The fields of `StringIndexError` are abstractly typed, so there's no reason to specialize on a concrete type. The change seems like it could prevent some invalidation on loading user code. --------- Co-authored-by: Shuhei Kadowaki <40514306+aviatesk@users.noreply.github.com> (cherry picked from commit bc33a3e)
The current method :jl_type_to_llvm takes a pointer-to-bool parameter isboxed, which if non-null, is set to true if the Julia Type requires boxing. However, one may want to know the julia type without boxing and there is no mechanism for doing so. Now there is `julia_struct_to_llvm`. (cherry picked from commit 85f1b8c)
The test on master uses opaque pointers which older LLVM versions don't support. Co-authored-by: Simeon David Schaub <simeon@schaub.rocks>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Backported PRs:
dirname.c
from MINGW #56413circshift!(::AbstractVector, ::Integer)
#57539::Real
fallback stack overflow #57790String
#57781mod
for mixes ofSigned
andUnsigned
#57853Base
:macro b_str
: restrict argument toString
#57863Base
:macro cmd
: restrict argument toString
#57862Random
:show
method forMersenneTwister
: invalidation resistance #57913Base
: shell escaping: inference improvement to prevent invalidation #57915append_c_digits
: typeassertInt
to improve inference #57950nextpow
,prevpow
for types withouttypemax
#49669reverse!
#58086@inbounds
annotations inaccumulate.jl
to only indexing calls #58200bind
inChannel
method doc string #58113hasmethod
with kwargs to exclude positional arg names #58410Ptr
values static-show w/ type-information #58584similar
method forType{<:CodeUnits}
#57826@nospecialize
forstring_index_err
#57604Need manual backport:
@time_imports
@trace_compile
@trace_dispatch
#58011exp_impl
topow
#58062one
for theSizedArray
test helper #58209Core
methods from newly-inferred list #58510IteratorSize
method forGenerator
#58110CartesianIndices
iteration #58742hygienic-scope
s in inner macro expansions #58965Contains multiple commits, manual intervention needed:
@time_imports
#55729struct
to hard #56755ndims
implementation with intent behind code #56999nextind
,prevind
methods #57608Non-merged PRs with backport label:
--trace-compile
#58535displaysize
to theIOContext
used by the REPL #55499isfile_casesensitive
fixes on Windows #55220@inbounds
andBase.@propagate_inbounds
#50157Manual backports:
[backports-release-1.10]
: Distributed: Worker: Bind to the first non-link-local IPv4 address #58895