Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
b65a9cc
Fix devcontainer definition (#57006)
M-PERSIC Jan 10, 2025
078105d
codegen: mark write barrier field load as volatile (#59559)
vtjnash Sep 16, 2025
85886aa
Remove GPL libraries from the Julia build for binary-dist target (#59…
ViralBShah Sep 22, 2025
546c712
also redirect JL_STDERR etc. when redirecting to devnull (#55958)
IanButterworth Oct 4, 2025
f12b9f6
[REPL] Do not corrupt input when using numbered_prompt! mode (#59730)
vtjnash Oct 6, 2025
8dd1e2d
Revert "Restrict COFF to a single thread when symbol count is high (#…
topolarity Oct 7, 2025
d27fc60
Fix removal of GPL libs (#60100)
nalimilan Nov 13, 2025
6109d8c
Remove precompile-time tempfiles from TEMP_CLEANUP (#60106)
deroulers Nov 13, 2025
62544df
Correct version in which at-lock was exported (#60279)
giordano Nov 29, 2025
67643b7
Logging: define isless between Integer and LogLevel (#60330)
EdsterG Dec 10, 2025
47abd35
1.11: add getter for global variable pointer matching jlvalue (#60684)
wsmoses Jan 14, 2026
4b23da6
Drop test `test/llvmpasses/gc-writebarrier-volatile.ll`
DilumAluthge Jan 16, 2026
35bec7e
CI: Update external GitHub Actions, and pin all external actions to a…
DilumAluthge Jan 16, 2026
29b3528
add wb_back on all task switch paths (#60617)
vtjnash Jan 15, 2026
a36ed76
[1.11] Backport #60718+#60746: Fix and test `jl_method_lookup_by_tt` …
maleadt Jan 20, 2026
9747c77
[1.11] [LLVMAllocOpt] Preserve metadata lowering an alloca (#60776)
wsmoses Jan 21, 2026
f91cd5f
🤖 [backports-release-1.11] Bump SparseArrays stdlib 2420351 → e4ffd9f…
DilumAluthgeBot Jan 21, 2026
e29b8e6
[backports-release-1.11] Fix namespace of `IOError` in `random_seed` …
jishnub Jan 21, 2026
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
3 changes: 0 additions & 3 deletions .devcontainer/Dockerfile

This file was deleted.

16 changes: 10 additions & 6 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
{
"extensions": [
"julialang.language-julia",
"ms-vscode.cpptools"
],

"dockerFile": "Dockerfile"
"image": "docker.io/library/julia:latest",
"customizations": {
"vscode": {
"extensions": [
"julialang.language-julia",
"ms-vscode.cpptools"
]
}
},
"onCreateCommand": "apt-get update && apt-get install -y build-essential libatomic1 python3 gfortran perl wget m4 cmake pkg-config git"
}
2 changes: 1 addition & 1 deletion .github/workflows/LabelCheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
- uses: yogevbd/[email protected]
- uses: yogevbd/enforce-label-action@a3c219da6b8fa73f6ba62b68ff09c469b3a1c024 # 2.2.2
with:
# REQUIRED_LABELS_ANY: "bug,enhancement,skip-changelog"
# REQUIRED_LABELS_ANY_DESCRIPTION: "Select at least one label ['bug','enhancement','skip-changelog']"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/Typos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
timeout-minutes: 5
steps:
- name: Checkout the JuliaLang/julia repository
uses: actions/checkout@v4
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
with:
persist-credentials: false
- name: Check spelling with typos
Expand Down
2 changes: 1 addition & 1 deletion base/lock.jl
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ This is similar to using [`lock`](@ref) with a `do` block, but avoids creating a
and thus can improve the performance.
!!! compat
`@lock` was added in Julia 1.3, and exported in Julia 1.10.
`@lock` was added in Julia 1.3, and exported in Julia 1.7.
"""
macro lock(l, expr)
quote
Expand Down
2 changes: 2 additions & 0 deletions base/logging/logging.jl
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,8 @@ end
LogLevel(level::LogLevel) = level

isless(a::LogLevel, b::LogLevel) = isless(a.level, b.level)
isless(a::LogLevel, b::Integer) = isless(a.level, b)
isless(a::Integer, b::LogLevel) = isless(a, b.level)
+(level::LogLevel, inc::Integer) = LogLevel(level.level+inc)
-(level::LogLevel, inc::Integer) = LogLevel(level.level-inc)
convert(::Type{LogLevel}, level::Integer) = LogLevel(level)
Expand Down
17 changes: 11 additions & 6 deletions base/stream.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1249,7 +1249,15 @@ function _redirect_io_libc(stream, unix_fd::Int)
-10 - unix_fd, Libc._get_osfhandle(posix_fd))
end
end
dup(posix_fd, RawFD(unix_fd))
GC.@preserve stream dup(posix_fd, RawFD(unix_fd))
nothing
end
function _redirect_io_cglobal(handle::Union{LibuvStream, IOStream, Nothing}, unix_fd::Int)
c_sym = unix_fd == 0 ? cglobal(:jl_uv_stdin, Ptr{Cvoid}) :
unix_fd == 1 ? cglobal(:jl_uv_stdout, Ptr{Cvoid}) :
unix_fd == 2 ? cglobal(:jl_uv_stderr, Ptr{Cvoid}) :
C_NULL
c_sym == C_NULL || unsafe_store!(c_sym, handle === nothing ? Ptr{Cvoid}(unix_fd) : handle.handle)
nothing
end
function _redirect_io_global(io, unix_fd::Int)
Expand All @@ -1260,11 +1268,7 @@ function _redirect_io_global(io, unix_fd::Int)
end
function (f::RedirectStdStream)(handle::Union{LibuvStream, IOStream})
_redirect_io_libc(handle, f.unix_fd)
c_sym = f.unix_fd == 0 ? cglobal(:jl_uv_stdin, Ptr{Cvoid}) :
f.unix_fd == 1 ? cglobal(:jl_uv_stdout, Ptr{Cvoid}) :
f.unix_fd == 2 ? cglobal(:jl_uv_stderr, Ptr{Cvoid}) :
C_NULL
c_sym == C_NULL || unsafe_store!(c_sym, handle.handle)
_redirect_io_cglobal(handle, f.unix_fd)
_redirect_io_global(handle, f.unix_fd)
return handle
end
Expand All @@ -1273,6 +1277,7 @@ function (f::RedirectStdStream)(::DevNull)
handle = open(nulldev, write=f.writable)
_redirect_io_libc(handle, f.unix_fd)
close(handle) # handle has been dup'ed in _redirect_io_libc
_redirect_io_cglobal(nothing, f.unix_fd)
_redirect_io_global(devnull, f.unix_fd)
return devnull
end
Expand Down
4 changes: 2 additions & 2 deletions contrib/generate_precompile.jl
Original file line number Diff line number Diff line change
Expand Up @@ -315,8 +315,8 @@ generate_precompile_statements() = try # Make sure `ansi_enablecursor` is printe
uuid = "$pkguuid"
""")
touch(joinpath(pkgpath, "Manifest.toml"))
tmp_prec = tempname(prec_path)
tmp_proc = tempname(prec_path)
tmp_prec = tempname(prec_path; cleanup=false)
tmp_proc = tempname(prec_path; cleanup=false)
s = """
pushfirst!(DEPOT_PATH, $(repr(joinpath(prec_path,"depot"))));
Base.PRECOMPILE_TRACE_COMPILE[] = $(repr(tmp_prec));
Expand Down

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
3ae2eebb167edd93aa2b67aef56f1764
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
bb8e24a95e84e59aa296b5b3d584e35dddf6cace926afb919c03c5d560aefbb7f6ad1442d0b2bf104212c62d8f578f5fb4e2c6dfdea196a0fae9bdf61527d8fa
17 changes: 9 additions & 8 deletions src/aotcompile.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,15 @@ void jl_get_llvm_gvs_impl(void *native_code, arraylist_t *gvs)
memcpy(gvs->items, data->jl_value_to_llvm.data(), gvs->len * sizeof(void*));
}

extern "C" JL_DLLEXPORT_CODEGEN
void jl_get_llvm_gvs_globals_impl(void *native_code, arraylist_t *gvs)
{
// map a memory location (jl_value_t or jl_binding_t) to a GlobalVariable
jl_native_code_desc_t *data = (jl_native_code_desc_t*)native_code;
arraylist_grow(gvs, data->jl_sysimg_gvars.size());
memcpy(gvs->items, data->jl_sysimg_gvars.data(), gvs->len * sizeof(void*));
}

extern "C" JL_DLLEXPORT_CODEGEN
void jl_get_llvm_external_fns_impl(void *native_code, arraylist_t *external_fns)
{
Expand Down Expand Up @@ -715,7 +724,6 @@ static FunctionInfo getFunctionWeight(const Function &F)
}

struct ModuleInfo {
Triple triple;
size_t globals;
size_t funcs;
size_t bbs;
Expand All @@ -726,7 +734,6 @@ struct ModuleInfo {

ModuleInfo compute_module_info(Module &M) {
ModuleInfo info;
info.triple = Triple(M.getTargetTriple());
info.globals = 0;
info.funcs = 0;
info.bbs = 0;
Expand Down Expand Up @@ -1519,12 +1526,6 @@ static unsigned compute_image_thread_count(const ModuleInfo &info) {
#endif
if (jl_is_timing_passes) // LLVM isn't thread safe when timing the passes https://github.com/llvm/llvm-project/issues/44417
return 1;
// COFF has limits on external symbols (even hidden) up to 65536. We reserve the last few
// for any of our other symbols that we insert during compilation.
if (info.triple.isOSBinFormatCOFF() && info.globals > 64000) {
LLVM_DEBUG(dbgs() << "COFF is restricted to a single thread for large images\n");
return 1;
}
// This is not overridable because empty modules do occasionally appear, but they'll be very small and thus exit early to
// known easy behavior. Plus they really don't warrant multiple threads
if (info.weight < 1000) {
Expand Down
1 change: 1 addition & 0 deletions src/codegen-stubs.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ JL_DLLEXPORT void jl_dump_native_fallback(void *native_code,
const char *bc_fname, const char *unopt_bc_fname, const char *obj_fname, const char *asm_fname,
ios_t *z, ios_t *s) UNAVAILABLE
JL_DLLEXPORT void jl_get_llvm_gvs_fallback(void *native_code, arraylist_t *gvs) UNAVAILABLE
JL_DLLEXPORT void jl_get_llvm_gvs_globals_fallback(void *native_code, arraylist_t *gvs) UNAVAILABLE
JL_DLLEXPORT void jl_get_llvm_external_fns_fallback(void *native_code, arraylist_t *gvs) UNAVAILABLE

JL_DLLEXPORT void jl_extern_c_fallback(jl_function_t *f, jl_value_t *rt, jl_value_t *argt, char *name) UNAVAILABLE
Expand Down
2 changes: 1 addition & 1 deletion src/gf.c
Original file line number Diff line number Diff line change
Expand Up @@ -1503,7 +1503,7 @@ static jl_method_instance_t *jl_mt_assoc_by_type(jl_methtable_t *mt JL_PROPAGATE
if (!mi) {
size_t min_valid = 0;
size_t max_valid = ~(size_t)0;
matc = _gf_invoke_lookup((jl_value_t*)tt, jl_nothing, world, &min_valid, &max_valid);
matc = _gf_invoke_lookup((jl_value_t*)tt, (jl_value_t*)mt, world, &min_valid, &max_valid);
if (matc) {
jl_method_t *m = matc->method;
jl_svec_t *env = matc->sparams;
Expand Down
1 change: 1 addition & 0 deletions src/jl_exported_funcs.inc
Original file line number Diff line number Diff line change
Expand Up @@ -531,6 +531,7 @@
YY(jl_get_LLVM_VERSION) \
YY(jl_dump_native) \
YY(jl_get_llvm_gvs) \
YY(jl_get_llvm_gvs_globals) \
YY(jl_get_llvm_external_fns) \
YY(jl_dump_function_asm) \
YY(jl_LLVMCreateDisasm) \
Expand Down
1 change: 1 addition & 0 deletions src/julia_internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -1738,6 +1738,7 @@ JL_DLLIMPORT void jl_dump_native(void *native_code,
const char *bc_fname, const char *unopt_bc_fname, const char *obj_fname, const char *asm_fname,
ios_t *z, ios_t *s, jl_emission_params_t *params);
JL_DLLIMPORT void jl_get_llvm_gvs(void *native_code, arraylist_t *gvs);
JL_DLLIMPORT void jl_get_llvm_gvs_globals(void *native_code, arraylist_t *gvs);
JL_DLLIMPORT void jl_get_llvm_external_fns(void *native_code, arraylist_t *gvs);
JL_DLLIMPORT void jl_get_function_id(void *native_code, jl_code_instance_t *ncode,
int32_t *func_idx, int32_t *specfunc_idx);
Expand Down
1 change: 1 addition & 0 deletions src/llvm-alloc-opt.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -681,6 +681,7 @@ void Optimizer::moveToStack(CallInst *orig_inst, size_t sz, bool has_ref, AllocF
IRBuilder<> builder(orig_inst);
initializeAlloca(builder, buff, allockind);
}
buff->copyMetadata(*orig_inst);
Instruction *new_inst = cast<Instruction>(prolog_builder.CreateBitCast(ptr, JuliaType::get_pjlvalue_ty(prolog_builder.getContext(), buff->getType()->getPointerAddressSpace())));
new_inst->takeName(orig_inst);

Expand Down
10 changes: 6 additions & 4 deletions src/task.c
Original file line number Diff line number Diff line change
Expand Up @@ -227,10 +227,6 @@ static void NOINLINE save_stack(jl_ptls_t ptls, jl_task_t *lastt, jl_task_t **pt
lastt->copy_stack = nb;
lastt->sticky = 1;
memcpy_stack_a16((uint64_t*)buf, (uint64_t*)frame_addr, nb);
// this task's stack could have been modified after
// it was marked by an incremental collection
// move the barrier back instead of walking it again here
jl_gc_wb_back(lastt);
}

JL_NO_ASAN static void NOINLINE JL_NORETURN restore_stack(jl_task_t *t, jl_ptls_t ptls, char *p)
Expand Down Expand Up @@ -493,6 +489,12 @@ JL_NO_ASAN static void ctx_switch(jl_task_t *lastt)
#endif
*pt = NULL; // can't fail after here: clear the gc-root for the target task now
}
// this task's stack or scope field could have been modified after
// it was marked by an incremental collection
// move the barrier back instead of walking the shadow stack again here to check if that is required
// even if killed (dropping the stack) and just the scope field matters,
// let the gc figure that out next time it does a quick mark
jl_gc_wb_back(lastt);

// set up global state for new task and clear global state for old task
t->ptls = ptls;
Expand Down
7 changes: 7 additions & 0 deletions stdlib/Logging/test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,13 @@ macro customlog(exs...) Base.CoreLogging.logmsg_code((Base.CoreLogging.@_sourcei
@test :handle_message in names(Logging, all=true) # non-exported public function
end

@testset "LogLevel compatibility with integers" begin
@test Logging.Debug + 1000 == Logging.Info
@test Logging.Warn - 1000 == Logging.Info
@test Logging.Info < 500
@test 500 < Logging.Warn
end

@testset "ConsoleLogger" begin
# First pass log limiting
@test min_enabled_level(ConsoleLogger(devnull, Logging.Debug)) == Logging.Debug
Expand Down
14 changes: 13 additions & 1 deletion stdlib/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ include $(JULIAHOME)/deps/*.version

VERSDIR := v$(shell cut -d. -f1-2 < $(JULIAHOME)/VERSION)
DIRS := $(build_datarootdir)/julia/stdlib/$(VERSDIR) $(build_prefix)/manifest/$(VERSDIR)

$(foreach dir,$(DIRS),$(eval $(call dir_target,$(dir))))

JLLS = DSFMT GMP CURL LIBGIT2 LLVM LIBSSH2 LIBUV MBEDTLS MPFR NGHTTP2 \
Expand Down Expand Up @@ -61,8 +62,19 @@ $(foreach module, $(STDLIBS), $(eval $(call symlink_target,$$(JULIAHOME)/stdlib/

STDLIBS_LINK_TARGETS := $(addprefix $(build_datarootdir)/julia/stdlib/$(VERSDIR)/,$(STDLIBS))

remove-gpl-libs:
ifeq ($(USE_GPL_LIBS),0)
@echo Removing GPL libs...
-rm -f $(build_private_libdir)/libcholmod*
-rm -f $(build_private_libdir)/libklu_cholmod*
-rm -f $(build_private_libdir)/librbio*
-rm -f $(build_private_libdir)/libspqr*
-rm -f $(build_private_libdir)/libumfpack*
endif

getall get: $(addprefix get-, $(STDLIBS_EXT) $(JLL_NAMES))
install: version-check $(addprefix install-, $(STDLIBS_EXT) $(JLL_NAMES)) $(STDLIBS_LINK_TARGETS)

install: version-check $(addprefix install-, $(STDLIBS_EXT) $(JLL_NAMES)) $(STDLIBS_LINK_TARGETS) remove-gpl-libs
version-check: $(addprefix version-check-, $(STDLIBS_EXT))
uninstall: $(addprefix uninstall-, $(STDLIBS_EXT))
extstdlibclean:
Expand Down
23 changes: 4 additions & 19 deletions stdlib/REPL/src/REPL.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1690,25 +1690,10 @@ function repl_eval_counter(hp)
end

function out_transform(@nospecialize(x), n::Ref{Int})
return Expr(:toplevel, get_usings!([], x)..., quote
let __temp_val_a72df459 = $x
$capture_result($n, __temp_val_a72df459)
__temp_val_a72df459
end
end)
end

function get_usings!(usings, ex)
ex isa Expr || return usings
# get all `using` and `import` statements which are at the top level
for (i, arg) in enumerate(ex.args)
if Base.isexpr(arg, :toplevel)
get_usings!(usings, arg)
elseif Base.isexpr(arg, [:using, :import])
push!(usings, popat!(ex.args, i))
end
end
return usings
return Expr(:block, # avoid line numbers or scope that would leak into the output and change the meaning of x
:(local __temp_val_a72df459 = $x),
Expr(:call, capture_result, n, :__temp_val_a72df459),
:__temp_val_a72df459)
end

function capture_result(n::Ref{Int}, @nospecialize(x))
Expand Down
2 changes: 1 addition & 1 deletion stdlib/Random/src/RNGs.jl
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ function random_seed()
# almost surely always getting distinct seeds, while having them printed reasonably tersely
return rand(RandomDevice(), UInt128)
catch ex
ex isa IOError || rethrow()
ex isa Base.IOError || rethrow()
@warn "Entropy pool not available to seed RNG; using ad-hoc entropy sources."
return Libc.rand()
end
Expand Down
2 changes: 1 addition & 1 deletion stdlib/SparseArrays.version
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
SPARSEARRAYS_BRANCH = release-1.11
SPARSEARRAYS_SHA1 = 242035184c0d539bdb5e64bf26eb7726b123db14
SPARSEARRAYS_SHA1 = e4ffd9f08f891103cf59f2ad32fcf38d75812f86
SPARSEARRAYS_GIT_URL := https://github.com/JuliaSparse/SparseArrays.jl.git
SPARSEARRAYS_TAR_URL = https://api.github.com/repos/JuliaSparse/SparseArrays.jl/tarball/$1
26 changes: 26 additions & 0 deletions test/compiler/contextual.jl
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,32 @@ methods = Base._methods_by_ftype(Tuple{typeof(sin), Float64}, OverlayModule.mt,
methods = Base._methods_by_ftype(Tuple{typeof(sin), Int}, OverlayModule.mt, 1, Base.get_world_counter())
@test isempty(methods)

# fresh module to ensure uncached methods
module OverlayMTTest
using Base.Experimental: @MethodTable, @overlay
@MethodTable(mt)

function overlay_only end
@overlay mt overlay_only(x::Int) = x * 2
end

# #60702 & #60716: Overlay methods must be found without prior cache population
let world = Base.get_world_counter()
mi = Base.method_instance(OverlayMTTest.overlay_only, Tuple{Int};
world, method_table=OverlayMTTest.mt)
@test mi isa Core.MethodInstance
@test mi.def.module === OverlayMTTest
end

# #60712: Global-only methods must NOT be found via custom MT
let
@eval global_only_func(x::Int) = x + 1
world = Base.get_world_counter()
mi = Base.method_instance(global_only_func, Tuple{Int};
world, method_table=OverlayMTTest.mt)
@test mi === nothing
end

# precompilation

load_path = mktempdir()
Expand Down