// File: /workspace/github_c_makefile_star2_O0/enzo1982[P]smooth/libraries/libwebp/src/dsp/yuv_sse2.c
// Function: VP8YuvToRgb32_SSE2
void VP8YuvToRgb32_SSE2(const uint8_t* y, const uint8_t* u, const uint8_t* v,
                        uint8_t* dst) {
  __m128i R0, R1, R2, R3, G0, G1, G2, G3, B0, B1, B2, B3;
  __m128i rgb0, rgb1, rgb2, rgb3, rgb4, rgb5;

  YUV444ToRGB_SSE2(y + 0, u + 0, v + 0, &R0, &G0, &B0);
  YUV444ToRGB_SSE2(y + 8, u + 8, v + 8, &R1, &G1, &B1);
  YUV444ToRGB_SSE2(y + 16, u + 16, v + 16, &R2, &G2, &B2);
  YUV444ToRGB_SSE2(y + 24, u + 24, v + 24, &R3, &G3, &B3);

  // Cast to 8b and store as RRRRGGGGBBBB.
  rgb0 = _mm_packus_epi16(R0, R1);
  rgb1 = _mm_packus_epi16(R2, R3);
  rgb2 = _mm_packus_epi16(G0, G1);
  rgb3 = _mm_packus_epi16(G2, G3);
  rgb4 = _mm_packus_epi16(B0, B1);
  rgb5 = _mm_packus_epi16(B2, B3);

  // Pack as RGBRGBRGBRGB.
  PlanarTo24b_SSE2(&rgb0, &rgb1, &rgb2, &rgb3, &rgb4, &rgb5, dst);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x210, %rsp            # imm = 0x210
movq %rdi, -0xc8(%rbp)
movq %rsi, -0xd0(%rbp)
movq %rdx, -0xd8(%rbp)
movq %rcx, -0xe0(%rbp)
movq -0xc8(%rbp), %rdi
movq -0xd0(%rbp), %rsi
movq -0xd8(%rbp), %rdx
leaq -0xf0(%rbp), %rcx
leaq -0x130(%rbp), %r8
leaq -0x170(%rbp), %r9
callq 0x17a920
movq -0xc8(%rbp), %rdi
addq $0x8, %rdi
movq -0xd0(%rbp), %rsi
addq $0x8, %rsi
movq -0xd8(%rbp), %rdx
addq $0x8, %rdx
leaq -0x100(%rbp), %rcx
leaq -0x140(%rbp), %r8
leaq -0x180(%rbp), %r9
callq 0x17a920
movq -0xc8(%rbp), %rdi
addq $0x10, %rdi
movq -0xd0(%rbp), %rsi
addq $0x10, %rsi
movq -0xd8(%rbp), %rdx
addq $0x10, %rdx
leaq -0x110(%rbp), %rcx
leaq -0x150(%rbp), %r8
leaq -0x190(%rbp), %r9
callq 0x17a920
movq -0xc8(%rbp), %rdi
addq $0x18, %rdi
movq -0xd0(%rbp), %rsi
addq $0x18, %rsi
movq -0xd8(%rbp), %rdx
addq $0x18, %rdx
leaq -0x120(%rbp), %rcx
leaq -0x160(%rbp), %r8
leaq -0x1a0(%rbp), %r9
callq 0x17a920
movdqa -0xf0(%rbp), %xmm1
movdqa -0x100(%rbp), %xmm0
movdqa %xmm1, -0x10(%rbp)
movdqa %xmm0, -0x20(%rbp)
movdqa -0x10(%rbp), %xmm0
movdqa -0x20(%rbp), %xmm1
packuswb %xmm1, %xmm0
movdqa %xmm0, -0x1b0(%rbp)
movdqa -0x110(%rbp), %xmm1
movdqa -0x120(%rbp), %xmm0
movdqa %xmm1, -0x30(%rbp)
movdqa %xmm0, -0x40(%rbp)
movdqa -0x30(%rbp), %xmm0
movdqa -0x40(%rbp), %xmm1
packuswb %xmm1, %xmm0
movdqa %xmm0, -0x1c0(%rbp)
movdqa -0x130(%rbp), %xmm1
movdqa -0x140(%rbp), %xmm0
movdqa %xmm1, -0x50(%rbp)
movdqa %xmm0, -0x60(%rbp)
movdqa -0x50(%rbp), %xmm0
movdqa -0x60(%rbp), %xmm1
packuswb %xmm1, %xmm0
movdqa %xmm0, -0x1d0(%rbp)
movdqa -0x150(%rbp), %xmm1
movdqa -0x160(%rbp), %xmm0
movdqa %xmm1, -0x70(%rbp)
movdqa %xmm0, -0x80(%rbp)
movdqa -0x70(%rbp), %xmm0
movdqa -0x80(%rbp), %xmm1
packuswb %xmm1, %xmm0
movdqa %xmm0, -0x1e0(%rbp)
movdqa -0x170(%rbp), %xmm1
movdqa -0x180(%rbp), %xmm0
movdqa %xmm1, -0x90(%rbp)
movdqa %xmm0, -0xa0(%rbp)
movdqa -0x90(%rbp), %xmm0
movdqa -0xa0(%rbp), %xmm1
packuswb %xmm1, %xmm0
movdqa %xmm0, -0x1f0(%rbp)
movdqa -0x190(%rbp), %xmm1
movdqa -0x1a0(%rbp), %xmm0
movdqa %xmm1, -0xb0(%rbp)
movdqa %xmm0, -0xc0(%rbp)
movdqa -0xb0(%rbp), %xmm0
movdqa -0xc0(%rbp), %xmm1
packuswb %xmm1, %xmm0
movdqa %xmm0, -0x200(%rbp)
movq -0xe0(%rbp), %rax
leaq -0x1b0(%rbp), %rdi
leaq -0x1c0(%rbp), %rsi
leaq -0x1d0(%rbp), %rdx
leaq -0x1e0(%rbp), %rcx
leaq -0x1f0(%rbp), %r8
leaq -0x200(%rbp), %r9
movq %rax, (%rsp)
callq 0x17bc50
addq $0x210, %rsp            # imm = 0x210
popq %rbp
retq
nopw %cs:(%rax,%rax)