[libyuv] Fix 32-bit x86 register constraint in I422ToRGB24Row_AVX2

android_x86 was running out registers

Using "+m" for width on __i386__ (matching the convention in
SSSE3 row functions) makes width a stack variable instead

Was
   3800 |       "vbroadcasti128 16+%[kShuffleMaskARGBToRGB24],%%ymm5 \n"
        |       ^
  1 error generated.

Test: libyuv_unittest --gunit_filter=*I422ToRGB24*
Bug: 42280902
Change-Id: I7e5e22e9e15b68be942c85dd3b7e233e9f4f1351
TAG=agy
CONV=5c8b22e3-9f50-4ace-b1d5-007ddf688477
Reviewed-on: https://chromium-review.googlesource.com/c/libyuv/libyuv/+/8127620
Reviewed-by: James Zern <jzern@google.com>
Reviewed-by: Wan-Teh Chang <wtc@google.com>
Commit-Queue: Frank Barchard <fbarchard@google.com>
This commit is contained in:
Frank Barchard 2026-07-20 18:51:44 -07:00 committed by libyuv-scoped@luci-project-accounts.iam.gserviceaccount.com
parent 86a4d94d7a
commit c1e9e69826
3 changed files with 7 additions and 3 deletions

View File

@ -1,6 +1,6 @@
Name: libyuv Name: libyuv
URL: https://chromium.googlesource.com/libyuv/libyuv/ URL: https://chromium.googlesource.com/libyuv/libyuv/
Version: 1950 Version: 1951
Revision: DEPS Revision: DEPS
License: BSD-3-Clause License: BSD-3-Clause
License File: LICENSE License File: LICENSE

View File

@ -11,6 +11,6 @@
#ifndef INCLUDE_LIBYUV_VERSION_H_ #ifndef INCLUDE_LIBYUV_VERSION_H_
#define INCLUDE_LIBYUV_VERSION_H_ #define INCLUDE_LIBYUV_VERSION_H_
#define LIBYUV_VERSION 1950 #define LIBYUV_VERSION 1951
#endif // INCLUDE_LIBYUV_VERSION_H_ #endif // INCLUDE_LIBYUV_VERSION_H_

View File

@ -3821,14 +3821,18 @@ void OMITFP I422ToRGB24Row_AVX2(const uint8_t* y_buf,
"vmovdqu %%xmm2,0x10(%[dst_rgb24]) \n" "vmovdqu %%xmm2,0x10(%[dst_rgb24]) \n"
"vmovdqu %%xmm3,0x20(%[dst_rgb24]) \n" "vmovdqu %%xmm3,0x20(%[dst_rgb24]) \n"
"lea 0x30(%[dst_rgb24]),%[dst_rgb24] \n" "lea 0x30(%[dst_rgb24]),%[dst_rgb24] \n"
"sub $0x10,%[width] \n" "subl $0x10,%[width] \n"
"jg 1b \n" "jg 1b \n"
"vzeroupper \n" "vzeroupper \n"
: [y_buf]"+r"(y_buf), // %[y_buf] : [y_buf]"+r"(y_buf), // %[y_buf]
[u_buf]"+r"(u_buf), // %[u_buf] [u_buf]"+r"(u_buf), // %[u_buf]
[v_buf]"+r"(v_buf), // %[v_buf] [v_buf]"+r"(v_buf), // %[v_buf]
[dst_rgb24]"+r"(dst_rgb24), // %[dst_rgb24] [dst_rgb24]"+r"(dst_rgb24), // %[dst_rgb24]
#if defined(__i386__)
[width]"+m"(width) // %[width]
#else
[width]"+rm"(width) // %[width] [width]"+rm"(width) // %[width]
#endif
: [yuvconstants]"r"(yuvconstants), // %[yuvconstants] : [yuvconstants]"r"(yuvconstants), // %[yuvconstants]
[kShuffleMaskARGBToRGB24]"m"(kShuffleMaskARGBToRGB24[0]) [kShuffleMaskARGBToRGB24]"m"(kShuffleMaskARGBToRGB24[0])
: "memory", "cc", YUVTORGB_REGS_AVX2 : "memory", "cc", YUVTORGB_REGS_AVX2