summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrancisco Jerez <[email protected]>2011-11-15 21:39:22 +0100
committerChristoph Bumiller <[email protected]>2012-04-14 21:54:00 +0200
commit099b81396eb4518cc4de0393ceff1028c5bee2bd (patch)
treef4bc483ef0664906dc24436e242fa4205736579d
parent18294844584f1a64454593c056148201c4d79ef7 (diff)
nv50/ir: Allow inserting isolated nodes to a graph.
-rw-r--r--src/gallium/drivers/nv50/codegen/nv50_ir_graph.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/gallium/drivers/nv50/codegen/nv50_ir_graph.cpp b/src/gallium/drivers/nv50/codegen/nv50_ir_graph.cpp
index 2c64a140f51..b1287001c37 100644
--- a/src/gallium/drivers/nv50/codegen/nv50_ir_graph.cpp
+++ b/src/gallium/drivers/nv50/codegen/nv50_ir_graph.cpp
@@ -43,13 +43,11 @@ Graph::~Graph()
void Graph::insert(Node *node)
{
- if (!root) {
+ if (!root)
root = node;
- size = 1;
- node->graph = this;
- } else {
- root->attach(node, Edge::TREE);
- }
+
+ node->graph = this;
+ size++;
}
void Graph::Edge::unlink()