libvorbis and gcc 2.95.2 + Re: [vorbis-dev] .ogg extension what the?

Monty xiphmont at xiph.org
Thu Jun 22 01:42:13 PDT 2000



> Now, the real topic:  Has anyone successfully compiled libvorbis using gcc
> 2.95.2?  I got serious clipping and other assorted junk from the example
> decoder when I tried.  It would appear that there's some kind of serious
> math problem (I'm still using glibc 2.0, which might not help either).

YES!  There is a *serious* bug in the inline floating point assembly headers 
(/usr/include/bits/mathinline.h) affecting several functions in glibc 2.0 and 
early glibc 2.1.  Glibc basically makes use of the FP stack without letting 
EGCS/GCC know that it's doing so.  Because this header assembly is handled 
after FPU stack allocation, glibc ends up overflowing the x387 FPU stack.

This bug affects *all* programs that compile against the glibc 2.0/early-2.1
headers.  Several math.h functions are affected (I believe it is specifically
log() and exp() that's biting vorbis).

To make Vorbis (and other programs that use floats) compile properly with older
glibc, the -D__NO_MATH_INLINES define is absolutely required.  I wonder if 
autoconf can check for glibc version...

(You don't want this define normally because it's a performance hit)

Monty

--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/



More information about the Vorbis-dev mailing list