diff --git a/srcpkgs/mold/patches/fix-arm-yield.patch b/srcpkgs/mold/patches/fix-arm-yield.patch new file mode 100644 index 00000000000..89cc4194d80 --- /dev/null +++ b/srcpkgs/mold/patches/fix-arm-yield.patch @@ -0,0 +1,18 @@ +Only use yield on ARM architectures that support it. Will be in next release. Taken from: +https://github.com/rui314/mold/commit/f0f61cc7ad482672a73d3bb4778430c65f01e237 +https://github.com/rui314/mold/commit/4510f4af81e65544fcd02826f253d3dc9e7fae9e +diff --git a/common/common.h b/common/common.h +index c9820877789..a9a52d6c5fb 100644 +--- a/common/common.h ++++ b/common/common.h +@@ -526,7 +526,9 @@ inline bool remove_prefix(std::string_view &s, std::string_view prefix) { + static inline void pause() { + #if defined(__x86_64__) + asm volatile("pause"); +-#elif defined(__arm__) || defined(__aarch64__) ++#elif defined(__aarch64__) ++ asm volatile("yield"); ++#elif defined(__ARM_ARCH_7A__) || defined(__ARM_ARCH_8A__) + asm volatile("yield"); + #endif + } diff --git a/srcpkgs/mold/template b/srcpkgs/mold/template index d898e1b1119..d20d757eab5 100644 --- a/srcpkgs/mold/template +++ b/srcpkgs/mold/template @@ -1,6 +1,6 @@ # Template file for 'mold' pkgname=mold -version=2.4.1 +version=2.31.0 revision=1 build_style=cmake configure_args="-DMOLD_USE_SYSTEM_MIMALLOC=ON -DMOLD_USE_SYSTEM_TBB=ON" @@ -14,7 +14,7 @@ license="MIT" homepage="https://github.com/rui314/mold" changelog="https://github.com/rui314/mold/releases" distfiles="https://github.com/rui314/mold/archive/refs/tags/v${version}.tar.gz" -checksum=c9853d007d6a1b4f3e36b7314346751f4cc91bc43c76e30db51709b53b44dd68 +checksum=3dc3af83a5d22a4b29971bfad17261851d426961c665480e2ca294e5c74aa1e5 post_install() { vlicense LICENSE