Yet another

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

 



Hi,

In case this isn't known, I have another example of gcc (4.6.3 in this case)
emitting line number 0.  Here's a summary:

.cpp:
>	switch( ntohl(m_ipaddr) )

.i:

[Note: This example is from a different file, let's call it foo.cpp]

>                   setOptionNumber ((__extension__ ({ register unsigned
>                   int __v, __x = (val); if (__builtin_constant_p
>                   (__x)) __v = ((((__x) & 0xff000000) >> 24) | (((__x)
>                   & 0x00ff0000) >> 8) | (((__x) & 0x0000ff00) << 8) |
>                   (((__x) & 0x000000ff) << 24)); else __asm__ ("bswap
>                   %0" : "=r" (__v) : "0" (__x)); __v; })), statp); 

.s:

> #APP
> # 1490 "foo.cpp" 1
>     bswap %eax
> # 0 "" 2
> .LVL948:

Note too the null file name.

Platform is i686-pc-linux-gnu, RHEL4. 

On Red Hat 4, ntohl() is substituted by __bswap32() via netinet/in.h. 
Origin of
# __bswap32() is unknown, it may be an intrinsic function.

Problem seen with gas 2.15, not seen with gas 2.17. We think 2.16 or 2.17
were modified to tolerate line number 0.  Problem seen with -O2, not seen
with no optimization.

I've verified our source base contains the fix for bug 21250
(http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21250), so perhaps this is
something different.  Contact me for more information.
Apologies if this is known.

Thanks
Tim
-- 
View this message in context: http://old.nabble.com/Yet-another-tp33759029p33759029.html
Sent from the gcc - Help mailing list archive at Nabble.com.



[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