summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/IPO/AddReadAttrs.cpp
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2008-09-30 18:30:35 +0000
committerDan Gohman <gohman@apple.com>2008-09-30 18:30:35 +0000
commit86aa16a69ad1e3ad0b484ec27b3c70e4f9ee5c90 (patch)
treed8d513f3d7ba5b5e6221015fbeb59f26cee1dbe1 /llvm/lib/Transforms/IPO/AddReadAttrs.cpp
parent985f69ab26a00b51c6d3e923029ff6c7ad25217a (diff)
downloadbcm5719-llvm-86aa16a69ad1e3ad0b484ec27b3c70e4f9ee5c90.tar.gz
bcm5719-llvm-86aa16a69ad1e3ad0b484ec27b3c70e4f9ee5c90.zip
Optimize SelectionDAG's AssignTopologicalOrder even further.
Completely eliminate the TopOrder std::vector. Instead, sort the AllNodes list in place. This also eliminates the need to call AllNodes.size(), a linear-time operation, before performing the sort. Also, eliminate the Sources temporary std::vector, since it essentially duplicates the sorted result as it is being built. This also changes the direction of the topological sort from bottom-up to top-down. The AllNodes list starts out in roughly top-down order, so this reduces the amount of reordering needed. Top-down is also more convenient for Legalize, and ISel needed only minor adjustments. llvm-svn: 56867
Diffstat (limited to 'llvm/lib/Transforms/IPO/AddReadAttrs.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud