[mythtv] [PATCH] dtk libsoundtouch bug
Daniel Thor Kristjansson
danielk at mrl.nyu.edu
Sun Jan 30 00:30:49 EST 2005
On Sun, 30 Jan 2005, Mark Spieth wrote:
]> ]also dont need the -fPIC
]> ]options. so I removed them too. static lib after all.
]> Isn't this getting statically linked into a dynamic lib?
]> Is it safe to get rid of -fPIC then?
]no idea. defer to the judgement of others. I only know it works
I believe this will either cause erratic behavior and/or break
pre-linking, depending on whether the linker is smart enough to realize
-fPIC wasn't used for the static library. It's just best to compile
position independent code unless on is sure the library is only being
used within the main executable.
]> Yep. But icc and newer gcc's like them. And those compilers may even
]> clobber the old intrinsics in certain situations.
]true. thus need an auto way of determining whether to use them or not.
]configure would do it. perhaps a mini script in the libmythsoundtouch.pro
]file to test for the presence of mmintrin.h
For now, I think it is best that we only use the mmx.h intrinsics. When
someone feels inspired to port MythTV to other x86 compilers we can
figure out a way to enable this code. Probably based on something
simple like testing the compiler name and version. I only left these in
because I accidentally ported to the wrong intrinsics initially, and
wanted to provide well tested mmintrin.h based code to who ever gets
inspired to do a gcc 3.5/icc 8.0 port someday.
But I think this may have actually caused the bug to sneak in because
while I thought I was testing both by changing a define and recompiling,
a missing dependency for the linking order meant only one of them was
actually being used in my tests.
More information about the mythtv-dev