HomeFreeBSD

Speed up *-old-* make targets by using sed instead of xargs

Description

Speed up *-old-* make targets by using sed instead of xargs

Targets like 'list-old-files' used "xargs -n1" to produce a list with
one file per line. Using xargs resulted in one fork+exec for each
Argument, resulting in rather long runtime. Instead, use sed to split
the list. On one machine make list-old-files took 30s wall clock time
with xargs and less than 1s with sed.

Reviewed by: jhb
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D34741

(cherry picked from commit a8267ecc3df0aa633daa56360d67a24f9b1d3961)

Details

Provenance
emasteAuthored on Apr 1 2022, 10:58 PM
Reviewer
jhb
Differential Revision
D34741: Speed up *-old-* make targets by using sed instead of xargs
Parents
rG4fac67126e87: x86: Add defines for workaround bits in AMD's MSR "Decode Configuration"
Branches
Unknown
Tags
Unknown