From owner-freebsd-hackers@freebsd.org Fri Mar 18 18:58:31 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 236D3AD40CF for ; Fri, 18 Mar 2016 18:58:31 +0000 (UTC) (envelope-from stas@FreeBSD.org) Received: from mx0.deglitch.com (mx0.deglitch.com [62.152.53.178]) by mx1.freebsd.org (Postfix) with ESMTP id D8165158A; Fri, 18 Mar 2016 18:58:30 +0000 (UTC) (envelope-from stas@FreeBSD.org) Received: from [IPv6:2620:10d:c082:1803:9c65:ebd8:7cd2:7e46] (unknown [IPv6:2620:10d:c090:200::f:9a2b]) by mx0.deglitch.com (Postfix) with ESMTPSA id DC8B58FC0B; Fri, 18 Mar 2016 11:58:21 -0700 (PDT) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 9.2 \(3112\)) Subject: Re: Peformance issues with r278325 From: Stanislav Sedov In-Reply-To: Date: Fri, 18 Mar 2016 11:58:19 -0700 Cc: John Baldwin , Adrian Chadd , Konstantin Belousov , "freebsd-hackers@freebsd.org" Content-Transfer-Encoding: quoted-printable Message-Id: <59BA610B-3754-43D6-839D-84FEE8F13CF7@FreeBSD.org> References: <8403291.NqUNo0Qq5W@ralph.baldwin.cx> <3277812.DVsZx4uMun@ralph.baldwin.cx> To: Ryan Stone X-Mailer: Apple Mail (2.3112) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 Mar 2016 18:58:31 -0000 > On Mar 18, 2016, at 11:49 AM, Ryan Stone wrote: >=20 > On Fri, Mar 18, 2016 at 1:37 PM, John Baldwin wrote: > I think I'll likely just convert it to use a direct > TSC delay loop always in HEAD (assuming that verifies ok in testing as = well). >=20 > Couldn't that work incorrectly on VM guests? The tsc is not = guaranteed to be monotonic in that environment. >=20 Another concern is SMP systems where the clock is not synchronized. SMP = TSC requires a complicated setup procedure on the system boot which is not followed = properly by all vendors, and I have seen some recent systems with SMP TSC skew. I'm afraid that using TSC in this code will make FreeBSD unusable on = such (arguably buggy) systems.=20 -- Stanislav Sedov ST4096-RIPE