Remove ancient register allocation (#3401)
This commit is contained in:
@@ -1,20 +1,14 @@
|
||||
//! Adapter for a `MachBackend` to implement the `TargetIsa` trait.
|
||||
|
||||
use crate::binemit;
|
||||
use crate::ir;
|
||||
use crate::isa::{EncInfo, Encoding, Encodings, Legalize, RegClass, RegInfo, TargetIsa};
|
||||
use crate::isa::{RegInfo, TargetIsa};
|
||||
use crate::machinst::*;
|
||||
use crate::regalloc::RegisterSet;
|
||||
use crate::settings::{self, Flags};
|
||||
|
||||
#[cfg(feature = "testing_hooks")]
|
||||
use crate::regalloc::RegDiversions;
|
||||
|
||||
#[cfg(feature = "unwind")]
|
||||
use crate::isa::unwind::systemv::RegisterMappingError;
|
||||
|
||||
use core::any::Any;
|
||||
use std::borrow::Cow;
|
||||
use std::fmt;
|
||||
use target_lexicon::Triple;
|
||||
|
||||
@@ -74,60 +68,6 @@ impl TargetIsa for TargetIsaAdapter {
|
||||
}
|
||||
}
|
||||
|
||||
fn legal_encodings<'a>(
|
||||
&'a self,
|
||||
_func: &'a ir::Function,
|
||||
_inst: &'a ir::InstructionData,
|
||||
_ctrl_typevar: ir::Type,
|
||||
) -> Encodings<'a> {
|
||||
panic!("Should not be called when new-style backend is available!")
|
||||
}
|
||||
|
||||
fn encode(
|
||||
&self,
|
||||
_func: &ir::Function,
|
||||
_inst: &ir::InstructionData,
|
||||
_ctrl_typevar: ir::Type,
|
||||
) -> Result<Encoding, Legalize> {
|
||||
panic!("Should not be called when new-style backend is available!")
|
||||
}
|
||||
|
||||
fn encoding_info(&self) -> EncInfo {
|
||||
panic!("Should not be called when new-style backend is available!")
|
||||
}
|
||||
|
||||
fn legalize_signature(&self, _sig: &mut Cow<ir::Signature>, _current: bool) {
|
||||
panic!("Should not be called when new-style backend is available!")
|
||||
}
|
||||
|
||||
fn regclass_for_abi_type(&self, _ty: ir::Type) -> RegClass {
|
||||
panic!("Should not be called when new-style backend is available!")
|
||||
}
|
||||
|
||||
fn allocatable_registers(&self, _func: &ir::Function) -> RegisterSet {
|
||||
panic!("Should not be called when new-style backend is available!")
|
||||
}
|
||||
|
||||
fn prologue_epilogue(&self, _func: &mut ir::Function) -> CodegenResult<()> {
|
||||
panic!("Should not be called when new-style backend is available!")
|
||||
}
|
||||
|
||||
#[cfg(feature = "testing_hooks")]
|
||||
fn emit_inst(
|
||||
&self,
|
||||
_func: &ir::Function,
|
||||
_inst: ir::Inst,
|
||||
_divert: &mut RegDiversions,
|
||||
_sink: &mut dyn binemit::CodeSink,
|
||||
) {
|
||||
panic!("Should not be called when new-style backend is available!")
|
||||
}
|
||||
|
||||
/// Emit a whole function into memory.
|
||||
fn emit_function_to_memory(&self, _func: &ir::Function, _sink: &mut binemit::MemoryCodeSink) {
|
||||
panic!("Should not be called when new-style backend is available!")
|
||||
}
|
||||
|
||||
fn get_mach_backend(&self) -> Option<&dyn MachBackend> {
|
||||
Some(&*self.backend)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user