From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10987 invoked by alias); 1 Dec 2006 10:54:18 -0000 Received: (qmail 10793 invoked by uid 22791); 1 Dec 2006 10:54:16 -0000 X-Spam-Check-By: sourceware.org Received: from mxout.hispeed.ch (HELO smtp.hispeed.ch) (62.2.95.247) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 01 Dec 2006 10:54:09 +0000 Received: from indel.ch (84-73-11-232.dclient.hispeed.ch [84.73.11.232]) by smtp.hispeed.ch (8.12.11.20060308/8.12.6/taifun-1.0) with SMTP id kB1As5m8011158 for ; Fri, 1 Dec 2006 11:54:06 +0100 Received: from FABI.indel.ch [192.168.1.91] by indel.ch [127.0.0.1] with SMTP (MDaemon.v2.7.SP5.R) for ; Fri, 01 Dec 2006 11:53:59 +0100 Message-Id: <5.2.0.9.1.20061201113741.0188c920@NT_SERVER> X-Sender: cenedese@NT_SERVER (Unverified) X-Mailer: QUALCOMM Windows Eudora Version 5.2.0.9 Date: Fri, 01 Dec 2006 10:54:00 -0000 To: gcc-help@gcc.gnu.org From: Fabian Cenedese Subject: Re: Comments in assember output In-Reply-To: <456F0E8D.8080003@solipsys.com> References: <200611301833.02142.artur@alice.phy.uct.ac.za> <200611241742.53004.artur@alice.phy.uct.ac.za> <200611301730.39617.artur@alice.phy.uct.ac.za> <200611301833.02142.artur@alice.phy.uct.ac.za> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-MDaemon-Deliver-To: gcc-help@gcc.gnu.org X-Return-Path: cenedese@indel.ch X-Virus-Status: Clean X-DCC-spamcheck-01.tornado.cablecom.ch-Metrics: smtp-08.tornado.cablecom.ch 1377; Body=1 Fuz1=1 Fuz2=1 X-IsSubscribed: yes Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2006-12/txt/msg00004.txt.bz2 At 12:02 30.11.2006 -0500, Tony Wetmore wrote: >Artur, > >I just tried playing around with this, and it appears the the "-S" flag is interfering. Perhaps by stopping the compilation process in that way, it prevents the generation of the "listing file". > >I tried compiling your example function as follows: > > gcc -c -g -O3 -Wa,-adhls=func.list func.c > >And got the following output (in func.list): > > 1 .file "func.c" > 4 .text > 5 Ltext0: > 28 .p2align 4,,15 > 32 .globl _func > 34 _func: > 1:func.c **** float func( float a, float b ) > 2:func.c **** { > 36 LM1: > 37 0000 55 pushl %ebp > 38 0001 89E5 movl %esp, %ebp > 40 LM2: > 41 0003 D9450C flds 12(%ebp) > 3:func.c **** return a * b; > 43 LM3: > 44 0006 D84D08 fmuls 8(%ebp) > 4:func.c **** } > 46 LM4: > 47 0009 5D popl %ebp > 48 000a C3 ret > 50 Lscope0: > 52 .text > 54 000b 90909090 Letext: > 54 90 > >This appears to be the sort of output you are looking for, right? That sounds usefull, I could use that as well. But when I tried it it didn't mix the lines, I just got (almost) all lines from the cpp source file and after that the assembler code. There are several functions in the cpp file, so at least those should be separatable in the assembler code. I compiled without optimization so the functions should not be intermingled. I tried the various -a flags but it didn't work so far. gcc 4.1.0, gas 2.16.1 Thanks bye Fabi