From a2bf3f78d8193b51a36be22f1f77df18533730da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?D=C3=A1niel=20Buga?= Date: Sun, 8 Oct 2023 18:21:07 +0200 Subject: [PATCH] Generate nm output and pipe through rustfilt --- xtask/src/main.rs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/xtask/src/main.rs b/xtask/src/main.rs index dc75941f..9c530b06 100644 --- a/xtask/src/main.rs +++ b/xtask/src/main.rs @@ -261,6 +261,18 @@ fn asm() -> AnyResult<()> { .stdout_path("target/asm.s") .run()?; + cmd!( + "xtensa-esp32s3-elf-nm", + "./target/xtensa-esp32s3-none-elf/release/card_io_fw", + "-S", + "--size-sort", + ) + .stdout_path("target/syms.txt") + .run()?; + + cmd!("rustfilt", "-i=target/asm.s", "-o=target/asm_filt.s").run()?; + cmd!("rustfilt", "-i=target/syms.txt", "-o=target/syms_filt.txt").run()?; + println!("🛠️ Assembly saved to target/asm.s"); Ok(())