Skip to contentSkip to conversation

arm64: -smp 2 hangs qemu

Qemu-devel Joel Schopp 1 participant 3 messages Jul 25, 2014 – Aug 5, 2014

lore
Share & tools
lore
#0 lore raw

Public bug reported:

It appears that smp is broken on qemu for arm64. I'm looking into the root cause but am curious if others can reproduce in their environments.

Tested with commit f368c33d5ab09dd5656924185cd975b11838cd25 (July 22) from https://github.com/qemu/qemu.git

[root@joelaarch64 ~]# /usr/local/bin/qemu-system-aarch64 --version QEMU emulator version 2.0.93, Copyright (c) 2003-2008 Fabrice Bellard

works fine:
qemu --enable-kvm -nographic -netdev tap,id=t0,ifname=tap0,script=no,downscript=no,vhost=on -device virtio-net-device,netdev=t0,id=nic0 -kernel /extra/rootfs/boot/Image -drive file=/extra/Styx-Acadia-42-2014-07-07_10-09-27.img,id=fs -device virtio-blk-device,drive=fs -m 1024 -M virt -cpu host -smp 1 -append "console=ttyAMA0 console=ttyS0 root=/dev/vda2"

hangs:
qemu --enable-kvm -nographic -netdev tap,id=t0,ifname=tap0,script=no,downscript=no,vhost=on -device virtio-net-device,netdev=t0,id=nic0 -kernel /extra/rootfs/boot/Image -drive file=/extra/Styx-Acadia-42-2014-07-07_10-09-27.img,id=fs -device virtio-blk-device,drive=fs -m 1024 -M virt -cpu host -smp 2 -append "console=ttyAMA0 console=ttyS0 root=/dev/vda2"

(gdb) t
[Current thread is 1 (Thread 0x3ffb6787cc0 (LWP 7619))] (gdb) bt

#0  0x000003ffb6e50330 in ppoll () from /lib64/libc.so.6
#1  0x00000000006631a0 in ppoll (__ss=0x0, __timeout=0x0, __nfds=<optimized out>, __fds=<optimized out>) at /usr/include/bits/poll2.h:77
#2  qemu_poll_ns (fds=<optimized out>, nfds=<optimized out>, timeout=<optimized out>) at qemu-timer.c:314
#3  0x0000000000662878 in os_host_main_loop_wait (timeout=<optimized out>) at main-loop.c:229
#4  main_loop_wait (nonblocking=<optimized out>) at main-loop.c:484
#5  0x000000000040fdf4 in main_loop () at vl.c:2010
#6  main (argc=<optimized out>, argv=<optimized out>, envp=<optimized out>) at vl.c:4541

(gdb) t
[Current thread is 1 (Thread 0x3ffb6787cc0 (LWP 7619))] (gdb) t 2
[Switching to thread 2 (Thread 0x3ffb64beef0 (LWP 7622))] #0 0x000003ffb6f10a44 in sigwait () from /lib64/libpthread.so.0 (gdb) bt

#0  0x000003ffb6f10a44 in sigwait () from /lib64/libpthread.so.0
#1  0x000000000069d78c in sigwait_compat (opaque=0xd752c0) at util/compatfd.c:36
#2  0x000003ffb6f07c20 in start_thread () from /lib64/libpthread.so.0
#3  0x000003ffb6e5a80c in clone () from /lib64/libc.so.6

** Affects: qemu
Importance: Undecided
Status: New

Signature · 50 lines
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1348719

Title:
  arm64: -smp 2 hangs qemu

Status in QEMU:
  New

