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.8: Backports for Julia 1.8.1 #46376

Merged
merged 33 commits into from
Sep 1, 2022
Merged

Commits on Aug 17, 2022

  1. leq for reals falls back to le and eq (#46341)

    (cherry picked from commit ef511c9)
    jishnub authored and KristofferC committed Aug 17, 2022
    Configuration menu
    Copy the full SHA
    27890c7 View commit details
    Browse the repository at this point in the history

Commits on Aug 22, 2022

  1. Configuration menu
    Copy the full SHA
    8ed3bc6 View commit details
    Browse the repository at this point in the history

Commits on Aug 24, 2022

  1. [release-1.8] Consistently use RUNPATH in our libraries (#46465)

    * Consistently use `RUNPATH` in our libraries
    
    When loading dependencies on Linux, we can either use `RPATH` or
    `RUNPATH` as a list of relative paths to search for libraries.  The
    difference, for our purposes, mainly lies within how this interacts with
    `LD_LIBRARY_PATH`: `RPATH` is searched first, then `LD_LIBRARY_PATH`,
    then `RUNPATH`.  So by using `RUNPATH` here, we are explicitly allowing
    ourselves to be overridden by `LD_LIBRARY_PATH`.  This is fine, as long
    as we are consistent across our entire library line, however in the
    `v1.8.0` release, there was an inconsistency, reported in [0].
    
    The inconsistency occured because of the following confluence of factors:
    
     - Ancient `ld` builds (such as the one used in our build environment)
       do not default to using `RUNPATH`, but instead use `RPATH`.
     - `patchelf`, when it rewrites the RPATH, will default to using
       `RUNPATH` instead.
     - We were only using `patchelf` on `libjulia-internal`, not on
       `libjulia-codegen`, which was newly added in `v1.8`.
    
    These three factors together caused us to ship a binary with `RUNPATH`
    in `libjulia-internal`, but `RPATH` in `libjulia-codegen`, which caused
    loading to fail in [0] due to first `libjulia-internal` being loaded,
    (which brought in the external `libstdc++`), then `libjulia-codegen`
    failed to load (because it found an incompatible `libstdc++`), causing
    the mysterious compiler error.
    
    This PR fixes this twofold; first, when building the libraries in the
    first place, we pass `--enable-new-dtags` to the linker to encourage it
    to use `runpath` when possible.  This removes the possibility for a
    missing `patchelf` invocation to break things in this way.  Second, we
    apply `patchelf` properly to `libjulia-codegen` as well.
    
    [0] #46409
    
    * fix whitespace
    
    Co-authored-by: Kristoffer Carlsson <kcarlsson89@gmail.com>
    staticfloat and KristofferC authored Aug 24, 2022
    Configuration menu
    Copy the full SHA
    5fed861 View commit details
    Browse the repository at this point in the history

Commits on Aug 26, 2022

  1. [Makefile] Fix codesign of libjulia when installing it on macOS (#44510)

    * [Makefile] Fix codesign of libjulia when installing it on macOS
    
    * Add shell sript for codesigning and use it in Makefile
    
    (cherry picked from commit 8076517)
    giordano authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    ffe7ea7 View commit details
    Browse the repository at this point in the history
  2. Change PDF cover font to DejaVu Sans (#45290)

    (cherry picked from commit c65e56f)
    mortenpi authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    21a53fb View commit details
    Browse the repository at this point in the history
  3. @kwdef: handle const and atomic fields (#46276)

    (cherry picked from commit 70656e2)
    IanButterworth authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    72b7511 View commit details
    Browse the repository at this point in the history
  4. Don't mutate the hashtable with forward edges during final iteration. (

    …#46375)
    
    By looking up keys, we possibly grow the hash table, invalidating the iteration
    we were doing in jl_collect_backedges. First perform a non-mutating check instead,
    and assert that the hashtable doesn't change during iteration.
    
    (cherry picked from commit 0ada892)
    maleadt authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    0be7f57 View commit details
    Browse the repository at this point in the history
  5. Fix #41096 and #43082, make sure env is restored when typeintersect…

    … tries a new Union decision (#46350)
    
    * `intersect_all` should always `restore_env`. let `merge_env` track valid `env` change.
    
    * Add test.
    
    Co-authored-by: Jeff Bezanson <jeff.bezanson@gmail.com>
    (cherry picked from commit 9aabb4c)
    N5N3 authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    9b3a2bb View commit details
    Browse the repository at this point in the history
  6. Fix @time compat description (#46416)

    (cherry picked from commit e0056c8)
    MasonProtter authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    5842378 View commit details
    Browse the repository at this point in the history
  7. Fix deepcopy for Base.GenericCondition (#46406)

    (cherry picked from commit 99e8953)
    DilumAluthge authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    bc457f6 View commit details
    Browse the repository at this point in the history
  8. Fix multiplication of AbstractQs (#46237)

    (cherry picked from commit 947c908)
    dkarrasch authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    0830823 View commit details
    Browse the repository at this point in the history
  9. Fix 3-arg dot for 1x1 structured matrices (#46473)

    (cherry picked from commit c3d5009)
    dkarrasch authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    0aa5201 View commit details
    Browse the repository at this point in the history
  10. @noinline exp by default. (#46359)

    also remove a bunch of `@inline` from when I didn't trust the compiler to do reasonable things.
    
    (cherry picked from commit 445586d)
    oscardssmith authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    3053b47 View commit details
    Browse the repository at this point in the history
  11. Handle PhiNode with edge==0 (#46388)

    (cherry picked from commit fd66c30)
    martinholters authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    ad8ca94 View commit details
    Browse the repository at this point in the history
  12. Properly declare alloca alignment (#46368)

    Turns out when you declare an alloca alignment, it also rounds up
    the allocated size. Replaces #46322 and #46260 and fixes the
    same issue.
    
    (cherry picked from commit e358a17)
    Keno authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    29c76db View commit details
    Browse the repository at this point in the history
  13. fix bug when error is infinite (#46436)

    (cherry picked from commit c491e79)
    oscardssmith authored and KristofferC committed Aug 26, 2022
    Configuration menu
    Copy the full SHA
    a239589 View commit details
    Browse the repository at this point in the history

Commits on Aug 29, 2022

  1. Fix ordering of headers so #define _GNU_SOURCE comes first (#46183)

    Co-authored-by: Kristoffer Carlsson <kcarlsson89@gmail.com>
    (cherry picked from commit 3b81696)
    akirakyle authored and KristofferC committed Aug 29, 2022
    Configuration menu
    Copy the full SHA
    99b466b View commit details
    Browse the repository at this point in the history
  2. Fix union!(s::BitSet, r::AbstractUnitRange{<:Integer}) when two range…

    …s do not overlap. (#45578)
    
    * Fix union!(s::BitSet, r::AbstractUnitRange{<:Integer}) when two ranges do not overlap.
    Resizing of BitSet should be filled with 0 by default.
    
    (cherry picked from commit 5e8e0a5)
    metab0t authored and KristofferC committed Aug 29, 2022
    Configuration menu
    Copy the full SHA
    c65611a View commit details
    Browse the repository at this point in the history
  3. inference: revive CachedMethodTable mechanism

    `CachedMethodTable` was removed within #44240 as we couldn't confirm any
    performance improvement then. However it turns out the optimization was
    critical in some real world cases (e.g. #46492), so this commit revives
    the mechanism with the following tweaks that should make it more effective:
    - create method table cache per inference (rather than per local
      inference on a function call as on the previous implementation)
    - only use cache mechanism for abstract types (since we already cache
      lookup result at the next level as for concrete types)
    
    As a result, the following snippet reported at #46492 recovers the
    compilation performance:
    ```julia
    using ControlSystems
    a_2 = [-5 -3; 2 -9]
    C_212 = ss(a_2, [1; 2], [1 0; 0 1], [0; 0])
    @time norm(C_212)
    ```
    
    > on master
    ```
    julia> @time norm(C_212)
    364.489044 seconds (724.44 M allocations: 92.524 GiB, 6.01% gc time, 100.00% compilation time)
    0.5345224838248489
    ```
    
    > on this commit
    ```
    julia> @time norm(C_212)
     26.539016 seconds (62.09 M allocations: 5.537 GiB, 5.55% gc time, 100.00% compilation time)
    0.5345224838248489
    ```
    
    (cherry picked from commit 8445744)
    aviatesk authored and KristofferC committed Aug 29, 2022
    Configuration menu
    Copy the full SHA
    5d03fcd View commit details
    Browse the repository at this point in the history

Commits on Aug 30, 2022

  1. fix invalidations in logging (#46481)

    (cherry picked from commit ce6e9ee)
    ranocha authored and KristofferC committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    bb94590 View commit details
    Browse the repository at this point in the history
  2. fix type instability/invalidations from nextind (#46489)

    (cherry picked from commit 98e1b13)
    ranocha authored and KristofferC committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    8bc5c9a View commit details
    Browse the repository at this point in the history
  3. Use Documenter 0.27.23 (#46516)

    (cherry picked from commit b64743b)
    mortenpi authored and KristofferC committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    9db7f85 View commit details
    Browse the repository at this point in the history
  4. Docs: Remove static scheduling warning (#46519)

    The docs on multithreading still warns that the default scheduler for @threads
    uses static scheduling. However, since #44136, dynamic scheduling has been the
    default. This commit removes the warning.
    
    (cherry picked from commit 72222d6)
    jakobnissen authored and KristofferC committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    a462c5a View commit details
    Browse the repository at this point in the history
  5. fix invalidations for Dicts from Static.jl (#46490)

    (cherry picked from commit 5c5af1f)
    ranocha authored and KristofferC committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    598b019 View commit details
    Browse the repository at this point in the history
  6. fix invalidations of REPL from HDF5.jl (#46486)

    (cherry picked from commit 431071b)
    ranocha authored and KristofferC committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    9787fa5 View commit details
    Browse the repository at this point in the history
  7. fix invalidations in sort! from Static.jl (#46491)

    (cherry picked from commit 1fae1b9)
    ranocha authored and KristofferC committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    0d42d02 View commit details
    Browse the repository at this point in the history
  8. fix invalidations in REPLCompletions from Static.jl (#46494)

    (cherry picked from commit 99340fe)
    ranocha authored and KristofferC committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    9efb6c4 View commit details
    Browse the repository at this point in the history
  9. Enhance StringIndexError display (correct escaping) (#46039)

    (cherry picked from commit 1715110)
    Rratic authored and KristofferC committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    98efbdf View commit details
    Browse the repository at this point in the history
  10. Improve foldl's stability on nested Iterators (#45789)

    * Make `Fix1(f, Int)` inference-stable
    * split `_xfadjoint` into `_xfadjoint_unwrap` and `_xfadjoint_wrap`
    * Improve `(c::ComposedFunction)(x...)`'s inferability
    * and fuse it in `Base._xfadjoint`.
    * define a `Typeof` operator that will partly work around internal type-system bugs
    
    Closes #45715
    
    (cherry picked from commit d58289c)
    N5N3 authored and KristofferC committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    8421c03 View commit details
    Browse the repository at this point in the history
  11. avoid one invalidation of isinf when loading Static.jl (#46493)

    (cherry picked from commit c2a1650)
    ranocha authored and KristofferC committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    b10b1dd View commit details
    Browse the repository at this point in the history
  12. Configuration menu
    Copy the full SHA
    f2ed5c3 View commit details
    Browse the repository at this point in the history

Commits on Aug 31, 2022

  1. fix invalidations in REPL LineEdit.jl from Static.jl (#46548)

    * fix invalidations in REPL LineEdit.jl from Static.jl
    
    (cherry picked from commit 99d8c7b)
    ranocha authored and KristofferC committed Aug 31, 2022
    Configuration menu
    Copy the full SHA
    d68417f View commit details
    Browse the repository at this point in the history
  2. fix another invalidation from Static.jl (#46546)

    This is a follow-up to #46481. I suggest the labels `latency` and `backport-1.8`.
    
    (cherry picked from commit f1f5d59)
    ranocha authored and KristofferC committed Aug 31, 2022
    Configuration menu
    Copy the full SHA
    173f336 View commit details
    Browse the repository at this point in the history