From mboxrd@z Thu Jan 1 00:00:00 1970 From: zimoun Subject: =?UTF-8?Q?Re=3A_Speeding_up_=E2=80=9Cguix_pull=E2=80=9D=3A_splitting_modules?= Date: Fri, 10 Jan 2020 13:53:38 +0100 Message-ID: References: <87k1657i7j.fsf@elephly.net> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:44462) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iptnU-0007PG-F9 for guix-devel@gnu.org; Fri, 10 Jan 2020 07:53:53 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iptnT-0004pm-8o for guix-devel@gnu.org; Fri, 10 Jan 2020 07:53:52 -0500 Received: from mail-qk1-x733.google.com ([2607:f8b0:4864:20::733]:42417) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iptnT-0004oC-3w for guix-devel@gnu.org; Fri, 10 Jan 2020 07:53:51 -0500 Received: by mail-qk1-x733.google.com with SMTP id z14so1663097qkg.9 for ; Fri, 10 Jan 2020 04:53:51 -0800 (PST) In-Reply-To: List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane-mx.org@gnu.org Sender: "Guix-devel" To: =?UTF-8?Q?G=C3=A1bor_Boskovits?= Cc: Guix Devel Hi G=C3=A1bor, On Fri, 10 Jan 2020 at 13:42, G=C3=A1bor Boskovits wr= ote: > > The modules graph (DAG) is already available. :-) > > The main problem here is that the modules do not form a DAG. > There are circular dependencies between the modules. > If those were not, then modular build would be possible, but because of > the spaghetti we are forced to build these together. Maybe we have a naming problem. :-) I agree that it is not an Acyclic graph and if I understand you correctly it is because there are cycles that the mess starts. Using the Directed properties (but not required in fact, whatever :-), traversing the graph detects the cycle. It is more or less what it is done in the function `guix/import/utils.scm (topological-sort)`. So knowing where the cycles are could help to transform the DaG (not fully acyclic yet) to a DAG. :-) All the best, simon