Commit 9c4ed439 authored by qinsoon's avatar qinsoon

remove warnings (and dead code)

parent a35577b7
......@@ -754,25 +754,7 @@ impl <'a> GraphColoring<'a> {
ret
}
pub fn get_spill_history(&self) -> LinkedHashMap<MuID, P<Value>> {
self.spill_history.clone()
}
pub fn get_spill_scratch_temps(&self) -> LinkedHashMap<MuID, MuID> {
self.spill_scratch_temps.clone()
}
pub fn get_coalesced(&self) -> LinkedHashMap<MuID, MuID> {
let mut ret = LinkedHashMap::new();
for mov in self.coalesced_moves.iter() {
let from = self.ig.get_temp_of(mov.from);
let to = self.ig.get_temp_of(mov.to);
ret.insert(from, to);
ret.insert(to , from);
}
ret
}
}
......@@ -90,15 +90,6 @@ impl InterferenceGraph {
}
}
/// returns all the temps in the graph
pub fn temps(&self) -> Vec<MuID>{
let mut ret = vec![];
for reg in self.nodes.keys() {
ret.push(*reg);
}
ret
}
/// returns all the nodes in the graph
pub fn nodes(&self) -> Vec<NodeIndex> {
let mut ret = vec![];
......@@ -113,11 +104,6 @@ impl InterferenceGraph {
&self.moves
}
/// returns the number of nodes in the graph
pub fn n_nodes(&self) -> usize {
self.nodes.len()
}
/// adds a move edge between two nodes
fn add_move(&mut self, src: NodeIndex, dst: NodeIndex) {
let src = {
......
......@@ -3,7 +3,6 @@ extern crate petgraph;
mod liveness;
mod coloring;
use compiler::backend::reg_alloc::graph_coloring::liveness::InterferenceGraph;
use compiler::backend::reg_alloc::graph_coloring::liveness::build_interference_graph_chaitin_briggs as build_inteference_graph;
use compiler::backend::reg_alloc::graph_coloring::coloring::GraphColoring;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment