- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi-
Does anyone know the compiler command line option to produce a mixed C source/assembly list file? I'd like to compare the asm output for various NIOS custom HDL usages (memory mapped vs. custom instructions) and having the mixed output list file would help greatly. Thanks, John SpethLink Copied
5 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
google "gcc lst file"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The option you are looking for is "-S" for the nios2-elf-objdump utility.
$ nios2-elf-objdump.exe
Usage: nios2-elf-objdump <option(s)> <file(s)>
Display information from object <file(s)>.
At least one of the following switches must be given:
-a, --archive-headers Display archive header information
-f, --file-headers Display the contents of the overall file header
-p, --private-headers Display object format specific file header contents
-h, --headers Display the contents of the section headers
-x, --all-headers Display the contents of all headers
-d, --disassemble Display assembler contents of executable sections
-D, --disassemble-all Display assembler contents of all sections
-S, --source Intermix source code with disassembly
-s, --full-contents Display the full contents of all sections requested
-g, --debugging Display debug information in object file
-e, --debugging-tags Display debug information using ctags style
-G, --stabs Display (in raw form) any STABS info in the file
-t, --syms Display the contents of the symbol table(s)
-T, --dynamic-syms Display the contents of the dynamic symbol table
-r, --reloc Display the relocation entries in the file
-R, --dynamic-reloc Display the dynamic relocation entries in the file
-v, --version Display this program's version number
-i, --info List object formats and architectures supported
-H, --help Display this information
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Try -Wa,-ahlms=aaa.lst
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks everyone for the clues and help (except for the not-so-helpful response). As with everything GCC, the answer is never in the most obvious place.
Here's how to get what I want: Go to the IDE menu Window / Preferences / NIOS II dialog. Make sure "Generate objdump file" is checked. The mixed C/ASM file for the **entire** project can be found in the "<project>\Debug" directory under the file name "<project>.elf.objdump". FWIW, I zeroed in on this solution because similar forum responses are searched and displayed at the bottom of thread page as each new response comes in. It's quite a nice feature! Even tangential responses seem to help. Thanks again, John Speth.- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
--- Quote Start --- As with everything GCC, the answer is never in the most obvious place. --- Quote End --- It's not at all a GCC thing, but rather a Nios II IDE thing. Cheers, --slacker

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page