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

Backports release 1.6.1 #40209

Merged
merged 37 commits into from
Apr 17, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
cf8b463
Fixed a spelling error. (#39372)
motchy869 Jan 25, 2021
47c13ff
fix #40050, handling fields that are pointers due to subtype circular…
JeffBezanson Mar 23, 2021
63ab04c
Fix #38491: fix an abspath() edge case on Windows (#38981)
belamenso Mar 25, 2021
78f9e7d
Have different Windows uninstall keys for different Julia versions (#…
jaakkor2 Mar 25, 2021
0d5821d
Fix armv7l trampoline (#40176)
staticfloat Mar 25, 2021
5452394
README: git checkout 1.6.0 in the instructions.
fredrikekre Mar 25, 2021
04afed6
Add new LLVM patches for Aarch64 issues (#39891)
Keno Mar 2, 2021
9c7e701
Remove eltype assumption from ldiv!(LowerTriangular(SparseMatrixCSC{T…
palday Mar 26, 2021
270c982
Fix a small bug in the TOML parser and add an example of printing to …
KristofferC Mar 29, 2021
fb4a489
Fix issue where approved credentials were not sent to git credential …
omus Mar 29, 2021
8a4b9e2
fix markdown list rendering (#40203)
KristofferC Mar 30, 2021
cffcbec
make some constructors bold in stacktraces (#40264)
mcabbott Mar 30, 2021
53748f8
Add aliasscope expr to interpreter (#40275)
vchuravy Mar 31, 2021
295e41e
add a missing propagate_inbounds to a getindex method (#40281)
KristofferC Apr 1, 2021
5250207
replace broken replaceuserpath function with existing contractuser on…
vtjnash Apr 2, 2021
bef3e1a
Fix rounding cases for fixed-width printing in ryu routines
quinnj Apr 2, 2021
62e7cf4
Fix relpath when path and startpath are in the same drive (#40323)
musm Apr 4, 2021
d080d85
exempt begin and underscore from macro hygiene (#40280)
simeonschaub Mar 31, 2021
9e996e7
fix macro hygiene for `@nospecialize(::T)` (#40293)
simeonschaub Apr 3, 2021
dc387d5
Update PCRE2 to 10.36 (#39310)
omus Jan 25, 2021
b97d605
fix #40258: nested string interpolation (#40261)
simeonschaub Mar 31, 2021
da9786d
Fix #40318 by using UInt to convert instead of Int on Ptr
quinnj Apr 2, 2021
162499a
Fix 32-bit
quinnj Apr 2, 2021
73bdd12
Fix reduce(vcat,...) type inference (#40277) (#40294)
dlfivefifty Apr 3, 2021
81e452d
Backport 1.6 of PR #40328. (#40377)
BenjaminGalliot Apr 6, 2021
230703e
fix #40249, reshaping SharedArray on another process (#40286)
JeffBezanson Apr 6, 2021
60d493a
[build] Add `symlink_system_library` calls for CSL (#40217)
staticfloat Apr 6, 2021
fefe955
fix #40337, no error info from serialized TaskFailedException (#40395)
JeffBezanson Apr 8, 2021
639325e
Fix temp install of BugReporting.jl (#40403)
fredrikekre Apr 8, 2021
f2392e7
fix a typo in TOML error message (#40428)
KristofferC Apr 10, 2021
7ee87dd
argmin ranges bug: you cannot pass an unsorted array to searchsorted
vtjnash Apr 6, 2021
f2bc4d3
searchsorted ranges: simplify code, fix bug with Unsigned needle
vtjnash Apr 6, 2021
43c621f
fix #32843, codegen attempting `typeof(NULL)` for some union tags
JeffBezanson Apr 6, 2021
01d77e2
bump Pkg to 1.6.1
KristofferC Apr 14, 2021
bd307ef
[automated] Bump the Tar stdlib from ac4d442 to 86825ec (#40421)
DilumAluthgeBot Apr 9, 2021
5d046b5
Normalize (simplify) `UnionAll`s when used as type parameter (#36211)
martinholters Apr 6, 2021
23e5f6f
prevent conj! into uninitialized memory (#40481)
KristofferC Apr 15, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 22 additions & 1 deletion Make.inc
Original file line number Diff line number Diff line change
Expand Up @@ -626,6 +626,21 @@ else
SHLIB_EXT := so
endif

ifeq ($(OS),WINNT)
define versioned_libname
$$(if $(2),$(1)-$(2).$(SHLIB_EXT),$(1).$(SHLIB_EXT))
endef
else ifeq ($(OS),Darwin)
define versioned_libname
$$(if $(2),$(1).$(2).$(SHLIB_EXT),$(1).$(SHLIB_EXT))
endef
else
define versioned_libname
$$(if $(2),$(1).$(SHLIB_EXT).$(2),$(1).$(SHLIB_EXT))
endef
endif


ifeq ($(SHLIB_EXT), so)
define SONAME_FLAGS
-Wl,-soname=$1
Expand Down Expand Up @@ -1178,6 +1193,8 @@ BB_TRIPLET_LIBGFORTRAN := $(subst $(SPACE),-,$(filter-out cxx%,$(subst -,$(SPACE
BB_TRIPLET_CXXABI := $(subst $(SPACE),-,$(filter-out libgfortran%,$(subst -,$(SPACE),$(BB_TRIPLET_LIBGFORTRAN_CXXABI))))
BB_TRIPLET := $(subst $(SPACE),-,$(filter-out cxx%,$(filter-out libgfortran%,$(subst -,$(SPACE),$(BB_TRIPLET_LIBGFORTRAN_CXXABI)))))

LIBGFORTRAN_VERSION := $(subst libgfortran,,$(filter libgfortran%,$(subst -,$(SPACE),$(BB_TRIPLET_LIBGFORTRAN))))

# This is the set of projects that BinaryBuilder dependencies are hooked up for.
BB_PROJECTS := OPENBLAS LLVM SUITESPARSE OPENLIBM GMP MBEDTLS LIBSSH2 NGHTTP2 MPFR CURL LIBGIT2 PCRE LIBUV LIBUNWIND DSFMT OBJCONV ZLIB P7ZIP CSL
define SET_BB_DEFAULT
Expand Down Expand Up @@ -1552,8 +1569,12 @@ ifneq ($(findstring $(OS),Linux FreeBSD),)
LIBGCC_NAME := libgcc_s.$(SHLIB_EXT).1
endif


# USE_SYSTEM_CSL causes it to get symlinked into build_private_shlibdir
ifeq ($(USE_SYSTEM_CSL),1)
LIBGCC_BUILD_DEPLIB := $(call dep_lib_path,$(build_libdir),$(build_private_shlibdir)/$(LIBGCC_NAME))
else
LIBGCC_BUILD_DEPLIB := $(call dep_lib_path,$(build_libdir),$(build_shlibdir)/$(LIBGCC_NAME))
endif
LIBGCC_INSTALL_DEPLIB := $(call dep_lib_path,$(libdir),$(private_shlibdir)/$(LIBGCC_NAME))

# USE_SYSTEM_LIBM and USE_SYSTEM_OPENLIBM causes it to get symlinked into build_private_shlibdir
Expand Down
7 changes: 5 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -291,8 +291,11 @@ endif
done \
done
for suffix in $(JL_PRIVATE_LIBS-1) ; do \
lib=$(build_private_libdir)/$${suffix}.$(SHLIB_EXT); \
$(INSTALL_M) $$lib $(DESTDIR)$(private_libdir) ; \
for lib in $(build_private_libdir)/$${suffix}.$(SHLIB_EXT)*; do \
if [ "$${lib##*.}" != "dSYM" ]; then \
$(INSTALL_M) $$lib $(DESTDIR)$(private_libdir) ; \
fi \
done \
done
endif
# Install `7z` into libexec/
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ Julia. However, most users should use the most recent stable version
of Julia. You can get this version by changing to the Julia directory
and running:

git checkout v1.5.0
git checkout v1.6.0

Now run `make` to build the `julia` executable.

Expand Down
88 changes: 52 additions & 36 deletions base/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -169,53 +169,69 @@ endif
# echo "$$P"

define symlink_system_library
symlink_$1: $$(build_private_libdir)/$1.$$(SHLIB_EXT)
$$(build_private_libdir)/$1.$$(SHLIB_EXT):
REALPATH=`$$(call spawn,$$(build_depsbindir)/libwhich) -p $$(notdir $$@)` && \
$$(call resolve_path,REALPATH) && \
[ -e "$$$$REALPATH" ] && \
([ ! -e "$$@" ] || rm "$$@") && \
echo ln -sf "$$$$REALPATH" "$$@" && \
ln -sf "$$$$REALPATH" "$$@"
ifneq ($2,)
ifneq ($$(USE_SYSTEM_$2),0)
SYMLINK_SYSTEM_LIBRARIES += symlink_$1
endif
libname_$2 := $$(notdir $(call versioned_libname,$2,$3))
libpath_$2 := $$(shell $$(call spawn,$$(build_depsbindir)/libwhich) -p $$(libname_$2) 2>/dev/null)
symlink_$2: $$(build_private_libdir)/$$(libname_$2)
$$(build_private_libdir)/$$(libname_$2):
@if [ -e "$$(libpath_$2)" ]; then \
REALPATH=$$(libpath_$2); \
$$(call resolve_path,REALPATH) && \
[ -e "$$$$REALPATH" ] && \
([ ! -e "$$@" ] || rm "$$@") && \
echo ln -sf "$$$$REALPATH" "$$@" && \
ln -sf "$$$$REALPATH" "$$@"; \
else \
if [ "$4" != "ALLOW_FAILURE" ]; then \
echo "System library symlink failure: Unable to locate $$(libname_$2) on your system!" >&2; \
false; \
fi; \
fi
ifneq ($$(USE_SYSTEM_$1),0)
SYMLINK_SYSTEM_LIBRARIES += symlink_$2
endif
endef

# the following excludes: libuv.a, libutf8proc.a

$(eval $(call symlink_system_library,$(LIBMNAME)))
ifneq ($(USE_SYSTEM_LIBM),0)
SYMLINK_SYSTEM_LIBRARIES += symlink_$(LIBMNAME)
$(eval $(call symlink_system_library,LIBM,$(LIBMNAME)))
else ifneq ($(USE_SYSTEM_OPENLIBM),0)
SYMLINK_SYSTEM_LIBRARIES += symlink_$(LIBMNAME)
$(eval $(call symlink_system_library,OPENLIBM,$(LIBMNAME)))
endif

$(eval $(call symlink_system_library,libpcre2-8,PCRE))
$(eval $(call symlink_system_library,libdSFMT,DSFMT))
$(eval $(call symlink_system_library,$(LIBBLASNAME),BLAS))
$(eval $(call symlink_system_library,CSL,libgcc_s,1))
ifneq (,$(LIBGFORTRAN_VERSION))
$(eval $(call symlink_system_library,CSL,libgfortran,$(LIBGFORTRAN_VERSION)))
endif
$(eval $(call symlink_system_library,CSL,libquadmath,0))
$(eval $(call symlink_system_library,CSL,libstdc++,6))
# We allow libssp, libatomic and libgomp to fail as they are not available on all systems
$(eval $(call symlink_system_library,CSL,libssp,0,ALLOW_FAILURE))
$(eval $(call symlink_system_library,CSL,libatomic,1,ALLOW_FAILURE))
$(eval $(call symlink_system_library,CSL,libgomp,1,ALLOW_FAILURE))
$(eval $(call symlink_system_library,PCRE,libpcre2-8))
$(eval $(call symlink_system_library,DSFMT,libdSFMT))
$(eval $(call symlink_system_library,BLAS,$(LIBBLASNAME)))
ifneq ($(LIBLAPACKNAME),$(LIBBLASNAME))
$(eval $(call symlink_system_library,$(LIBLAPACKNAME),LAPACK))
$(eval $(call symlink_system_library,LAPACK,$(LIBLAPACKNAME)))
endif
$(eval $(call symlink_system_library,libgmp,GMP))
$(eval $(call symlink_system_library,libmpfr,MPFR))
$(eval $(call symlink_system_library,libmbedtls,MBEDTLS))
$(eval $(call symlink_system_library,libmbedcrypto,MBEDTLS))
$(eval $(call symlink_system_library,libmbedx509,MBEDTLS))
$(eval $(call symlink_system_library,libssh2,LIBSSH2))
$(eval $(call symlink_system_library,libnghttp2,NGHTTP2))
$(eval $(call symlink_system_library,libcurl,CURL))
$(eval $(call symlink_system_library,libgit2,LIBGIT2))
$(eval $(call symlink_system_library,libamd,SUITESPARSE))
$(eval $(call symlink_system_library,libcamd,SUITESPARSE))
$(eval $(call symlink_system_library,libccolamd,SUITESPARSE))
$(eval $(call symlink_system_library,libcholmod,SUITESPARSE))
$(eval $(call symlink_system_library,libcolamd,SUITESPARSE))
$(eval $(call symlink_system_library,libumfpack,SUITESPARSE))
$(eval $(call symlink_system_library,libspqr,SUITESPARSE))
$(eval $(call symlink_system_library,libsuitesparseconfig,SUITESPARSE))
$(eval $(call symlink_system_library,GMP,libgmp))
$(eval $(call symlink_system_library,MPFR,libmpfr))
$(eval $(call symlink_system_library,MBEDTLS,libmbedtls))
$(eval $(call symlink_system_library,MBEDTLS,libmbedcrypto))
$(eval $(call symlink_system_library,MBEDTLS,libmbedx509))
$(eval $(call symlink_system_library,LIBSSH2,libssh2))
$(eval $(call symlink_system_library,NGHTTP2,libnghttp2))
$(eval $(call symlink_system_library,CURL,libcurl))
$(eval $(call symlink_system_library,LIBGIT2,libgit2))
$(eval $(call symlink_system_library,SUITESPARSE,libamd))
$(eval $(call symlink_system_library,SUITESPARSE,libcamd))
$(eval $(call symlink_system_library,SUITESPARSE,libccolamd))
$(eval $(call symlink_system_library,SUITESPARSE,libcholmod))
$(eval $(call symlink_system_library,SUITESPARSE,libcolamd))
$(eval $(call symlink_system_library,SUITESPARSE,libumfpack))
$(eval $(call symlink_system_library,SUITESPARSE,libspqr))
$(eval $(call symlink_system_library,SUITESPARSE,libsuitesparseconfig))
# EXCLUDED LIBRARIES (installed/used, but not vendored for use with dlopen):
# libunwind
endif # WINNT
Expand Down
4 changes: 2 additions & 2 deletions base/abstractarray.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1170,7 +1170,7 @@ function getindex(A::AbstractArray, I...)
_getindex(IndexStyle(A), A, to_indices(A, I)...)
end
# To avoid invalidations from multidimensional.jl: getindex(A::Array, i1::Union{Integer, CartesianIndex}, I::Union{Integer, CartesianIndex}...)
getindex(A::Array, i1::Integer, I::Integer...) = A[to_indices(A, (i1, I...))...]
@propagate_inbounds getindex(A::Array, i1::Integer, I::Integer...) = A[to_indices(A, (i1, I...))...]

function unsafe_getindex(A::AbstractArray, I...)
@_inline_meta
Expand Down Expand Up @@ -1489,7 +1489,7 @@ AbstractVecOrTuple{T} = Union{AbstractVector{<:T}, Tuple{Vararg{T}}}

_typed_vcat_similar(V, ::Type{T}, n) where T = similar(V[1], T, n)
_typed_vcat(::Type{T}, V::AbstractVecOrTuple{AbstractVector}) where T =
_typed_vcat!(_typed_vcat_similar(V, T, mapreduce(length, +, V)), V)
_typed_vcat!(_typed_vcat_similar(V, T, sum(map(length, V))), V)

function _typed_vcat!(a::AbstractVector{T}, V::AbstractVecOrTuple{AbstractVector}) where T
pos = 1
Expand Down
9 changes: 1 addition & 8 deletions base/errorshow.jl
Original file line number Diff line number Diff line change
Expand Up @@ -555,13 +555,6 @@ end
# replace `sf` as needed.
const update_stackframes_callback = Ref{Function}(identity)

function replaceuserpath(str)
str = replace(str, homedir() => "~")
# seems to be necessary for some paths with small letter drive c:// etc
str = replace(str, lowercasefirst(homedir()) => "~")
return str
end

const STACKTRACE_MODULECOLORS = [:magenta, :cyan, :green, :yellow]
const STACKTRACE_FIXEDCOLORS = IdDict(Base => :light_black, Core => :light_black)

Expand Down Expand Up @@ -701,7 +694,7 @@ end
function print_stackframe(io, i, frame::StackFrame, n::Int, digit_align_width, modulecolor)
file, line = string(frame.file), frame.line
stacktrace_expand_basepaths() && (file = something(find_source_file(file), file))
stacktrace_contract_userdir() && (file = replaceuserpath(file))
stacktrace_contract_userdir() && (file = contractuser(file))

# Used by the REPL to make it possible to open
# the location of a stackframe/method in the editor.
Expand Down
28 changes: 22 additions & 6 deletions base/path.jl
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,19 @@ normpath(a::AbstractString, b::AbstractString...) = normpath(joinpath(a,b...))
Convert a path to an absolute path by adding the current directory if necessary.
Also normalizes the path as in [`normpath`](@ref).
"""
abspath(a::String) = normpath(isabspath(a) ? a : joinpath(pwd(),a))
function abspath(a::String)::String
if !isabspath(a)
cwd = pwd()
a_drive, a_nodrive = splitdrive(a)
if a_drive != "" && lowercase(splitdrive(cwd)[1]) != lowercase(a_drive)
cwd = a_drive * path_separator
a = joinpath(cwd, a_nodrive)
else
a = joinpath(cwd, a)
end
end
return normpath(a)
end

"""
abspath(path::AbstractString, paths::AbstractString...) -> String
Expand Down Expand Up @@ -502,12 +514,16 @@ function relpath(path::String, startpath::String = ".")
curdir = "."
pardir = ".."
path == startpath && return curdir
path_drive, path_without_drive = splitdrive(path)
startpath_drive, startpath_without_drive = splitdrive(startpath)
path_arr = split(abspath(path_without_drive), path_separator_re)
start_arr = split(abspath(startpath_without_drive), path_separator_re)
if Sys.iswindows()
lowercase(path_drive) != lowercase(startpath_drive) && return abspath(path)
path_drive, path_without_drive = splitdrive(path)
startpath_drive, startpath_without_drive = splitdrive(startpath)
isempty(startpath_drive) && (startpath_drive = path_drive) # by default assume same as path drive
uppercase(path_drive) == uppercase(startpath_drive) || return abspath(path) # if drives differ return first path
path_arr = split(abspath(path_drive * path_without_drive), path_separator_re)
start_arr = split(abspath(path_drive * startpath_without_drive), path_separator_re)
else
path_arr = split(abspath(path), path_separator_re)
start_arr = split(abspath(startpath), path_separator_re)
end
i = 0
while i < min(length(path_arr), length(start_arr))
Expand Down
4 changes: 2 additions & 2 deletions base/range.jl
Original file line number Diff line number Diff line change
Expand Up @@ -632,7 +632,7 @@ function argmin(r::AbstractRange)
elseif step(r) > 0
firstindex(r)
else
first(searchsorted(r, last(r)))
lastindex(r)
end
end

Expand All @@ -647,7 +647,7 @@ function argmax(r::AbstractRange)
if isempty(r)
throw(ArgumentError("range must be non-empty"))
elseif step(r) > 0
first(searchsorted(r, last(r)))
lastindex(r)
else
firstindex(r)
end
Expand Down
2 changes: 1 addition & 1 deletion base/ryu/exp.jl
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@
roundPos = pos
while true
roundPos -= 1
if roundPos == (startpos - 1) || buf[roundPos] == UInt8('-')
if roundPos == (startpos - 1) || buf[roundPos] == UInt8('-') || (plus && buf[roundPos] == UInt8('+')) || (space && buf[roundPos] == UInt8(' '))
buf[roundPos + 1] = UInt8('1')
e += 1
break
Expand Down
2 changes: 1 addition & 1 deletion base/ryu/fixed.jl
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@
dotPos = 1
while true
roundPos -= 1
if roundPos == (startpos - 1) || (buf[roundPos] == UInt8('-'))
if roundPos == (startpos - 1) || (buf[roundPos] == UInt8('-')) || (plus && buf[roundPos] == UInt8('+')) || (space && buf[roundPos] == UInt8(' '))
buf[roundPos + 1] = UInt8('1')
if dotPos > 1
buf[dotPos] = UInt8('0')
Expand Down
2 changes: 1 addition & 1 deletion base/show.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2195,7 +2195,7 @@ function show_signature_function(io::IO, @nospecialize(ft), demangle=false, farg
uwf = unwrap_unionall(f)
parens = isa(f, UnionAll) && !(isa(uwf, DataType) && f === uwf.name.wrapper)
parens && print(io, "(")
show(io, f)
print_within_stacktrace(io, f, bold=true)
parens && print(io, ")")
else
if html
Expand Down
Loading