diff --git a/README.chromium b/README.chromium index 0069484cf..98060c126 100644 --- a/README.chromium +++ b/README.chromium @@ -1,6 +1,6 @@ Name: libyuv URL: http://code.google.com/p/libyuv/ -Version: 832 +Version: 833 License: BSD License File: LICENSE diff --git a/include/libyuv/planar_functions.h b/include/libyuv/planar_functions.h index f2d82cf7f..6b0dae855 100644 --- a/include/libyuv/planar_functions.h +++ b/include/libyuv/planar_functions.h @@ -72,6 +72,7 @@ int YUY2ToI422(const uint8* src_yuy2, int src_stride_yuy2, int width, int height); // Convert UYVY to I422. +LIBYUV_API int UYVYToI422(const uint8* src_uyvy, int src_stride_uyvy, uint8* dst_y, int dst_stride_y, uint8* dst_u, int dst_stride_u, diff --git a/include/libyuv/version.h b/include/libyuv/version.h index a4b6b5560..5b5e24f62 100644 --- a/include/libyuv/version.h +++ b/include/libyuv/version.h @@ -11,6 +11,6 @@ #ifndef INCLUDE_LIBYUV_VERSION_H_ // NOLINT #define INCLUDE_LIBYUV_VERSION_H_ -#define LIBYUV_VERSION 832 +#define LIBYUV_VERSION 833 #endif // INCLUDE_LIBYUV_VERSION_H_ NOLINT diff --git a/source/cpu_id.cc b/source/cpu_id.cc index 086c4cecf..e223153d3 100644 --- a/source/cpu_id.cc +++ b/source/cpu_id.cc @@ -60,15 +60,22 @@ void CpuId(uint32 eax, uint32 ecx, uint32* cpu_info) { cpu_info[3] = edx; #endif // defined(_MSC_VER) } + #if !defined(__native_client__) #define HAS_XGETBV // X86 CPUs have xgetbv to detect OS saves high parts of ymm registers. int TestOsSaveYmm() { - uint32 xcr0; -#if defined(_MSC_VER) + uint32 xcr0 = 0u; +#if defined(_MSC_VER) && (_MSC_FULL_VER >= 160040219) xcr0 = static_cast(_xgetbv(0)); // VS2010 SP1 required. -#else - asm volatile ("xgetbv" : "=a" (xcr0) : "c" (0) : "%edx" ); // NOLINT +#elif defined(_M_IX86) + __asm { + xor ecx, ecx // xcr 0 + _asm _emit 0x0f _asm _emit 0x01 _asm _emit 0xd0 // For VS2010 and earlier. + mov xcr0, eax + } +#elif defined(__i386__) || defined(__x86_64__) + asm volatile (".byte 0x0f, 0x01, 0xd0" : "=a" (xcr0) : "c" (0) : "%edx" ); #endif // defined(_MSC_VER) return((xcr0 & 6) == 6); // Is ymm saved? }