From owner-svn-src-all@FreeBSD.ORG Tue Nov 17 00:11:23 2009 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 855FF106566B; Tue, 17 Nov 2009 00:11:23 +0000 (UTC) (envelope-from lynx.ripe@gmail.com) Received: from fg-out-1718.google.com (fg-out-1718.google.com [72.14.220.153]) by mx1.freebsd.org (Postfix) with ESMTP id 6FCFC8FC13; Tue, 17 Nov 2009 00:11:16 +0000 (UTC) Received: by fg-out-1718.google.com with SMTP id e12so1286730fga.13 for ; Mon, 16 Nov 2009 16:11:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from :user-agent:mime-version:to:cc:subject:content-type :content-transfer-encoding; bh=L5rJ7vonNbE57RAkR/QN0t/1omRGKH7cQU0YZbcKbUw=; b=SsNPV8dRhRtUo5DN7vajPaJlZvjNwKzjMPZFDKvjLPpfh2i7XAH8Ov1IhxyLq0QrZ3 6gboLfUKkHT5yJAXqC+DnXvOQgRgWSNEZn61tnJ1ZAAsjWAke5BU0bb+yYaJXXaXOezR JqADohtEJbno7WlcPusSFUXVeCeaCawDZdLhc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :content-type:content-transfer-encoding; b=as6mC6rJEfb+vmaVBHtB/QMmoAq7SZ90PXmeuV27N59dvwAgq+tGZJBxp1be3VsOtB IScMPJ1gfuS8YY/NT7pGtkYN3FGQY6PzavLwqKj08dWWCTwak/IolO5qCwnNaS8SVkvu OGwgBWUxNyfA63E2VT8B3MiG5guz3TgyQzoow= Received: by 10.86.254.17 with SMTP id b17mr2888688fgi.65.1258415435685; Mon, 16 Nov 2009 15:50:35 -0800 (PST) Received: from lynx.homenet (244-200-132-95.pool.ukrtel.net [95.132.200.244]) by mx.google.com with ESMTPS id 3sm327497fge.29.2009.11.16.15.50.34 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 16 Nov 2009 15:50:34 -0800 (PST) Message-ID: <4B01E548.7040708@gmail.com> Date: Tue, 17 Nov 2009 01:50:32 +0200 From: Dmitry Pryanishnikov User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.8.1.23) Gecko/20090906 SeaMonkey/1.1.18 MIME-Version: 1.0 To: Edwin Groothuis Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r194783 - head/lib/libc/stdtime X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Nov 2009 00:11:23 -0000 Hello! > Author: edwin > Date: Tue Jun 23 22:28:44 2009 > New Revision: 194783 > URL: http://svn.freebsd.org/changeset/base/194783 > > Log: > Remove duplicate if-statement on gmt_is_set in gmtsub(). > > MFC after: 1 week > > Modified: > head/lib/libc/stdtime/localtime.c > > Modified: head/lib/libc/stdtime/localtime.c > ============================================================================== > --- head/lib/libc/stdtime/localtime.c Tue Jun 23 22:22:20 2009 (r194782) > +++ head/lib/libc/stdtime/localtime.c Tue Jun 23 22:28:44 2009 (r194783) > @@ -1472,18 +1472,16 @@ struct tm * const tmp; > { > register struct tm * result; > > + _MUTEX_LOCK(&gmt_mutex); > if (!gmt_is_set) { > - _MUTEX_LOCK(&gmt_mutex); > - if (!gmt_is_set) { This change looks like a (small?) pessimization to me: before it, _MUTEX_LOCK/_MUTEX_UNLOCK pair would be skipped for the case gmt_is_set == TRUE (all invocations except the first one), now it won't. I'm not sure whether this is critical here though... Sincerely, Dmitry -- nic-hdl: LYNX-RIPE