Re: Question regarding the values of labels

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

 



Matthew Plant <rookie.mp@xxxxxxxxx> writes:

> So my final question is this: what determines the addresses of labels?
> Can this problem be fixed with at least semi-readable code?

Speaking very roughly, gcc separates the code into basic blocks and
builds a control flow graph.  The blocks in the control flow graph are
sorted based on the predicted results of branches.  The blocks are then
output in the order.

Nothing like what you want to do is possible with gcc.  You are assuming
that there is a natural correspondence between your source code and
gcc's internal representation; that is a natural thing assumption, but
in actual fact no such correspondence exists.

Ian


[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