Skip to content

Updating binding version to fix MMTk CI #57298

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

Merged
merged 4 commits into from
Feb 8, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
18 changes: 18 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -282,8 +282,26 @@ endif
endif

ifneq (${MMTK_PLAN},None)
# Make sure we use the right version of $MMTK_PLAN, $MMTK_MOVING and $MMTK_BUILD
# if we use the BinaryBuilder version of mmtk-julia
ifeq ($(USE_BINARYBUILDER_MMTK_JULIA),1)
ifeq (${MMTK_PLAN},Immix)
LIB_PATH_PLAN = immix
else ifeq (${MMTK_PLAN},StickyImmix)
LIB_PATH_PLAN = sticky
endif

ifeq ($(MMTK_MOVING), 0)
LIB_PATH_MOVING := non_moving
else
LIB_PATH_MOVING := moving
endif

JL_PRIVATE_LIBS-0 += $(LIB_PATH_PLAN)/$(LIB_PATH_MOVING)/$(MMTK_BUILD)/libmmtk_julia
else
JL_PRIVATE_LIBS-0 += libmmtk_julia
endif
endif

# Note that we disable MSYS2's path munging here, as otherwise
# it replaces our `:`-separated list as a `;`-separated one.
Expand Down
4 changes: 4 additions & 0 deletions deps/checksums/mmtk_julia
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,7 @@ mmtk_julia-c9e046baf3a0d52fe75d6c8b28f6afd69b045d95.tar.gz/md5/73a8fbea71edce30a
mmtk_julia-c9e046baf3a0d52fe75d6c8b28f6afd69b045d95.tar.gz/sha512/374848b7696b565dea66daa208830581f92c1fcb0138e7a7ab88564402e94bc79c54b6ed370ec68473e31e2bd411bf82c97793796c31d39aafbbfffea9c05588
mmtk_julia.v0.30.4+0.x86_64-linux-gnu.tar.gz/md5/8cdeb14fd69945f64308be49f6912f9c
mmtk_julia.v0.30.4+0.x86_64-linux-gnu.tar.gz/sha512/3692502f65dec8c0971b56b9bf8178641892b390d520cbcd69880d75b7500e6341534d87882246e68998f590f824ec54c18f4b8fb4aa09b8f313de065c48450e
mmtk_julia-10ad6638b69b31a97a844f2f4e651e5ccea4e298.tar.gz/md5/59ed2c0e0b48673988a40527907f13ae
mmtk_julia-10ad6638b69b31a97a844f2f4e651e5ccea4e298.tar.gz/sha512/d0988c37e82b8d481753f4ce83f38ba11276af3dafa8f65ee2c51122fce0dab056a65b3029cb255732226cc28d1a02e607bdaac91a02c0fd6a9fcfae834fee8c
mmtk_julia.v0.30.5+1.x86_64-linux-gnu.tar.gz/md5/4d12d64754bb5c61e86e97e88bcf7912
mmtk_julia.v0.30.5+1.x86_64-linux-gnu.tar.gz/sha512/0d619f00fd644338ca1ca2582b20e41db702dff8e0c338c093b2759b54379ba26ae7e0181c64931a45ebd5c3995540e535c248df9b986e73b18b65a39c5d78d2
19 changes: 19 additions & 0 deletions deps/mmtk_julia.mk
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,25 @@ endif # MMTK_JULIA_DIR
else
# We are building using the BinaryBuilder version of the binding

# This will download all the versions of the binding that are available in the BinaryBuilder
$(eval $(call bb-install,mmtk_julia,MMTK_JULIA,false))

# Make sure we use the right version of $MMTK_PLAN, $MMTK_MOVING and $MMTK_BUILD
ifeq (${MMTK_PLAN},Immix)
LIB_PATH_PLAN = immix
else ifeq (${MMTK_PLAN},StickyImmix)
LIB_PATH_PLAN = sticky
endif

ifeq ($(MMTK_MOVING), 0)
LIB_PATH_MOVING := non_moving
else
LIB_PATH_MOVING := moving
endif

version-check-mmtk_julia: $(BUILDROOT)/usr/lib/libmmtk_julia.so

$(BUILDROOT)/usr/lib/libmmtk_julia.so: get-mmtk_julia
@ln -sf $(BUILDROOT)/usr/lib/$(LIB_PATH_PLAN)/$(LIB_PATH_MOVING)/$(MMTK_BUILD)/libmmtk_julia.so $@

endif # USE_BINARYBUILDER_MMTK_JULIA
6 changes: 3 additions & 3 deletions deps/mmtk_julia.version
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MMTK_JULIA_BRANCH = master
MMTK_JULIA_SHA1 = c9e046baf3a0d52fe75d6c8b28f6afd69b045d95
MMTK_JULIA_SHA1 = 10ad6638b69b31a97a844f2f4e651e5ccea4e298
MMTK_JULIA_GIT_URL := https://github.com/mmtk/mmtk-julia.git
MMTK_JULIA_TAR_URL = https://github.com/mmtk/mmtk-julia/archive/refs/tags/v0.30.4.tar.gz
MMTK_JULIA_JLL_VER := 0.30.4+0
MMTK_JULIA_TAR_URL = https://github.com/mmtk/mmtk-julia/archive/refs/tags/v0.30.5.tar.gz
MMTK_JULIA_JLL_VER := 0.30.5+1
MMTK_JULIA_JLL_NAME := mmtk_julia
19 changes: 8 additions & 11 deletions stdlib/Profile/test/allocs.jl
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ let iobuf = IOBuffer()
end
end

# Issue #57103: This test does not work with MMTk because of fastpath
# allocation which never calls the allocation profiler.
# TODO: We should port these observability tools (e.g. allocation
# profiler and heap snapshot) to MMTk
@static if Base.USING_STOCK_GC
@testset "alloc profiler doesn't segfault" begin
res = Allocs.@profile sample_rate=1.0 begin
# test the allocations during compilation
Expand Down Expand Up @@ -73,14 +78,8 @@ end
@test length(first_alloc.stacktrace) > 0
@test length(string(first_alloc.type)) > 0

# Issue #57103: This test does not work with MMTk because of fastpath
# allocation which never calls the allocation profiler.
# TODO: We should port these observability tools (e.g. allocation
# profiler and heap snapshot) to MMTk
@static if Base.USING_STOCK_GC
@testset for type in (Task, Vector{Float64},)
@test length(filter(a->a.type <: type, profile.allocs)) >= NUM_TASKS
end
@testset for type in (Task, Vector{Float64},)
@test length(filter(a->a.type <: type, profile.allocs)) >= NUM_TASKS
end

# TODO: it would be nice to assert that these tasks
Expand Down Expand Up @@ -149,8 +148,6 @@ end
@test length([a for a in prof.allocs if a.type == String]) >= 1
end

# FIXME: Issue #57103 disabling test for MMTk.
@static if Base.USING_STOCK_GC
@testset "alloc profiler catches allocs from codegen" begin
@eval begin
struct MyType x::Int; y::Int end
Expand All @@ -170,7 +167,6 @@ end
@test length(prof.allocs) >= 1
@test length([a for a in prof.allocs if a.type == MyType]) >= 1
end
end

@testset "alloc profiler catches allocs from buffer resize" begin
f(a) = for _ in 1:100; push!(a, 1); end
Expand All @@ -187,3 +183,4 @@ end
@test length([a for a in prof.allocs if a.type === Allocs.BufferType]) == 1
@test length([a for a in prof.allocs if a.type === Memory{Int}]) >= 2
end
end