Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

`node --help' crashes inside qemu-user in 17.2.0 #517

Closed
hexchain opened this issue Jan 3, 2022 · 4 comments
Closed

`node --help' crashes inside qemu-user in 17.2.0 #517

hexchain opened this issue Jan 3, 2022 · 4 comments
Assignees

Comments

@hexchain
Copy link

hexchain commented Jan 3, 2022

Nodejs crashes when executing node --help, probably after nodejs/node#40488.

Version:
qemu-user: 6.2.0
node: 17.2.0 (but bisected to that PR)

GDB stack trace doesn't seem very useful with QEMU_GDB:

>>> thr apply all bt

Thread 7 (Thread 1.129 (CPU#6 [running])):
#0  0x00000040066abc06 in __futex_abstimed_wait_common64 () from /mnt/rv64/usr/lib/libpthread.so.0
#1  0x00000040066a9128 in __new_sem_wait_slow64.constprop.0 () from /mnt/rv64/usr/lib/libpthread.so.0
#2  0x00000040040f1f70 in uv_sem_wait () from /mnt/rv64/usr/lib/libuv.so.1
Backtrace stopped: frame did not save the PC

Thread 6 (Thread 1.128 (CPU#5 [running])):
#0  0x00000040066abc06 in __futex_abstimed_wait_common64 () from /mnt/rv64/usr/lib/libpthread.so.0
#1  0x00000040066a7024 in pthread_cond_wait@@GLIBC_2.27 () from /mnt/rv64/usr/lib/libpthread.so.0
#2  0x00000040040f1f38 in uv_cond_wait () from /mnt/rv64/usr/lib/libuv.so.1
Backtrace stopped: frame did not save the PC

Thread 5 (Thread 1.127 (CPU#4 [running])):
#0  0x00000040066abc06 in __futex_abstimed_wait_common64 () from /mnt/rv64/usr/lib/libpthread.so.0
#1  0x00000040066a7024 in pthread_cond_wait@@GLIBC_2.27 () from /mnt/rv64/usr/lib/libpthread.so.0
#2  0x00000040040f1f38 in uv_cond_wait () from /mnt/rv64/usr/lib/libuv.so.1
Backtrace stopped: frame did not save the PC

Thread 4 (Thread 1.126 (CPU#3 [running])):
#0  0x00000040066abc06 in __futex_abstimed_wait_common64 () from /mnt/rv64/usr/lib/libpthread.so.0
#1  0x00000040066a7024 in pthread_cond_wait@@GLIBC_2.27 () from /mnt/rv64/usr/lib/libpthread.so.0
#2  0x00000040040f1f38 in uv_cond_wait () from /mnt/rv64/usr/lib/libuv.so.1
Backtrace stopped: frame did not save the PC

Thread 3 (Thread 1.125 (CPU#2 [running])):
#0  0x00000040066abc06 in __futex_abstimed_wait_common64 () from /mnt/rv64/usr/lib/libpthread.so.0
#1  0x00000040066a7024 in pthread_cond_wait@@GLIBC_2.27 () from /mnt/rv64/usr/lib/libpthread.so.0
#2  0x00000040040f1f38 in uv_cond_wait () from /mnt/rv64/usr/lib/libuv.so.1
Backtrace stopped: frame did not save the PC

Thread 2 (Thread 1.124 (CPU#1 [running])):
#0  0x000000400675b322 in epoll_pwait () from /mnt/rv64/usr/lib/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

Thread 1 (Thread 1.121 (CPU#0 [running])):
#0  0x00007f8e54046b54 in ?? ()

Instructions around $pc:

>>> x/40i 0x00007f8e54046b00
   0x7f8e54046b00:      bnez    a0,0x7f8e54046c4c
   0x7f8e54046b04:      addi    sp,sp,-56
   0x7f8e54046b08:      ld      t2,-40(s0)
   0x7f8e54046b0c:      ld      a0,-48(s0)
   0x7f8e54046b10:      sub     a6,a0,t2
   0x7f8e54046b14:      ld      a1,-56(s0)
   0x7f8e54046b18:      addi    a0,a6,-1
   0x7f8e54046b1c:      slli    t1,a1,0x0
   0x7f8e54046b20:      sub     a0,a0,t1
   0x7f8e54046b24:      sd      a0,-80(s0)
   0x7f8e54046b28:      lui     a5,0x3fc73
   0x7f8e54046b2c:      addi    a5,a5,-1534
   0x7f8e54046b30:      slli    a5,a5,0xb
   0x7f8e54046b34:      ori     a5,a5,409
   0x7f8e54046b38:      slli    a5,a5,0x6
   0x7f8e54046b3c:      ori     a5,a5,33
   0x7f8e54046b40:      bnez    a1,0x7f8e54046b4c
   0x7f8e54046b44:      li      a7,10
   0x7f8e54046b48:      j       0x7f8e54046b58
   0x7f8e54046b4c:      addi    s3,a6,-1
   0x7f8e54046b50:      add     t1,t2,s3
=> 0x7f8e54046b54:      lbu     a7,0(t1)
   0x7f8e54046b58:      sd      a0,-104(s0)
   0x7f8e54046b5c:      sd      a0,-112(s0)
   0x7f8e54046b60:      sd      a0,-120(s0)
   0x7f8e54046b64:      sd      a0,-128(s0)
   0x7f8e54046b68:      sd      a0,-136(s0)
   0x7f8e54046b6c:      sd      a0,-144(s0)
   0x7f8e54046b70:      lui     t0,0x200
   0x7f8e54046b74:      addi    t0,t0,329
   0x7f8e54046b78:      slli    t0,t0,0xb
   0x7f8e54046b7c:      ori     t0,t0,700
   0x7f8e54046b80:      slli    t0,t0,0x6
   0x7f8e54046b84:      ori     t0,t0,24
   0x7f8e54046b88:      ld      t0,0(t0)
   0x7f8e54046b8c:      j       0x7f8e540466cc
   0x7f8e54046b90:      ld      a1,-48(s0)
   0x7f8e54046b94:      ld      a0,-32(s0)
   0x7f8e54046b98:      ld      a2,-56(s0)
   0x7f8e54046b9c:      sub     a1,t2,a1
@luyahan
Copy link
Collaborator

luyahan commented Jan 4, 2022

V17.2 node use v8 9.6. This v8version is unstable. Please use V17.1 or wait node checkout v8 to V9.7.

@qjivy
Copy link
Collaborator

qjivy commented Jan 17, 2022

@hexchain Any update? Does the problem still happen after the version change?

@hexchain
Copy link
Author

hexchain commented Jan 17, 2022

It seems that they are still in the progress of updating v8 to 9.7. It is blocked for now due to some problems in v8 itself: nodejs/node#40907

@qjivy
Copy link
Collaborator

qjivy commented Feb 8, 2022

OK, I just close this issue now.
After the updating to 9.7, if there still crashes on RISCV64 target, pls reopen this issue.
Thx!

@qjivy qjivy closed this as completed Feb 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants