3 ms·
Reversing the arrows looks pretty silly at first, but apparently the idea is that if you start with the files that changed, you can read partial dependency grap
by skybrian 12y ago
Reversing the arrows looks pretty silly at first, but apparently the idea is that if you start with the files that changed, you can read partial dependency graphs and start building any downstream dependencies that changed before the entire build graph is loaded. If you start from the top down, you have to load and compute the entire dependency graph up front.
This will matter for large build systems where just loading the build files takes significant time. Another way to solve it is just to make loading the build file very fast so that it's a non-issue, which is what ninja [1] does.
Apparently there's some influence: "There are many other build systems that are more user-friendly or featureful than Ninja itself. For some recommendations: the Ninja author found the tup build system influential in Ninja’s design, and thinks redo's design is quite clever." [2]
[1] http://martine.github.io/ninja/ http://martine.github.io/ninja/
[2] http://martine.github.io/ninja/manual.html http://martine.github.io/ninja/manual.html
- dima55 12y agoEvery time tup comes up, there's a question I have that nobody seems to know the answer to: how does tup know what changed? Make does this by starting from what it needs to build (which it knows) and traversing the dependencies. Does tup have some sort of daemon that monitors the file system? What if the file system isn't local (NFS, say)?
- foxhill 12y agoi don't know for certain but i'd guess at; for each file specified in tupfile is target output file's creation date older than input file's last modified date? yes -> build, no -> skip.
- xt 12y agoIt uses inotify for file systems that supports it.
- deleted 12y ago[deleted]
- dima55 12y agoSo then it DOES have a daemon? Have you actually tried it? And inotify doesn't work over NFS.
- deleted 12y ago[deleted]
- mbq 12y agoYou can have a daemon (tup monitor), but it is not required; in the second case tup will compare last-mod times of files with those from the last run (stored in the .tup dir).
- dima55 12y agoThank you!