From owner-svn-src-all@freebsd.org Thu Sep 17 15:55:06 2020 Return-Path: Delivered-To: svn-src-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 540323E50A2 for ; Thu, 17 Sep 2020 15:55:06 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qt1-x832.google.com (mail-qt1-x832.google.com [IPv6:2607:f8b0:4864:20::832]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BshPP2HLrz4CQr for ; Thu, 17 Sep 2020 15:55:05 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qt1-x832.google.com with SMTP id n10so2261141qtv.3 for ; Thu, 17 Sep 2020 08:55:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=iWF4cX0WNcvfsQb+S2VhetJhPFx8aDtcw5UU1WVdhBs=; b=r+5R2O7NERewbxBQ2tzF6sXGEY6lTUQvNpFMZbG41yOIzDBYXGCmfeay9HOupL/e/y tysBJbCmXw03Jn63DVHBclNuh0IwwD06mOSDUotKDujhbA4tpR6NgW+CQdxpSutbFsiQ 3gcJgKTbP8Ln7hOMYVMhbJbnFkHYeG33Ems7AFiSqqscfdwZKQyRooOJAZe/0EpG7efh zsZZIJ4FJCydc2mFwN7mK8cZHfh4OxyEBW/9Odng++v82/UE0FzvyTwfFSs6eSBSVi4R gO6s707Q47azJ64NIyxQKQFzyvcpVGd96cNXT6WIKRCOVZky3cl9XYSQT6MhH4MNzuMT jTRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=iWF4cX0WNcvfsQb+S2VhetJhPFx8aDtcw5UU1WVdhBs=; b=ZWevAsR+f6m2xIT5WDBlePud8kuiu5KWzJYjImy3oGN3qIdwUot6qoXIJDmUczbP2t BfcCIEjC9JoM4rWqOXK6dPSU7xoh875q2HLqZE4ZGsy/uObkARjnpNMgZKhzAK6pYC0s +Uw6f6T3rYh6SLSnQt4LK2XwrJ9gXCnGUyjbN339vmiCQWQSJ/evqRSiZbCBfrDYmcdV LXAgYD5O5/rsvukpbfis3/4+uDJphsnG6/1O8Fc8xP6oqRoNGyBEcFlv9ADuTACRE2ti QEDwYaqS/vvOsnyzA+ZK17vSx5yVl5LkxuFU5ybIYHTKRA55mmvz07fjOFDsLEqHf608 qBtA== X-Gm-Message-State: AOAM531Z/hUrtffoFHIQEUDA1JfH24R86/ExBNLvFBQz0HKhDV99zv2j j3fdwKjMpyR+45Mn1sN0OHpup3+4Ee5t7iStGTSfiFetw9UtYg== X-Google-Smtp-Source: ABdhPJwmkXvsm410Pb0VqMh+BofhhsraLHVOQlA72l6cpvIiKW3q7BzG6MdZElA/q+lWUj35udVy6ngk2vP7FMvoUQQ= X-Received: by 2002:ac8:7388:: with SMTP id t8mr28672311qtp.187.1600358103310; Thu, 17 Sep 2020 08:55:03 -0700 (PDT) MIME-Version: 1.0 References: <202009171507.08HF7Qns080555@repo.freebsd.org> <20200917153843.tZEGn%steffen@sdaoden.eu> In-Reply-To: <20200917153843.tZEGn%steffen@sdaoden.eu> From: Warner Losh Date: Thu, 17 Sep 2020 09:54:52 -0600 Message-ID: Subject: Re: svn commit: r365836 - head/share/mk To: Alex Richardson , src-committers , svn-src-all , svn-src-head X-Rspamd-Queue-Id: 4BshPP2HLrz4CQr X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20150623.gappssmtp.com header.s=20150623 header.b=r+5R2O7N; dmarc=none; spf=none (mx1.freebsd.org: domain of wlosh@bsdimp.com has no SPF policy when checking 2607:f8b0:4864:20::832) smtp.mailfrom=wlosh@bsdimp.com X-Spamd-Result: default: False [-2.35 / 15.00]; ARC_NA(0.00)[]; MAILMAN_DEST(0.00)[svn-src-all]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20150623.gappssmtp.com:s=20150623]; NEURAL_HAM_MEDIUM(-0.96)[-0.961]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[4]; NEURAL_HAM_LONG(-1.00)[-0.998]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[svn-src-all@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20150623.gappssmtp.com:+]; NEURAL_HAM_SHORT(-0.39)[-0.394]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::832:from]; R_SPF_NA(0.00)[no SPF record]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; MIME_TRACE(0.00)[0:+,1:+,2:~]; RCVD_COUNT_TWO(0.00)[2]; RCVD_TLS_ALL(0.00)[]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Sep 2020 15:55:06 -0000 On Thu, Sep 17, 2020 at 9:39 AM Steffen Nurpmeso wrote: > Alex Richardson wrote in > <202009171507.08HF7Qns080555@repo.freebsd.org>: > |Author: arichardson > |Date: Thu Sep 17 15:07:25 2020 > |New Revision: 365836 > |URL: https://svnweb.freebsd.org/changeset/base/365836 > | > |Log: > | Stop using lorder and ranlib when building libraries > | > | Use of ranlib or lorder is no longer necessary with current linkers > | (probably anything newer than ~1990) and ar's ability to create an > object > | index and symbol table in the archive. > | Currently the build system uses lorder+tsort to sort the .o files in > | dependency order so that a single-pass linker can use them. However, > | we can use the -s flag to ar to add an index to the .a file which makes > | lorder unnecessary. > | Running ar -s is equivalent to running ranlib afterwards, so we can > also > | skip the ranlib invocation. > > That ranlib thing yes (for long indeed), but i have vague memories > that the tsort/lorder ordering was also meant to keep the things > which heavily interdepend nearby each other. (Luckily Linux > always had at least tsort available.) > This no longer matters for all the platforms FreeBSD supports? > tsort has no notion of how dependent the modules are, just an order that allows a single pass through the .a file (otherwise you'd need to list the .a file multiple times on the command line absent ranlib). That's the original purpose of tsort. tsort, lsort, and ranlib all arrived in 7th edition unix on a PDP-11, where size was more important than proximity to locations (modulo overlays, which this doesn't affect at all). There were some issues of long vs short jumps on earlier architectures that this helped (since you could only jump 16MB, for example). However, there were workarounds for this issue on those platforms too. And if you have a program that this does make a difference, then you can still use tsort/lorder. They are still in the system. I doubt you could measure a difference here today. I doubt, honestly, that anybody will notice at all. Warner