From: Stefan Sperling Subject: Re: Optimized branch switching? To: Christian Weisgerber Cc: gameoftrees@openbsd.org Date: Tue, 13 Sep 2022 12:34:49 +0200 On Mon, Sep 12, 2022 at 10:45:05PM +0200, Christian Weisgerber wrote: > $ time got up > Already up-to-date > 0m22.21s real 0m04.38s user 0m09.26s system > > It's a slow machine (APU2). > So you're right, it's just the "got update" time. > Looks like "got update" scales with the speed of the underlying > hardware, which isn't that surprising. :-) It is even slower on my APU2, which is running 7.1; hopefully 7.2 will be faster with the mmap speedup that was committed. The attached profile trace graph suggests a bottleneck is in the open() call in get_file_status(). We might be able to work around that somehow. My test results below: $ gotadmin info /git/ports.git | grep ^pack pack files: 1 packed objects: 1750824 packed total size: 507M $ cd /usr/ports/ $ got --version got 0.76-current $ time got update Already up-to-date 0m42.44s real 0m06.59s user 0m11.65s system $ time got update Already up-to-date 0m32.93s real 0m05.60s user 0m10.62s system $ cpu0: AMD GX-412TC SOC, 998.25 MHz, 16-30-01 bios0 at mainbus0: SMBIOS rev. 3.0 @ 0xcfe81040 (13 entries) bios0: vendor coreboot version "v4.16.0.3" date 04/21/2022 bios0: PC Engines apu2 sd0 at scsibus1 targ 0 lun 0: naa.5001b444a44c85f0 sd0: 15272MB, 512 bytes/sector, 31277232 sectors, thin Performance adjustment mode: manual (1000 MHz)