Bug description:
  It appears that smp is broken on qemu for arm64.  I'm looking into the
  root cause but am curious if others can reproduce in their
  environments.

  Tested with commit f368c33d5ab09dd5656924185cd975b11838cd25 (July 22)
  from https://github.com/qemu/qemu.git

  [root@joelaarch64 ~]# /usr/local/bin/qemu-system-aarch64 --version
  QEMU emulator version 2.0.93, Copyright (c) 2003-2008 Fabrice Bellard

  works fine:
  qemu --enable-kvm -nographic -netdev tap,id=t0,ifname=tap0,script=no,downscript=no,vhost=on -device virtio-net-device,netdev=t0,id=nic0 -kernel /extra/rootfs/boot/Image -drive file=/extra/Styx-Acadia-42-2014-07-07_10-09-27.img,id=fs -device virtio-blk-device,drive=fs -m 1024 -M virt -cpu host -smp 1 -append "console=ttyAMA0 console=ttyS0 root=/dev/vda2"

  hangs:
  qemu --enable-kvm -nographic -netdev tap,id=t0,ifname=tap0,script=no,downscript=no,vhost=on -device virtio-net-device,netdev=t0,id=nic0 -kernel /extra/rootfs/boot/Image -drive file=/extra/Styx-Acadia-42-2014-07-07_10-09-27.img,id=fs -device virtio-blk-device,drive=fs -m 1024 -M virt -cpu host -smp 2 -append "console=ttyAMA0 console=ttyS0 root=/dev/vda2"

  (gdb) t
  [Current thread is 1 (Thread 0x3ffb6787cc0 (LWP 7619))]
  (gdb) bt
  #0  0x000003ffb6e50330 in ppoll () from /lib64/libc.so.6
  #1  0x00000000006631a0 in ppoll (__ss=0x0, __timeout=0x0, __nfds=<optimized out>, __fds=<optimized out>) at /usr/include/bits/poll2.h:77
  #2  qemu_poll_ns (fds=<optimized out>, nfds=<optimized out>, timeout=<optimized out>) at qemu-timer.c:314
  #3  0x0000000000662878 in os_host_main_loop_wait (timeout=<optimized out>) at main-loop.c:229
  #4  main_loop_wait (nonblocking=<optimized out>) at main-loop.c:484
  #5  0x000000000040fdf4 in main_loop () at vl.c:2010
  #6  main (argc=<optimized out>, argv=<optimized out>, envp=<optimized out>) at vl.c:4541
  (gdb) t
  [Current thread is 1 (Thread 0x3ffb6787cc0 (LWP 7619))]
  (gdb) t 2
  [Switching to thread 2 (Thread 0x3ffb64beef0 (LWP 7622))]
  #0  0x000003ffb6f10a44 in sigwait () from /lib64/libpthread.so.0
  (gdb) bt
  #0  0x000003ffb6f10a44 in sigwait () from /lib64/libpthread.so.0
  #1  0x000000000069d78c in sigwait_compat (opaque=0xd752c0) at util/compatfd.c:36
  #2  0x000003ffb6f07c20 in start_thread () from /lib64/libpthread.so.0
  #3  0x000003ffb6e5a80c in clone () from /lib64/libc.so.6

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1348719/+subscriptions
#1 lore raw

** Changed in: qemu
Assignee: (unassigned) => Joel Schopp (joel-schopp)

Signature · 50 lines
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1348719

Title:
  arm64: -smp 2 hangs qemu

Status in QEMU:
  New

Bug description:
  It appears that smp is broken on qemu for arm64.  I'm looking into the
  root cause but am curious if others can reproduce in their
  environments.

  Tested with commit f368c33d5ab09dd5656924185cd975b11838cd25 (July 22)
  from https://github.com/qemu/qemu.git

  [root@joelaarch64 ~]# /usr/local/bin/qemu-system-aarch64 --version
  QEMU emulator version 2.0.93, Copyright (c) 2003-2008 Fabrice Bellard

  works fine:
  qemu --enable-kvm -nographic -netdev tap,id=t0,ifname=tap0,script=no,downscript=no,vhost=on -device virtio-net-device,netdev=t0,id=nic0 -kernel /extra/rootfs/boot/Image -drive file=/extra/Styx-Acadia-42-2014-07-07_10-09-27.img,id=fs -device virtio-blk-device,drive=fs -m 1024 -M virt -cpu host -smp 1 -append "console=ttyAMA0 console=ttyS0 root=/dev/vda2"

  hangs:
  qemu --enable-kvm -nographic -netdev tap,id=t0,ifname=tap0,script=no,downscript=no,vhost=on -device virtio-net-device,netdev=t0,id=nic0 -kernel /extra/rootfs/boot/Image -drive file=/extra/Styx-Acadia-42-2014-07-07_10-09-27.img,id=fs -device virtio-blk-device,drive=fs -m 1024 -M virt -cpu host -smp 2 -append "console=ttyAMA0 console=ttyS0 root=/dev/vda2"

  (gdb) t
  [Current thread is 1 (Thread 0x3ffb6787cc0 (LWP 7619))]
  (gdb) bt
  #0  0x000003ffb6e50330 in ppoll () from /lib64/libc.so.6
  #1  0x00000000006631a0 in ppoll (__ss=0x0, __timeout=0x0, __nfds=<optimized out>, __fds=<optimized out>) at /usr/include/bits/poll2.h:77
  #2  qemu_poll_ns (fds=<optimized out>, nfds=<optimized out>, timeout=<optimized out>) at qemu-timer.c:314
  #3  0x0000000000662878 in os_host_main_loop_wait (timeout=<optimized out>) at main-loop.c:229
  #4  main_loop_wait (nonblocking=<optimized out>) at main-loop.c:484
  #5  0x000000000040fdf4 in main_loop () at vl.c:2010
  #6  main (argc=<optimized out>, argv=<optimized out>, envp=<optimized out>) at vl.c:4541
  (gdb) t
  [Current thread is 1 (Thread 0x3ffb6787cc0 (LWP 7619))]
  (gdb) t 2
  [Switching to thread 2 (Thread 0x3ffb64beef0 (LWP 7622))]
  #0  0x000003ffb6f10a44 in sigwait () from /lib64/libpthread.so.0
  (gdb) bt
  #0  0x000003ffb6f10a44 in sigwait () from /lib64/libpthread.so.0
  #1  0x000000000069d78c in sigwait_compat (opaque=0xd752c0) at util/compatfd.c:36
  #2  0x000003ffb6f07c20 in start_thread () from /lib64/libpthread.so.0
  #3  0x000003ffb6e5a80c in clone () from /lib64/libc.so.6

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1348719/+subscriptions
#2 lore raw
In reply to Joel Schopp

