chore: align disasm print more with objdump(1)
This commit is contained in:
@@ -66,22 +66,22 @@ impl Register {
|
||||
impl fmt::Display for Register {
|
||||
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
||||
match self {
|
||||
Self::AX => write!(f, "ax"),
|
||||
Self::BX => write!(f, "bx"),
|
||||
Self::CX => write!(f, "cx"),
|
||||
Self::DX => write!(f, "dx"),
|
||||
Self::AH => write!(f, "ah"),
|
||||
Self::AL => write!(f, "al"),
|
||||
Self::BL => write!(f, "bl"),
|
||||
Self::BH => write!(f, "bh"),
|
||||
Self::CH => write!(f, "ch"),
|
||||
Self::CL => write!(f, "cl"),
|
||||
Self::DH => write!(f, "dh"),
|
||||
Self::DL => write!(f, "dl"),
|
||||
Self::DI => write!(f, "di"),
|
||||
Self::SI => write!(f, "si"),
|
||||
Self::BP => write!(f, "bp"),
|
||||
Self::SP => write!(f, "sp"),
|
||||
Self::AX => write!(f, "%ax"),
|
||||
Self::BX => write!(f, "%bx"),
|
||||
Self::CX => write!(f, "%cx"),
|
||||
Self::DX => write!(f, "%dx"),
|
||||
Self::AH => write!(f, "%ah"),
|
||||
Self::AL => write!(f, "%al"),
|
||||
Self::BL => write!(f, "%bl"),
|
||||
Self::BH => write!(f, "%bh"),
|
||||
Self::CH => write!(f, "%ch"),
|
||||
Self::CL => write!(f, "%cl"),
|
||||
Self::DH => write!(f, "%dh"),
|
||||
Self::DL => write!(f, "%dl"),
|
||||
Self::DI => write!(f, "%di"),
|
||||
Self::SI => write!(f, "%si"),
|
||||
Self::BP => write!(f, "%bp"),
|
||||
Self::SP => write!(f, "%sp"),
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -113,10 +113,10 @@ impl SegmentRegister {
|
||||
impl fmt::Display for SegmentRegister {
|
||||
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
||||
match self {
|
||||
Self::DS => write!(f, "ds"),
|
||||
Self::ES => write!(f, "es"),
|
||||
Self::SS => write!(f, "ss"),
|
||||
Self::CS => write!(f, "cs"),
|
||||
Self::DS => write!(f, "%ds"),
|
||||
Self::ES => write!(f, "%es"),
|
||||
Self::SS => write!(f, "%ss"),
|
||||
Self::CS => write!(f, "%cs"),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user