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

[release 1.5] more backports for 1.5-rc2 #36755

Merged
merged 21 commits into from
Jul 26, 2020
Merged

Conversation

JeffBezanson
Copy link
Member

@JeffBezanson JeffBezanson commented Jul 21, 2020

mbauman and others added 6 commits July 21, 2020 16:40
Previously, `isempty(c::Channel)` would fall back to `iterate(c) ===
nothing`, which actually consumed a value from the channel.  Instead,
let's just define it in terms of its internal datastructures.

(cherry picked from commit 4481500)
Otherwise it's illegal to hold onto this object without having
set ->instance, which is just asking for crashes. Fixes #36649.

(cherry picked from commit d778a3d)
* Stop transpose(A) \ lu(B)' from overwriting `A`

This fixes the following bug I just found:
```julia
julia> A = randn(5,5)
5×5 Array{Float64,2}:
  0.485776   1.29655    0.0790172   0.66021   -1.49472
  0.971676  -1.01382    0.630476    0.479027  -0.843428
 -0.264609   0.392383   0.646729    0.510696   0.34913
 -0.795944  -2.47709   -1.81052    -1.0947    -0.30381
 -0.938873   2.16395   -1.33484    -0.745461   1.43709

julia> transpose(A) / lu(randn(5,5))' # should not change A
5×5 Adjoint{Float64,Array{Float64,2}}:
  14.36      11.9797   -7.32563    1.87016   -16.2731
 -18.4415   -13.7036   10.6455    -2.47396    19.9999
   8.0401     8.31723  -5.16714    2.13261    -9.637
   4.19849    3.9865   -1.98478    0.714778   -4.62445
  -5.36059   -2.60991   0.917052   0.290281    4.62547

julia> A # but does!
5×5 Array{Float64,2}:
  14.36     -18.4415    8.0401    4.19849   -5.36059
  11.9797   -13.7036    8.31723   3.9865    -2.60991
  -7.32563   10.6455   -5.16714  -1.98478    0.917052
   1.87016   -2.47396   2.13261   0.714778   0.290281
 -16.2731    19.9999   -9.637    -4.62445    4.62547
```

Co-authored-by: Daniel Karrasch <daniel.karrasch@posteo.de>
(cherry picked from commit 94398d1)
(cherry picked from commit 47989fa)
Keno and others added 2 commits July 21, 2020 23:53
The `Core.sizeof` function can take either a value or a type,
which can be a bit confusing in the tfunc, because the tfunc
operates on the types of the values passed to the builtin.
In particular, we were incorrectly returning Const(16) (on 64bit)
for sizeof_tfunc(UnionAll), because it was treating it the asme
as `sizeof_tfunc(Const(UnionAll))`. Try to clean that up as well
as fixing a similar confusion in the nothrow version of this
function. Lastly, we had a similar fast path in codegen, which
would try to inline the actual size for a constant datatype argument.
For codegen, just rm that whole code path, since it should have no
more information than inference and figuring it out in inference
exposes strictly more optimization opportunities.

Fixes #36710

(cherry picked from commit 004cb25)
MasonProtter and others added 4 commits July 22, 2020 17:02
Followup to #36739 (and currently built atop it), this restores the `pointer(::SubArray{<:Any,<:Any,<:Array,<:Tuple{Vararg{RangeIndex}}}, ::Tuple)` method that was removed in #36405. It does so, however, as a deprecated method, with the actual method being implemented on `(::SubArray{...}, ::CartesianIndex)`.

The rationale here is because the `::Tuple` method was undocumented and only supported on that one _highly_ specific `SubArray` type. I am keeping this patch as minimal as possible for backporting; in the future I aim to support `Vararg{CartesianIndex, Integer}` locations to make this more `getindex`-y and move farther away from the conflation with memory offsets.

(cherry picked from commit d9b7d7e)
@JeffBezanson JeffBezanson added this to the 1.5 milestone Jul 23, 2020
@mbauman
Copy link
Member

mbauman commented Jul 23, 2020

The FreeBSD tester looks like it froze. I clicked rebuild.

@oscardssmith
Copy link
Member

Not sure if this is the right place to ask, but is the goal to have 1.5 out for JuliaCon?

@StefanKarpinski
Copy link
Member

That would be great, but we're not going to rush or slow down the release based on JuliaCon. The final 1.5 will be released when it's ready — i.e. after a release candidate has been out for a week or so without any release blockers.

@JeffBezanson
Copy link
Member Author

This is ready to go.

@rfourquet
Copy link
Member

rfourquet commented Jul 24, 2020

Can the following be backported? #36734, #36561, #36560, and maybe the as yet unmerged #36658. (edit: I could take care of it if there is agreement)

@JeffBezanson
Copy link
Member Author

Yes those all look fine. Go ahead and cherry-pick -x them onto this branch and push it.

@JeffBezanson
Copy link
Member Author

Wow, a lot of files were missing license headers.

(cherry picked from commit 8825dab)
Since the regex r"\bemacs" matches the cmd `emacs -nw`, the regex
r"\bemacs\b.*\s(-nw|--no-window-system)\b" should be considered in the
EDITOR_CALLBACKS list before it.

Without this change, when JULIA_EDITOR="emacs -nw", julia tries to
open the editor with run(...; wait=false) which causes the error:

emacs: standard input is not a tty

or for emacsclient:

emacsclient: could not get terminal name
emacsclient: error executing alternate editor ""
(cherry picked from commit 6385107)
@rfourquet
Copy link
Member

I just pushed #36346 here which is a bug fix, I hope this is ok.

@JeffBezanson JeffBezanson merged commit 522a08a into release-1.5 Jul 26, 2020
@JeffBezanson JeffBezanson deleted the backports-release-1.5 branch July 26, 2020 17:55
vchuravy pushed a commit to JuliaLang/Distributed.jl that referenced this pull request Oct 6, 2023
vchuravy pushed a commit to JuliaLang/Test.jl that referenced this pull request Oct 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.