The combination of a newer kernel and newer qemu make qemu work with -smp 2 . Rather than go figure out what got fixed let's just be happy it did.

** Changed in: qemu
Status: New => Fix Released

Signature · 50 lines
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1348719

Title:
  arm64: -smp 2 hangs qemu

Status in QEMU:
  Fix Released

Bug description:
  It appears that smp is broken on qemu for arm64.  I'm looking into the
  root cause but am curious if others can reproduce in their
  environments.

  Tested with commit f368c33d5ab09dd5656924185cd975b11838cd25 (July 22)
  from https://github.com/qemu/qemu.git

  [root@joelaarch64 ~]# /usr/local/bin/qemu-system-aarch64 --version
  QEMU emulator version 2.0.93, Copyright (c) 2003-2008 Fabrice Bellard

  works fine:
  qemu --enable-kvm -nographic -netdev tap,id=t0,ifname=tap0,script=no,downscript=no,vhost=on -device virtio-net-device,netdev=t0,id=nic0 -kernel /extra/rootfs/boot/Image -drive file=/extra/Styx-Acadia-42-2014-07-07_10-09-27.img,id=fs -device virtio-blk-device,drive=fs -m 1024 -M virt -cpu host -smp 1 -append "console=ttyAMA0 console=ttyS0 root=/dev/vda2"

  hangs:
  qemu --enable-kvm -nographic -netdev tap,id=t0,ifname=tap0,script=no,downscript=no,vhost=on -device virtio-net-device,netdev=t0,id=nic0 -kernel /extra/rootfs/boot/Image -drive file=/extra/Styx-Acadia-42-2014-07-07_10-09-27.img,id=fs -device virtio-blk-device,drive=fs -m 1024 -M virt -cpu host -smp 2 -append "console=ttyAMA0 console=ttyS0 root=/dev/vda2"

  (gdb) t
  [Current thread is 1 (Thread 0x3ffb6787cc0 (LWP 7619))]
  (gdb) bt
  #0  0x000003ffb6e50330 in ppoll () from /lib64/libc.so.6
  #1  0x00000000006631a0 in ppoll (__ss=0x0, __timeout=0x0, __nfds=<optimized out>, __fds=<optimized out>) at /usr/include/bits/poll2.h:77
  #2  qemu_poll_ns (fds=<optimized out>, nfds=<optimized out>, timeout=<optimized out>) at qemu-timer.c:314
  #3  0x0000000000662878 in os_host_main_loop_wait (timeout=<optimized out>) at main-loop.c:229
  #4  main_loop_wait (nonblocking=<optimized out>) at main-loop.c:484
  #5  0x000000000040fdf4 in main_loop () at vl.c:2010
  #6  main (argc=<optimized out>, argv=<optimized out>, envp=<optimized out>) at vl.c:4541
  (gdb) t
  [Current thread is 1 (Thread 0x3ffb6787cc0 (LWP 7619))]
  (gdb) t 2
  [Switching to thread 2 (Thread 0x3ffb64beef0 (LWP 7622))]
  #0  0x000003ffb6f10a44 in sigwait () from /lib64/libpthread.so.0
  (gdb) bt
  #0  0x000003ffb6f10a44 in sigwait () from /lib64/libpthread.so.0
  #1  0x000000000069d78c in sigwait_compat (opaque=0xd752c0) at util/compatfd.c:36
  #2  0x000003ffb6f07c20 in start_thread () from /lib64/libpthread.so.0
  #3  0x000003ffb6e5a80c in clone () from /lib64/libc.so.6

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1348719/+subscriptions