[vlc-devel] [PATCH] Do adjust filter in SSE2 and SSE4.1

Martin Briza Gamajun at seznam.cz
Sat Jul 23 17:52:41 CEST 2011


>> Added whole header file (modules/video_filter/adjust_asm.h) with inline
>> assembly functions to be used in the filter
>
> I'm not an expert in x86 assembly. I'm precisely a bit concerned that  
> this
> we should keep the C code legible, meaining clear of massive blocks of
> CPU-specific optimizations, and use separate files for that (which this
> only partly does).
>
> Otherwise, it's going to be the deinterlace mess all over again.

After thinking about it for a while, I think it would be possible to do  
this with function pointers to avoid huge blocks of redundant code. These  
pointed functions would be inline of course - delay caused by calling them  
as pointers should be minimal with used compiler optimizations.

The resulting functions would be basically the same as before the patch,  
just instead of those block processing parts, there will be a pointer to  
processing functions (C or asm).

Do you agree with this solution?



More information about the vlc-devel mailing list