machinst x64: New backend unwind (#2266)
Addresses unwind for experimental x64 backend. The preliminary code enables backtrace on SystemV call convension.
This commit is contained in:
@@ -274,6 +274,7 @@ impl MachInstEmitInfo for EmitInfo {
|
||||
impl MachInstEmit for Inst {
|
||||
type Info = EmitInfo;
|
||||
type State = EmitState;
|
||||
type UnwindInfo = super::unwind::Arm32UnwindInfo;
|
||||
|
||||
fn emit(&self, sink: &mut MachBuffer<Inst>, emit_info: &Self::Info, state: &mut EmitState) {
|
||||
let start_off = sink.cur_offset();
|
||||
|
||||
@@ -22,6 +22,7 @@ mod emit;
|
||||
pub use self::emit::*;
|
||||
mod regs;
|
||||
pub use self::regs::*;
|
||||
pub mod unwind;
|
||||
|
||||
#[cfg(test)]
|
||||
mod emit_tests;
|
||||
|
||||
15
cranelift/codegen/src/isa/arm32/inst/unwind.rs
Normal file
15
cranelift/codegen/src/isa/arm32/inst/unwind.rs
Normal file
@@ -0,0 +1,15 @@
|
||||
use super::*;
|
||||
use crate::isa::unwind::UnwindInfo;
|
||||
use crate::result::CodegenResult;
|
||||
|
||||
pub struct Arm32UnwindInfo;
|
||||
|
||||
impl UnwindInfoGenerator<Inst> for Arm32UnwindInfo {
|
||||
fn create_unwind_info(
|
||||
_context: UnwindInfoContext<Inst>,
|
||||
_kind: UnwindInfoKind,
|
||||
) -> CodegenResult<Option<UnwindInfo>> {
|
||||
// TODO
|
||||
Ok(None)
|
||||
}
|
||||
}
|
||||
@@ -73,6 +73,7 @@ impl MachBackend for Arm32Backend {
|
||||
buffer,
|
||||
frame_size,
|
||||
disasm,
|
||||
unwind_info: None,
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user