# uptime/w i386 breakage?



## pallfreeman (Apr 20, 2018)

My recent 11.1 i386 is exhibiting a seg fault with the `w` (hence `uptime`) command. OK on amd64. Is it just me?


```
icefall% uname -a
FreeBSD icefall 11.1-STABLE FreeBSD 11.1-STABLE #4 r332642: Tue Apr 17 15:13:05 BST 2018     ip@icefall:/usr/src/sys/i386/compile/GENERIC  i386
icefall% pwd
/usr/obj/usr/src/usr.bin/w
icefall% gdb w.full
GNU gdb 6.1.1 [FreeBSD]
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-marcel-freebsd"...
(gdb) r
Starting program: /usr/obj/usr/src/usr.bin/w/w.full

Program received signal SIGSEGV, Segmentation fault.
xo_transition (xop=0x2806aff0, flags=<value optimized out>,
    name=0x804ac13 "uptime-information", new_state=1)
    at /usr/src/contrib/libxo/libxo/libxo.c:7559
7559        old_state = xsp->xs_state;
Current language:  auto; currently minimal
(gdb)
```


----------



## SirDice (Apr 20, 2018)

Why are you running it from /usr/obj?


----------



## acheron (Apr 20, 2018)

SirDice said:


> Why are you running it from /usr/obj?


He probably recompiled it with debug symbol and didn't want to install it in /usr/bin.


----------



## acheron (Apr 20, 2018)

It was reported on @stable https://lists.freebsd.org/pipermail/freebsd-stable/2018-April/088740.html


----------



## DewayneG (Apr 23, 2018)

Thanks for raising the issue Pallfreeman, you've ruled out my customisations as the sole cause  .  I have a similar problem with 11.2-PRERELEASE FreeBSD 11.2-PRERELEASE  r332843M, operating as an amd64 base-system with a few i386 and amd64 jails.  The i386 jails are experiencing seg faults with "uptime" and "w" as you reported, but also a few others (ps,ls,gpart).   The /rescue/ps /rescue/ls work on i386, but they don't include libxo, sadly neither does gpart.
The amd64 jails appear fine, and successfully package complex things like samba46.   Perhaps clang doesn't like something while building i386?


----------



## DewayneG (Apr 23, 2018)

acheron said:


> It was reported on @stable https://lists.freebsd.org/pipermail/freebsd-stable/2018-April/088740.html


Thanks I should've walked the posts, when I did I found that a value in libxo was "optimised away".


----------



## pallfreeman (Apr 23, 2018)

Thanks guys. I managed to duplicate duplicate my comment on bugzilla, wonder if I'll get two notifications?


----------



## Crivens (Apr 23, 2018)

Did you also quadruple something in that report, so wee can have a procession?


----------

