From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Newsgroups: gmane.lisp.guile.bugs Subject: bug#68504: [PATCH v3] Add copy-on-write support to scm_copy_file. Date: Thu, 21 Mar 2024 15:23:33 +0100 Message-ID: <87a5mrvf2y.fsf@gnu.org> References: <20240116124817.14680-1-~@wolfsden.cz> <20240124191607.3571-1-~@wolfsden.cz> <878r2nmwf9.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20840"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 68504@debbugs.gnu.org To: Tomas Volf <~@wolfsden.cz> Original-X-From: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Thu Mar 21 15:47:44 2024 Return-path: Envelope-to: guile-bugs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rnJhn-0005HQ-WA for guile-bugs@m.gmane-mx.org; Thu, 21 Mar 2024 15:47:44 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rnJhU-0007nl-F0; Thu, 21 Mar 2024 10:47:24 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rnJhS-0007nG-RJ for bug-guile@gnu.org; Thu, 21 Mar 2024 10:47:22 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rnJhS-0007Ei-IN for bug-guile@gnu.org; Thu, 21 Mar 2024 10:47:22 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rnJi6-00016G-4T for bug-guile@gnu.org; Thu, 21 Mar 2024 10:48:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: bug-guile@gnu.org Resent-Date: Thu, 21 Mar 2024 14:48:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68504 X-GNU-PR-Package: guile X-GNU-PR-Keywords: patch Original-Received: via spool by 68504-submit@debbugs.gnu.org id=B68504.17110324574190 (code B ref 68504); Thu, 21 Mar 2024 14:48:02 +0000 Original-Received: (at 68504) by debbugs.gnu.org; 21 Mar 2024 14:47:37 +0000 Original-Received: from localhost ([127.0.0.1]:37041 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rnJhh-00015W-5s for submit@debbugs.gnu.org; Thu, 21 Mar 2024 10:47:37 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:37140) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rnJhc-00015B-13 for 68504@debbugs.gnu.org; Thu, 21 Mar 2024 10:47:35 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rnJKR-00023s-Ux; Thu, 21 Mar 2024 10:23:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To: From; bh=DQy3sROtmG3NMr+dAW3aLwmyBkd91K4IVd0ILpRRTJA=; b=GGm+XCBBP4DpAZkk6p4b Y8RQ6BiZkT+ODkcZ/FTRXN0MM7kbSZptlYVNiovYpmeipptGBK3JDJQLyxvAHBIqkUXteeZNN/B4A JHoa5VlavT8jVfJb9ahbottjmlL3KhJIp/q568+yraGViYeS0YE54Y1sr1SIdeIQEb+bNh2hiG5a0 l6e+nO0EcrH4Ssq3DJ8FCy7hxRkVY6AyCQv7uZAG0PMW2rPSUHpFlq6LzYWCq7YmIV5DY1RmU6uRx USvlN+kDMmtq7JAVILHFkz2x9aZtrhvgPMF6XJJ46PkE3oud7GJsvKovg1QKb4v4yU6jaHLL795Uv A3mIE6KsrN0COA==; In-Reply-To: (Tomas Volf's message of "Wed, 13 Mar 2024 00:19:24 +0100") X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: Duodi 2 Germinal an 232 de la =?UTF-8?Q?R=C3=A9volution, ?= jour du Platane X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guile@gnu.org List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Original-Sender: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.lisp.guile.bugs:10797 Archived-At: Hi, Tomas Volf <~@wolfsden.cz> skribis: > Sure, I am willing to do my part. I managed to find this blog post[0], s= o after > some minor troubles I did manage to get a VM with GNU/Hurd running. Next= I will > read up on copy_file_range and try to put together a patch. It=E2=80=99s really just (service hurd-vm-service-type) on Guix System: https://guix.gnu.org/manual/devel/en/html_node/Virtualization-Services.ht= ml#The-Hurd-in-a-Virtual-Machine > Just to make sure, your idea here is exactly what? Always try to use > copy_file_range before the regular copy? So the flow would be > > For 'always case: > > CoW ---fail--> FAIL > > For 'auto case: > > CoW ---fail--> copy_file_range ---fail--> current copy ---fail--= > FAIL > > For 'never case: > > copy_file_range ---fail--> current copy ---fail--> FAIL > > Is that an accurate summary? Yes, that=E2=80=99s exactly what I had in mind. Actually it might be better to use sendfile(2), which is slightly less generic but otherwise equivalent AFAICS, and which happens to have a Hurd implementation in glibc. Thanks for your help! Ludo=E2=80=99.