[vorbis-dev] fast math optimization patch
Timothy J. Wood
tjw at omnigroup.com
Sat Feb 10 18:06:30 PST 2001
Good points. Would we rather get an compile time error when there is
a possible optimization that you're missing out on (forcing a developer
on the platform in question to make this decision as part of their
porting process), or would we rather just punt and run slower?
Could you describe what sort of bitfield portability problems you know
about? I haven't seen any real problems with bitfields (although I
certainly don't use every compiler in the world or read ANSI C standards
for fun :)
If people do run into bitfield portability problems, we could take a
couple of approaches:
- Only turn on the optimizations on specific platforms (gcc/ppc,
gcc/x86, msvc++/x86, for example) and disable them otherwise
- Write some autoconf tests to see what the current compiler/cpu does
and automatically turn stuff on/off.
- ... something else?
It seems like the autoconf approach makes the most sense, at least for
determining whether a particular piece of optimization code would
_work_, but not for whether it should be turned on (since even if it
does work, it might not be as fast as the plain C on a particular CPU).
-tim
On Saturday, February 10, 2001, at 05:07 PM, Michael Smith wrote:
> Looked mostly very good. Except that it defines the endianness for a
> couple
> of platforms and lets the others sit there broken. Since the rest of
> libvorbis is completely endian-neutral, this is a bit of a pain. Or
> maybe I
> misread the code, and it just falls back to the old version when it's
> not
> defined.
>
> And it uses bitfields, which are chronically unportable when you want to
> use them with any real meaning (C doesn't guarantee enough about them to
> make them very useful)
--- >8 ----
List archives: http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-dev-request at xiph.org'
containing only the word 'unsubscribe' in the body. No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.
More information about the Vorbis-dev
mailing list