-
-
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 for julia v1.10.0-beta2 #50708
Merged
Merged
Conversation
This file contains 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
This makes irinterp not override `:nothrow=true` that are assumed by `Base.@assume_effects`.
…ompact!`-ion (#50767) In code like below ```julia Base.@assume_effects :nothrow function erase_before_inlining(x, y) z = sin(y) if x return "julia" end return z end let y::Float64 length(erase_before_inlining(true, y)) end ``` the constant prop' can figure out the constant return type of `erase_before_inlining(true, y)` while it is profitable not to inline expand it since otherwise we left some `!:nothrow` callees there (xref: #47305). In order to workaround this problem, this commit makes `compact!`move inlineable constants into argument positions so that the such "inlineable, but safe as a whole" calls to be erased during compaction. This should give us general compile-time performance improvement too as we no longer need to expand the IR for those calls. Requires: - #50764 - #50765 - #50768
Co-authored-by: Martin Holters <[email protected]> (cherry picked from commit 210c5b5)
fixes #50575 Co-authored-by: Shuhei Kadowaki <[email protected]> (cherry picked from commit 9822257)
(cherry picked from commit bea8c44)
If something odd happens during GC (the PC goes to sleep) or a very big transient the heuristics might make a bad decision. What this PR implements is if we try to make our target more than double the one we had before we fallback to a more conservative method. This fixes the new issue @vtjnash found in #40644 for me. (cherry picked from commit ab94fad)
``` julia> @CCall jl_dump_host_cpu()::Cvoid CPU: znver2 Features: sse3, pclmul, ssse3, fma, cx16, sse4.1, sse4.2, movbe, popcnt, aes, xsave, avx, f16c, rdrnd, fsgsbase, bmi, avx2, bmi2, rdseed, adx, clflushopt, clwb, sha, rdpid, sahf, lzcnt, sse4a, prfchw, mwaitx, xsaveopt, xsavec, xsaves, clzero, wbnoinvd julia> target = only(Base.current_image_targets()) znver2; flags=0; features_en=(sse3, pclmul, ssse3, fma, cx16, sse4.1, sse4.2, movbe, popcnt, aes, xsave, avx, f16c, fsgsbase, bmi, avx2, bmi2, adx, clflushopt, clwb, sha, rdpid, sahf, lzcnt, sse4a, prfchw, mwaitx, xsavec, xsaves, clzero, wbnoinvd) ``` Co-authored-by: Prem Chintalapudi <[email protected]> Co-authored-by: Jameson Nash <[email protected]> (cherry picked from commit 958da95)
…50844) Detailed discussion and benchmarks by @oscardssmith in JuliaPackaging/Yggdrasil#7189 (cherry picked from commit 626f687)
This bumps the build numbers for stdlib and binary dependency JLLs, updates libssh2 to 1.11.0, libgit2 to 1.6.4, and objconv to 2.53. Julia's FreeBSD CI has been running on FreeBSD 13.2 for a while, but until more recently, Yggdrasil was still building FreeBSD binaries using the 12.2 sysroot. The sysroot was updated to 13.2 and I went through and rebuilt the dependencies that Julia uses. The updated build numbers correspond to these rebuilt but otherwise unchanged binaries. The actual version updates are because libssh2 in Yggdrasil was at 1.11.0 so I left it there (its [release notes](https://github.com/libssh2/libssh2/releases/tag/libssh2-1.11.0) suggest it's a safe update), libgit2 had a newer patch version available and needed to be fixed anyway since the Windows build was broken, and objconv needed its Yggdrasil build recipe fixed but Elliot's GitHub mirror of objconv was at 2.53 so I updated to use that. (cherry picked from commit 5e51fbe)
Currently, `Array(r::AbstractRange)` falls back to `vcat(r)`, but certain ranges may choose to specialize `vcat(r::AbstractRange)` to not return an `Array`. This PR ensures that `Array(r)` always returns an `Array`. At present, there's some code overlap with `vcat` (just above the `Array` method added in this PR). Perhaps some of these may be replaced by `unsafe_copyto!`, but the tests for ranges include some special cases that don't support `getindex`, which complicates things a bit. I've not done this for now. In any case, the common bit of code is pretty simple, so perhaps the duplication is harmless. (cherry picked from commit 3cc0590)
The documentation of `Pkg.jl` is instructing developers to rely on the existence of this function, and there doesn't seem to be any alternative which is a part of the API that developers can use instead on to guarantee forward compatibility for the same behavior. `Base.get_extension` is [referred to explicitly](https://pkgdocs.julialang.org/v1.9/creating-packages/#Backwards-compatibility) in the `Pkg.jl` docs to conditionally use package extensions vs `Requires.jl`. The `Pkg.jl` docs suggest ```julia if !isdefined(Base, :get_extension) include("../ext/PlottingContourExt.jl") end ``` to transition from "normal dependency to extension," which will break and automatically load the extension in future versions should `Base.get_extension` go away. `Base.get_extension` is the only way (that I know of) to directly access the module associated with a package extension, which can be a useful utility as well. (cherry picked from commit d1759bc)
@nanosoldier |
…poptask (#50802) Currently `poptask` is allocating every time it calls into `jl_task_get_next` due to `StickyWorkqueue` (`IntrusiveLinkedListSynchronized`) being immutable and requiring an allocation to be used as `Any` on the `ccall`. The allocations can be seen in the following snippet: ``` function work() done = 0.0 l = Threads.SpinLock() Threads.@sync for _ in 1:(Threads.nthreads() / 2) Threads.@Spawn begin v = 1.0 for i in 1:(1<<33) v *= 1.0001 if i % (1 << 13) == 0 yield() end end Base.@lock_nofail l done += v end end return done end julia> @time work() 15.758794 seconds (5.03 M allocations: 153.523 MiB, 0.35% gc time) ``` Which after the change becomes: ``` julia> @time work() 15.907513 seconds (67 allocations: 4.719 KiB) ``` (cherry picked from commit 2f03072)
We don't need to merge all of the workqueue modules when performing compilation with `--image-codegen` set, we just need the global variable initializers to be defined before they're used in one of the modules. Therefore we can do this by compiling all of the global variable initializers upfront, so that later references will link them properly. (cherry picked from commit ff14eaf)
This sticks the compiled opaque closure module into the `compiled_functions` list of modules that we have compiled for the particular `jl_codegen_params_t`. We probably should manage that vector in codegen_params, since it lets us see if a particular codeinst has already been compiled but not yet emitted. (cherry picked from commit 441fcb1)
(cherry picked from commit 3708229)
(cherry picked from commit f337c3d)
The package evaluation job you requested has completed - possible new issues were detected. |
Otherwise we may end up with the state of a dead thread, as the system IDs can alias. This can lead to an early return from the exception handler, resulting in e.g. safepoint exceptions being actually delivered to user code. --------- Co-authored-by: Jameson Nash <[email protected]> Co-authored-by: Cody Tapscott <[email protected]>
(cherry picked from commit 5e3fb41)
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:
@time
msg into print buffer #50665versioninfo()
: include build info and unofficial warning #50635--pkgimage=no
caches for stdlibs #50666:nothrow
modeling ofgetglobal
#50765:nothrow
only when it is not proved yet #50764compact!
constantPiNode
#50768compact!
-ion #50767tanpi
docstring to method #50689get!
#50771bit_map!
with aliasing #50781Array(::AbstractRange)
should return anArray
#50568Need manual backport:
Contains multiple commits, manual intervention needed:
Non-merged PRs with backport label: