> Hi Yueling,
>
> you can declare the input array as follow:
>
>
> _MM_ALIGN16  float  array[index];
> "_MM_ALIGN16" will call "__declspec(align(16))" indirectly,
>
> then you can use "_mm_load_ps" safely.
>
> BR
> dianming
>
> 2010/11/29 pl bossart <[email protected]>
>
> On Mon, Nov 29, 2010 at 2:13 AM, Yue, Ling <[email protected]> wrote:
>> > Hi, group
>> >
>> > I am looking at Meego bug #5603:
>> >
>> > Bug 5603 - SSE misalignment removal in gstreamer base plugin
>> "audioresample"
>> >
>> > (http://bugs.meego.com/show_bug.cgi?id=5603)
>> >
>> > It's about removing the SSE misalignment in gstreamer audio resample
>> > element.
>> >
>> > Since the input array can't ensure 16-byte aligned, when _USE_SSE is
>> > configured,
>> >
>> > _mm_loadu_ps() will be used instead of _mm_load_ps() to load from array.
>> >
>> > And _mm_loadu_ps should be the main cause for high CPU usage according
>> to
>> > BMC#5603.
>> >
>> > The prototyping codes suggest removing misalignment for oversample=1 and
>> 2,
>> > this will reduce the hot function overhead by about 60%.
>> >
>> > Of course the disadvantage of removing the mis-alignment is to increase
>> the
>> > code complexity a lot.
>> >
>> >
>> >
>> > I plan to optimize gstreamer audio resample code now. And since this is
>> a
>> > common issue for speex, ffmpeg, pulseaudio etc, I wonder what's the
>> > suggested method to increase SSE optimization utilization for all of
>> them~
>> >
>> > I googled and found someone asked about SSE optimization for moblin
>> audio
>> > before but I can't see the cached content.
>>
>> I wouldn't spend too much time fixing this bug since we want
>> resampling to take place in PulseAudio, so that the rate of a specific
>> stream is adjusted to the output exactly once. If you enable
>> resampling in gstreamer, you have no idea what the actual output
>> sampling frequency is and you will do this costly operation twice.
>> remove the audioresample element from the pipeline and it should work
>> just fine. Likewise all volume control operations should be handled in
>> PulseAudio.
>> -Pierre
>> _______________________________________________
>> MeeGo-dev mailing list
>> [email protected]
>> http://lists.meego.com/listinfo/meego-dev
>>
>
>
_______________________________________________
MeeGo-dev mailing list
[email protected]
http://lists.meego.com/listinfo/meego-dev

Reply via email to