Marker fix for powx and colorconv routines

2008-02-12
2013-04-23
  • Ravindra Babu
    Ravindra Babu
    2008-02-12

    PowX_64f and certain color conversion routines listed below might fail due to incorrect markers specified for the available optimization levels.

    The functions requiring marker fix are

    Signal routines(Set maximum optimization level to OREFR in fwSignal_opt.h)

    fwsPowx_64f_A50
    fwsPowx_64f_A53

    Image routines(Set maximum optimization level to OSSE2 in fwImage_opt.h)

    fwiYCbCr420ToRGB_8u_P3C3R
    fwiYUV422ToRGB_8u_C2C3R 
    fwiYUV422ToRGB_8u_P3R   
    fwiYUV422ToRGB_8u_P3    
    fwiYUV422ToRGB_8u_P3C3R 
    fwiYUV422ToRGB_8u_P3C3  
    fwiYUV422ToRGB_8u_P3AC4R
    fwiYUV420ToRGB_8u_P3R         
    fwiYUV420ToRGB_8u_P3          
    fwiYUV420ToRGB_8u_P3C3R       
    fwiYUV420ToRGB_8u_P3C3        
    fwiYUV420ToRGB_8u_P3AC4R      
    fwiYUV420ToBGR_8u_P3C3R       
    fwiYUV420ToRGB565_8u16u_P3C3R 
    fwiYUV420ToRGB555_8u16u_P3C3R 
    fwiYUV420ToRGB444_8u16u_P3C3R 
    fwiYUV420ToBGR565_8u16u_P3C3R 
    fwiYUV420ToBGR555_8u16u_P3C3R 
    fwiYUV420ToBGR444_8u16u_P3C3R 
    fwiCbYCr422ToYCbCr420_8u_C2P3R

    This bug is present in the tagged portion of the code but fixed in the main branch. The fix is to change the markers for the failing functions to have the maximum optimization level as OREFR or OSSE2 as the case may be. This would ensure that the function falls back to maximum optimization path of SSE2 if it is OSSE2 or to Reference if it is OREFR.

    The workaround for these failing function without change to source code is by setting the maximum optimization level programmatically by calling fwStaticInitCpu function, before using these functions

    ex: fwStaticInitCpu (fwCpuSSE2); //maximum optimization level is SSE2