After the commit "fork: lock VMAs of the parent process when forking" in [1], the compilation time increases from ~2 minutes to 8.5 minutes when enabling CONFIG_DEBUG_INFO* (CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT/CONFIG_DEBUG_INFO_DWARF4/CONFIG_DEBUG_INFO_DWARF5).
Looking at the commit changes, not sure why it causes the increase in compilation time. Any ideas?
From:
# time make -j
real 1m51.522s
user 59m55.836s
sys 5m29.177s
Increase to:
# time make -j
real 8m31.967s
user 69m24.410s
sys 5m54.588s
Note, compile time above with ARCH=riscv, defconfig + CONFIG_DEBUG_INFO_DWARF4.
[1]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=2b4f3b4987b56365b981f44a7e843efa5b6619b9