9e0f2a9 | Keno Fischer | 04 April 2024, 19:56:02 UTC | Disallow `.` after unary operator | 04 April 2024, 19:56:13 UTC |
781bb32 | Keno Fischer | 04 April 2024, 19:47:30 UTC | Allow :. to continue working (but consider it deprecated) | 04 April 2024, 19:47:30 UTC |
2519832 | Keno Fischer | 04 April 2024, 18:55:11 UTC | WIP | 04 April 2024, 18:55:11 UTC |
d224635 | Keno Fischer | 04 April 2024, 00:53:36 UTC | RFC: Curried getproperty syntax This PR adds support for parsing `.a` as `x->x.a`. This kind of thing has come up multiple times in the past, but I'm currently finding myself doing a lot of work on nested structs where this operation is very common. In general, we've had the position that this kind of thing should be a special case of the short-currying syntax (e.g. #38713), but I actually think that might be a false constraint. In particular, `.a` is a bit of a worst case for the curry syntax. If there is no requirement for `.a` to be excessively short in an eventual underscore curry syntax, I think that could open more options. That said, any syntax proposal of course needs to stand on its own, so let me motivate the cases where I think this plays: A. Curried getfield I think this is probably the most obvious and often requested. The syntax here is very useful for situations where higher order functions operate on collections of records: 1. `map(.a, vec)` and reductions for getting the fields of an object - also includes things like `sum(.price, items)` 2. Predicates like `sort(vecs, by=.x)` or `filter(!.deleted, entries)` 3. In pipelines `vecs |> .x |> sqrt |> sum` I think that's mostly what people are thinking of, but the use case for this syntax is more general. B. A syntax for lenses Packages like Accessors.jl provide lens-like abstractions. Currently these are written as `lens = @optic _.a`. An example use of Accessors.jl is (from their documentation) ``` julia> modify(lowercase, (;a="AA", b="BB"), @optic _.a) T("aa", "BB") ``` This PR can be thought of as providing lenses first class syntax, as in: ``` julia> modify(lowercase, (;a="AA", b="BB"), .a) T("aa", "BB") ``` C. Symbol index generalization to hierachical structures We have a lot of packages in the ecosystem that support named axes of various forms (Canonical examples might be DataFrames and NamedArrays, but there's probably two dozen of these). Generally the way that this syntax works is that people use quoted symbols for indexing: ``` df[5, :col] ``` However, this breaks down when there is hierachical composition involved. For example, for simulation models, you often build parameter sets and solutions out of hierarchies of simpler models. There's a couple of solutions that people have come up with for this problem: 1. Some packages parse out hierachy from symbol names: `sol[:var"my.nested.hierachy.state"]` 2. Other packages have a global root object: `sol[β.my.nested.hierarchy.state]` 2a. A variant of this is using the object as its own root `sol[sol.my.nested.hierarchy.state]` 2b. Yet another variant is having the root object be context specific `sol[sys.my.nested.hierarchy.state]` 3. Yet other packages put symbolic names into the global namespaces `sol[my.nested.hierarchy.state]` These solutions are all lacking. 1 requires string manipulation for composition, the various variants of 2 are ok, but there is no agreement among packages what the root object looks like or is spelled, and even so, it's an extra export and 3 pollutes the global namespaces. By using the same mechanism here, we essentially standardize the solution `2`, but make the root object implicit.` | 04 April 2024, 00:53:36 UTC |
1d532f4 | Florian | 17 March 2024, 15:05:53 UTC | remove dllexport `jl_arraylen` which no longer exists (#53765) | 17 March 2024, 15:05:53 UTC |
0b1587c | Jishnu Bhattacharya | 17 March 2024, 13:01:25 UTC | Add an IndexStyle example to the diagind docstring (#53757) Also, simplifies the docstring by splitting the usage into two lines. | 17 March 2024, 13:01:25 UTC |
912460b | Jeff Fessler | 15 March 2024, 04:46:03 UTC | Use Julian way `β₯(0)` in `findall` docs (#53740) I'm pretty sure the manual advises against `x -> x >= 0` :) | 15 March 2024, 04:46:03 UTC |
67cdb9b | Gabriel Baraldi | 15 March 2024, 02:17:44 UTC | Enable analyzegc checks for try catch and fix found issues (#53527) This PR also makes a successful `JL_TRY` not do so much work + fixes clang not finding the sdk when running those tests in macos. Fixes https://github.com/JuliaLang/julia/issues/ Co-authored-by: Cody Tapscott <84105208+topolarity@users.noreply.github.com> Co-authored-by: Jameson Nash <vtjnash@gmail.com> | 15 March 2024, 02:17:44 UTC |
3c4af03 | Shuhei Kadowaki | 15 March 2024, 00:43:19 UTC | enhance the effectiveness of the test cases introduced in #53300 (#53478) While experimenting with precompilation for external absints on builds just after #53300 was merged, I found that the test case for `CustomAbstractInterpreterCaching2.jl` fails if the test case for `CustomAbstractInterpreterCaching1.jl` isn't run in the same session beforehand. That is probably because of the previous lack of support for proper `CodeInstance` caching. To address this, I've changed the tests to run in separate processes in this commit. Note that it appears that a recent refactor concerning `CodeInstance` might have resolved this issue, so the new test cases runs successfully on master. However, I suspect the fix hasn't been applied to v1.11 yet, we would need more research. | 15 March 2024, 00:43:19 UTC |
b730d33 | Shuhei Kadowaki | 15 March 2024, 00:39:56 UTC | inlining: bail out unless `match.spec_types <: match.method.sig` (#53720) As Jameson pointed out in the link below, while the union-split handles cases when there are uncovered matches, sometimes the expected condition `spec_types <: method.sig` that the union-split algorithm relies on isn't met in such cases, which caused issues like #52644. This commit fixes the problem by adding explicit checks for such cases. Note that this is based on #52092. The extra handling for single method match unmatched static parameters based on `only_method` that was removed in JuliaLang/#52092 has been ineffective and would otherwise cause problematic inlining on this PR. We'll likely need to come back to this later and figure out a safe and effective way to deal with such cases in the future when the handling for either case turns out to be necessary. - closes #52644 - xref: <https://github.com/JuliaLang/julia/pull/53600#pullrequestreview-1917272781> | 15 March 2024, 00:39:56 UTC |
0f04b33 | Gabriel Baraldi | 14 March 2024, 19:30:40 UTC | Default to the medium code model in x86 linux (#53391) This shouldn't have any cost on smaller images because the only thing that gets put into ldata is the system image data, which is only reference via `dlsym`. This allows for images larger than 2gb (tested by putting a 2gb array in the base image) I did not test how this might be handled in other platforms (Windows doesn't support it). | 14 March 2024, 19:30:40 UTC |
a910f04 | Jameson Nash | 14 March 2024, 14:52:20 UTC | Fix some issues with precompilation with threads on (#53697) This doesn't fix all issues, but should make some of them more correct than before. These fixes may also enable exiting julia with threads running safer in the future. | 14 March 2024, 14:52:20 UTC |
cb47b01 | Gabriel Baraldi | 14 March 2024, 14:51:10 UTC | codegen: change tbaa of ptr_phi to tbaa_value (#53655) Fixes https://github.com/JuliaLang/julia/issues/53612 | 14 March 2024, 14:51:10 UTC |
c4ab0d4 | Ian Butterworth | 14 March 2024, 14:23:58 UTC | Increase build precompilation (#53682) - Bake precompilepkgs into the sysimage - Enable compilation in stdlib JLLs @staticfloat I guess this is ok now we have pkgimages? - Add some hardcoded precompiles encountered locally - Disable a problematic llvm test, with a note With this there's no compilation loading Pkg in interactive mode ``` % ./julia --trace-compile=stderr --start=no -q julia> ] (@v1.12) pkg> ``` Before ``` % time julia +nightly --start=no --trace-compile=stderr -q -e "using Pkg" precompile(Tuple{typeof(Base.setindex!), Base.Dict{Symbol, Union{Nothing, Bool, Int64, String}}, Int64, Symbol}) precompile(Tuple{typeof(Base.haskey), Base.Dict{String, Any}, String}) precompile(Tuple{typeof(MbedTLS_jll.__init__)}) precompile(Tuple{typeof(LibSSH2_jll.__init__)}) precompile(Tuple{typeof(LibGit2_jll.__init__)}) precompile(Tuple{typeof(nghttp2_jll.__init__)}) precompile(Tuple{typeof(LibCURL_jll.__init__)}) precompile(Tuple{typeof(MozillaCACerts_jll.__init__)}) precompile(Tuple{typeof(Base.Filesystem.normpath), String, String, Vararg{String}}) precompile(Tuple{typeof(p7zip_jll.__init__)}) precompile(Tuple{typeof(p7zip_jll.init_p7zip_path)}) precompile(Tuple{typeof(Base.append!), Array{String, 1}, Array{String, 1}}) precompile(Tuple{typeof(Base.join), Array{String, 1}, Char}) julia +nightly --start=no --trace-compile=stderr -q -e "using Pkg" 1.48s user 0.40s system 206% cpu 0.910 total ``` PR ``` % time ./julia --start=no --trace-compile=stderr -q -e "using Pkg" ./julia --start=no --trace-compile=stderr -q -e "using Pkg" 1.62s user 0.13s system 402% cpu 0.433 total ``` | 14 March 2024, 14:23:58 UTC |
b507330 | Jishnu Bhattacharya | 14 March 2024, 14:04:50 UTC | Remove specialized IndexStyle method for SubArray (#53726) The fallback method `IndexStyle(::Type{<:AbstractArray})` does the same, so this is unnecessary. | 14 March 2024, 14:04:50 UTC |
8287943 | Jishnu Bhattacharya | 14 March 2024, 14:03:01 UTC | Remove specialized view method for `OneTo` arguments (#53725) This seems unnecessary, as the fallback method on line 221 does the same. | 14 March 2024, 14:03:01 UTC |
5023ee2 | Shuhei Kadowaki | 14 March 2024, 11:15:40 UTC | replace `REPL.TerminalMenus.terminal` with type stable function (#53704) | 14 March 2024, 11:15:40 UTC |
612393c | Cody Tapscott | 14 March 2024, 11:01:22 UTC | Avoid macro-expand recursion into `Expr(:toplevel, ...)` (#53515) Here's an example output from macroexpand: ``` Expr head: Symbol thunk args: Array{Any}((1,)) 1: Core.CodeInfo code: Array{Any}((2,)) 1: Expr head: Symbol toplevel args: Array{Any}((17,)) 1: Expr head: Symbol hygienic-scope args: Array{Any}((3,)) 1: LineNumberNode 2: Module Base.Enums 3: LineNumberNode 2: Expr head: Symbol hygienic-scope args: Array{Any}((3,)) 1: Expr 2: Module Base.Enums 3: LineNumberNode 3: Expr head: Symbol hygienic-scope args: Array{Any}((3,)) 1: LineNumberNode 2: Module Base.Enums 3: LineNumberNode 4: Expr head: Symbol hygienic-scope args: Array{Any}((3,)) 1: Expr 2: Module Base.Enums 3: LineNumberNode ... ``` Currently fails during bootstrap with: ``` LoadError("sysimg.jl", 3, LoadError("Base.jl", 542, ErrorException("cannot document the following expression:\n\n#= mpfr.jl:65 =# @enum MPFRRoundingMode begin\n #= mpfr.jl:66 =#\n MPFRRoundNearest\n #= mpfr.jl:67 =#\n MPFRRoundToZero\n #= mpfr.jl:68 =#\n MPFRRoundUp\n #= mpfr.jl:69 =#\n MPFRRoundDown\n #= mpfr.jl:70 =#\n MPFRRoundFromZero\n #= mpfr.jl:71 =#\n MPFRRoundFaithful\n end\n\n'@enum' not documentable. See 'Base.@__doc__' docs for details.\n"))) ``` Perhaps we can do better than wrapping each `Expr(:toplevel, ...)` arg individually, or I should be filtering out the LineNumberNodes? --------- Co-authored-by: Keno Fischer <keno@juliacomputing.com> Co-authored-by: Keno Fischer <keno@juliahub.com> | 14 March 2024, 11:01:22 UTC |
f24364a | Keno Fischer | 14 March 2024, 08:07:25 UTC | Don't recurse lowering symbol renaming through `Expr(:toplevel)` (#53730) Fixes #53729. | 14 March 2024, 08:07:25 UTC |
48e89db | Diogo Netto | 13 March 2024, 22:06:55 UTC | bump number of GC threads to the number of compute threads (as opposed to half of it) (#53608) The GC scheduler seems to have matured enough for us to do this. | 13 March 2024, 22:06:55 UTC |
2e876fc | Shuhei Kadowaki | 13 March 2024, 16:23:57 UTC | inlining: remove ineffective handling for unmatched params (#52092) The deleted branch was added in #45062, although it had not been tested. I tried the following diff to find cases optimized by that, but I just found the handling proved to be in vain in all cases I tried. ```diff diff --git a/base/compiler/ssair/inlining.jl b/base/compiler/ssair/inlining.jl index 318b21b09b..7e42a65aa4 100644 --- a/base/compiler/ssair/inlining.jl +++ b/base/compiler/ssair/inlining.jl @@ -1473,6 +1473,14 @@ function compute_inlining_cases(@nospecialize(info::CallInfo), flag::UInt32, sig handle_any_const_result!(cases, result, match, argtypes, info, flag, state; allow_abstract=true, allow_typevars=true) fully_covered = handled_all_cases = match.fully_covers + if length(cases) == 1 && fully_covered + println("first case: ", only_method) + elseif length(cases) == 1 + atype = argtypes_to_type(sig.argtypes) + if atype isa DataType && cases[1].sig isa DataType + println("second case: ", only_method) + end + end elseif !handled_all_cases # if we've not seen all candidates, union split is valid only for dispatch tuples filter!(case::InliningCase->isdispatchtuple(case.sig), cases) ``` | 13 March 2024, 16:23:57 UTC |
3d34f11 | N5N3 | 13 March 2024, 15:52:05 UTC | typeintersect: fix potential free `TypeVar` caused by chained inner var. (#53675) Noticed when working on 02f27c24929ab2561bcb21d3f58c1d313ae5d6e8. The substitution and re-sorting of inner vars are incomplete on master. This commit re-organized the code by: 1. Flatten the inner vars into a reversed list and handling them just like vars in norm bindings. 2. Then perform a global re-sorting on all vars. 3. After that, the inner vars get frozen and dependent bounds are refreshed. | 13 March 2024, 15:52:05 UTC |
8d31f33 | Florian | 13 March 2024, 09:04:08 UTC | Move `isexecutable, isreadable, iswritable` to `filesystem.jl` (#53699) This PR migrates the methods `isexecutable, isreadable, iswritable` from `Sys` to `Base`, but also generates an alias in `Sys` for backwards compatibility. Furthermore, `iswriteable` is renamed to `iswritable` in order to match the already existing `Base.iswritable` method. Suggested in https://github.com/JuliaLang/julia/pull/53320#issuecomment-1989217973. | 13 March 2024, 09:04:08 UTC |
9ae7eab | Keno Fischer | 13 March 2024, 07:31:51 UTC | Implement proper macro scope resolution for generator/for (#53674) I'm not super familiar with this code, but it appears to me that these need to be treated as equivalent to implicit let blocks for the purposes of macro hygiene, so add appropriate logic to the macroexpander. Fixes #53673. | 13 March 2024, 07:31:51 UTC |
b1dd26a | Diogo Netto | 13 March 2024, 05:09:25 UTC | remove duplicate definition of is_anonfn_typename (#53711) They seem to be doing the same thing. Centralize the definition in a single place. | 13 March 2024, 05:09:25 UTC |
7613c69 | Cameron Bieganek | 12 March 2024, 20:24:51 UTC | Make some improvements to the Scoped Values documentation. (#53628) Fixes #53471. One thing to note, I changed the signature in the `with` docstring from this: ```julia with(f, (var::ScopedValue{T} => val::T)...) ``` to this: ```julia with(f, (var::ScopedValue{T} => val)...) ``` ...since the original signature in the docstring was too strict. I also added this sentence to the docstring: ```julia `val` will be converted to type `T`. ``` I added a couple tests that verify the conversion behavior. | 12 March 2024, 20:24:51 UTC |
df28bf7 | Jameson Nash | 12 March 2024, 18:30:20 UTC | use afoldl instead of tail recursion for tuples (#53665) It is easy to accidentally call these functions (they are used by vcat, which is syntax) with very long lists of values, causing inference to crash and take a long time. The `afoldl` function can handle that very well however, while naive recursion did not. Fixes #53585 | 12 March 2024, 18:30:20 UTC |
2a72d65 | DilumAluthgeBot | 12 March 2024, 13:47:06 UTC | π€ [master] Bump the Pkg stdlib from e0821116e to 6859d6857 (#53703) Stdlib: Pkg URL: https://github.com/JuliaLang/Pkg.jl.git Stdlib branch: master Julia branch: master Old commit: e0821116e New commit: 6859d6857 Julia version: 1.12.0-DEV Pkg version: 1.12.0 Bump invoked by: @IanButterworth Powered by: [BumpStdlibs.jl](https://github.com/JuliaLang/BumpStdlibs.jl) Diff: https://github.com/JuliaLang/Pkg.jl/compare/e0821116e9f4364a2b37a77183e93d055a111f4d...6859d68579e7970daf00720901cf487563dca0da ``` $ git log --oneline e0821116e..6859d6857 6859d6857 precompile: update kwargs (#3838) 4d73d60aa move threads assignment after precompilation (#3840) 28bbbd46f remove line about changing UUID to dev in readme (#3837) ``` Co-authored-by: Dilum Aluthge <dilum@aluthge.com> | 12 March 2024, 13:47:06 UTC |
7eb5cb8 | Shuhei Kadowaki | 12 March 2024, 11:57:25 UTC | set `slot_syms` for methods of OCs constructed via `Core.OpaqueClosure` (#53650) Previously `oc` constructed via `Core.OpaqueClosure` does not set `oc.source.slot_syms` set, which caused segfaults either when trying to `show` `oc.source` or if invocation of `oc(...)` threw an error. This commit fixes that by making sure `oc.source.slot_syms` is set for `oc` created with `jl_new_opaque_closure_from_code_info`. | 12 March 2024, 11:57:25 UTC |
22602a2 | Jishnu Bhattacharya | 12 March 2024, 10:28:37 UTC | Slightly improve grammar in precompilation info text (#53700) Uses the singular "configuration" if `length(configs) == 1`, instead of the current "configurations" | 12 March 2024, 10:28:37 UTC |
0b95caf | Keno Fischer | 12 March 2024, 10:21:38 UTC | Fix `--compile=all` mode after CodeInstance refactor (#53421) This codepath does not have tests, so it wasn't quite correct. Hopefully this fixes it. | 12 March 2024, 10:21:38 UTC |
8e7751c | Jishnu Bhattacharya | 12 March 2024, 08:48:04 UTC | propagate_inbounds to inline in indexing CartesianIndices{0} (#53701) There's no indexing call in this method which an `@inbounds` may be propagated to. | 12 March 2024, 08:48:04 UTC |
2c81e5d | Jishnu Bhattacharya | 12 March 2024, 02:05:27 UTC | Linalg: remove unnecessary matprod_dest specializations (#53620) These methods are not necessary, as the fallback methods for `StructuredArrays` on line 577 and 578 do the same. | 12 March 2024, 02:05:27 UTC |
dcd1fb2 | Jishnu Bhattacharya | 12 March 2024, 02:04:25 UTC | LAPACK: validate input parameters to throw informative errors (#53631) This PR validates the input parameters to the Julia LAPACK wrappers, so that the error messages are more informative. On nightly ```julia julia> using LinearAlgebra julia> LAPACK.geev!('X', 'X', rand(2,2)) ** On entry to DGEEV parameter number 1 had an illegal value ERROR: ArgumentError: invalid argument #1 to LAPACK call ``` This PR ```julia julia> using LinearAlgebra julia> LAPACK.geev!('X', 'X', rand(2,2)) ERROR: ArgumentError: argument #1: jobvl must be one of ('N', 'V'), but 'X' was passed ``` Secondly, moved certain allocations (e.g. in `geevx`) below the validation checks, so that these only happen for valid parameter values. Thirdly, added `require_one_based_indexing` checks to functions where these were missing. | 12 March 2024, 02:04:25 UTC |
dcfad21 | Kenta Murata | 11 March 2024, 23:45:00 UTC | Add throw option in wait(::Task) (#53685) As we discussed with @vtjnash in PR #53341, it might be useful to introduce the `throw` option in the `wait` function for `Task`. If `throw=false` is specified, `wait` behaves like `_wait`; it prevents throwing a `TaskFailedException`. | 11 March 2024, 23:45:00 UTC |
a4783b0 | gbaraldi | 11 March 2024, 22:25:27 UTC | Also don't increment it for gc threads | 11 March 2024, 22:25:27 UTC |
2d24401 | gbaraldi | 11 March 2024, 21:51:26 UTC | Don't double increment nrunning when starting threads | 11 March 2024, 21:51:26 UTC |
a0cee55 | Oscar Smith | 11 March 2024, 21:13:44 UTC | add check for invalid state in `_growend!` slow-path (#53513) This only triggers in cases where the user has done something pretty bad (e.g. modified the size incorrectly, or calling `push!` from multiple threads on the same vector without a lock). I'm very unsure if `ConcurrencyViolationError` is the right error to throw here, but I think most of the time, that is going to be the cause. This check is in the slow path because adding extra checks here is basically free (since it will run rarely, and will be batched with O(n) work to copy everything over). | 11 March 2024, 21:13:44 UTC |
5fc1662 | Mosè Giordano | 11 March 2024, 20:54:46 UTC | Fix warning about comparison of integer expressions of different signedness (#53658) | 11 March 2024, 20:54:46 UTC |
f9e08f7 | Jeff Bezanson | 11 March 2024, 19:09:12 UTC | fix #52025, re-allow all implicit pointer casts in cconvert for Array (#53659) fix #52025 | 11 March 2024, 19:09:12 UTC |
6f143ea | Jameson Nash | 11 March 2024, 16:54:11 UTC | invert linetable representation (#52415) Previously, our linetables (similar to LLVM) represented line information as a linked list from callee via inlined_at up to the original information. This requires many copies of this information to be created. Instead we can take advantage of the necessary existence of the line table from the child to flip this chain of information and instead make each statement be a table describing (for each IR instruction): `(current line number, (index into edges, index into edges statements))` plus a table of all edges, plus a table with the original line numbers from the parser, plus the file name. This is all packed into the struct struct DebugInfo def::Union{Method,MethodInstance,Symbol} linetable::Union{Nothing,DebugInfo} edges::SimpleVector{DebugInfo} codelocs::String end Which is described in doc/src/devdocs/ast.md for what each field means and look at stacktraces.jl or compiler/ssair/show.jl to look at how to decode and interpret this information. For the sysimage, this saves several megabytes (about 113 MB -> 110 MB) and about 5% of the stdlib pkgimages (294 MB -> 279 MB). It also now happens to have the full type information for the inlined functions. Now if you create an `IRShow.DILineInfoPrinter` with `showtypes=true`, it can print that information when printing IR. ``` julia> @eval Base.IRShow DILineInfoPrinter(debuginfo, def) = DILineInfoPrinter(debuginfo, def, true) DILineInfoPrinter (generic function with 2 methods) julia> (@code_typed 1 + 1.0)[1] CodeInfo( @ promotion.jl:425 within `+` β invoke MethodInstance for promote(::Int64, ::Float64) β @ promotion.jl:396 within `promote` ββ invoke MethodInstance for Base._promote(::Int64, ::Float64) ββ @ promotion.jl:373 within `_promote` βββ invoke MethodInstance for convert(::Type{Float64}, ::Int64) βββ @ number.jl:7 within `convert` ββββ invoke MethodInstance for Float64(::Int64) ββββ @ float.jl:221 within `Float64` 1 βββββ %1 = Base.sitofp(Float64, x)::Float64 β ββββ β β invoke MethodInstance for +(::Float64, ::Float64) β β @ float.jl:460 within `+` β β %2 = Base.add_float(%1, y)::Float64 β β βββ return %2 ) ``` | 11 March 2024, 16:54:11 UTC |
8413b97 | Kenta Murata | 11 March 2024, 15:35:31 UTC | Add waitany and waitall functions to wait multiple tasks at once (#53341) This adds two functions: `waitany` and `waitall`, as discussed in the issue #53226. These functions wait for multiple tasks at once. The `waitany` function blocks until one task finishes. The `waitall` function blocks until all tasks finish. Co-authored-by: Shuhei Kadowaki <aviatesk@gmail.com> Co-authored-by: Jameson Nash <vtjnash@gmail.com> | 11 March 2024, 15:35:31 UTC |
f882c00 | Jishnu Bhattacharya | 11 March 2024, 14:15:30 UTC | Linalg: matprod_dest for Diagonal and adjvec (#53611) | 11 March 2024, 14:15:30 UTC |
2978a64 | Jameson Nash | 11 March 2024, 12:28:49 UTC | [REPL] fix incorrectly cleared line after completions accepted (#53662) The hint must be cleared before the screen state is reset, otherwise the state after reset may not be compatible with being able to clear it. Fixes #52264 | 11 March 2024, 12:28:49 UTC |
60d4b7b | Jameson Nash | 11 March 2024, 12:28:24 UTC | add isassigned methods for reinterpretarray (#53663) Fixes #52925 Refs #51760 | 11 March 2024, 12:28:24 UTC |
57efee1 | Keno Fischer | 11 March 2024, 10:56:59 UTC | Correct `@NamedTuple` printing for non-identitifer keys (#53689) Before: ``` julia> typeof((;:var"#"=>1)) @NamedTuple{#::Int64} julia> @NamedTuple{#::Int64} ERROR: ParseError: # Error @ REPL[47]:2:2 @NamedTuple{#::Int64} #β ββ Expected `}` Stacktrace: [1] top-level scope @ none:1 ``` After: ``` julia> typeof((;:var"#"=>1)) @NamedTuple{var"#"::Int64} julia> @NamedTuple{var"#"::Int64} @NamedTuple{var"#"::Int64} ``` | 11 March 2024, 10:56:59 UTC |
1ba83f0 | Jishnu Bhattacharya | 11 March 2024, 06:50:16 UTC | LinAlg: fzeropreserving unit triangular broadcast preserves structure (#53648) On master ```julia julia> UU = UnitUpperTriangular(reshape([1:9;],3,3)) 3Γ3 UnitUpperTriangular{Int64, Matrix{Int64}}: 1 4 7 β
1 8 β
β
1 julia> UU .* 2 3Γ3 Matrix{Int64}: 2 8 14 0 2 16 0 0 2 ``` This PR ```julia julia> UU .* 2 3Γ3 UpperTriangular{Int64, Matrix{Int64}}: 2 8 14 β
2 16 β
β
2 ``` This also improves performance, as the `materialize` skips the structured zeros. ```julia julia> UU = UnitUpperTriangular(rand(100, 100)); julia> @btime $UU .* 2; 12.788 ΞΌs (3 allocations: 78.20 KiB) # master 7.821 ΞΌs (3 allocations: 78.20 KiB) # PR ``` | 11 March 2024, 06:50:16 UTC |
6e3044d | Jishnu Bhattacharya | 11 March 2024, 06:14:28 UTC | Fix linear indexing for ReshapedArray if the parent has offset axes (#41232) This PR fixes ```julia julia> r = reshape(Base.IdentityUnitRange(3:4), 2, 1) 2Γ1 reshape(::Base.IdentityUnitRange{UnitRange{Int64}}, 2, 1) with eltype Int64: 3 4 julia> collect(r) == r false julia> collect(r) 2Γ1 Matrix{Int64}: 3258125826116431922 3688512103538242609 ``` After this PR, ```julia julia> collect(r) 2Γ1 Matrix{Int64}: 3 4 ``` | 11 March 2024, 06:14:28 UTC |
26b3b5f | Ian Butterworth | 10 March 2024, 22:34:55 UTC | move precompile workload back from Base (#53679) | 10 March 2024, 22:34:55 UTC |
ccdf89e | Tim Holy | 10 March 2024, 21:15:20 UTC | Noteworthy differences: `exp.(A)` vs `exp(A)` (#53686) | 10 March 2024, 21:15:20 UTC |
30450c3 | Jeff Bezanson | 10 March 2024, 18:58:14 UTC | add error for inconsistent public/export declarations (#53664) Co-authored-by: Ian Butterworth <i.r.butterworth@gmail.com> Co-authored-by: Lilith Orion Hafner <lilithhafner@gmail.com> | 10 March 2024, 18:58:14 UTC |
5c7d244 | Gabriel Baraldi | 09 March 2024, 22:22:20 UTC | Bump CSL to 1.1.1 to fix libgomp bug (#53643) Resolves https://github.com/JuliaLang/julia/issues/53363 | 09 March 2024, 22:22:20 UTC |
39f141d | Jameson Nash | 09 March 2024, 18:41:47 UTC | increase max atomic size to 16 on 64-bit platforms (#42268) | 09 March 2024, 18:41:47 UTC |
e9c84c8 | Jameson Nash | 09 March 2024, 18:40:54 UTC | permit NamedTuple{<:Any, Union{}} to be created (#53516) | 09 March 2024, 18:40:54 UTC |
fc6c618 | Frames White | 09 March 2024, 18:36:14 UTC | Handle zero on arrays of unions of number types and missings (#53602) | 09 March 2024, 18:36:14 UTC |
c705a25 | Steven G. Johnson | 09 March 2024, 15:42:22 UTC | document exact BigInt determinants (#53579) New users are commonly surprised that determinants of integer matrices give an approximate floating-point answer (#40128), and are unaware that an exact algorithm is implemented for `BigInt` matrices (#40868). This PR comments on both of these facts in the `det` documentation. (At some point, we may want to mark `LinearAlgebra.det_bareiss` as `public`, and document it, but that can be done in a future PR.) | 09 March 2024, 15:42:22 UTC |
0d029ea | Ian Butterworth | 09 March 2024, 14:58:25 UTC | Load Pkg if not already to reinstate missing package add prompt (#52125) | 09 March 2024, 14:58:25 UTC |
6f8ba49 | Jishnu Bhattacharya | 09 March 2024, 13:51:03 UTC | Add methods to index identityUnitRange/Slice with another IdentityUnitRange (#41224) Adding these methods lets `OffsetArrays` define `getindex(::AbstractUnitRange, ::IdentityUnitRange)` without ambiguities. This is in the domain of sanctioned type-piracy, as the result is an offset range in general and cannot be represented correctly using `Base` types. Re: https://github.com/JuliaArrays/OffsetArrays.jl/pull/244 cc: @johnnychen94 Edit: this also fixes an indexing bug in `IdentityUntiRange`: master ```julia julia> r = Base.IdentityUnitRange(-3:3) Base.IdentityUnitRange(-3:3) julia> r[2] 2 julia> r[big(2)] -2 ``` Co-authored-by: jishnub <jishnub@users.noreply.github.com> | 09 March 2024, 13:51:03 UTC |
18a2e70 | Keno Fischer | 09 March 2024, 13:28:55 UTC | Fix bootstrap Base precompile in cross compile configuration (#53671) | 09 March 2024, 13:28:55 UTC |
53048b2 | Jishnu Bhattacharya | 09 March 2024, 10:44:25 UTC | Linalg: Reduce allocations in triangular tests (#53634) Reuses a pre-allocated matrix in tests to avoid allocating a fresh matrix in every call. | 09 March 2024, 10:44:25 UTC |
ed1d6a0 | Jameson Nash | 09 March 2024, 04:23:38 UTC | some fixes for precompile with threads Not sure what I was thinking before here. | 09 March 2024, 04:23:47 UTC |
bb35dc9 | Diogo Netto | 08 March 2024, 21:44:48 UTC | optimize remset marking (#52476) Tag the lowest bit of a pointer to indicate it's in the remset and enqueue objects in the remset for later processing when GC threads have woken up, instead of sequentially marking them all at once. In principle, this should allow for more parallelism in the mark phase, though I didn't benchmark it yet. | 08 March 2024, 21:44:48 UTC |
e618369 | Kristoffer Carlsson | 08 March 2024, 16:02:54 UTC | precompilepkgs: package in boths deps and weakdeps are in fact only weak (#53649) Missed when porting from Pkg. Fixes https://github.com/JuliaLang/Pkg.jl/issues/3834. | 08 March 2024, 16:02:54 UTC |
78351b5 | Ian Butterworth | 08 March 2024, 15:21:33 UTC | Use Base parallel precompilation to build stdlibs (#53598) Follow-on from https://github.com/JuliaLang/julia/pull/53403 This extends `Base.Precompilation.precompilepkgs` to take a list of configurations to precompile each package with, while parallelizing across all packages and configurations, and uses it to build the stdlib pkgimages. It simplifies the stdlib pkgimage build process but is (currently) dependent on having an accurately resolved Manifest.toml (Project.toml included to make the manifest easier to make). Any new/removed stdlibs or changes their dependencies will require updating the Manifest.toml. It's a bit chicken and egg, but should be manageable with manual editing of the Manifest.toml. In terms of speed improvement: MacOS aarch64 CI runner 6m19s before, 5m19 with this Note that CI builds will show the basic print with timing of each package, whereas local build will be the tidier fancy print without timings. Co-authored-by: Valentin Churavy <vchuravy@users.noreply.github.com> | 08 March 2024, 15:21:33 UTC |
a998082 | DilumAluthgeBot | 08 March 2024, 15:11:22 UTC | π€ [master] Bump the Pkg stdlib from 56c379045 to e0821116e (#53654) Stdlib: Pkg URL: https://github.com/JuliaLang/Pkg.jl.git Stdlib branch: master Julia branch: master Old commit: 56c379045 New commit: e0821116e Julia version: 1.12.0-DEV Pkg version: 1.12.0 Bump invoked by: @IanButterworth Powered by: [BumpStdlibs.jl](https://github.com/JuliaLang/BumpStdlibs.jl) Diff: https://github.com/JuliaLang/Pkg.jl/compare/56c379045c8cf876b365c284a5b442f2dc9fc8af...e0821116e9f4364a2b37a77183e93d055a111f4d ``` $ git log --oneline 56c379045..e0821116e e0821116e re-enable Pkg precompilation (#3835) a2b8729ea Update version on master to 1.12 (#3832) ``` Co-authored-by: Dilum Aluthge <dilum@aluthge.com> | 08 March 2024, 15:11:22 UTC |
4dcf357 | Keno Fischer | 08 March 2024, 06:26:43 UTC | inference: Don't confuse frames in different interpreters (#53627) Diffractor's abstract interpreter sometimes needs to do side queries using the native interpreter. These are pushed onto the regular inference callstack in anticipation of a future where compiler plugins may want to recurse from the native interpreter back into the Diffractor abstract interpreter. However, this introduced a subtle challenge: When the native interpreter is looking at a frame that is currently on the inference stack, it would treat them as the same, incorrectly merging inference across the two abstract interpreters (which have different semantics and may not be confused). The caches for the two abstract interpreters were already different, so once things are inferred, there's no problem (likely because things were already inferred on the native interpreter), but if not, this could cause subtle and hard to debug problems. | 08 March 2024, 06:26:43 UTC |
321fb2c | Keno Fischer | 08 March 2024, 06:26:10 UTC | sroa: Fix incorrect scope counting (#53630) Sroa was incorrectly assuming that every :leave leaves exactly one scope. In reality, it leaves as many scopes as the corresponding :leave references. Fix that to fix #53521. | 08 March 2024, 06:26:10 UTC |
fa90883 | DilumAluthgeBot | 08 March 2024, 03:31:27 UTC | π€ [master] Bump the Pkg stdlib from e7d740ac8 to 56c379045 (#53637) Stdlib: Pkg URL: https://github.com/JuliaLang/Pkg.jl.git Stdlib branch: master Julia branch: master Old commit: e7d740ac8 New commit: 56c379045 Julia version: 1.12.0-DEV Pkg version: 1.11.0(Does not match) Bump invoked by: @KristofferC Powered by: [BumpStdlibs.jl](https://github.com/JuliaLang/BumpStdlibs.jl) Diff: https://github.com/JuliaLang/Pkg.jl/compare/e7d740ac82fa4c289bb58f9acb6e60eebb6d8a8e...56c379045c8cf876b365c284a5b442f2dc9fc8af ``` $ git log --oneline e7d740ac8..56c379045 56c379045 make `delayed_delete_dir` usage a bit more backwards compatible (#3830) 5a68d7953 restore unwrap UnstableIO in precompile (#3831) ``` Co-authored-by: Dilum Aluthge <dilum@aluthge.com> | 08 March 2024, 03:31:27 UTC |
f6504e4 | Shuhei Kadowaki | 08 March 2024, 00:42:49 UTC | add `construct_[post]domtree(::[IRCode|CFG])` interfaces (#53638) We currently have `construct_[post]domtree(::Vector{BasicBlock})` only. The higher level interfaces are often convenient. | 08 March 2024, 00:42:49 UTC |
d45581c | Shuhei Kadowaki | 07 March 2024, 16:15:35 UTC | inlining: use method match signature for union-spliting (#53600) In cases where the results of constant inference, like concrete-eval, are used for union-split inlining, `isa`-blocks are generated using the `result.edge.specTypes` stored within each `result`. However, it's been found that the `edge` returned by abstract interpretation may have been widened by the new `@nospecializeinfer`, which can result in invalid union-splitting. To address this problem, this commit tweaks the inlining algorithm so that it performs union-split inlining using the original signatures that abstract interpretation used for union-split inference, by using `match::MethodMatch`. - fixes #53590 | 07 March 2024, 16:15:35 UTC |
a182880 | Frames White | 07 March 2024, 15:09:12 UTC | use isempty in tests (#53617) This was not being used as it didn't have fancy printing when it failed. But that was fixed in https://github.com/JuliaLang/julia/pull/30721 so we can do this now | 07 March 2024, 15:09:12 UTC |
cf5f163 | Phillip Alday | 07 March 2024, 15:07:59 UTC | typo fix in scoped values docs (#53629) | 07 March 2024, 15:07:59 UTC |
56f1c8a | N5N3 | 06 March 2024, 21:55:49 UTC | typeintersect: fix `UnionAll` unaliasing bug caused by innervars. (#53553) typeintersect: fix `UnionAll` unaliasing bug caused by innervars. | 06 March 2024, 21:55:49 UTC |
6335386 | Valentin Churavy | 06 March 2024, 15:04:22 UTC | Unexport with, at_with, and ScopedValue from Base (#53004) fixes #52535 --------- Co-authored-by: Kristoffer Carlsson <kcarlsson89@gmail.com> | 06 March 2024, 15:04:22 UTC |
02f27c2 | N5N3 | 02 March 2024, 07:29:18 UTC | typeintersect: more organized innervar wrapping | 06 March 2024, 14:11:04 UTC |
a556af2 | N5N3 | 02 March 2024, 05:27:21 UTC | typeintersect: fuse `unalias_unionall` And ensures all innervar get checked. | 06 March 2024, 11:59:14 UTC |
90d84d4 | Shuhei Kadowaki | 06 March 2024, 00:32:31 UTC | cleanups on `src_inlining_policy` (#53599) - fixed the check with `src_inlining_policy` in typeinfer.jl - removed the `SemiConcreteResult` handling, which is no longer needed | 06 March 2024, 00:32:31 UTC |
fb71a5d | DilumAluthgeBot | 05 March 2024, 21:32:17 UTC | π€ [master] Bump the Pkg stdlib from 48eea8dbd to e7d740ac8 (#53610) Stdlib: Pkg URL: https://github.com/JuliaLang/Pkg.jl.git Stdlib branch: master Julia branch: master Old commit: 48eea8dbd New commit: e7d740ac8 Julia version: 1.12.0-DEV Pkg version: 1.11.0(Does not match) Bump invoked by: @KristofferC Powered by: [BumpStdlibs.jl](https://github.com/JuliaLang/BumpStdlibs.jl) Diff: https://github.com/JuliaLang/Pkg.jl/compare/48eea8dbd7b651cdc932b909c1b718bb9c3f94f4...e7d740ac82fa4c289bb58f9acb6e60eebb6d8a8e ``` $ git log --oneline 48eea8dbd..e7d740ac8 e7d740ac8 move to using Base parallel precompile (#3820) d1f91fd37 fix relative paths in test project for `[sources]` (#3825) 5c73d7f3c Support a `[sources]` section in Project.toml for specifying paths and repo locations for dependencies (#3783) 0d9aa51a9 do not use UnstableIO for subprocess (in e.g. Pkg.test) (#3823) ``` Co-authored-by: Dilum Aluthge <dilum@aluthge.com> | 05 March 2024, 21:32:17 UTC |
427da5c | Kristoffer Carlsson | 05 March 2024, 17:23:08 UTC | fix error path in `precompilepkgs` (#53606) this was accidentally left when porting this from Pkg.jl | 05 March 2024, 17:23:08 UTC |
58291db | Jameson Nash | 05 March 2024, 15:00:15 UTC | codegen: optimize const fields of mutable objects (#53484) For example, we seek to eliminate the gc frame from this function, as observed here: ```julia julia> code_llvm((BitSet,), raw=true) do x; r = x.bits; GC.safepoint(); @inbounds r[1]; end ; Function Signature: var"https://github.com/JuliaLang/julia/issues/3"(Base.BitSet) ; @ REPL[1]:1 within `https://github.com/JuliaLang/julia/issues/3` define swiftcc i64 @"julia_#3_494"(ptr nonnull swiftself %pgcstack, ptr noundef nonnull align 8 dereferenceable(16) %"x::BitSet") #0 !dbg !5 { top: call void @llvm.dbg.declare(metadata ptr %"x::BitSet", metadata !21, metadata !DIExpression()), !dbg !22 %ptls_field = getelementptr inbounds ptr, ptr %pgcstack, i64 2 %ptls_load = load ptr, ptr %ptls_field, align 8, !tbaa !23 %0 = getelementptr inbounds ptr, ptr %ptls_load, i64 2 %safepoint = load ptr, ptr %0, align 8, !tbaa !27 fence syncscope("singlethread") seq_cst %1 = load volatile i64, ptr %safepoint, align 8, !dbg !22 fence syncscope("singlethread") seq_cst ; β @ Base.jl:49 within `getproperty` %"x::BitSet.bits" = load atomic ptr, ptr %"x::BitSet" unordered, align 8, !dbg !29, !tbaa !27, !alias.scope !33, !noalias !36, !nonnull !11, !dereferenceable !41, !align !42 ; β ; β @ gcutils.jl:253 within `safepoint` %ptls_load4 = load ptr, ptr %ptls_field, align 8, !dbg !43, !tbaa !23 %2 = getelementptr inbounds ptr, ptr %ptls_load4, i64 2, !dbg !43 %safepoint5 = load ptr, ptr %2, align 8, !dbg !43, !tbaa !27 fence syncscope("singlethread") seq_cst, !dbg !43 %3 = load volatile i64, ptr %safepoint5, align 8, !dbg !43 fence syncscope("singlethread") seq_cst, !dbg !43 ; β ; β @ essentials.jl:892 within `getindex` %4 = load ptr, ptr %"x::BitSet.bits", align 8, !dbg !46, !tbaa !49, !alias.scope !52, !noalias !53 %5 = load i64, ptr %4, align 8, !dbg !46, !tbaa !54, !alias.scope !57, !noalias !58 ret i64 %5, !dbg !46 ; β } ``` | 05 March 2024, 15:00:15 UTC |
3df016d | Eric Hanson | 05 March 2024, 13:49:02 UTC | Semver: specify VersionNumber's follow v2-rc2 specifically (#53538) Since v2 has changed from v2-rc2 by saying build numbers MUST not be taken into account in precedence. I don't think changing VersionNumber's ordering in a minor release of Julia is acceptable, but since the semver landing page is now v2 rather than v2-rc2, we should update the link. closes https://github.com/JuliaLang/julia/issues/53502 | 05 March 2024, 13:49:02 UTC |
b50344f | inky | 05 March 2024, 10:00:14 UTC | build: remove extra .a file (#53596) fix #53569 | 05 March 2024, 10:00:14 UTC |
d3ee213 | Kristoffer Carlsson | 05 March 2024, 09:59:32 UTC | add back `unsafe_convert` to pointer for arrays (#53589) This caused a pretty big breakage in the ecosystem (~50 packages) and is according to Jameson "Too breaking for no necessary reason". So let's add it back. --------- Co-authored-by: Jameson Nash <vtjnash@gmail.com> | 05 March 2024, 09:59:32 UTC |
892c491 | Dilum Aluthge | 05 March 2024, 04:00:26 UTC | Docs: change "Package naming guidelines" to "Package naming rules" (#53566) I think that "guidelines" implies that these are just optional suggestions. But in practice, I think we usually insist that these are followed. So I think it might be worth changing "guidelines" to "rules", to clarify that we enforce these. | 05 March 2024, 04:00:26 UTC |
6745160 | Kristoffer Carlsson | 05 March 2024, 01:07:34 UTC | Move parallel precompilation to Base (#53403) Parallel precompilation is more or less now required in order to use somewhat large packages unless you want to wait an obscene long time for it to complete. Right now, we even start a parallel precompilation on a package load if we notice that the package you are loading is not precompiled. This functionally has typically been implemented in Pkg but with Pkg not being in the sysimage it becomes a bit awkward because we then need to load Pkg from Base. The only real reason this functionality has been implemented in Pkg is that Pkg has some useful features for parsing environments. Moving precompilation to Base has typically been stalled on such an environment parser not existing in Base. However, in https://github.com/JuliaLang/julia/pull/46690 I started implemented code loading on top of a more up front environment parser (instead of the "incremental" one that currently exists in `loading.jl`) and we can retro fit this to be used as the basis of parallel precompilation. At some later point code loading could be implemented on top of it but that is for now considered future work. This PR thus adds the environment parser from the codeloading PR and implementes the parallel precompilation feature from Pkg on top of it (instead of on top of the `EnvCache` in Pkg). Some points to bring up here: - This copy pastes the progress bar implementation in Pkg into here. It is probably a bit excessive to use so we can simplify that significantly. - Parallel precompilation uses the `FileWatching` module to avoid different processes trying to precompile the same package concurrently. Right now, I used grab this from `Base.loaded_modules` relying on it being in the sysimage. - This removes the "suspended" functionality from the Pkg precompilation which does not try to precompile packages if they have "recently" failed which is unclear how useful it is in practice. This also requires the Serialization stdlib and uses data structures defined in Pkg so it is hard to keep when moving this to Base. --------- Co-authored-by: Ian Butterworth <i.r.butterworth@gmail.com> | 05 March 2024, 01:07:34 UTC |
50114d7 | Jameson Nash | 26 February 2024, 20:49:39 UTC | codegen: optimize const fields of mutable objects even more Make this analysis even stronger, using a function from llvm-late-gc-lowering.cpp that implements it more aggressively | 04 March 2024, 21:14:31 UTC |
ece8814 | Jameson Nash | 26 February 2024, 20:06:31 UTC | codegen: optimize const fields of mutable objects For example, we seek to eliminate the gc frame from this function, as observed here: ```julia julia> code_llvm((BitSet,), raw=true) do x; r = x.bits; GC.safepoint(); @inbounds r[1]; end ; Function Signature: var"#3"(Base.BitSet) ; @ REPL[1]:1 within `#3` define swiftcc i64 @"julia_#3_494"(ptr nonnull swiftself %pgcstack, ptr noundef nonnull align 8 dereferenceable(16) %"x::BitSet") #0 !dbg !5 { top: call void @llvm.dbg.declare(metadata ptr %"x::BitSet", metadata !21, metadata !DIExpression()), !dbg !22 %ptls_field = getelementptr inbounds ptr, ptr %pgcstack, i64 2 %ptls_load = load ptr, ptr %ptls_field, align 8, !tbaa !23 %0 = getelementptr inbounds ptr, ptr %ptls_load, i64 2 %safepoint = load ptr, ptr %0, align 8, !tbaa !27 fence syncscope("singlethread") seq_cst %1 = load volatile i64, ptr %safepoint, align 8, !dbg !22 fence syncscope("singlethread") seq_cst ; β @ Base.jl:49 within `getproperty` %"x::BitSet.bits" = load atomic ptr, ptr %"x::BitSet" unordered, align 8, !dbg !29, !tbaa !27, !alias.scope !33, !noalias !36, !nonnull !11, !dereferenceable !41, !align !42 ; β ; β @ gcutils.jl:253 within `safepoint` %ptls_load4 = load ptr, ptr %ptls_field, align 8, !dbg !43, !tbaa !23 %2 = getelementptr inbounds ptr, ptr %ptls_load4, i64 2, !dbg !43 %safepoint5 = load ptr, ptr %2, align 8, !dbg !43, !tbaa !27 fence syncscope("singlethread") seq_cst, !dbg !43 %3 = load volatile i64, ptr %safepoint5, align 8, !dbg !43 fence syncscope("singlethread") seq_cst, !dbg !43 ; β ; β @ essentials.jl:892 within `getindex` %4 = load ptr, ptr %"x::BitSet.bits", align 8, !dbg !46, !tbaa !49, !alias.scope !52, !noalias !53 %5 = load i64, ptr %4, align 8, !dbg !46, !tbaa !54, !alias.scope !57, !noalias !58 ret i64 %5, !dbg !46 ; β } ``` | 04 March 2024, 21:14:31 UTC |
f66fd47 | Jameson Nash | 04 March 2024, 21:14:08 UTC | make MethodError for unhandled kwarg more accurate (#53500) Previously it threw this error manually, so it did not have the world info for this lookup and message to be fully accurate. | 04 March 2024, 21:14:08 UTC |
688ae0a | cui fliter | 04 March 2024, 18:09:52 UTC | remove repetitive code (#53592) | 04 March 2024, 18:09:52 UTC |
144f58b | Shuhei Kadowaki | 04 March 2024, 17:58:28 UTC | disable irinterp for interpreters with `may_optimize(...)=false` (#53580) As discussed at <https://github.com/JuliaLang/julia/commit/b8a0a3978ccf163ce8fc371a4882547dc1271d53#commitcomment-139076159>, currently external abstract interpreter that configures `may_optimize` to return `false` may end up with the internal error from irinterp since it fundamentally required optimized IR but it currently assumes that all sources from cached `CodeInstance`s are optimized. This commit addresses the issue by incorporating a `may_optimize` check in `concrete_eval_eligible`, which in turn automatically disables irinterp for such interpreters. Although there were earlier discussions suggesting the revival of `codeinfo.inferred::Bool`, this commit does not need it, and I think this approach maintains the current state more cleanly. This should fix the error of `"inference"` benchmarks from BaseBenchmarks.jl. | 04 March 2024, 17:58:28 UTC |
0311aa4 | Michael Goerz | 04 March 2024, 16:34:27 UTC | Update Documenter to v1.3 for inventory writing (#53571) With the newest Documenter release, the Julia documentation will automatically have an `objects.inv` file. This file allows any other project using Documenter with the [`DocumenterInterLinks`](https://github.com/JuliaDocs/DocumenterInterLinks.jl) plugin (or any project using [Sphinx](https://www.sphinx-doc.org/en/master/)) to link directly into the Julia documentation, e.g., with ```[`Base.sort!`](@extref Julia)```. See also https://github.com/JuliaDocs/Documenter.jl/pull/2424#issuecomment-1960025462 and the following comments | 04 March 2024, 16:34:27 UTC |
973b4ff | Diogo Netto | 04 March 2024, 16:16:28 UTC | yet more atomics & cache-line fixes on work-stealing queue (#53424) This regression at a large number of GC threads still shows up on a large aarch64 machine (80-core ARM Neoverse N1). ``` bench = "many_refs.jl" (gcthreads, threads) = (1, 1) [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback βββββββββββ¬βββββββββββββ¬ββββββββββ¬ββββββββββββ¬βββββββββββββ¬βββββββββββββββ¬ββββββββββββββββββββ¬βββββββββββ¬βββββββββββββ β β total time β gc time β mark time β sweep time β max GC pause β time to safepoint β max heap β percent gc β β β ms β ms β ms β ms β ms β us β MB β % β βββββββββββΌβββββββββββββΌββββββββββΌββββββββββββΌβββββββββββββΌβββββββββββββββΌββββββββββββββββββββΌβββββββββββΌβββββββββββββ€ β minimum β 3807 β 2826 β 2633 β 193 β 960 β 13 β 892 β 74 β β median β 3810 β 2826 β 2633 β 193 β 961 β 15 β 892 β 74 β β maximum β 3810 β 2831 β 2638 β 193 β 962 β 27 β 892 β 74 β β stdev β 2 β 3 β 3 β 0 β 1 β 7 β 0 β 0 β βββββββββββ΄βββββββββββββ΄ββββββββββ΄ββββββββββββ΄βββββββββββββ΄βββββββββββββββ΄ββββββββββββββββββββ΄βββββββββββ΄βββββββββββββ (gcthreads, threads) = (2, 1) [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback βββββββββββ¬βββββββββββββ¬ββββββββββ¬ββββββββββββ¬βββββββββββββ¬βββββββββββββββ¬ββββββββββββββββββββ¬βββββββββββ¬βββββββββββββ β β total time β gc time β mark time β sweep time β max GC pause β time to safepoint β max heap β percent gc β β β ms β ms β ms β ms β ms β us β MB β % β βββββββββββΌβββββββββββββΌββββββββββΌββββββββββββΌβββββββββββββΌβββββββββββββββΌββββββββββββββββββββΌβββββββββββΌβββββββββββββ€ β minimum β 2455 β 1476 β 1350 β 126 β 488 β 20 β 892 β 60 β β median β 2459 β 1478 β 1352 β 126 β 489 β 23 β 892 β 60 β β maximum β 2465 β 1479 β 1352 β 126 β 489 β 23 β 893 β 60 β β stdev β 5 β 1 β 1 β 0 β 1 β 2 β 0 β 0 β βββββββββββ΄βββββββββββββ΄ββββββββββ΄ββββββββββββ΄βββββββββββββ΄βββββββββββββββ΄ββββββββββββββββββββ΄βββββββββββ΄βββββββββββββ (gcthreads, threads) = (4, 1) [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback βββββββββββ¬βββββββββββββ¬ββββββββββ¬ββββββββββββ¬βββββββββββββ¬βββββββββββββββ¬ββββββββββββββββββββ¬βββββββββββ¬βββββββββββββ β β total time β gc time β mark time β sweep time β max GC pause β time to safepoint β max heap β percent gc β β β ms β ms β ms β ms β ms β us β MB β % β βββββββββββΌβββββββββββββΌββββββββββΌββββββββββββΌβββββββββββββΌβββββββββββββββΌββββββββββββββββββββΌβββββββββββΌβββββββββββββ€ β minimum β 2173 β 1194 β 1115 β 77 β 463 β 18 β 892 β 54 β β median β 2187 β 1194 β 1116 β 78 β 463 β 19 β 893 β 55 β β maximum β 2217 β 1208 β 1130 β 78 β 463 β 19 β 893 β 55 β β stdev β 22 β 8 β 8 β 1 β 0 β 1 β 0 β 0 β βββββββββββ΄βββββββββββββ΄ββββββββββ΄ββββββββββββ΄βββββββββββββ΄βββββββββββββββ΄ββββββββββββββββββββ΄βββββββββββ΄βββββββββββββ (gcthreads, threads) = (8, 1) [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback βββββββββββ¬βββββββββββββ¬ββββββββββ¬ββββββββββββ¬βββββββββββββ¬βββββββββββββββ¬ββββββββββββββββββββ¬βββββββββββ¬βββββββββββββ β β total time β gc time β mark time β sweep time β max GC pause β time to safepoint β max heap β percent gc β β β ms β ms β ms β ms β ms β us β MB β % β βββββββββββΌβββββββββββββΌββββββββββΌββββββββββββΌβββββββββββββΌβββββββββββββββΌββββββββββββββββββββΌβββββββββββΌβββββββββββββ€ β minimum β 2191 β 1212 β 1149 β 63 β 539 β 19 β 901 β 55 β β median β 2199 β 1219 β 1156 β 63 β 540 β 20 β 901 β 55 β β maximum β 2201 β 1222 β 1157 β 65 β 540 β 20 β 901 β 56 β β stdev β 5 β 5 β 4 β 1 β 1 β 1 β 0 β 0 β βββββββββββ΄βββββββββββββ΄ββββββββββ΄ββββββββββββ΄βββββββββββββ΄βββββββββββββββ΄ββββββββββββββββββββ΄βββββββββββ΄βββββββββββββ (gcthreads, threads) = (16, 1) [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback βββββββββββ¬βββββββββββββ¬ββββββββββ¬ββββββββββββ¬βββββββββββββ¬βββββββββββββββ¬ββββββββββββββββββββ¬βββββββββββ¬βββββββββββββ β β total time β gc time β mark time β sweep time β max GC pause β time to safepoint β max heap β percent gc β β β ms β ms β ms β ms β ms β us β MB β % β βββββββββββΌβββββββββββββΌββββββββββΌββββββββββββΌβββββββββββββΌβββββββββββββββΌββββββββββββββββββββΌβββββββββββΌβββββββββββββ€ β minimum β 3897 β 2916 β 2854 β 60 β 1423 β 20 β 902 β 75 β β median β 4012 β 3032 β 2972 β 62 β 1491 β 21 β 904 β 75 β β maximum β 4026 β 3106 β 3044 β 62 β 1511 β 22 β 904 β 77 β β stdev β 70 β 96 β 96 β 1 β 46 β 1 β 1 β 1 β βββββββββββ΄βββββββββββββ΄ββββββββββ΄ββββββββββββ΄βββββββββββββ΄βββββββββββββββ΄ββββββββββββββββββββ΄βββββββββββ΄βββββββββββββ ``` This patch seems to improve performance at 16 GC threads though we still have some negative scaling for this benchmark beyond 8 GC threads (others seem fine). I didn't test whether this is indeed the optimal struct layout for the queue in this benchmark. ``` bench = "many_refs.jl" (gcthreads, threads) = (1, 1) [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback βββββββββββ¬βββββββββββββ¬ββββββββββ¬ββββββββββββ¬βββββββββββββ¬βββββββββββββββ¬ββββββββββββββββββββ¬βββββββββββ¬βββββββββββββ β β total time β gc time β mark time β sweep time β max GC pause β time to safepoint β max heap β percent gc β β β ms β ms β ms β ms β ms β us β MB β % β βββββββββββΌβββββββββββββΌββββββββββΌββββββββββββΌβββββββββββββΌβββββββββββββββΌββββββββββββββββββββΌβββββββββββΌβββββββββββββ€ β minimum β 3807 β 2822 β 2630 β 193 β 959 β 15 β 892 β 74 β β median β 3824 β 2823 β 2630 β 193 β 959 β 15 β 892 β 74 β β maximum β 4307 β 3194 β 2974 β 220 β 1086 β 19 β 892 β 74 β β stdev β 284 β 215 β 199 β 16 β 74 β 2 β 0 β 0 β βββββββββββ΄βββββββββββββ΄ββββββββββ΄ββββββββββββ΄βββββββββββββ΄βββββββββββββββ΄ββββββββββββββββββββ΄βββββββββββ΄βββββββββββββ (gcthreads, threads) = (2, 1) [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback βββββββββββ¬βββββββββββββ¬ββββββββββ¬ββββββββββββ¬βββββββββββββ¬βββββββββββββββ¬ββββββββββββββββββββ¬βββββββββββ¬βββββββββββββ β β total time β gc time β mark time β sweep time β max GC pause β time to safepoint β max heap β percent gc β β β ms β ms β ms β ms β ms β us β MB β % β βββββββββββΌβββββββββββββΌββββββββββΌββββββββββββΌβββββββββββββΌβββββββββββββββΌββββββββββββββββββββΌβββββββββββΌβββββββββββββ€ β minimum β 2459 β 1476 β 1349 β 126 β 488 β 19 β 892 β 60 β β median β 2460 β 1479 β 1352 β 127 β 488 β 21 β 893 β 60 β β maximum β 2770 β 1661 β 1526 β 135 β 570 β 22 β 893 β 60 β β stdev β 179 β 106 β 101 β 5 β 47 β 1 β 0 β 0 β βββββββββββ΄βββββββββββββ΄ββββββββββ΄ββββββββββββ΄βββββββββββββ΄βββββββββββββββ΄ββββββββββββββββββββ΄βββββββββββ΄βββββββββββββ (gcthreads, threads) = (4, 1) [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback βββββββββββ¬βββββββββββββ¬ββββββββββ¬ββββββββββββ¬βββββββββββββ¬βββββββββββββββ¬ββββββββββββββββββββ¬βββββββββββ¬βββββββββββββ β β total time β gc time β mark time β sweep time β max GC pause β time to safepoint β max heap β percent gc β β β ms β ms β ms β ms β ms β us β MB β % β βββββββββββΌβββββββββββββΌββββββββββΌββββββββββββΌβββββββββββββΌβββββββββββββββΌββββββββββββββββββββΌβββββββββββΌβββββββββββββ€ β minimum β 2215 β 1233 β 1155 β 77 β 485 β 20 β 892 β 53 β β median β 2320 β 1248 β 1171 β 78 β 492 β 21 β 893 β 54 β β maximum β 2372 β 1259 β 1176 β 83 β 493 β 22 β 893 β 56 β β stdev β 80 β 13 β 11 β 3 β 5 β 1 β 1 β 1 β βββββββββββ΄βββββββββββββ΄ββββββββββ΄ββββββββββββ΄βββββββββββββ΄βββββββββββββββ΄ββββββββββββββββββββ΄βββββββββββ΄βββββββββββββ (gcthreads, threads) = (8, 1) [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback βββββββββββ¬βββββββββββββ¬ββββββββββ¬ββββββββββββ¬βββββββββββββ¬βββββββββββββββ¬ββββββββββββββββββββ¬βββββββββββ¬βββββββββββββ β β total time β gc time β mark time β sweep time β max GC pause β time to safepoint β max heap β percent gc β β β ms β ms β ms β ms β ms β us β MB β % β βββββββββββΌβββββββββββββΌββββββββββΌββββββββββββΌβββββββββββββΌβββββββββββββββΌββββββββββββββββββββΌβββββββββββΌβββββββββββββ€ β minimum β 2204 β 1220 β 1156 β 64 β 544 β 23 β 901 β 53 β β median β 2362 β 1249 β 1181 β 64 β 553 β 23 β 901 β 53 β β maximum β 2374 β 1261 β 1196 β 68 β 558 β 25 β 901 β 55 β β stdev β 95 β 21 β 20 β 2 β 7 β 1 β 0 β 1 β βββββββββββ΄βββββββββββββ΄ββββββββββ΄ββββββββββββ΄βββββββββββββ΄βββββββββββββββ΄ββββββββββββββββββββ΄βββββββββββ΄βββββββββββββ (gcthreads, threads) = (16, 1) [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback [ Info: Setting GC memory pressure callback βββββββββββ¬βββββββββββββ¬ββββββββββ¬ββββββββββββ¬βββββββββββββ¬βββββββββββββββ¬ββββββββββββββββββββ¬βββββββββββ¬βββββββββββββ β β total time β gc time β mark time β sweep time β max GC pause β time to safepoint β max heap β percent gc β β β ms β ms β ms β ms β ms β us β MB β % β βββββββββββΌβββββββββββββΌββββββββββΌββββββββββββΌβββββββββββββΌβββββββββββββββΌββββββββββββββββββββΌβββββββββββΌβββββββββββββ€ β minimum β 2502 β 1519 β 1458 β 62 β 721 β 22 β 902 β 58 β β median β 2511 β 1524 β 1461 β 63 β 728 β 23 β 903 β 61 β β maximum β 2664 β 1554 β 1486 β 68 β 741 β 25 β 905 β 61 β β stdev β 91 β 19 β 16 β 3 β 10 β 1 β 2 β 1 β βββββββββββ΄βββββββββββββ΄ββββββββββ΄ββββββββββββ΄βββββββββββββ΄βββββββββββββββ΄ββββββββββββββββββββ΄βββββββββββ΄βββββββββββββ ``` | 04 March 2024, 16:16:28 UTC |
4d5a20d | Dilum Aluthge | 04 March 2024, 11:36:24 UTC | Docs: Change "Packages that wrap external libraries or programs should be named after those libraries or programs" to "Packages that wrap external libraries or programs can be named after those libraries or programs" (#53567) Before this PR: > Packages that wrap external libraries or programs should be named after those libraries or programs. I think that "should" is a little too strong. After this PR: > Packages that wrap external libraries or programs can be named after those libraries or programs. ## Motivation This might make it a bit easier to convince package authors that they can use a longer more descriptive name for their package, instead of needing to exactly match the name of the underlying software that they are wrapping. Suppose for example that someone is making a Julia package to wrap a piece of software named `HW`. Under the "should be named..." guideline, this would lead the package author to register a Julia package named HW.jl. Personally I'd like to encourage longer and more descriptive names. So, under the "can be named..." guideline, the author won't feel like the Julia package needs to be named HW.jl, and thus they might be more amenable to a longer name such as HelloWorld.jl. | 04 March 2024, 11:36:24 UTC |
bc2212c | Alexander Plavin | 04 March 2024, 01:20:49 UTC | allow convert from RegexMatch to Dict/NamedTuple (#50988) Added implementation + tests, will add to docs if ok --------- Co-authored-by: Dilum Aluthge <dilum@aluthge.com> Co-authored-by: Jeff Bezanson <jeff.bezanson@gmail.com> | 04 March 2024, 01:20:49 UTC |
7179050 | erich-9 | 03 March 2024, 03:14:28 UTC | Always return a value in 1-d circshift! of abstractarray.jl (#53554) Co-authored-by: Sukera <11753998+Seelengrab@users.noreply.github.com> Co-authored-by: Mosè Giordano <giordano@users.noreply.github.com> | 03 March 2024, 03:14:28 UTC |
0f902bf | Eric Hanson | 03 March 2024, 03:14:06 UTC | Provide better error hint when `UndefVarError` results from name clashes (#53469) We can detect this since we set the `usingfailed` bit when the clash occurs (to avoid printing the `WARNING` multiple times). In this case, typos or missing imports (the current message) isn't quite as clear as it could be, because in fact the name is probably spelled totally right, it's just that there is a missing explicit import or the name should be qualified. This code will stop working if we change the flags in `Core.Binding`, but the test I added should catch that. However if REPL is supposed to be independent of Base and not depend on internals there, there could be an issue. In that case we should probably add an API to Base to inspect this `usingfailed` bit so we can use it in the REPL. --------- Co-authored-by: Jameson Nash <vtjnash@gmail.com> Co-authored-by: Alex Arslan <ararslan@comcast.net> | 03 March 2024, 03:14:06 UTC |
e7734ea | Abel Soares Siqueira | 03 March 2024, 01:23:18 UTC | Add a GitHub Actions workflow for automatic validation of the citation metadata file (`CITATION.CFF`) (#44062) Hello! We noticed that your `CITATION.cff` had a small issue and fixed it. In addition to the fix, this Pull Request automates validation of that file using the [cffconvert GitHub Action](https://github.com/marketplace/actions/cffconvert). That way, it's a little bit easier to be robust against future changes to the `CITATION.cff` file. BTW it's perfectly fine if you don't feel like accepting this Pull Request for whatever reason -- we just thought it might be helpful is all. We found your repository using a partially automated workflow; if you have any questions about that, feel free to create an issue over at https://github.com/cffbots/filtering/issues/ On behalf of the cffbots team, @abelsiqueira / @fdiblen / @jspaaks --------- Co-authored-by: Max Horn <max@quendi.de> | 03 March 2024, 01:23:18 UTC |
a586d3c | Mason Protter | 03 March 2024, 01:16:51 UTC | Clarify docstring for `zero`, `one`, and `oneunit`. (#52107) spurred by a conversation on Slack where someone was thrown off wondering why `zero(Vector{Int})` errors, but `zero(Int)` is fine. --------- Co-authored-by: Sukera <11753998+Seelengrab@users.noreply.github.com> Co-authored-by: Max Horn <max@quendi.de> Co-authored-by: Simon Byrne <simonbyrne@gmail.com> | 03 March 2024, 01:16:51 UTC |
86f5b21 | Jakob Nybo Nissen | 03 March 2024, 01:16:23 UTC | Make dump print `const` before const fields (#53492) This provides more information to the user when dumping types, and also makes the output of dump slightly more similar to the type definition syntax. EDIT: This has been changed to print: * The kind of type before the type name `abstract type`, `mutable struct`, etc. * `const` only for `const` fields of `mutable struct` New behaviour ``` julia> dump(Float32) primitive type Float32 <: AbstractFloat julia> dump(Signed) abstract type Signed <: Integer julia> dump(Pair{Int, String}) struct Pair{Int64, String} <: Any first::Int64 second::String julia> dump(BitSet) mutable struct BitSet <: AbstractSet{Int64} const bits::Vector{UInt64} offset::Int64 julia> dump(Set) UnionAll var: TypeVar name: Symbol T lb: Union{} ub: abstract type Any body: struct Set{T} <: AbstractSet{T} dict::Dict{T, Nothing} ``` --------- Co-authored-by: Shuhei Kadowaki <aviatesk@gmail.com> | 03 March 2024, 01:16:23 UTC |
e3b2462 | Mateus AraΓΊjo | 02 March 2024, 19:02:45 UTC | fix number of chunks (#53413) The manual claims that `a` is split into `nthreads()` chunks, but this is not true in general. As it was you could get an error, if `length(a) < nthreads()`, or a number of chunks larger than `nthreads()`, if `nthreads()` is smaller than `length(a)` but does not divide it. With `cld`, on the other hand, you always get at most `nthreads()` chunks. | 02 March 2024, 19:02:45 UTC |