From c07826e57f609474dfb75952361e97f3c796a4cd Mon Sep 17 00:00:00 2001 From: Luke Street Date: Mon, 7 Aug 2023 20:03:34 -0400 Subject: [PATCH] Output common/rename in write_split --- src/util/config.rs | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/src/util/config.rs b/src/util/config.rs index 9ac40f0..8a4ff88 100644 --- a/src/util/config.rs +++ b/src/util/config.rs @@ -264,8 +264,19 @@ pub fn write_splits(w: &mut W, obj: &ObjInfo) -> Result<()> { split_iter.peek().map(|&(addr, _)| addr).unwrap_or(0) }; let section = obj.section_at(addr)?; - writeln!(w, "\t{:<11} start:{:#010X} end:{:#010X}", section.name, addr, end)?; - // align:{} + write!(w, "\t{:<11} start:{:#010X} end:{:#010X}", section.name, addr, end)?; + // if let Some(align) = split.align { + // write!(w, " align:{}", align)?; + // } + if split.common { + write!(w, " common")?; + } + if let Some(name) = obj.named_sections.get(&addr) { + if name != §ion.name { + write!(w, " rename:{}", name)?; + } + } + writeln!(w)?; } } Ok(())