Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 05 Jun 2023 12:28:32 +0000
From:      bugzilla-noreply@freebsd.org
To:        ports-bugs@FreeBSD.org
Subject:   [Bug 271838] lang/v8: fails with kern.elf64.allow_wx=1 but elfctl -e +wxneeded doesn't help
Message-ID:  <bug-271838-7788@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D271838

            Bug ID: 271838
           Summary: lang/v8: fails with kern.elf64.allow_wx=3D1 but elfctl
                    -e +wxneeded doesn't help
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: sunpoet@FreeBSD.org
          Reporter: jbeich@FreeBSD.org
            Blocks: 252629
          Assignee: sunpoet@FreeBSD.org
             Flags: maintainer-feedback?(sunpoet@FreeBSD.org)

Ports with embedded v8 either don't build or don't run. Some like www/node*
(bug 261952) can be worked around via USES=3Delfctl.

$ sysctl kern.elf32.allow_wx=3D1
$ sysctl kern.elf64.allow_wx=3D1
$ pkg install v8

$ proccontrol -m wxmap v8_shell
V8 version 10.4.132.20 [sample shell]
> ^D

$ elfctl -e +wxneeded `which v8_shell`
$ v8_shell


#
# Fatal error in , line 0
# Check failed: 12 =3D=3D (* __error()).
#
#
#
#FailureMessage Object: 0x2f206175e170
=3D=3D=3D=3D C stack trace =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D

    0x2f2066df6053 <v8::base::debug::StackTrace::StackTrace()+0x13> at
/usr/local/lib/libv8_libbase.so
    0x2f2064e31cab <v8::platform::DefaultPlatform::GetStackTracePrinter()+0=
x3b>
at /usr/local/lib/libv8_libplatform.so
    0x2f2066de91a5 <V8_Fatal(char const*, ...)+0x145> at
/usr/local/lib/libv8_libbase.so
    0x2f2066df4a80 <v8::base::OS::SetPermissions(void*, unsigned long,
v8::base::OS::MemoryPermission)+0x50> at /usr/local/lib/libv8_libbase.so
    0x2f20636833a6
<v8::internal::MemoryAllocator::Unmapper::EnsureUnmappingCompleted()+0x566>=
 at
/usr/local/lib/libv8.so
    0x2f20636831c5
<v8::internal::MemoryAllocator::Unmapper::EnsureUnmappingCompleted()+0x385>=
 at
/usr/local/lib/libv8.so
    0x2f206368350d
<v8::internal::MemoryAllocator::Unmapper::EnsureUnmappingCompleted()+0x6cd>=
 at
/usr/local/lib/libv8.so
    0x2f2063683a12
<v8::internal::MemoryAllocator::AllocatePage(v8::internal::MemoryAllocator:=
:AllocationMode,
v8::internal::Space*, v8::internal::Executability)+0x102> at
/usr/local/lib/libv8.so
    0x2f2063695fac <v8::internal::PagedSpaceBase::Expand()+0x2c> at
/usr/local/lib/libv8.so
    0x2f2063697115 <v8::internal::PagedSpaceBase::RawRefillLabMain(int,
v8::internal::AllocationOrigin)+0x1a5> at /usr/local/lib/libv8.so
    0x2f2063696f61 <v8::internal::PagedSpaceBase::RefillLabMain(int,
v8::internal::AllocationOrigin)+0x21> at /usr/local/lib/libv8.so
    0x2f2063602e04
<v8::internal::HeapAllocator::AllocateRawWithLightRetrySlowPath(int,
v8::internal::AllocationType, v8::internal::AllocationOrigin,
v8::internal::AllocationAlignment)+0x214> at /usr/local/lib/libv8.so
    0x2f2063603e23
<v8::internal::HeapAllocator::AllocateRawWithRetryOrFailSlowPath(int,
v8::internal::AllocationType, v8::internal::AllocationOrigin,
v8::internal::AllocationAlignment)+0x33> at /usr/local/lib/libv8.so
    0x2f206399ba87
<v8::internal::Deserializer<v8::internal::Isolate>::PostProcessNewJSReceive=
r(v8::internal::Map,
v8::internal::Handle<v8::internal::JSReceiver>, v8::internal::JSReceiver,
v8::internal::InstanceType, v8::internal::SnapshotSpace)+0x5f7> at
/usr/local/lib/libv8.so
    0x2f20639986ae
<v8::internal::Deserializer<v8::internal::Isolate>::ReadObject(v8::internal=
::SnapshotSpace)+0x11e>
at /usr/local/lib/libv8.so
    0x2f206399a1f0
<v8::internal::Deserializer<v8::internal::Isolate>::ReadData(v8::internal::=
Handle<v8::internal::HeapObject>,
int, int)+0xd00> at /usr/local/lib/libv8.so
    0x2f206399941e
<v8::internal::Deserializer<v8::internal::Isolate>::VisitRootPointers(v8::i=
nternal::Root,
char const*, v8::internal::FullObjectSlot, v8::internal::FullObjectSlot)+0x=
3e>
at /usr/local/lib/libv8.so
    0x2f2063618d86 <v8::internal::Heap::InSpaceSlow(unsigned long,
v8::internal::AllocationSpace) const+0x276> at /usr/local/lib/libv8.so
    0x2f20639ac387
<v8::internal::WarmUpSnapshotDataBlobInternal(v8::StartupData, char
const*)+0x1d7> at /usr/local/lib/libv8.so
    0x2f20635a5255 <v8::internal::Isolate::Init(v8::internal::SnapshotData*,
v8::internal::SnapshotData*, v8::internal::SnapshotData*, bool)+0xf95> at
/usr/local/lib/libv8.so
    0x2f20635a56d9
<v8::internal::Isolate::InitWithSnapshot(v8::internal::SnapshotData*,
v8::internal::SnapshotData*, v8::internal::SnapshotData*, bool)+0x9> at
/usr/local/lib/libv8.so
    0x2f20639a9c84 <v8::internal::Checksum(v8::base::Vector<unsigned char
const>)+0x474> at /usr/local/lib/libv8.so
    0x2f2063486507 <v8::Isolate::Initialize(v8::Isolate*,
v8::Isolate::CreateParams const&)+0x1b7> at /usr/local/lib/libv8.so
    0x2f206348670d <v8::Isolate::New(v8::Isolate::CreateParams const&)+0x1d=
> at
/usr/local/lib/libv8.so
Trace/BPT trap


Referenced Bugs:

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D252629
[Bug 252629] Need infrastructure to set ELF feature note flags via elfctl
--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-271838-7788>