Electronics & Programming

develissimo

Open Source electronics development and programming

  • You are not logged in.
  • Root
  • » AVR-GCC
  • » [avr-gcc-list] How does one get gcc *.lst file with interspersedSource Listing and Assembler? [RSS Feed]

#1 Dec. 2, 2005 11:44:02

Nigel W.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

[avr-gcc-list] How does one get gcc *.lst file with interspersedSource Listing and Assembler?


> This should work for you:
>
> avr-gcc -c -gstabs -Wa,-ahlmsd=file.lst file.c

Take note, the original post showed a i386 dissassembly, Patrick O'Sullivan
isn't using avr-gcc.

Also IIRC there is a documented bug about emitting source lines with -gdwarf-2
option, I'm on my employer's time now so can't do the search.

Nigel Winterbottom





_______________________________________________
AVR-GCC-list mailing list
AVR-GCC-list@nongnu.orghttp://lists.nongnu.org/mailman/listinfo/avr-gcc-list

Offline

#2 Dec. 2, 2005 17:16:28

Dave H.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

[avr-gcc-list] How does one get gcc *.lst file with interspersedSource Listing and Assembler?


Hi Nigel,

> > This should work for you:
> >
> > avr-gcc -c -gstabs -Wa,-ahlmsd=file.lst file.c
>
> Take note, the original post showed a i386 dissassembly, Patrick O'Sullivan
> isn't using avr-gcc.

That's the beauty of gcc. The exact same command (minus the avr-
prefix) also works with the intel flavour of gcc. My experience is
that -gstabs works on more platforms that just -g (i.e. -g by itself
doesn't work on the AVR for doing the above interlisting).

The d option in the -Wa,-ahldms=... casues the debug information to be
removed from the interlisting output.

--
Dave Hylands
Vancouver, BC, Canadahttp://www.DaveHylands.com/_______________________________________________
AVR-GCC-list mailing list
AVR-GCC-list@nongnu.orghttp://lists.nongnu.org/mailman/listinfo/avr-gcc-list

Offline

  • Root
  • » AVR-GCC
  • » [avr-gcc-list] How does one get gcc *.lst file with interspersedSource Listing and Assembler? [RSS Feed]

Board footer

Moderator control

Enjoy the 20th of January
PoweredBy

The Forums are managed by develissimo stuff members, if you find any issues or misplaced content please help us to fix it. Thank you! Tell us via Contact Options
Leave a Message
Welcome to Develissimo Live Support