wasmer_compiler/types/
address_map.rs#![allow(missing_docs)]
use crate::lib::std::vec::Vec;
use rkyv::{Archive, Deserialize as RkyvDeserialize, Serialize as RkyvSerialize};
#[cfg(feature = "enable-serde")]
use serde::{Deserialize, Serialize};
use wasmer_types::SourceLoc;
#[cfg_attr(feature = "enable-serde", derive(Serialize, Deserialize))]
#[cfg_attr(feature = "artifact-size", derive(loupe::MemoryUsage))]
#[derive(RkyvSerialize, RkyvDeserialize, Archive, Debug, Clone, Copy, PartialEq, Eq)]
#[rkyv(derive(Debug))]
pub struct InstructionAddressMap {
pub srcloc: SourceLoc,
pub code_offset: usize,
pub code_len: usize,
}
#[cfg_attr(feature = "artifact-size", derive(loupe::MemoryUsage))]
#[cfg_attr(feature = "enable-serde", derive(Serialize, Deserialize))]
#[derive(RkyvSerialize, RkyvDeserialize, Archive, Debug, Clone, PartialEq, Eq, Default)]
#[rkyv(derive(Debug))]
pub struct FunctionAddressMap {
pub instructions: Vec<InstructionAddressMap>,
pub start_srcloc: SourceLoc,
pub end_srcloc: SourceLoc,
pub body_offset: usize,
pub body_len: usize,
}