package/ripgrep: bump to version 13.0.0
PATCH 1/1 package/ripgrep: bump to version 13.0.0
From: Sam Voss <[email protected]>
Also adds patch to make the jemalloc feature optional on musl, due to toolchains not being supported by upstream project.
--- ...llocator-behind-a-cargo-feature-flag.patch | 131 ++++++++++++++++++ package/ripgrep/ripgrep.hash | 4 +- package/ripgrep/ripgrep.mk | 2 +- 3 files changed, 134 insertions(+), 3 deletions(-) create mode 100644 package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +131 -0
@@ -0,0 +1,131 @@ +From 68c2a4d7a5d9b46f65121958fdb12d5270bfd1b6 Mon Sep 17 00:00:00 2001 +From: Jonathan Stites <[email protected]> +Date: Wed, 6 May 2020 12:55:35 +0000 +Subject: [PATCH] puts jemalloc allocator behind a cargo feature flag + +Retrieved from: https://github.com/BurntSushi/ripgrep/pull/1569 + +Moves jemalloc behind a feature for musl builds, where it is not +supported by the upstream project, so ripgrep will fail to build. + +Signed-off-by: Sam Voss <[email protected]> +--- + .github/workflows/ci.yml | 6 ++++++ + .github/workflows/release.yml | 8 +++++++- + Cargo.toml | 8 +++++++- + README.md | 9 +++++++++ + crates/core/main.rs | 8 ++++++-- + 5 files changed, 35 insertions(+), 4 deletions(-) + +diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml +index ab154ec..aa567d9 100644 +--- a/.github/workflows/ci.yml ++++ b/.github/workflows/ci.yml +@@ -149,6 +149,12 @@ jobs: + if: matrix.target != '' + run: ${{ env.CARGO }} test --verbose --workspace ${{ env.TARGET_FLAGS }} + ++ - name: Run tests with jemalloc (Musl) ++ # We only use the jemalloc allocator when building with musl. ++ # The system allocator is good enough for other platforms. ++ if: matrix.os == 'nightly-musl' ++ run: ${{ env.CARGO }} test --verbose --all --features jemalloc ${{ env.TARGET_FLAGS }} ++ + - name: Test for existence of build artifacts (Windows) + if: matrix.os == 'windows-2019' + shell: bash +diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml +index 7cfb6a4..ad6b82d 100644 +--- a/.github/workflows/release.yml ++++ b/.github/workflows/release.yml +@@ -133,7 +133,13 @@ jobs: + echo "target flag is: ${{ env.TARGET_FLAGS }}" + echo "target dir is: ${{ env.TARGET_DIR }}" + +- - name: Build release binary ++ - name: Build release binary (linux) ++ if: matrix.build == 'linux' ++ # Use jemalloc allocator for much better performance over the musl default allocator ++ run: ${{ env.CARGO }} build --verbose --release --features "pcre2 jemalloc" ${{ env.TARGET_FLAGS }} ++ ++ - name: Build release binary (non-linux) ++ if: matrix.build != 'linux' + run: ${{ env.CARGO }} build --verbose --release --features pcre2 ${{ env.TARGET_FLAGS }} + + - name: Strip release binary (linux and macos) +diff --git a/Cargo.toml b/Cargo.toml +index fb78fcb..0d34b1e 100644 +--- a/Cargo.toml ++++ b/Cargo.toml +@@ -56,8 +56,9 @@ version = "2.33.0" + default-features = false + features = ["suggestions"] + +-[target.'cfg(all(target_env = "musl", target_pointer_width = "64"))'.dependencies.jemallocator] ++[dependencies.jemallocator] + version = "0.3.0" ++optional = true + + [build-dependencies] + lazy_static = "1.1.0" +@@ -75,6 +76,11 @@ walkdir = "2" + [features] + simd-accel = ["grep/simd-accel"] + pcre2 = ["grep/pcre2"] ++# The jemalloc allocator is used for improved ++# performance on x86 musl builds. ++# Cargo does not yet support platform-specific features ++# https://github.com/rust-lang/cargo/issues/1197 ++jemalloc = ["jemallocator"] + + [profile.release] + debug = 1 +diff --git a/README.md b/README.md +index 46938bc..9917b29 100644 +--- a/README.md ++++ b/README.md +@@ -406,6 +406,15 @@ build a static executable with MUSL and with PCRE2, then you will need to have + `musl-gcc` installed, which might be in a separate package from the actual + MUSL library, depending on your Linux distribution. + ++When building with the MUSL target on Linux, it is recommended to use the ++jemalloc allocator for performance: ++ ++``` ++$ rustup target add x86_64-unknown-linux-musl ++$ cargo build --release --target x86_64-unknown-linux-musl --features jemalloc ++``` ++ ++ + + ### Running tests + +diff --git a/crates/core/main.rs b/crates/core/main.rs +index 47385de..c9dae5a 100644 +--- a/crates/core/main.rs ++++ b/crates/core/main.rs +@@ -31,7 +31,7 @@ mod subject; + // have the fastest version of everything. Its goal is to be small and amenable + // to static compilation.) Even though ripgrep isn't particularly allocation + // heavy, musl's allocator appears to slow down ripgrep quite a bit. Therefore, +-// when building with musl, we use jemalloc. ++// we expose a feature for using jemalloc when building with musl. + // + // We don't unconditionally use jemalloc because it can be nice to use the + // system's default allocator by default. Moreover, jemalloc seems to increase +@@ -39,7 +39,11 @@ mod subject; + // + // Moreover, we only do this on 64-bit systems since jemalloc doesn't support + // i686. +-#[cfg(all(target_env = "musl", target_pointer_width = "64"))] ++#[cfg(all( ++ target_env = "musl", ++ target_pointer_width = "64", ++ feature = "jemalloc" ++))] + #[global_allocator] + static ALLOC: jemallocator::Jemalloc = jemallocator::Jemalloc; + +-- +2.32.0 +
package/ripgrep/ripgrep.hash +2 -2
@@ -1,3 +1,3 @@ # Locally calculated -sha256 7035379fce0c1e32552e8ee528b92c3d01b8d3935ea31d26c51a73287be74bb3 ripgrep-0.8.1.tar.gz -sha256 0f96a83840e146e43c0ec96a22ec1f392e0680e6c1226e6f3ba87e0740af850f LICENSE-MIT +sha256 0fb17aaf285b3eee8ddab17b833af1e190d73de317ff9648751ab0660d763ed2 ripgrep-13.0.0.tar.gz +sha256 0f96a83840e146e43c0ec96a22ec1f392e0680e6c1226e6f3ba87e0740af850f LICENSE-MIT
package/ripgrep/ripgrep.mk +1 -1
@@ -4,7 +4,7 @@ # ################################################################################ -RIPGREP_VERSION = 0.8.1 +RIPGREP_VERSION = 13.0.0 RIPGREP_SITE = $(call github,burntsushi,ripgrep,$(RIPGREP_VERSION)) RIPGREP_LICENSE = MIT RIPGREP_LICENSE_FILES = LICENSE-MIT
Signature · 6 lines
2.32.0 _______________________________________________ buildroot mailing list [email protected] http://lists.busybox.net/mailman/listinfo/buildroot
Thomas Petazzoni
AppliedQuoted 5 lines · On Sat, 14 Aug 2021 14:51:43 -0500 [email protected] wrote:
From: Sam Voss <[email protected]>
Also adds patch to make the jemalloc feature optional on musl, due to toolchains not being supported by upstream project.
Quoted 7 lines
Signed-off-by Sam Voss <[email protected]>--- ...llocator-behind-a-cargo-feature-flag.patch | 131 ++++++++++++++++++ package/ripgrep/ripgrep.hash | 4 +- package/ripgrep/ripgrep.mk | 2 +- 3 files changed, 134 insertions(+), 3 deletions(-) create mode 100644 package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Applied to next, thanks.
Thomas
Signature · 7 lines
Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com _______________________________________________ buildroot mailing list [email protected] http://lists.busybox.net/mailman/listinfo/buildroot
Quoted 5 lines · On Sat, Aug 14, 2021 at 1:52 PM <[email protected]> wrote:
From: Sam Voss <[email protected]>
Also adds patch to make the jemalloc feature optional on musl, due to toolchains not being supported by upstream project.
Which toolchains are not supported here specifically?
Quoted 130 lines
Signed-off-by Sam Voss <[email protected]>--- ...llocator-behind-a-cargo-feature-flag.patch | 131 ++++++++++++++++++ package/ripgrep/ripgrep.hash | 4 +- package/ripgrep/ripgrep.mk | 2 +- 3 files changed, 134 insertions(+), 3 deletions(-) create mode 100644 package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patchpackage/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +115
-0@@ -0,0 +1,131 @@ +From 68c2a4d7a5d9b46f65121958fdb12d5270bfd1b6 Mon Sep 17 00:00:00 2001 +From: Jonathan Stites <[email protected]> +Date: Wed, 6 May 2020 12:55:35 +0000 +Subject: [PATCH] puts jemalloc allocator behind a cargo feature flag + +Retrieved from: https://github.com/BurntSushi/ripgrep/pull/1569 + +Moves jemalloc behind a feature for musl builds, where it is not +supported by the upstream project, so ripgrep will fail to build. + +Signed-off-by: Sam Voss <[email protected]> +--- + .github/workflows/ci.yml | 6 ++++++ + .github/workflows/release.yml | 8 +++++++- + Cargo.toml | 8 +++++++- + README.md | 9 +++++++++ + crates/core/main.rs | 8 ++++++-- + 5 files changed, 35 insertions(+), 4 deletions(-) + +diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml +index ab154ec..aa567d9 100644 +--- a/.github/workflows/ci.yml ++++ b/.github/workflows/ci.yml +@@ -149,6 +149,12 @@ jobs: + if: matrix.target != '' + run: ${{ env.CARGO }} test --verbose --workspace ${{ env.TARGET_FLAGS }} + ++ - name: Run tests with jemalloc (Musl) ++ # We only use the jemalloc allocator when building with musl. ++ # The system allocator is good enough for other platforms. ++ if: matrix.os == 'nightly-musl' ++ run: ${{ env.CARGO }} test --verbose --all --features jemalloc ${{ env.TARGET_FLAGS }} ++ + - name: Test for existence of build artifacts (Windows) + if: matrix.os == 'windows-2019' + shell: bash +diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml +index 7cfb6a4..ad6b82d 100644 +--- a/.github/workflows/release.yml ++++ b/.github/workflows/release.yml +@@ -133,7 +133,13 @@ jobs: + echo "target flag is: ${{ env.TARGET_FLAGS }}" + echo "target dir is: ${{ env.TARGET_DIR }}" + +- - name: Build release binary ++ - name: Build release binary (linux) ++ if: matrix.build == 'linux' ++ # Use jemalloc allocator for much better performance over the musl default allocator ++ run: ${{ env.CARGO }} build --verbose --release --features "pcre2 jemalloc" ${{ env.TARGET_FLAGS }} ++ ++ - name: Build release binary (non-linux) ++ if: matrix.build != 'linux' + run: ${{ env.CARGO }} build --verbose --release --features pcre2 ${{ env.TARGET_FLAGS }} + + - name: Strip release binary (linux and macos) +diff --git a/Cargo.toml b/Cargo.toml +index fb78fcb..0d34b1e 100644 +--- a/Cargo.toml ++++ b/Cargo.toml +@@ -56,8 +56,9 @@ version = "2.33.0" + default-features = false + features = ["suggestions"] + +-[target.'cfg(all(target_env = "musl", target_pointer_width = "64"))'.dependencies.jemallocator] ++[dependencies.jemallocator] + version = "0.3.0" ++optional = true + + [build-dependencies] + lazy_static = "1.1.0" +@@ -75,6 +76,11 @@ walkdir = "2" + [features] + simd-accel = ["grep/simd-accel"] + pcre2 = ["grep/pcre2"] ++# The jemalloc allocator is used for improved ++# performance on x86 musl builds. ++# Cargo does not yet support platform-specific features ++# https://github.com/rust-lang/cargo/issues/1197 ++jemalloc = ["jemallocator"] + + [profile.release] + debug = 1 +diff --git a/README.md b/README.md +index 46938bc..9917b29 100644 +--- a/README.md ++++ b/README.md +@@ -406,6 +406,15 @@ build a static executable with MUSL and with PCRE2, then you will need to have + `musl-gcc` installed, which might be in a separate package from the actual + MUSL library, depending on your Linux distribution. + ++When building with the MUSL target on Linux, it is recommended to use the ++jemalloc allocator for performance: ++ ++``` ++$ rustup target add x86_64-unknown-linux-musl ++$ cargo build --release --target x86_64-unknown-linux-musl --features jemalloc ++``` ++ ++ + + ### Running tests + +diff --git a/crates/core/main.rs b/crates/core/main.rs +index 47385de..c9dae5a 100644 +--- a/crates/core/main.rs ++++ b/crates/core/main.rs +@@ -31,7 +31,7 @@ mod subject; + // have the fastest version of everything. Its goal is to be small and amenable + // to static compilation.) Even though ripgrep isn't particularly allocation + // heavy, musl's allocator appears to slow down ripgrep quite a bit. Therefore, +-// when building with musl, we use jemalloc. ++// we expose a feature for using jemalloc when building with musl. + // + // We don't unconditionally use jemalloc because it can be nice to use the + // system's default allocator by default. Moreover, jemalloc seems to increase
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch line 125
Quoted 10 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +10
-0+@@ -39,7 +39,11 @@ mod subject; + // + // Moreover, we only do this on 64-bit systems since jemalloc doesn't support + // i686. +-#[cfg(all(target_env = "musl", target_pointer_width = "64"))] ++#[cfg(all( ++ target_env = "musl", ++ target_pointer_width = "64", ++ feature = "jemalloc" ++))]
Might make more sense to explicitly specify known working architectures using:
https://doc.rust-lang.org/reference/conditional-compilation.html#target_arch
Quoted 32 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +6
-0+ #[global_allocator] + static ALLOC: jemallocator::Jemalloc = jemallocator::Jemalloc; + +-- +2.32.0 +package/ripgrep/ripgrep.hash +2
-2@@ -1,3 +1,3 @@ # Locally calculated -sha256 7035379fce0c1e32552e8ee528b92c3d01b8d3935ea31d26c51a73287be74bb3 ripgrep-0.8.1.tar.gz -sha256 0f96a83840e146e43c0ec96a22ec1f392e0680e6c1226e6f3ba87e0740af850f LICENSE-MIT +sha256 0fb17aaf285b3eee8ddab17b833af1e190d73de317ff9648751ab0660d763ed2 ripgrep-13.0.0.tar.gz +sha256 0f96a83840e146e43c0ec96a22ec1f392e0680e6c1226e6f3ba87e0740af850f LICENSE-MITpackage/ripgrep/ripgrep.mk +1
-2@@ -4,7 +4,7 @@ # ################################################################################ -RIPGREP_VERSION = 0.8.1 +RIPGREP_VERSION = 13.0.0 RIPGREP_SITE = $(call github,burntsushi,ripgrep,$(RIPGREP_VERSION)) RIPGREP_LICENSE = MIT RIPGREP_LICENSE_FILES = LICENSE-MIT --2.32.0
Quoted 4 lines
_______________________________________________
buildroot mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/buildroot
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Hi James,
Quoted 9 lines · James Hilliard
Quoted 5 lines · On Sat, Aug 14, 2021 at 1:52 PM <[email protected]> wrote:
From: Sam Voss <[email protected]>
Also adds patch to make the jemalloc feature optional on musl, due to toolchains not being supported by upstream project.
Which toolchains are not supported here specifically?
I could have made this more clear in the original thread, although just incase it came across confusing the "upstream project" that doesn't support it is jemallocator, and not ripgrep.
The project specifically calls out their mapping of fully supported toolchains:
https://github.com/gnzlbg/jemallocator
I discovered this when running the default set of test-pkg targets, and the bootlin-x86-64-musl failed.
After digging into the issue a bit, it seems like this could be an issue for more rust projects which use jemalloc on musl for improved allocation performance, however I have not investigated any further.
Quoted 9 lines
Quoted 9 lines
Signed-off-by Sam Voss <[email protected]>--- ...llocator-behind-a-cargo-feature-flag.patch | 131 ++++++++++++++++++ package/ripgrep/ripgrep.hash | 4 +- package/ripgrep/ripgrep.mk | 2 +- 3 files changed, 134 insertions(+), 3 deletions(-) create mode 100644
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 2 lines
Quoted 2 lines
diff --git
a/package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch b/package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 4 lines
Quoted 4 lines
new file mode 100644
index 0000000000..e2ba68f389
---/dev/null
+++
b/package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 19 lines
Quoted 19 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +18
-0@@ -0,0 +1,131 @@ +From 68c2a4d7a5d9b46f65121958fdb12d5270bfd1b6 Mon Sep 17 00:00:00 2001 +From: Jonathan Stites <[email protected]> +Date: Wed, 6 May 2020 12:55:35 +0000 +Subject: [PATCH] puts jemalloc allocator behind a cargo feature flag + +Retrieved from: https://github.com/BurntSushi/ripgrep/pull/1569 + +Moves jemalloc behind a feature for musl builds, where it is not +supported by the upstream project, so ripgrep will fail to build. + +Signed-off-by: Sam Voss <[email protected]> +--- + .github/workflows/ci.yml | 6 ++++++ + .github/workflows/release.yml | 8 +++++++- + Cargo.toml | 8 +++++++- + README.md | 9 +++++++++ + crates/core/main.rs | 8 ++++++-- + 5 files changed, 35 insertions(+), 4 deletions(-)
Quoted 8 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 8 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +8
-0+ +diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml +index ab154ec..aa567d9 100644 +--- a/.github/workflows/ci.yml ++++ b/.github/workflows/ci.yml +@@ -149,6 +149,12 @@ jobs: + if: matrix.target != '' + run: ${{ env.CARGO }} test --verbose --workspace ${{
env.TARGET_FLAGS }}
Quoted 6 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 6 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +6
-0+ ++ - name: Run tests with jemalloc (Musl) ++ # We only use the jemalloc allocator when building with musl. ++ # The system allocator is good enough for other platforms. ++ if: matrix.os == 'nightly-musl' ++ run: ${{ env.CARGO }} test --verbose --all --features jemalloc
${{ env.TARGET_FLAGS }}
Quoted 5 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 5 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +5
-0++ + - name: Test for existence of build artifacts (Windows) + if: matrix.os == 'windows-2019' + shell: bash +diff --git a/.github/workflows/release.yml
b/.github/workflows/release.yml
Quoted 11 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 11 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +11
-0+index 7cfb6a4..ad6b82d 100644 +--- a/.github/workflows/release.yml ++++ b/.github/workflows/release.yml +@@ -133,7 +133,13 @@ jobs: + echo "target flag is: ${{ env.TARGET_FLAGS }}" + echo "target dir is: ${{ env.TARGET_DIR }}" + +- - name: Build release binary ++ - name: Build release binary (linux) ++ if: matrix.build == 'linux' ++ # Use jemalloc allocator for much better performance over the
musl default allocator
Quoted 1 line
Review line 49
Quoted 1 line
(quoted diff) +1
-0++ run: ${{ env.CARGO }} build --verbose --release --features
"pcre2 jemalloc" ${{ env.TARGET_FLAGS }}
Quoted 4 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 4 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +4
-0++ ++ - name: Build release binary (non-linux) ++ if: matrix.build != 'linux' + run: ${{ env.CARGO }} build --verbose --release --features
pcre2 ${{ env.TARGET_FLAGS }}
Quoted 11 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 11 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +11
-0+ + - name: Strip release binary (linux and macos) +diff --git a/Cargo.toml b/Cargo.toml +index fb78fcb..0d34b1e 100644 +--- a/Cargo.toml ++++ b/Cargo.toml +@@ -56,8 +56,9 @@ version = "2.33.0" + default-features = false + features = ["suggestions"] + +-[target.'cfg(all(target_env = "musl", target_pointer_width =
"64"))'.dependencies.jemallocator]
Quoted 15 lines
Quoted 15 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +15
-0++[dependencies.jemallocator] + version = "0.3.0" ++optional = true + + [build-dependencies] + lazy_static = "1.1.0" +@@ -75,6 +76,11 @@ walkdir = "2" + [features] + simd-accel = ["grep/simd-accel"] + pcre2 = ["grep/pcre2"] ++# The jemalloc allocator is used for improved ++# performance on x86 musl builds. ++# Cargo does not yet support platform-specific features ++# https://github.com/rust-lang/cargo/issues/1197 ++jemalloc = ["jemallocator"]
Quoted 8 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 8 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +8
-0+ + [profile.release] + debug = 1 +diff --git a/README.md b/README.md +index 46938bc..9917b29 100644 +--- a/README.md ++++ b/README.md +@@ -406,6 +406,15 @@ build a static executable with MUSL and with
PCRE2, then you will need to have
Quoted 1 line
Review line 88
Quoted 1 line
(quoted diff) +1
-0+ `musl-gcc` installed, which might be in a separate package from the
actual
Quoted 3 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 3 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +3
-0+ MUSL library, depending on your Linux distribution. + ++When building with the MUSL target on Linux, it is recommended to use
the
Quoted 5 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 5 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +5
-0++jemalloc allocator for performance: ++ ++``` ++$ rustup target add x86_64-unknown-linux-musl ++$ cargo build --release --target x86_64-unknown-linux-musl --features
jemalloc
Quoted 4 lines
Quoted 4 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +4
-0++``` ++ ++ +
Quoted 8 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 8 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +8
-0+ ### Running tests + +diff --git a/crates/core/main.rs b/crates/core/main.rs +index 47385de..c9dae5a 100644 +--- a/crates/core/main.rs ++++ b/crates/core/main.rs +@@ -31,7 +31,7 @@ mod subject; + // have the fastest version of everything. Its goal is to be small
and amenable
Quoted 1 line
Review line 109
Quoted 1 line
(quoted diff) +1
-0+ // to static compilation.) Even though ripgrep isn't particularly
allocation
Quoted 1 line
Review line 110
Quoted 1 line
(quoted diff) +1
-0+ // heavy, musl's allocator appears to slow down ripgrep quite a bit.
Therefore,
Quoted 4 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 4 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +4
-0+-// when building with musl, we use jemalloc. ++// we expose a feature for using jemalloc when building with musl. + // + // We don't unconditionally use jemalloc because it can be nice to
use the
Quoted 1 line
Review line 115
Quoted 1 line
(quoted diff) +1
-0+ // system's default allocator by default. Moreover, jemalloc seems to
increase
Quoted 3 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch
Quoted 3 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +3
-0+@@ -39,7 +39,11 @@ mod subject; + // + // Moreover, we only do this on 64-bit systems since jemalloc doesn't
support
Quoted 9 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch line 125
Quoted 7 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +7
-0+ // i686. +-#[cfg(all(target_env = "musl", target_pointer_width = "64"))] ++#[cfg(all( ++ target_env = "musl", ++ target_pointer_width = "64", ++ feature = "jemalloc" ++))]Might make more sense to explicitly specify known working architectures
using:
Quoted 1 line
https://doc.rust-lang.org/reference/conditional-compilation.html#target_arch
Quoted 14 lines
Quoted 12 lines
package/ripgrep/0001-puts-jemalloc-allocator-behind-a-cargo-feature-flag.patch new file +6
-0+ #[global_allocator] + static ALLOC: jemallocator::Jemalloc = jemallocator::Jemalloc; + +-- +2.32.0 +package/ripgrep/ripgrep.hash +0
-0package/ripgrep/ripgrep.hash line 2
Quoted 2 lines
package/ripgrep/ripgrep.hash +0
-1@@ -1,3 +1,3 @@ # Locally calculated -sha256
7035379fce0c1e32552e8ee528b92c3d01b8d3935ea31d26c51a73287be74bb3 ripgrep-0.8.1.tar.gz
Quoted 1 line
package/ripgrep/ripgrep.hash line 3
Quoted 1 line
package/ripgrep/ripgrep.hash +0
-1-sha256
0f96a83840e146e43c0ec96a22ec1f392e0680e6c1226e6f3ba87e0740af850f LICENSE-MIT
Quoted 1 line
package/ripgrep/ripgrep.hash line 2
Quoted 1 line
package/ripgrep/ripgrep.hash +1
-0+sha256
0fb17aaf285b3eee8ddab17b833af1e190d73de317ff9648751ab0660d763ed2 ripgrep-13.0.0.tar.gz
Quoted 1 line
package/ripgrep/ripgrep.hash line 3
Quoted 1 line
package/ripgrep/ripgrep.hash +1
-0+sha256
0f96a83840e146e43c0ec96a22ec1f392e0680e6c1226e6f3ba87e0740af850f LICENSE-MIT
Quoted 7 lines
package/ripgrep/ripgrep.mk line 5
Quoted 7 lines
package/ripgrep/ripgrep.mk +0
-0@@ -4,7 +4,7 @@ #
################################################################################
Quoted 9 lines
Quoted 9 lines
package/ripgrep/ripgrep.mk +1
-2-RIPGREP_VERSION = 0.8.1 +RIPGREP_VERSION = 13.0.0 RIPGREP_SITE = $(call github,burntsushi,ripgrep,$(RIPGREP_VERSION)) RIPGREP_LICENSE = MIT RIPGREP_LICENSE_FILES = LICENSE-MIT --2.32.0
Quoted 4 lines
Quoted 4 lines
_______________________________________________
buildroot mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/buildroot
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot