Repository navigation
compile error ,target=arm7 #3224
Description
Activity
- addedbuildIssues and PRs related to Node.js builds or CI infrastructure.Issues and PRs related to Node.js builds or CI infrastructure.
on Oct 6, 2015 - addedarmIssues and PRs related to the ARM architecture.Issues and PRs related to the ARM architecture.
on Oct 6, 2015 Can you show how you're configuring and building (specifically what commands)? Additionally, are you cross-compiling or compiling on-device?
I used script on this post: https://gist.github.com/Gioyik/7895192
And I'm cross-compiling on linux pc.It looks like you're hitting a compiler bug, not much we can do about that. See if you can upgrade to g++ 4.9 or 5.1 or try using clang++.
Thank you for your comment.
gcc 4.8.2 resolves the error .
I guess early 4.8 gcc version might have the problemI compiled successfully, but when I download cross-compiled node* to arm board and execute it, I've got error
$ ./node Illegal instruction $Does
node --noenable_vfp3work? If so, you may need to configure the FPU. A patch for that landed just yesterday, commit 17665af.Same situation of Illegal Instruction here. Tried with --noenable_vfp3. Any ideas what else to try? My SoC is a Cortex-A9 (Broadcom 4708) without a FPU. Here is the backtrace.
(gdb) run The program being debugged has been started already. Start it from the beginning? (y or n) y Starting program: /tmp/mnt/sandisk/entware.arm/local/node-v4.2.1/bin/node "--noenable_vfp3" warning: File "/tmp/mnt/sandisk/entware.arm/lib/libthread_db-1.0.so" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load". warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available. [New LWP 4707] [New LWP 4708] [New LWP 4709] [New LWP 4710] Program received signal SIGILL, Illegal instruction. 0x55e1e284 in ?? () (gdb) bt #0 0x55e1e284 in ?? () #1 0x003addb0 in v8::internal::Execution::Call(v8::internal::Isolate*, v8::internal::Handle<v8::internal::Object>, v8::internal::Handle<v8::internal::Object>, int, v8::internal::Handle<v8::internal::Object>*, bool) () #2 0x0026a214 in v8::internal::Genesis::CompileNative(v8::internal::Isolate*, v8::internal::Vector<char const>, v8::internal::Handle<v8::internal::String>, int, v8::internal::Handle<v8::internal::Object>*) () #3 0x0026ee00 in v8::internal::Genesis::CompileBuiltin(v8::internal::Isolate*, int) () #4 0x0027259c in v8::internal::Genesis::InstallNatives() () #5 0x002744d4 in v8::internal::Genesis::Genesis(v8::internal::Isolate*, v8::internal::MaybeHandle<v8::internal::JSGlobalProxy>, v8::Local<v8::ObjectTemplate>, v8::ExtensionConfiguration*) () #6 0x002748f0 in v8::internal::Bootstrapper::CreateEnvironment(v8::internal::MaybeHandle<v8::internal::JSGlobalProxy>, v8::Local<v8::ObjectTemplate>, v8::ExtensionConfiguration*) () #7 0x002426c8 in v8::Context::New(v8::Isolate*, v8::ExtensionConfiguration*, v8::Local<v8::ObjectTemplate>, v8::Local<v8::Value>) () #8 0x0072c7c4 in node::Start(int, char**) () #9 0x402681bc in __libc_start_main () from /opt/lib/libc.so.6 #10 0x00213634 in _start () Backtrace stopped: previous frame identical to this frame (corrupt stack?)What does
disassemble $pc,$pc+16print?PS: I don't think node.js and V8 support nofpu mode as such but I would expect the kernel to emulate floating point instructions.
Here you're (thanks for the speedy response btw:)
(gdb) disassemble $pc,$pc+16 Dump of assembler code from 0x3cf1e284 to 0x3cf1e294: => 0x3cf1e284: vpush {d8-d15} 0x3cf1e288: mov r12, #0 0x3cf1e28c: vmov d14, r12, r12 0x3cf1e290: vmrs r4, fpscr End of assembler dump.My kernel perhaps doesn't have FPU emulation compiled in. I'll need to check. I compiled node.js+v8 with -mfloat-abi=soft. I thought FPU emulation handled by c/c++ libraries without kernel involvement?
Right, it looks like emulation is indeed disabled.
I compiled node.js+v8 with -mfloat-abi=soft. I thought FPU emulation handled by c/c++ libraries without kernel involvement?
For C and C++ code, yes. V8 is a JIT compiler however, it generates machine code at run-time, and I'm almost positive it doesn't support FPU-less mode.
Closing due to inactivity.
I'm trying to compile nodejs v4.1.0 with gcc version 4.8 for arm v7 platform. but I've got an error:
V8_ALIGNAS is defined in deps/v8/include/v8config.h