[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Automake-NG] Idea: Inverse sort re-builds by time
From: |
Bob Friesenhahn |
Subject: |
[Automake-NG] Idea: Inverse sort re-builds by time |
Date: |
Fri, 31 Aug 2012 14:21:25 -0500 (CDT) |
User-agent: |
Alpine 2.01 (GSO 1266 2009-07-14) |
Given the mention of 'sort' in another thread, I would like to mention
something that I have thought about for some time. When one does
parallel builds on systems with many cores (particularly slow cores),
the time to complete a build is improved if build products which take
a long time are done first and ones which complete quickly are done
last. Most importantly, a really slow compilation/link should not be
scheduled last if at all possible. The reason for this is that all
other objects may have already been compiled while one or two last
objects which are slow to compile or link are still completing.
Linking may be I/O bound and take a long time while leaving plenty of
CPU for other compilations.
The thought is that if the time to build each component is captured
and saved, then subsequent builds can be done in inverse order of
build times (by listing them in that order), subject to build
dependencies. This could even be codified in the makefiles in the
distribution tarball.
The benefits would be greatest for non-recursive builds where all of
the targets may be scheduled at once (modified by explicit
dependencies) by one make process.
The maximum possible benefit would be determined by the slowest build
product (if it had been scheduled to start last).
Thoughts?
Bob
--
Bob Friesenhahn
address@hidden, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer, http://www.GraphicsMagick.org/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Automake-NG] Idea: Inverse sort re-builds by time,
Bob Friesenhahn <=