From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Noah Lavine Newsgroups: gmane.lisp.guile.devel Subject: =?windows-1252?Q?Re=3A_=5BPATCH=5D_Bindings_for_=91sendfile=92?= Date: Thu, 21 Mar 2013 11:39:53 -0400 Message-ID: References: <87ip4liufs.fsf@gnu.org> <8738vp3yhe.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=047d7bd7646e94d09a04d871271b X-Trace: ger.gmane.org 1363880428 15520 80.91.229.3 (21 Mar 2013 15:40:28 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 21 Mar 2013 15:40:28 +0000 (UTC) Cc: guile-devel To: =?ISO-8859-1?Q?Ludovic_Court=E8s?= Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Thu Mar 21 16:40:48 2013 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1UIhbg-0004qs-IR for guile-devel@m.gmane.org; Thu, 21 Mar 2013 16:40:44 +0100 Original-Received: from localhost ([::1]:56278 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UIhbJ-0005Wx-9O for guile-devel@m.gmane.org; Thu, 21 Mar 2013 11:40:21 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:33155) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UIhbE-0005Wr-If for guile-devel@gnu.org; Thu, 21 Mar 2013 11:40:18 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UIhbC-0004pf-Rc for guile-devel@gnu.org; Thu, 21 Mar 2013 11:40:16 -0400 Original-Received: from mail-pb0-f42.google.com ([209.85.160.42]:50078) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UIhbC-0004pa-LD; Thu, 21 Mar 2013 11:40:14 -0400 Original-Received: by mail-pb0-f42.google.com with SMTP id xb4so2335017pbc.29 for ; Thu, 21 Mar 2013 08:40:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=9KbaxT9NLwSpH7aLjzwuVI/3gXe2UzCv1hq9tXInQBk=; b=v5whatLjoCbgxyw4bq/zwdl2u1nZ4UJ3NppJWy9uKVkdiNlWyOptm/RHknj8zzdWwz mOdxbNZhCNvMBAML0ERgyLhdz1cOaJdrwz37UrXsbeTdX18LahO500++xmnE1vqwrluh wkd45ad2a8qzMVWr/64Z1d+yWZmlxCgE/t51ql1sj/ilM7lTMurGlkWU8QTM87XibjiG ZpjjlM3RHEQZCNGv6QO2G5IBJ1w+o7cgUIWBZxv1LO2kYxLl73DPET6NCIFUUtXxOGU/ /1zNFQZR6RUjSRi/DxdSdMMFb3A71bQ7IbZNMjDmDOHUIUSdMSxvs8Go6+IOzQ4icPEN avCA== X-Received: by 10.68.184.33 with SMTP id er1mr15754288pbc.151.1363880413808; Thu, 21 Mar 2013 08:40:13 -0700 (PDT) Original-Received: by 10.68.157.42 with HTTP; Thu, 21 Mar 2013 08:39:53 -0700 (PDT) In-Reply-To: <8738vp3yhe.fsf@gnu.org> X-Google-Sender-Auth: 7yyOIMsBJWifpyW6V3ppBhoKUfE X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 209.85.160.42 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:15956 Archived-At: --047d7bd7646e94d09a04d871271b Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Hello, Yes, you're completely right - making it work on all platforms is much better than what I had proposed. I'm glad you're doing this. Thanks, Noah On Thu, Mar 21, 2013 at 5:15 AM, Ludovic Court=E8s wrote: > Hi Noah, > > Noah Lavine skribis: > > > I've thought for a while that if I had time (which I know I won't) I > would > > make a module called (linux) with bindings for non-POSIX Linux kernel > > features. What do you think of this idea? If so, what do you think of > > putting sendfile there and expanding it with other functions as we need > > them? > > I=92ve thought about it, but ended up with making sendfile work whether o= r > not the syscall is available (just like glibc does, after all). > > So for this particular case, I=92d rather keep it in the global name > space. There=92s also the untold argument that even if sendfile(2) is > unavailable, the loop written in C is going to be faster than the > equivalent bytecode. > > FWIW, I plan to integrate the Linux bindings I wrote for =93boot-to-Guile= =94 > eventually: > > > http://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/patches/guile= -linux-syscalls.patch > > These are not defined in POSIX, but apart from the Linux module > syscalls, they (that is, mount(2) and the networking ioctls) happen to > be supported by glibc on all 3 kernels, and also by other libcs. Thus, > I=92d rather keep them in the global name space as well. > > WDYT? > > Thanks, > Ludo=92. > --047d7bd7646e94d09a04d871271b Content-Type: text/html; charset=windows-1252 Content-Transfer-Encoding: quoted-printable
Hello,

Yes, you're completely right - maki= ng it work on all platforms is much better than what I had proposed. I'= m glad you're doing this.

Thanks,
Noah


On Thu, Mar 21, 2013 at 5:15 AM, Ludovic= Court=E8s <ludo@gnu.org> wrote:
noah.b.lavine@gm= ail.com> skribis:

> I've thought for a while that if I had time (which I know I won= 9;t) I would
> make a module called (linux) with bindings for non-POSIX Linux kernel<= br> > features. What do you think of this idea? If so, what do you think of<= br> > putting sendfile there and expanding it with other functions as we nee= d
> them?

I=92ve thought about it, but ended up with making sendfile work wheth= er or
not the syscall is available (just like glibc does, after all).

So for this particular case, I=92d rather keep it in the global name
space. =A0There=92s also the untold argument that even if sendfile(2) is unavailable, the loop written in C is going to be faster than the
equivalent bytecode.

FWIW, I plan to integrate the Linux bindings I wrote for =93boot-to-Guile= =94
eventually:

=A0 http://git.savannah.g= nu.org/cgit/guix.git/tree/gnu/packages/patches/guile-linux-syscalls.patch

These are not defined in POSIX, but apart from the Linux module
syscalls, they (that is, mount(2) and the networking ioctls) happen to
be supported by glibc on all 3 kernels, and also by other libcs. =A0Thus, I=92d rather keep them in the global name space as well.

WDYT?

Thanks,
Ludo=92.

--047d7bd7646e94d09a04d871271b--