|
Ninja
|
DependencyScan manages the process of scanning the files in a graph and updating the dirty/outputs_ready state of all the nodes and edges. More...
#include <graph.h>
Public Member Functions | |
| BuildLog * | build_log () const |
| DependencyScan (State *state, BuildLog *build_log, DepsLog *deps_log, DiskInterface *disk_interface, DepfileParserOptions const *depfile_parser_options) | |
| DepsLog * | deps_log () const |
| bool | RecomputeDirty (Node *node, string *err) |
| Update the |dirty_| state of the given node by inspecting its input edge. More... | |
| bool | RecomputeOutputsDirty (Edge *edge, Node *most_recent_input, bool *dirty, string *err) |
| Recompute whether any output of the edge is dirty, if so sets |*dirty|. More... | |
| void | set_build_log (BuildLog *log) |
Private Member Functions | |
| bool | RecomputeDirty (Node *node, vector< Node *> *stack, string *err) |
| bool | RecomputeOutputDirty (Edge *edge, Node *most_recent_input, const string &command, Node *output) |
| Recompute whether a given single output should be marked dirty. More... | |
| bool | VerifyDAG (Node *node, vector< Node *> *stack, string *err) |
Private Attributes | |
| BuildLog * | build_log_ |
| ImplicitDepLoader | dep_loader_ |
| DiskInterface * | disk_interface_ |
DependencyScan manages the process of scanning the files in a graph and updating the dirty/outputs_ready state of all the nodes and edges.
|
inline |
|
inline |
Definition at line 274 of file graph.h.
Referenced by Builder::FinishCommand(), and RecomputeOutputDirty().
|
inline |
Definition at line 281 of file graph.h.
Referenced by Builder::FinishCommand().
| bool DependencyScan::RecomputeDirty | ( | Node * | node, |
| string * | err | ||
| ) |
Update the |dirty_| state of the given node by inspecting its input edge.
Examine inputs, outputs, and command lines to judge whether an edge needs to be re-run, and update outputs_ready_ and each outputs' |dirty_| state accordingly. Returns false on failure.
Definition at line 34 of file graph.cc.
Referenced by Builder::AddTarget(), and RecomputeDirty().
Definition at line 39 of file graph.cc.
References dep_loader_, Edge::deps_missing_, disk_interface_, Node::exists(), EXPLAIN, Node::in_edge(), Edge::inputs_, Edge::is_order_only(), Edge::is_phony(), ImplicitDepLoader::LoadDeps(), Edge::mark_, Node::MarkDirty(), Node::mtime(), Edge::outputs_, Edge::outputs_ready_, Node::path(), RecomputeDirty(), RecomputeOutputsDirty(), Node::set_dirty(), Node::StatIfNecessary(), Node::status_known(), VerifyDAG(), Edge::VisitDone, and Edge::VisitInStack.
|
private |
Recompute whether a given single output should be marked dirty.
Returns true if so.
Definition at line 196 of file graph.cc.
References build_log(), BuildLog::LogEntry::command_hash, Node::exists(), EXPLAIN, Edge::GetBindingBool(), BuildLog::LogEntry::HashCommand(), Edge::inputs_, Edge::is_phony(), BuildLog::LookupByOutput(), BuildLog::LogEntry::mtime, Node::mtime(), Node::path(), and PRId64.
Referenced by RecomputeOutputsDirty().
| bool DependencyScan::RecomputeOutputsDirty | ( | Edge * | edge, |
| Node * | most_recent_input, | ||
| bool * | dirty, | ||
| string * | err | ||
| ) |
Recompute whether any output of the edge is dirty, if so sets |*dirty|.
Returns false on failure.
Definition at line 183 of file graph.cc.
References Edge::EvaluateCommand(), Edge::outputs_, and RecomputeOutputDirty().
Referenced by Plan::CleanNode(), and RecomputeDirty().
|
inline |
Definition at line 277 of file graph.h.
Referenced by Builder::SetBuildLog().
Definition at line 144 of file graph.cc.
References Node::in_edge(), Edge::mark_, Edge::maybe_phonycycle_diagnostic(), and Edge::VisitInStack.
Referenced by RecomputeDirty().
|
private |
Definition at line 296 of file graph.h.
Referenced by RecomputeDirty().
|
private |
Definition at line 295 of file graph.h.
Referenced by RecomputeDirty().
1.8.14