Re: efficiency

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Bob Rossi writes:
 > On Thu, Mar 16, 2006 at 05:58:29PM -0800, Brian Budge wrote:
 > > Hi -
 > > 
 > > This is not really a gcc question, and it should really be asked
 > > elsewhere... however, it's unlikely that this occasional dereference
 > > will adversely affect performance.
 > 
 > OK, where should a question like this be asked? if not the compiler that
 > does the optimization?

I agree with you, Bob -- it's a perfectly reasonable question.

 > I forgot to mention, I only really care about the efficiency
 > regarding gcc's output.

Well, if you really want to know, use "gcc -S".

Access to a local is something like

        movl    8(%ebp), %eax

and to a global via a pointer

        movl    sfoo, %eax
        movl    4(%eax), %eax
 
Andrew.

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux