From 4cffad2f5848d9bfd89dba4d906fc0284c4d4f88 Mon Sep 17 00:00:00 2001 From: Owen Rafferty Date: Thu, 12 Dec 2024 17:32:30 -0600 Subject: [PATCH] mold: 2.35.0 --- extra/mold/checksums | 4 +- extra/mold/patches/amd64_only.patch | 72 +++++++++++++++-------------- extra/mold/sources | 2 +- extra/mold/version | 2 +- 4 files changed, 42 insertions(+), 38 deletions(-) diff --git a/extra/mold/checksums b/extra/mold/checksums index 5359c042..abf3d10a 100644 --- a/extra/mold/checksums +++ b/extra/mold/checksums @@ -1,2 +1,2 @@ -4acf3c19aefbf42d8455675f0d48a50c1413ed6217a46ef51992909834323dab69 -680c898ed54f13e995b72df4b56f0978bca8c6463a3e7d53f0799f10e5d7bedb1f +bd49d68dba54effc9a3c94a9884c1cc7a4538bf2967a10fdd0f2ccede38088cec5 +fd4aec2a4e57e7c055b20e4b224b5f77c5269962b4152c8030aed3e70d2802ea33 diff --git a/extra/mold/patches/amd64_only.patch b/extra/mold/patches/amd64_only.patch index 1004c04e..3df87ff1 100644 --- a/extra/mold/patches/amd64_only.patch +++ b/extra/mold/patches/amd64_only.patch @@ -1,59 +1,59 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index d6d1500..9e831f7 100644 +index aff8fc6..9790e28 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -304,12 +304,9 @@ include_directories(${CMAKE_CURRENT_BINARY_DIR}) +@@ -310,14 +310,9 @@ include_directories(${CMAKE_CURRENT_BINARY_DIR}) # compiler instances. This is hacky but greatly reduces compile time # on a multicore machine. list(APPEND MOLD_ELF_TARGETS -- X86_64 I386 ARM64 ARM32 RV32LE RV32BE RV64LE RV64BE PPC32 PPC64V1 PPC64V2 -- S390X SPARC64 M68K SH4 LOONGARCH32 LOONGARCH64) +- X86_64 I386 ARM64LE ARM64BE ARM32 RV32LE RV32BE RV64LE RV64BE PPC32 +- PPC64V1 PPC64V2 S390X SPARC64 M68K SH4LE SH4BE LOONGARCH32 LOONGARCH64) + X86_64) list(APPEND MOLD_ELF_TEMPLATE_FILES +- src/arch-arm64.cc - src/arch-loongarch.cc - src/arch-riscv.cc +- src/arch-sh4.cc src/cmdline.cc + src/filetype.cc src/gc-sections.cc - src/gdb-index.cc -@@ -376,16 +373,6 @@ target_sources(mold PRIVATE +@@ -385,14 +380,6 @@ target_sources(mold PRIVATE lib/perf.cc lib/random.cc lib/tar.cc - src/arch-arm32.cc -- src/arch-arm64.cc - src/arch-i386.cc - src/arch-m68k.cc - src/arch-ppc32.cc - src/arch-ppc64v1.cc - src/arch-ppc64v2.cc - src/arch-s390x.cc -- src/arch-sh4.cc - src/arch-sparc64.cc src/arch-x86-64.cc src/config.cc src/elf.cc diff --git a/src/main.cc b/src/main.cc -index ce94043..2373218 100644 +index 4674b1c..b1ca4cb 100644 --- a/src/main.cc +++ b/src/main.cc -@@ -361,11 +361,6 @@ int mold_main(int argc, char **argv) { +@@ -290,11 +290,6 @@ int mold_main(int argc, char **argv) { if (ctx.arg.emulation.empty()) ctx.arg.emulation = detect_machine_type(ctx, file_args); - // Redo if -m is not x86-64. - if constexpr (is_x86_64) -- if (ctx.arg.emulation != X86_64::target_name) +- if (ctx.arg.emulation != X86_64::name) - return redo_main(ctx, argc, argv); - Timer t_all(ctx, "all"); install_signal_handler(); diff --git a/src/mold.h b/src/mold.h -index 322a0ea..9058295 100644 +index ce74a26..079c0a8 100644 --- a/src/mold.h +++ b/src/mold.h -@@ -1563,7 +1563,6 @@ std::vector parse_nonpositional_args(Context &ctx); +@@ -1603,7 +1603,6 @@ std::vector parse_nonpositional_args(Context &ctx); // passes.cc // @@ -62,10 +62,10 @@ index 322a0ea..9058295 100644 template void apply_exclude_libs(Context &); template void create_synthetic_sections(Context &); diff --git a/src/passes.cc b/src/passes.cc -index 807bb2b..0ef86a1 100644 +index aeac428..078f43a 100644 --- a/src/passes.cc +++ b/src/passes.cc -@@ -14,48 +14,6 @@ +@@ -14,52 +14,6 @@ namespace mold { @@ -76,37 +76,41 @@ index 807bb2b..0ef86a1 100644 -int redo_main(Context &ctx, int argc, char **argv) { - std::string_view target = ctx.arg.emulation; - -- if (target == I386::target_name) +- if (target == I386::name) - return mold_main(argc, argv); -- if (target == ARM64::target_name) -- return mold_main(argc, argv); -- if (target == ARM32::target_name) +- if (target == ARM64LE::name) +- return mold_main(argc, argv); +- if (target == ARM64BE::name) +- return mold_main(argc, argv); +- if (target == ARM32::name) - return mold_main(argc, argv); -- if (target == RV64LE::target_name) +- if (target == RV64LE::name) - return mold_main(argc, argv); -- if (target == RV64BE::target_name) +- if (target == RV64BE::name) - return mold_main(argc, argv); -- if (target == RV32LE::target_name) +- if (target == RV32LE::name) - return mold_main(argc, argv); -- if (target == RV32BE::target_name) +- if (target == RV32BE::name) - return mold_main(argc, argv); -- if (target == PPC32::target_name) +- if (target == PPC32::name) - return mold_main(argc, argv); -- if (target == PPC64V1::target_name) +- if (target == PPC64V1::name) - return mold_main(argc, argv); -- if (target == PPC64V2::target_name) +- if (target == PPC64V2::name) - return mold_main(argc, argv); -- if (target == S390X::target_name) +- if (target == S390X::name) - return mold_main(argc, argv); -- if (target == SPARC64::target_name) +- if (target == SPARC64::name) - return mold_main(argc, argv); -- if (target == M68K::target_name) +- if (target == M68K::name) - return mold_main(argc, argv); -- if (target == SH4::target_name) -- return mold_main(argc, argv); -- if (target == LOONGARCH32::target_name) +- if (target == SH4LE::name) +- return mold_main(argc, argv); +- if (target == SH4BE::name) +- return mold_main(argc, argv); +- if (target == LOONGARCH32::name) - return mold_main(argc, argv); -- if (target == LOONGARCH64::target_name) +- if (target == LOONGARCH64::name) - return mold_main(argc, argv); - unreachable(); -} @@ -114,7 +118,7 @@ index 807bb2b..0ef86a1 100644 template void apply_exclude_libs(Context &ctx) { Timer t(ctx, "apply_exclude_libs"); -@@ -3210,7 +3168,6 @@ void show_stats(Context &ctx) { +@@ -3222,7 +3176,6 @@ void show_stats(Context &ctx) { using E = MOLD_TARGET; diff --git a/extra/mold/sources b/extra/mold/sources index 58dc28e1..d1582d32 100644 --- a/extra/mold/sources +++ b/extra/mold/sources @@ -1,2 +1,2 @@ -https://github.com/rui314/mold/archive/v2.34.1.tar.gz +https://github.com/rui314/mold/archive/v2.35.0.tar.gz patches/amd64_only.patch diff --git a/extra/mold/version b/extra/mold/version index 8f2581bf..60c41c0b 100644 --- a/extra/mold/version +++ b/extra/mold/version @@ -1 +1 @@ -2.34.1 1 +2.35.0 1