diff options
author | Sergii Dmytruk <sergii.dmytruk@3mdeb.com> | 2024-06-14 11:56:07 +0300 |
---|---|---|
committer | Felix Singer <service+coreboot-gerrit@felixsinger.de> | 2024-07-05 12:55:49 +0000 |
commit | 1ad9c32ae36d783792027a45c4dfe71c66137bd2 (patch) | |
tree | 42300bca720e634aac5c87bd8988fd2579c6f038 | |
parent | 282d647a0cd3304197fda967609b6f270b1f17f5 (diff) |
payloads/external: don't prevent parallel build of iPXE
When starting a nested instance Make communicates information on the
number of jobs and how to synchronize difference instances via MAKEFLAGS
variable. Explicitly overwriting it when invoking
payloads/external/iPXE/Makefile ends up forcing serial build of iPXE.
iPXE builds hundreds of files and its dependency generation is done
separately from compilation making the whole process take couple minutes
on a single CPU (which becomes several seconds if large enough number of
CPUs is available).
iPXE seems to have Make-based build system that has no problems with
parallel build and not utilizing that effectively turns it into a
bottleneck when building a coreboot image in parallel.
It's unclear whether MAKEFLAGS= was even added for any particular
purpose. It doesn't prevent child instances from using variables of
parents, nor it prevents child instance from running in parallel
(because it's still passed as an environment variable that's processed
prior of variable assignments on command-line), but it does prevent
grandchild instance from running in parallel (actual iPXE's Makefile).
MFLAGS contains flags from MAKEFLAGS and isn't used implicitly by Make,
so no need to clear it either because iPXE doesn't use it.
Change-Id: Iac00e2f86d160793d3217e00ddc5012202b3196a
Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/83081
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de>
Reviewed-by: Krystian Hebel <krystian.hebel@3mdeb.com>
-rw-r--r-- | payloads/external/Makefile.mk | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/payloads/external/Makefile.mk b/payloads/external/Makefile.mk index 4a17791052..73b600b2bb 100644 --- a/payloads/external/Makefile.mk +++ b/payloads/external/Makefile.mk @@ -381,8 +381,7 @@ payloads/external/iPXE/ipxe/ipxe.rom ipxe: $(DOTCONFIG) $(IPXE_CONFIG_SCRIPT) CONFIG_HAS_SCRIPT=$(CONFIG_IPXE_ADD_SCRIPT) \ CONFIG_IPXE_NO_PROMPT=$(CONFIG_IPXE_NO_PROMPT) \ CONFIG_IPXE_HAS_HTTPS=$(CONFIG_IPXE_HAS_HTTPS) \ - CONFIG_PXE_TRUST_CMD=$(CONFIG_PXE_TRUST_CMD) \ - MFLAGS= MAKEFLAGS= + CONFIG_PXE_TRUST_CMD=$(CONFIG_PXE_TRUST_CMD) # LinuxBoot LINUXBOOT_CROSS_COMPILE_ARCH-$(CONFIG_LINUXBOOT_X86) = x86_32 |