Package: bird
Version: 1.3.7-1
Severity: important
Tags: patch

Hello,

Installing bird 1.3.7-1 (wheezy aka stable) on a DockStar (CPU ARM5TE,
Debian architecture armel) led to a hang: The bird process ran into an
endless loop, eating 100% CPU. Before detaching, so bird.postinst was
stuck.

This exists in wheezy (1.3.7-1) only, squeeze, wheezy-backports and
jessie are fine.

Reverse-bisecting led to

efd6d12b975441c7e1875a59dd9e0f3db7e958cb is the first bad commit
commit efd6d12b975441c7e1875a59dd9e0f3db7e958cb
Author: Ondrej Zajicek <[email protected]>
Date:   Wed Apr 17 15:09:50 2013 +0200

    Adds two new default GCC options.

    Adds two new default GCC options related to optimizations
    (-fno-strict-aliasing and -fno-strict-overflow). This
    should fix some hyperaggressive GCC optimizations.

    Also updates autoconf option detection.

but simply adding that one to the patch queue does not alter the
compile options actually used, therefore a bird executable from
a newly built Debian package still shows the problem.


The patch below adds a memory barrier to the place where the optimizer
goes wild, and solves the issue. This was found by coincidence when
using debug print statements. This code path is rarely used so the
performance penalty should be impossible to notice.

Let me know if you're interested in fixing this via a point release,
I'll do more tests then. For the time being and/or for other people
affected by this: Patch your package and give feedback, or use the
wheezy-backports version of bird.

    Christoph


--- a/nest/iface.c
+++ b/nest/iface.c
@@ -478,6 +478,7 @@
     {
       a->flags |= IA_PRIMARY;
       rem_node(&a->n);
+      asm volatile("": : :"memory");
       add_head(&i->addrs, &a->n);
     }


-- System Information:
Debian Release: 7.4
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: armel (armv5tel)

Kernel: Linux 3.10.33
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/dash

Versions of packages bird depends on:
ii  libc6         2.13-38+deb7u1
ii  libncurses5   5.9-10
ii  libreadline6  6.2+dfsg-0.1+~jj1
ii  libtinfo5     5.9-10

Versions of packages bird recommends:
pn  bird6  <none>

bird suggests no packages.

-- no debconf information

Attachment: signature.asc
Description: Digital signature

Reply via email to