From owner-freebsd-stable@freebsd.org Mon Jan 29 00:41:21 2018 Return-Path: Delivered-To: freebsd-stable@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2EAA1EC8D77 for ; Mon, 29 Jan 2018 00:41:21 +0000 (UTC) (envelope-from truckman@FreeBSD.org) Received: from mx2.catspoiler.org (mx2.catspoiler.org [IPv6:2607:f740:16::d18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "amnesiac", Issuer "amnesiac" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id B707D768E5; Mon, 29 Jan 2018 00:41:20 +0000 (UTC) (envelope-from truckman@FreeBSD.org) Received: from gw.catspoiler.org ([76.212.85.177]) by mx2.catspoiler.org (8.15.2/8.15.2) with ESMTPS id w0T0fmdi014628 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 29 Jan 2018 00:41:50 GMT (envelope-from truckman@FreeBSD.org) Received: from mousie.catspoiler.org (mousie.catspoiler.org [192.168.101.2]) by gw.catspoiler.org (8.15.2/8.15.2) with ESMTPS id w0T0BfYF005315 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 28 Jan 2018 16:41:12 -0800 (PST) (envelope-from truckman@FreeBSD.org) Date: Sun, 28 Jan 2018 16:41:11 -0800 (PST) From: Don Lewis Subject: Re: Ryzen issues on FreeBSD ? To: Mike Tancsa cc: Peter Moody , Pete French , freebsd-stable@freebsd.org, Andriy Gapon In-Reply-To: <55913e41-3a8a-9a4d-6862-e09a3d0f4d55@sentex.net> Message-ID: References: <8e842dec-ade7-37d1-6bd8-856ea1a827ca@sentex.net> <9b769e4e-b098-b294-0bce-8bb1c42e8a59@rootautomation.com> <730eb882-1c6a-afb7-0ada-396db44fb34b@ingresso.co.uk> <8b882970-4d5d-2a96-4dac-779cab07b9ae@sentex.net> <343acf99-3e9e-093a-7390-c142396c2985@sentex.net> <3dd9a61b-511d-db2e-80ca-cbc9a4b65f92@sentex.net> <55913e41-3a8a-9a4d-6862-e09a3d0f4d55@sentex.net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; CHARSET=us-ascii Content-Disposition: INLINE X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Jan 2018 00:41:21 -0000 On 27 Jan, Mike Tancsa wrote: > On 1/27/2018 3:23 AM, Don Lewis wrote: >> >> I just ran into this for this first time with samba46. I kicked of a >> ports build this evening before leaving for several hours. When I >> returned, samba46 had failed with a build runaway. I just tried again >> and I see python stuck in the usem state. This is what I see with >> procstat -k: > > Hmmm, is this indicative of a processor bug or a FreeBSD bug or its > indeterminate at this point ? My suspicion is a FreeBSD bug, probably a locking / race issue. I know that we've had to make some tweeks to our code for AMD CPUs, like this: ------------------------------------------------------------------------ r321608 | kib | 2017-07-27 01:37:07 -0700 (Thu, 27 Jul 2017) | 9 lines Use MFENCE to serialize RDTSC on non-Intel CPUs. Kernel already used the stronger barrier instruction for AMDs, correct the userspace fast gettimeofday() implementation as well. I did go back and look at the build runaways that I've occasionally seen on my AMD FX-8320E package builder. I haven't seen the python issue there, but have seen gmake get stuck in a sleeping state with a bunch of zombie offspring.