From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id oNFWDzqQPmXuZgAAG6o9tA:P1 (envelope-from ) for ; Sun, 29 Oct 2023 18:02:50 +0100 Received: from aspmx1.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id oNFWDzqQPmXuZgAAG6o9tA (envelope-from ) for ; Sun, 29 Oct 2023 18:02:50 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id CB717312E2 for ; Sun, 29 Oct 2023 18:02:49 +0100 (CET) Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b="a/RuwpJb"; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1698598970; a=rsa-sha256; cv=none; b=ZX368Pdkxa9FVOl0RZw5FnLET3GHEqD6ElMpSlY4tMgmV0ObGsDHyowOXadlpzB43Lcyb/ 4/u7ik9IFEa5k6HwxK8MPU8m3Ph2fxe4c1gdwlkFlc2y1YUzc5xdpeEmIefSSsJ078pa+0 zd4uUlscBBvtTxvAlfOqGyn4S5TQqEzF/UBmIEt4etee0VkcEGd3h1B9/m+gzKDdhAlAWL GZ13Ddos+2jdEBCI7MunHIKTB5friTelJ++J0BNfFTSbVETXRlqq0B73ZsQRX9PixmP27Q WLRrrzEYF4pOgDSj3M1EFgaz8GAs55EqaFkGdA1trIKd0IGQxpQnrrwtEj7kOg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b="a/RuwpJb"; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1698598970; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=RcMXtz0gXC9Q/I9/czPuwjPCxJCe6V1bjenF0BUlAos=; b=VG/GK034Os8l40K32twpXzzfyFELRN3boUGY9WcOTRmto/MSKjIFu2Gus73nBhxqBLKxPl RO88nTQ7nTsC4t1jtwjQ7LYz90zXUEAKJzK+1QunG6yFOjKOsVqRqVq36Tcp4IRRu5IQQF 0MjI7IyQbi/k341PpVOM93wLJkPTzz2ayZBROVmuDto0bfNPQ83bTWAO5KuFEFIAOIwlrS SKxnyfBxlz/b6eavDc5uHMF6dbRK9dQ31gZcpKRb3j+I6XqMg1YxzHOEaaUWweRuQyo2Ga GXoKfhhZHp3ne6cH+Tc1LmK6ZRWmz0i/Kc+ycXLmIBkFu5k9GpcDS9m95+QfxA== Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qx9BH-0002LI-T6; Sun, 29 Oct 2023 13:02:31 -0400 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 1qx9BG-0002L9-Mx for bug-guix@gnu.org; Sun, 29 Oct 2023 13:02:31 -0400 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 1qx9BG-0008Hd-3v for bug-guix@gnu.org; Sun, 29 Oct 2023 13:02:30 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qx9Bm-00008z-9s for bug-guix@gnu.org; Sun, 29 Oct 2023 13:03:02 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#63412: Topological sorting in cuirass Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Sun, 29 Oct 2023 17:03:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 63412 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Andreas Enge Cc: 63412@debbugs.gnu.org Received: via spool by 63412-submit@debbugs.gnu.org id=B63412.1698598926472 (code B ref 63412); Sun, 29 Oct 2023 17:03:02 +0000 Received: (at 63412) by debbugs.gnu.org; 29 Oct 2023 17:02:06 +0000 Received: from localhost ([127.0.0.1]:43271 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qx9As-00007W-9h for submit@debbugs.gnu.org; Sun, 29 Oct 2023 13:02:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:44164) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qx9Ao-00006t-60 for 63412@debbugs.gnu.org; Sun, 29 Oct 2023 13:02:04 -0400 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 1qx9AB-0008Ek-C1; Sun, 29 Oct 2023 13:01:23 -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=RcMXtz0gXC9Q/I9/czPuwjPCxJCe6V1bjenF0BUlAos=; b=a/RuwpJbfRtQGFVVXHmc xY+LGw+02ja9N8wLsv6rDbK9kZiDs52dbO1sJlhUZywNuVcmdkTWWTFV/QJWl7hoVfNYccZnNJ84s ZW2MvH1ge+tpF1H6c1m/xilC5xEOzCNZk6iYdLMfTsSzM9WO/vk3zBLNV3jYjaVTDtCk/B613OEtk Ne5FYpduJNtlJ0HPIpRk7Y8MXH/Oupm0sddBFLhHKTtdk+3Q22E3a/4K3A0x9hz/HvN02xtejldy+ 6dMGocEWdAJ7WJGZs4wbM4hCW1D+7srp0BVSDamaGmibcDiLbP2E2Sc4/MpTAu3r919ffyuUJpoLM cgxQn5pieq5uRQ==; From: Ludovic =?UTF-8?Q?Court=C3=A8s?= In-Reply-To: (Andreas Enge's message of "Wed, 10 May 2023 12:06:28 +0200") References: Date: Sun, 29 Oct 2023 18:01:20 +0100 Message-ID: <87jzr5747z.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: bug-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Queue-Id: CB717312E2 X-Migadu-Scanner: mx12.migadu.com X-Migadu-Spam-Score: -6.57 X-Spam-Score: -6.57 X-TUID: GqYZIvYtsDwc Hi, Andreas Enge skribis: > This is a wishlist bug, but it is important for architectures where we > are currently short on build power, and where this issue can stall builds > and waste an arbitrary amount of build power. > > Cuirass should sort builds and only offload derivations for which all > inputs are available. Cuirass has two build backends: talking to the build daemon, and using the ZeroMQ-based =E2=80=9Cremote worker=E2=80=9D protocol. In practice we = use the latter, which fixes scalability issues with the former. The worker protocol implements work stealing: workers periodically send messages to =E2=80=9Cremote server=E2=80=9D asking for work. Said server r= eplies with a derivation for one of the systems the worker supports; that derivation is chosen among the =E2=80=9Cbuilds=E2=80=9D whose dependencies have all be= en successfully built. And here=E2=80=99s the trick: the server is doing the right thing, but it h= as a partial view. Namely, the server sees =E2=80=9Cbuilds=E2=80=9D rather than =E2=80=9Cderivations=E2=80=9D. =E2=80=9CBuilds=E2=80=9D are the things exp= licitly declared in the jobset. If you have a declared build for GCC, but no build for MPC and MPFR, then the server will consider that GCC has zero non-built dependencies, even though MPFR and MPC may still need to be built. Having =E2=80=98remote-worker=E2=80=99 operate on derivations rather than b= uilds would address this impedance mismatch, though there are complications (there are bits of the database schema that amalgamate build/derivation). Food for thought! Ludo=E2=80=99.