Skip to content

Building with pointer compression is broken #57650

Description

@avcribl

Version

20.18.0

Platform

Linux ip-10-8-28-166.us-west-2.compute.internal 4.18.0-553.el8_10.x86_64 #1 SMP Fri May 10 15:19:13 EDT 2024 x86_64 x86_64 x86_64 GNU/Linux

The same failure happens for the arm and Windows architectures as well.

Subsystem

No response

What steps will reproduce the bug?

  • ./configure --ninja --experimental-enable-pointer-compression
  • ninja -C out/Release

How often does it reproduce? Is there a required condition?

Always

What is the expected behavior? Why is that the expected behavior?

To build nodejs with pointer compression without any failure

What do you see instead?

Fatal error in , line 0

Check failed: GetProcessWideSandbox()->Contains(pointer).

#FailureMessage Object: 0xffffc3290550
----- Native stack trace -----

1: 0x10bb988 [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
2: 0x1e4e8c0 V8_Fatal(char const*, ...) [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
3: 0x1649424 v8::internal::Factory::NewJSTypedArray(v8::internal::ExternalArrayType, v8::internal::Handlev8::internal::JSArrayBuffer, unsigned long, unsigned long, bool) [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
4: 0x15591f8 v8::Float64Array::New(v8::Localv8::ArrayBuffer, unsigned long, unsigned long) [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
5: 0x1250920 node::AsyncHooks::AsyncHooks(v8::Isolate*, node::AsyncHooks::SerializeInfo const*) [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
6: 0x1264bb4 node::Environment::Environment(node::IsolateData*, v8::Isolate*, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > > const&, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > > const&, node::EnvSerializeInfo const*, node::EnvironmentFlags::Flags, node::ThreadId) [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
7: 0x11f8688 node::CreateEnvironment(node::IsolateData*, v8::Localv8::Context, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > > const&, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > > const&, node::EnvironmentFlags::Flags, node::ThreadId, std::unique_ptr<node::InspectorParentHandle, std::default_deletenode::InspectorParentHandle >) [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
8: 0x11f3fe8 [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
9: 0x11f4ff4 node::CommonEnvironmentSetup::CommonEnvironmentSetup(node::MultiIsolatePlatform*, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > >, node::EmbedderSnapshotData const, unsigned int, std::function<node::Environment* (node::CommonEnvironmentSetup const*)>, node::SnapshotConfig const*) [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
10: 0x11f55a8 node::CommonEnvironmentSetup::CreateForSnapshotting(node::MultiIsolatePlatform*, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > >, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > > const&, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > > const&, node::SnapshotConfig const&) [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
11: 0x10f5220 node::BuildSnapshotWithoutCodeCache(node::SnapshotData
, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > > const&, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > > const&, std::optional<std::basic_string_view<char, std::char_traits > >, node::SnapshotConfig const&) [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
12: 0x10f720c node::SnapshotBuilder::GenerateAsSource(char const*, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > > const&, std::vector<std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > > > const&, node::SnapshotConfig const&, bool) [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
13: 0xfff3bc BuildSnapshot(int, char**) [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
14: 0xffffa8f17de4 __libc_start_main [/lib64/libc.so.6]
15: 0xb9a990 [/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot]
/bin/sh: line 1: 87983 Trace/breakpoint trap "/js2bin/build/node-v20.18.0/out/Release/node_mksnapshot" "/js2bin/build/node-v20.18.0/out/Release/obj/gen/node_snapshot.cc"

Additional information

  • There is a test failure in node_test_fixture.cc that can be skipped.
  • The build with pointer compression is broken for v22.14.0 as well. It returns a segmentation fault error though.

Activity

  1. avcribl commented on Mar 27, 2025

    @avcribl
    ContributorAuthor

    @joyeecheung Is there any plan for fixing the build with pointer compression?

  2. joyeecheung commented on Mar 27, 2025

    @joyeecheung
    Member

    I think it's been broken for a while. There were some discussions in #55735 but I don't know the latest status. @jasnell

  3. avcribl commented on Apr 2, 2025

    @avcribl
    ContributorAuthor

    @jasnell I saw your comment about memory leak here #57114 (comment)
    I wonder if it's related to v8::IsolateGroup because I see a memory leak when the pointer compression is on for versions 20.16.0 and below.

  4. sapics commented on May 27, 2025

    @sapics
    Contributor

    I don't know if this is the right way to do it, but when I make disable the sandbox, the build succeeds and works find on my server.
    (I cherry-pick this commit sapics@17d7e84)

  5. avcribl commented on May 27, 2025

    @avcribl
    ContributorAuthor

    @sapics Yeah, it gets compiled, however, I noticed it causes a memory leak.

  6. github-actions commented on Apr 20, 2026

    @github-actions
    Contributor

    This issue has been marked as stale due to 210 days of inactivity.
    It will be automatically closed in 30 days if no further activity occurs. If this is still relevant, please leave a comment or update it to keep it open.

  7. added
    staleIssues and PRs marked stale due to inactivity and scheduled for automatic closure.
    on Apr 20, 2026
  8. github-actions commented on May 21, 2026

    @github-actions
    Contributor

    This issue has been automatically closed after 30 days of inactivity following its stale status (no activity for a total of 240 days).
    If this is still relevant, feel free to reopen it or leave a comment with additional details so we can continue the discussion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    staleIssues and PRs marked stale due to inactivity and scheduled for automatic closure.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions