Unverified Commit fd9c524a authored by JJ Kasper's avatar JJ Kasper Committed by GitHub

Revert "Use turbo-tasks-malloc on all platforms" (#66884)

Reverting while we investigate further 

Reverts vercel/next.js#66815
parent 6ae9828c
This diff is collapsed.
......@@ -37,11 +37,11 @@ swc_core = { version = "0.93.4", features = [
testing = { version = "0.35.25" }
# Turbo crates
turbopack-binding = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-240614.1" }
turbopack-binding = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-240612.3" }
# [TODO]: need to refactor embed_directory! macro usages, as well as resolving turbo_tasks::function, macros..
turbo-tasks = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-240614.1" }
turbo-tasks = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-240612.3" }
# [TODO]: need to refactor embed_directory! macro usage in next-core
turbo-tasks-fs = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-240614.1" }
turbo-tasks-fs = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-240612.3" }
# General Deps
......
......@@ -35,6 +35,26 @@ __internal_dhat-heap = ["dhat"]
# effectively does nothing.
__internal_dhat-ad-hoc = ["dhat"]
# Making custom_allocator as default feature will break some targets (i.e aarch64-linux), controlling it with
# build-time cfg instead.
#
# [NOTE] this is a workaround to enable downstream features for the own pkgs, since
# cargo does not support per-target features enablement.
[target.'cfg(all(target_os = "linux", target_arch = "aarch64"))'.dependencies]
turbopack-binding = { workspace = true, features = ["__turbo_tasks_malloc"] }
[target.'cfg(all(target_os = "linux", not(any(target_arch = "aarch64", target_arch = "wasm32"))))'.dependencies]
turbopack-binding = { workspace = true, features = [
"__turbo_tasks_malloc",
"__turbo_tasks_malloc_custom_allocator",
] }
[target.'cfg(not(any(target_os = "linux", target_arch = "wasm32")))'.dependencies]
turbopack-binding = { workspace = true, features = [
"__turbo_tasks_malloc",
"__turbo_tasks_malloc_custom_allocator",
] }
# Enable specific tls features per-target.
[target.'cfg(all(target_os = "windows", target_arch = "aarch64"))'.dependencies]
next-core = { workspace = true, features = ["native-tls"] }
......@@ -88,8 +108,6 @@ turbopack-binding = { workspace = true, features = [
"__feature_mdx_rs",
"__turbo",
"__turbo_tasks",
"__turbo_tasks_malloc",
"__turbo_tasks_malloc_custom_allocator",
"__turbo_tasks_memory",
"__turbopack",
"__turbopack_ecmascript_hmr_protocol",
......@@ -103,7 +121,6 @@ turbopack-binding = { workspace = true, features = [
"__swc_core_binding_napi",
"__swc_core_serde",
"__feature_mdx_rs",
"__turbo_tasks_malloc",
] }
# wasi-only dependencies.
......
......@@ -68,7 +68,14 @@ pub mod util;
// Declare build-time information variables generated in build.rs
shadow_rs::shadow!(build);
#[cfg(not(any(feature = "__internal_dhat-heap", feature = "__internal_dhat-ad-hoc")))]
// don't use turbo malloc (`mimalloc`) on linux-musl-aarch64 because of the
// compile error
#[cfg(not(any(
all(target_os = "linux", target_env = "musl", target_arch = "aarch64"),
target_arch = "wasm32",
feature = "__internal_dhat-heap",
feature = "__internal_dhat-ad-hoc"
)))]
#[global_allocator]
static ALLOC: turbopack_binding::turbo::malloc::TurboMalloc =
turbopack_binding::turbo::malloc::TurboMalloc;
......
......@@ -206,7 +206,7 @@
"@types/ws": "8.2.0",
"@vercel/ncc": "0.34.0",
"@vercel/nft": "0.27.1",
"@vercel/turbopack-ecmascript-runtime": "https://gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-240614.1",
"@vercel/turbopack-ecmascript-runtime": "https://gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-240612.1",
"acorn": "8.11.3",
"amphtml-validator": "1.0.35",
"anser": "1.4.9",
......
......@@ -1108,8 +1108,8 @@ importers:
specifier: 0.27.1
version: 0.27.1
'@vercel/turbopack-ecmascript-runtime':
specifier: https://gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-240614.1
version: '@gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-240614.1'
specifier: https://gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-240612.1
version: '@gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-240612.1'
acorn:
specifier: 8.11.3
version: 8.11.3
......@@ -26558,8 +26558,8 @@ packages:
/zwitch@2.0.4:
resolution: {integrity: sha512-bXE4cR/kVZhKZX/RjPEflHaKVhUVl85noU3v6b8apfQEc1x4A+zBxjZ4lN8LqGd6WZ3dl98pY4o717VFmoPp+A==}
'@gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-240614.1':
resolution: {tarball: https://gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-240614.1}
'@gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-240612.1':
resolution: {tarball: https://gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-240612.1}
name: '@vercel/turbopack-ecmascript-runtime'
version: 0.0.0
dependencies:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment