From owner-freebsd-arch@FreeBSD.ORG Wed Jul 18 14:43:42 2012 Return-Path: Delivered-To: arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6798F106566C for ; Wed, 18 Jul 2012 14:43:42 +0000 (UTC) (envelope-from gnn@FreeBSD.org) Received: from vps.hungerhost.com (vps.hungerhost.com [216.38.53.176]) by mx1.freebsd.org (Postfix) with ESMTP id 3E3598FC1E for ; Wed, 18 Jul 2012 14:43:42 +0000 (UTC) Received: from [209.249.190.124] (port=60266 helo=gnnmac.hudson-trading.com) by vps.hungerhost.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.77) (envelope-from ) id 1SrVTZ-0006oT-1e for arch@freebsd.org; Wed, 18 Jul 2012 10:43:41 -0400 From: George Neville-Neil Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Date: Wed, 18 Jul 2012 10:43:42 -0400 Message-Id: <3CE55F29-A5B2-44A7-8854-1ED38BAE6F16@FreeBSD.org> To: arch@freebsd.org Mime-Version: 1.0 (Apple Message framework v1280) X-Mailer: Apple Mail (2.1280) X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - vps.hungerhost.com X-AntiAbuse: Original Domain - freebsd.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - FreeBSD.org Cc: Subject: aio in GENERIC? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Jul 2012 14:43:42 -0000 Howdy, I was wondering why aio is not yet in GENERIC. Now that it's properly = locked and all. Best, George From owner-freebsd-arch@FreeBSD.ORG Thu Jul 19 00:10:29 2012 Return-Path: Delivered-To: arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A9C851065674; Thu, 19 Jul 2012 00:10:29 +0000 (UTC) (envelope-from listlog2011@gmail.com) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 769838FC12; Thu, 19 Jul 2012 00:10:29 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.5/8.14.5) with ESMTP id q6J0ASFs030941; Thu, 19 Jul 2012 00:10:28 GMT (envelope-from listlog2011@gmail.com) Message-ID: <50075072.5050906@gmail.com> Date: Thu, 19 Jul 2012 08:10:26 +0800 From: David Xu User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:13.0) Gecko/20120614 Thunderbird/13.0.1 MIME-Version: 1.0 To: George Neville-Neil References: <3CE55F29-A5B2-44A7-8854-1ED38BAE6F16@FreeBSD.org> In-Reply-To: <3CE55F29-A5B2-44A7-8854-1ED38BAE6F16@FreeBSD.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: arch@FreeBSD.org Subject: Re: aio in GENERIC? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: davidxu@FreeBSD.org List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Jul 2012 00:10:29 -0000 On 2012/7/18 22:43, George Neville-Neil wrote: > Howdy, > > I was wondering why aio is not yet in GENERIC. Now that it's properly locked and all. > > Best, > George > I think one of the problem in the AIO code is it allows user code to pass pipe, socket and other file handles to kernel, however it may not work well, the AIO threads may be blocked forever. I suggest to disable support for socket or pipe except normal file or disk device. it should either fully support it or do not support it at all, not half-baked. Regards, David Xu From owner-freebsd-arch@FreeBSD.ORG Thu Jul 19 00:20:30 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 766F3106566B for ; Thu, 19 Jul 2012 00:20:30 +0000 (UTC) (envelope-from mj@feral.com) Received: from ns1.feral.com (ns1.feral.com [192.67.166.1]) by mx1.freebsd.org (Postfix) with ESMTP id 384C98FC15 for ; Thu, 19 Jul 2012 00:20:30 +0000 (UTC) Received: from centos62.localhost (localhost [127.0.0.1]) by ns1.feral.com (8.14.4/8.14.4) with ESMTP id q6J0KTn6048227 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Wed, 18 Jul 2012 17:20:29 -0700 (PDT) (envelope-from mj@feral.com) Message-ID: <500752CD.9030107@feral.com> Date: Wed, 18 Jul 2012 17:20:29 -0700 From: Matthew Jacob User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.6esrpre) Gecko/20120717 Thunderbird/10.0.6 MIME-Version: 1.0 To: freebsd-arch@freebsd.org References: <3CE55F29-A5B2-44A7-8854-1ED38BAE6F16@FreeBSD.org> <50075072.5050906@gmail.com> In-Reply-To: <50075072.5050906@gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.2.7 (ns1.feral.com [127.0.0.1]); Wed, 18 Jul 2012 17:20:29 -0700 (PDT) Subject: Re: aio in GENERIC? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Jul 2012 00:20:30 -0000 What practically does aio offer that is not achieved via pthreads other than slightly simpler code? From owner-freebsd-arch@FreeBSD.ORG Thu Jul 19 00:25:19 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BC9581065673 for ; Thu, 19 Jul 2012 00:25:19 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id A178B8FC1F for ; Thu, 19 Jul 2012 00:25:19 +0000 (UTC) Received: by elvis.mu.org (Postfix, from userid 1192) id 4E4661A3CD0; Wed, 18 Jul 2012 17:25:19 -0700 (PDT) Date: Wed, 18 Jul 2012 17:25:19 -0700 From: Alfred Perlstein To: Matthew Jacob Message-ID: <20120719002519.GK98608@elvis.mu.org> References: <3CE55F29-A5B2-44A7-8854-1ED38BAE6F16@FreeBSD.org> <50075072.5050906@gmail.com> <500752CD.9030107@feral.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <500752CD.9030107@feral.com> User-Agent: Mutt/1.4.2.3i Cc: freebsd-arch@freebsd.org Subject: Re: aio in GENERIC? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Jul 2012 00:25:19 -0000 * Matthew Jacob [120718 17:20] wrote: > What practically does aio offer that is not achieved via pthreads other > than slightly simpler code? People expect it to be there. -- - Alfred Perlstein .- VMOA #5191, 03 vmax, 92 gs500, 85 ch250, 07 zx10 .- FreeBSD committer From owner-freebsd-arch@FreeBSD.ORG Thu Jul 19 15:58:14 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 87D79106566C for ; Thu, 19 Jul 2012 15:58:14 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-gg0-f182.google.com (mail-gg0-f182.google.com [209.85.161.182]) by mx1.freebsd.org (Postfix) with ESMTP id 406068FC14 for ; Thu, 19 Jul 2012 15:58:14 +0000 (UTC) Received: by ggnm2 with SMTP id m2so3480590ggn.13 for ; Thu, 19 Jul 2012 08:58:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=Tsyx6vkJctCFiNOGr2sGro+P1rZDT9Dfn2t+7vfahKQ=; b=zM89rmTGI6csZafpdGBXKQGqI8eavwBZWjigghW0Mqrv4luJhhopABNswchsUOFNg8 EN5SZjixQeVrquImUJ3/vZVuFEfP4Aon94xjfIfibbX8Wnnd1ik9+IwvIvsG408Rdndn ueGQotsRcQOaIvb0XSy4szhsyMgNWI2nU98fvsmTuQupkhbMoYdlOMQGtVAqwwLIiLK2 /CBx5Qyq6ttxiU3Vg/M4RswCawEiCJNQIMYas7Pis8SGuGMJJHvaTnXfgq+PBdqS6WJm 9JdysVk3pG/fW9rUHxc9q+KlZ5nsNhlTy3DGvn8sLk8OTUlVY9UoYnpJAyZ8zjUzXsWK qMpA== MIME-Version: 1.0 Received: by 10.68.201.9 with SMTP id jw9mr6414594pbc.28.1342713493162; Thu, 19 Jul 2012 08:58:13 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.68.191.138 with HTTP; Thu, 19 Jul 2012 08:58:13 -0700 (PDT) In-Reply-To: <500752CD.9030107@feral.com> References: <3CE55F29-A5B2-44A7-8854-1ED38BAE6F16@FreeBSD.org> <50075072.5050906@gmail.com> <500752CD.9030107@feral.com> Date: Thu, 19 Jul 2012 08:58:13 -0700 X-Google-Sender-Auth: vLrxl_fcEB4jWsTnuMpiXTNwyaQ Message-ID: From: Adrian Chadd To: Matthew Jacob Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-arch@freebsd.org Subject: Re: aio in GENERIC? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Jul 2012 15:58:14 -0000 .. the API supports the avoidance of copyin/copyout? Adrian On 18 July 2012 17:20, Matthew Jacob wrote: > What practically does aio offer that is not achieved via pthreads other than > slightly simpler code? > > _______________________________________________ > freebsd-arch@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-arch > To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org" From owner-freebsd-arch@FreeBSD.ORG Thu Jul 19 16:08:04 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 58DD0106566C for ; Thu, 19 Jul 2012 16:08:04 +0000 (UTC) (envelope-from mj@feral.com) Received: from ns1.feral.com (ns1.feral.com [192.67.166.1]) by mx1.freebsd.org (Postfix) with ESMTP id E4A538FC14 for ; Thu, 19 Jul 2012 16:08:03 +0000 (UTC) Received: from [192.168.135.103] (c-76-126-166-136.hsd1.ca.comcast.net [76.126.166.136]) (authenticated bits=0) by ns1.feral.com (8.14.4/8.14.4) with ESMTP id q6JG7tDB058543 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO) for ; Thu, 19 Jul 2012 09:07:56 -0700 (PDT) (envelope-from mj@feral.com) Message-ID: <500830D5.6000409@feral.com> Date: Thu, 19 Jul 2012 09:07:49 -0700 From: Matthew Jacob Organization: Feral Software User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20120614 Thunderbird/13.0.1 MIME-Version: 1.0 To: freebsd-arch@freebsd.org References: <3CE55F29-A5B2-44A7-8854-1ED38BAE6F16@FreeBSD.org> <50075072.5050906@gmail.com> <500752CD.9030107@feral.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (ns1.feral.com [192.67.166.1]); Thu, 19 Jul 2012 09:07:57 -0700 (PDT) Subject: Re: aio in GENERIC? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: mj@feral.com List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Jul 2012 16:08:04 -0000 On 7/19/2012 8:58 AM, Adrian Chadd wrote: > .. the API supports the avoidance of copyin/copyout? > > okay, I'll buy that, although I'm not certain of the utility in general of that. The reason I asked was that I have rarely, if ever, run into an AIO implementation that was more trouble than it was worth. It certainly has caused major grief in FreeBSD when used with CAM target mode. From owner-freebsd-arch@FreeBSD.ORG Thu Jul 19 21:25:58 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5E8471065672 for ; Thu, 19 Jul 2012 21:25:58 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 45F3E8FC0A for ; Thu, 19 Jul 2012 21:25:58 +0000 (UTC) Received: by elvis.mu.org (Postfix, from userid 1192) id 2C4B41A3C6D; Thu, 19 Jul 2012 14:25:58 -0700 (PDT) Date: Thu, 19 Jul 2012 14:25:58 -0700 From: Alfred Perlstein To: Matthew Jacob Message-ID: <20120719212558.GO98608@elvis.mu.org> References: <3CE55F29-A5B2-44A7-8854-1ED38BAE6F16@FreeBSD.org> <50075072.5050906@gmail.com> <500752CD.9030107@feral.com> <500830D5.6000409@feral.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <500830D5.6000409@feral.com> User-Agent: Mutt/1.4.2.3i Cc: freebsd-arch@freebsd.org Subject: Re: aio in GENERIC? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Jul 2012 21:25:58 -0000 * Matthew Jacob [120719 09:08] wrote: > On 7/19/2012 8:58 AM, Adrian Chadd wrote: > >.. the API supports the avoidance of copyin/copyout? > > > > > okay, I'll buy that, although I'm not certain of the utility in general > of that. > > The reason I asked was that I have rarely, if ever, run into an AIO > implementation that was more trouble than it was worth. It certainly has > caused major grief in FreeBSD when used with CAM target mode. {AIO,Pthreads,SMP,etc} are hard, let's go shopping? really? :) -Alfred From owner-freebsd-arch@FreeBSD.ORG Fri Jul 20 04:42:22 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 3182F106564A for ; Fri, 20 Jul 2012 04:42:22 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from mail-gg0-f182.google.com (mail-gg0-f182.google.com [209.85.161.182]) by mx1.freebsd.org (Postfix) with ESMTP id DD5868FC0C for ; Fri, 20 Jul 2012 04:42:21 +0000 (UTC) Received: by ggnm2 with SMTP id m2so4253898ggn.13 for ; Thu, 19 Jul 2012 21:42:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=sender:from:content-type:content-transfer-encoding:subject:date :message-id:to:mime-version:x-mailer:x-gm-message-state; bh=xKkr+RN31iGk9g7iXI6mnExkNK80ozzcDQmP28Wxy7s=; b=nvYrszD255JRsTGH0BbCQiBGlmR0CIbv72nKF6XX80xaVtXXZUR0W3h6i9e/NTBHei yOROU3sWdVjd6zFMqsLxkaZ293ssdEBW6kSI488vRjcWoRRneO8Sq/SEAb6lCaIdps+G TNjIs2e42g1spBnqLADErmuqfwDACCQBrOr2FN16sNW0Vf4KUqELmqBXZqa1OwO6xt8v RlolB7K1meMpqxgFwPLh4n99HV48nQs+VBLN6g9lt2UH/bwAwthtjQ4oLN7z+ip6CA7T V/a8dNfTt192476xILg/TJhVt0pKOVyzpC16GllCSfIvdZ17fEFugqF3+YWaRjixgxme L4NQ== Received: by 10.66.76.170 with SMTP id l10mr8478383paw.57.1342759340913; Thu, 19 Jul 2012 21:42:20 -0700 (PDT) Received: from [172.80.90.174] ([67.213.234.99]) by mx.google.com with ESMTPS id qa5sm3151498pbb.19.2012.07.19.21.42.19 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 19 Jul 2012 21:42:20 -0700 (PDT) Sender: Warner Losh From: Warner Losh Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Thu, 19 Jul 2012 22:42:15 -0600 Message-Id: To: FreeBSD-arch Arch Mime-Version: 1.0 (Apple Message framework v1084) X-Mailer: Apple Mail (2.1084) X-Gm-Message-State: ALoCoQn0lXauxbFO06UAfdK+x6d8xT8Hj3H1M1JVbQIXhMckPcXkXontoH6HyoIQQTnv3YODiBmL Subject: Flex update X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Jul 2012 04:42:22 -0000 Is there some reason that flex has never been updated from 2.4.5a? Warner From owner-freebsd-arch@FreeBSD.ORG Fri Jul 20 05:05:05 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 90BFE106564A for ; Fri, 20 Jul 2012 05:05:05 +0000 (UTC) (envelope-from julian@freebsd.org) Received: from vps1.elischer.org (vps1.elischer.org [204.109.63.16]) by mx1.freebsd.org (Postfix) with ESMTP id 3F33F8FC0C for ; Fri, 20 Jul 2012 05:05:05 +0000 (UTC) Received: from jre-mbp.elischer.org (c-67-180-24-15.hsd1.ca.comcast.net [67.180.24.15]) (authenticated bits=0) by vps1.elischer.org (8.14.5/8.14.5) with ESMTP id q6K54mxL015876 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Thu, 19 Jul 2012 22:04:51 -0700 (PDT) (envelope-from julian@freebsd.org) Message-ID: <5008E6EC.2040504@freebsd.org> Date: Thu, 19 Jul 2012 22:04:44 -0700 From: Julian Elischer User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:13.0) Gecko/20120614 Thunderbird/13.0.1 MIME-Version: 1.0 To: Matthew Jacob References: <3CE55F29-A5B2-44A7-8854-1ED38BAE6F16@FreeBSD.org> <50075072.5050906@gmail.com> <500752CD.9030107@feral.com> In-Reply-To: <500752CD.9030107@feral.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-arch@freebsd.org Subject: Re: aio in GENERIC? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Jul 2012 05:05:05 -0000 On 7/18/12 5:20 PM, Matthew Jacob wrote: > What practically does aio offer that is not achieved via pthreads > other than slightly simpler code? the ability to run posix aio code? > _______________________________________________ > freebsd-arch@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-arch > To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org" > From owner-freebsd-arch@FreeBSD.ORG Fri Jul 20 07:27:53 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6EFBF106566B for ; Fri, 20 Jul 2012 07:27:53 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-pb0-f54.google.com (mail-pb0-f54.google.com [209.85.160.54]) by mx1.freebsd.org (Postfix) with ESMTP id 416BC8FC08 for ; Fri, 20 Jul 2012 07:27:53 +0000 (UTC) Received: by pbbro2 with SMTP id ro2so6192788pbb.13 for ; Fri, 20 Jul 2012 00:27:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=Hy3L2fsUMOG2m2/cypb1c2iqfhA5en/GIEsyyAo/gkg=; b=zLxNgZ5cdc+2ZzgDFFRba4HQ2uEun37Kkennw6BXAdMhuXHmEpSGg2N5ScRoL58zY7 n0hUUyQTw+JNl2X4l758li8qZSUsfMTYa2H3yy9dPR2rJrwkvfWiJckev7+ZFAE6W+yk sLK8mnigzwrKAmLWcw1QdbndSyICGbErLPUUuxPttPJ5rKSfN18e16AE21quWEsaUvkf 3IbA5qa6XGdX0zuRm898KwCltzINHQuwj0p6DWZfJlGakXSRmXxN8JJlRbNHBI9J2N6x vx9t63M4uYuGwyamNxc4iQNWxxPDIVvPX3NbZ6nKcD5BnkZnbFMOF5Wf/N0pmqO8fkhB /EJA== MIME-Version: 1.0 Received: by 10.68.201.9 with SMTP id jw9mr11583308pbc.28.1342769272790; Fri, 20 Jul 2012 00:27:52 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.68.191.138 with HTTP; Fri, 20 Jul 2012 00:27:52 -0700 (PDT) In-Reply-To: <500830D5.6000409@feral.com> References: <3CE55F29-A5B2-44A7-8854-1ED38BAE6F16@FreeBSD.org> <50075072.5050906@gmail.com> <500752CD.9030107@feral.com> <500830D5.6000409@feral.com> Date: Fri, 20 Jul 2012 00:27:52 -0700 X-Google-Sender-Auth: yKVL3C_SHdVi8L00GT1vruLBj-w Message-ID: From: Adrian Chadd To: mj@feral.com Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-arch@freebsd.org Subject: Re: aio in GENERIC? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Jul 2012 07:27:53 -0000 On 19 July 2012 09:07, Matthew Jacob wrote: > On 7/19/2012 8:58 AM, Adrian Chadd wrote: >> >> .. the API supports the avoidance of copyin/copyout? >> >> > okay, I'll buy that, although I'm not certain of the utility in general of > that. > > The reason I asked was that I have rarely, if ever, run into an AIO > implementation that was more trouble than it was worth. It certainly has > caused major grief in FreeBSD when used with CAM target mode. Because the userland code was wrong, or because supporting it in the kernel for CAM target mode is hard? I used posix AIO for Squid servers. It dropped CPU use quite noticably. Adrian From owner-freebsd-arch@FreeBSD.ORG Fri Jul 20 09:23:41 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D47FC106566B for ; Fri, 20 Jul 2012 09:23:41 +0000 (UTC) (envelope-from tom@invisible-island.net) Received: from vms173009pub.verizon.net (vms173009pub.verizon.net [206.46.173.9]) by mx1.freebsd.org (Postfix) with ESMTP id A550A8FC14 for ; Fri, 20 Jul 2012 09:23:41 +0000 (UTC) Received: from par-debian50-32.jexium-island.net ([unknown] [96.255.140.153]) by vms173009.mailsrvcs.net (Sun Java(tm) System Messaging Server 7u2-7.02 32bit (built Apr 16 2009)) with ESMTPA id <0M7G007P59YDIFA0@vms173009.mailsrvcs.net> for freebsd-arch@freebsd.org; Fri, 20 Jul 2012 03:23:05 -0500 (CDT) Received: from par-debian50-32.jexium-island.net (localhost [127.0.0.1]) by par-debian50-32.jexium-island.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id q6K8N0dH005261 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Fri, 20 Jul 2012 04:23:00 -0400 Received: (from tom@localhost) by par-debian50-32.jexium-island.net (8.14.3/8.14.3/Submit) id q6K8N0gE005259; Fri, 20 Jul 2012 04:23:00 -0400 Date: Fri, 20 Jul 2012 04:23:00 -0400 From: Thomas Dickey To: Warner Losh Message-id: <20120720082300.GA5077@debian50-32.invisible-island.net> References: MIME-version: 1.0 Content-type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary=G4iJoqBmSsgzjUCe Content-disposition: inline In-reply-to: User-Agent: Mutt/1.5.18 (2008-05-17) Cc: FreeBSD-arch Arch Subject: Re: Flex update X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: dickey@his.com List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Jul 2012 09:23:41 -0000 --G4iJoqBmSsgzjUCe Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Jul 19, 2012 at 10:42:15PM -0600, Warner Losh wrote: > Is there some reason that flex has never been updated from 2.4.5a? It depends on what you mean by "updated". The usual answer is the sourceforge project. It's not exactly an "update", since it breaks existing applications, and its maintainer is unwilling to address those problems. Debian for instance has old/new versions. I don't use either - see http://invisible-island.net/reflex/ (earlier this year, Baptiste Daroussin suggested some additional changes to this version, along the lines of the ones I incorporated into byacc). --=20 Thomas E. Dickey http://invisible-island.net ftp://invisible-island.net --G4iJoqBmSsgzjUCe Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAlAJFWQACgkQcCNT4Pfkjtte1QCfbc0B8je4nJfikMCtxrgEO+6o UeEAoJXSTWQWNzlrWbsH8zsbshOMFBY/ =8WCR -----END PGP SIGNATURE----- --G4iJoqBmSsgzjUCe-- From owner-freebsd-arch@FreeBSD.ORG Fri Jul 20 14:59:55 2012 Return-Path: Delivered-To: arch@freebsd.org Received: from mx2.freebsd.org (mx2.freebsd.org [IPv6:2001:4f8:fff6::35]) by hub.freebsd.org (Postfix) with ESMTP id 7DA111065670; Fri, 20 Jul 2012 14:59:55 +0000 (UTC) (envelope-from melifaro@FreeBSD.org) Received: from dhcp170-36-red.yandex.net (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx2.freebsd.org (Postfix) with ESMTP id 48E7C14D85C; Fri, 20 Jul 2012 14:59:54 +0000 (UTC) Message-ID: <500971F1.5070907@FreeBSD.org> Date: Fri, 20 Jul 2012 18:57:53 +0400 From: "Alexander V. Chernikov" User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:13.0) Gecko/20120627 Thunderbird/13.0.1 MIME-Version: 1.0 To: arch@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Gleb Smirnoff Subject: Dynamic Per-cpu allocator X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Jul 2012 14:59:55 -0000 Hello list! It seems it is time to discuss dynamic part of pcpu allocator. We already have great static one, permitting to statically define per-cpu counters/structures in the source code including modules. (Just in case, it uses DPCPU_ macro and resides in sys/sys/pcpu.h) However, this is not enough since there are many non-sigleton objects requiring dynamic per-cpu counters allocations. Networking stack is definitely candidate for using such api (interface counters, netgraph nodes counters, global / per-protocol statistics (it seems existing DPCPU macro can be used for the latter)). My routing performance tests shows, that eliminating contested counters can give quite significant speed improvement. For example, after removing interface counters and IP statistics (~ 11 counters total) forwarding speed increases from 2MPPS (2 millions packets/sec) to 3MPPS. There are more details about this particular test in http://lists.freebsd.org/pipermail/freebsd-net/2012-July/032714.html On the other side, PoC ipfw per-cpu counters implementation shows no observable overhead between enabled/disabled rule counters: http://lists.freebsd.org/pipermail/freebsd-net/2012-July/032824.html Preemption is not disabled here (typically either netisr thread or isr routine is already cpu-bound) Disabling preemption via critical_enter() gives us 80kpps drop (with one counter): http://lists.freebsd.org/pipermail/freebsd-net/2012-July/032835.html It seems that there is no reason in precise accounting for total number of bytes forwarded (or fastforwarded). On the other side, one may want to account interface bytes/packes. So, what do we need for networking stack (from my point of view): 1) Ability to allocate single pcpu counter (various ng* nodes) 2) Ability to allocate arbitrary structures (per-VNET protocol statistics) 3) Ability to allocate either contiguous linear pool for objects or uma-like allocation (per-interface counters) 4) Ability to use either fast (non-protected) or precise updating What others do: I've found nothing related in OpenSolaris and DragonFly (maybe someone?) Good observation of Linux API: http://www.makelinux.net/ldd3/chp-8-sect-5 Proposed API (not even a draft, just to start discussion with something): We already have DPCPU_ macro for "static" data, but I'm not sure if we can keep the same names for dynamic data. We can add 1) * DPCPU_ALLOC_CNTR() * DPCU_FREE_CNTR() (not sure if existing DPCPU_ macro can be used) 2 + 3) /* * Allocate structure (or several items) of total size "size" with * given alignment "align" and malloc flags "flags. * Returns: * array of pointers (with mp_maxid or MAXCPU size) to per-cpu data: +------------------------------------------- |pcpu0 pcpu1 pcpu2 pcpu3 .pcpuN.. +------------------------------------------- + + + + +------+ +------+ +------+ +------+ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | +------+ +------+ +------+ +------+ */ (void *) DPCPU_ALLOC(size_t size, int align, int flags) DPCPU_FREE(void *) /* * Returns typed pointer to per-cpu data block. * Disables preemption */ type *DPCPU_GET(void *, type) /* * Enables preemption again */ DPCPU_PUT(void *) /* * Returns typed pointer to per-cpu data block without * disabling preemption */ DPCPU_GET_FAST(void *, type) DPCPU_PUT_FAST(void *) /* No-op */ /* * Get remote cpu value */ DPCPU_GET_REMOTE(void *, type, index) /* Use CPU_FOREACH for summary */ -- WBR, Alexander From owner-freebsd-arch@FreeBSD.ORG Fri Jul 20 19:02:40 2012 Return-Path: Delivered-To: arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 3A408106566B; Fri, 20 Jul 2012 19:02:40 +0000 (UTC) (envelope-from jilles@stack.nl) Received: from mx1.stack.nl (relay04.stack.nl [IPv6:2001:610:1108:5010::107]) by mx1.freebsd.org (Postfix) with ESMTP id C1C908FC0C; Fri, 20 Jul 2012 19:02:39 +0000 (UTC) Received: from snail.stack.nl (snail.stack.nl [IPv6:2001:610:1108:5010::131]) by mx1.stack.nl (Postfix) with ESMTP id DD3C91DD45A; Fri, 20 Jul 2012 21:02:38 +0200 (CEST) Received: by snail.stack.nl (Postfix, from userid 1677) id B60442847B; Fri, 20 Jul 2012 21:02:38 +0200 (CEST) Date: Fri, 20 Jul 2012 21:02:38 +0200 From: Jilles Tjoelker To: davidxu@FreeBSD.org Message-ID: <20120720190238.GA90393@stack.nl> References: <3CE55F29-A5B2-44A7-8854-1ED38BAE6F16@FreeBSD.org> <50075072.5050906@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <50075072.5050906@gmail.com> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: George Neville-Neil , arch@FreeBSD.org Subject: Re: aio in GENERIC? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Jul 2012 19:02:40 -0000 On Thu, Jul 19, 2012 at 08:10:26AM +0800, David Xu wrote: > On 2012/7/18 22:43, George Neville-Neil wrote: > > I was wondering why aio is not yet in GENERIC. Now that it's > > properly locked and all. > I think one of the problem in the AIO code is it allows user code to > pass pipe, socket and other file handles to kernel, however it may > not work well, the AIO threads may be blocked forever. I suggest to > disable support for socket or pipe except normal file or disk device. Yes, there seems to be an implicit assumption in the POSIX spec that AIO is only used on "fast" devices. There is no mention how a request should be cancelled that has already partially committed, such as a large write on a blocking socket, and there is text in the aio_cancel() description suggesting that it can only remove queued requests: ] The value AIO_NOTCANCELED shall be returned if at least one of the ] requested operation(s) cannot be canceled because it is in progress. An implementation might take more liberty with the cancellation implicit in exec or exit (because status need not be returned) but the FreeBSD implementation does not. Ideally, aio_cancel() and exec/exit would abort operations in progress at least in all situations where a signal would interrupt a corresponding blocking call. Additionally, it may be helpful for very large requests that need to be split up, not to start new I/O requests for parts that have not been started yet (probably only for exec/exit). The code only considers an operation on a socket "in progress" if the socket buffer has had some data/space but this is insufficient because another operation might use up that before this one starts and a large blocking write may not fit into the socket buffer at once. > it should either fully support it or do not support it at all, not > half-baked. Agreed. The current code may get stuck indefinitely if an operation blocks indefinitely. Depending on what applications actually use this, you could try failing with [EOPNOTSUPP] if aio_read/aio_write/aio_fsync is attempted on an unsupported file type. -- Jilles Tjoelker From owner-freebsd-arch@FreeBSD.ORG Sat Jul 21 15:26:41 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E740A106564A for ; Sat, 21 Jul 2012 15:26:41 +0000 (UTC) (envelope-from rmh.aybabtu@gmail.com) Received: from mail-yw0-f54.google.com (mail-yw0-f54.google.com [209.85.213.54]) by mx1.freebsd.org (Postfix) with ESMTP id A17CA8FC15 for ; Sat, 21 Jul 2012 15:26:41 +0000 (UTC) Received: by yhfs35 with SMTP id s35so5536594yhf.13 for ; Sat, 21 Jul 2012 08:26:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=EGX/vWF9A8E73wKaweaOraebUcH1thlG+HaCFtuOtzQ=; b=o5Vf0G5is/fee9DxQyXzjnaAcaQLy3onag8Zjn9jfRFJaV+YYpwwjy+Lx9SzuckhkA 4wgHnEADGJNguBGanE54KSaqauq9QzC+JSZBeNtmrVB8N2Z61UdtZzW5cK4GURX+UC/k PvcSNywv8nrn6EEIEvanoDm7HVo/b/C7msj7x9QanRjxLX8fClcBGYjbUbAy/O/IQ2vX 4l0yfitiFeWggvfsTpYihmShq6meBejIOhaz4iABF3Cu3gfenpIczpyF8pZt+vgi2YgF OvlwKiWjdJW6/HWdmAdVagFc/Vw7KQw+kSz0WA6Iwr5Pu05bjdFHRlQz086SCUBgMvl7 12hw== MIME-Version: 1.0 Received: by 10.43.106.1 with SMTP id ds1mr5626886icc.24.1342884399825; Sat, 21 Jul 2012 08:26:39 -0700 (PDT) Sender: rmh.aybabtu@gmail.com Received: by 10.42.136.7 with HTTP; Sat, 21 Jul 2012 08:26:39 -0700 (PDT) In-Reply-To: <20120626063017.D05DA58081@chaos.jnpr.net> References: <20120626063017.D05DA58081@chaos.jnpr.net> Date: Sat, 21 Jul 2012 17:26:39 +0200 X-Google-Sender-Auth: CtWAIGD6mCLN80CyX_egizQL254 Message-ID: From: Robert Millan To: Simon Gerraty Content-Type: text/plain; charset=UTF-8 Cc: freebsd-arch@freebsd.org Subject: Re: Allow user install X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Jul 2012 15:26:42 -0000 2012/6/26 Simon Gerraty : > The patch below is a step towards supporting unprivileged buildworld > etc. Eg. > > $ cd bin/cat > $ make -n install DESTDIR=/tmp > install -s -o root -g wheel -m 555 cat /tmp/bin > install -o root -g wheel -m 444 cat.1.gz /tmp/usr/share/man/man1 > $ make -n install -DWITHOUT_INSTALL_OWN DESTDIR=/tmp > install -s -m 555 cat /tmp/bin > install -m 444 cat.1.gz /tmp/usr/share/man/man1 > $ Just FYI, Debian archieves this in a very different approach: it uses the fakeroot tool to fool the makefiles into creating "fake" ownerships. This has the advantage that it works for any sort of extraneous makefiles, not just for your own build system: http://fakeroot.alioth.debian.org/ I notice that FreeBSD integrates external build systems into its own, although this practice is a lot less common than it is for Debian. Perhaps you find fakeroot (or the idea behind it) useful... -- Robert Millan From owner-freebsd-arch@FreeBSD.ORG Sat Jul 21 17:15:07 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 46E39106566C; Sat, 21 Jul 2012 17:15:07 +0000 (UTC) (envelope-from tim@kientzle.com) Received: from monday.kientzle.com (99-115-135-74.uvs.sntcca.sbcglobal.net [99.115.135.74]) by mx1.freebsd.org (Postfix) with ESMTP id 1AB2C8FC12; Sat, 21 Jul 2012 17:15:06 +0000 (UTC) Received: (from root@localhost) by monday.kientzle.com (8.14.4/8.14.4) id q6LHExSS091482; Sat, 21 Jul 2012 17:14:59 GMT (envelope-from tim@kientzle.com) Received: from [192.168.2.143] (CiscoE3000 [192.168.1.65]) by kientzle.com with SMTP id dqn7n7dpb6j8ehb2wkznprg33a; Sat, 21 Jul 2012 17:14:59 +0000 (UTC) (envelope-from tim@kientzle.com) Mime-Version: 1.0 (Apple Message framework v1278) Content-Type: text/plain; charset=us-ascii From: Tim Kientzle In-Reply-To: Date: Sat, 21 Jul 2012 10:14:57 -0700 Content-Transfer-Encoding: 7bit Message-Id: References: <20120626063017.D05DA58081@chaos.jnpr.net> To: Robert Millan X-Mailer: Apple Mail (2.1278) Cc: freebsd-arch@freebsd.org, Simon Gerraty Subject: Re: Allow user install X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Jul 2012 17:15:07 -0000 On Jul 21, 2012, at 8:26 AM, Robert Millan wrote: > 2012/6/26 Simon Gerraty : >> The patch below is a step towards supporting unprivileged buildworld >> etc. Eg. >> >> $ cd bin/cat >> $ make -n install DESTDIR=/tmp >> install -s -o root -g wheel -m 555 cat /tmp/bin >> install -o root -g wheel -m 444 cat.1.gz /tmp/usr/share/man/man1 >> $ make -n install -DWITHOUT_INSTALL_OWN DESTDIR=/tmp >> install -s -m 555 cat /tmp/bin >> install -m 444 cat.1.gz /tmp/usr/share/man/man1 >> $ > > Just FYI, Debian archieves this in a very different approach: it uses > the fakeroot tool to fool the makefiles into creating "fake" > ownerships. This has the advantage that it works for any sort of > extraneous makefiles, not just for your own build system: > > http://fakeroot.alioth.debian.org/ > > I notice that FreeBSD integrates external build systems into its own, > although this practice is a lot less common than it is for Debian. > Perhaps you find fakeroot (or the idea behind it) useful... Does fakeroot itself require root permissions to run? I was under the impression that it used some form of loopback mount which --- at least in FreeBSD --- still requires root permissions. Tim