#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */
typedef int /*<<< orphan*/ int16_t;
typedef int /*<<< orphan*/ __m128i;

/* Variables and functions */
int /*<<< orphan*/ _mm_load_si128(int /*<<< orphan*/ const *);
int /*<<< orphan*/ _mm_set1_epi16(int);
int /*<<< orphan*/ _mm_sub_epi16(int /*<<< orphan*/, int /*<<< orphan*/);
void load_b_values(const int16_t *zbin_ptr, __m128i *zbin,
                   const int16_t *round_ptr, __m128i *round,
                   const int16_t *quant_ptr, __m128i *quant,
                   const int16_t *dequant_ptr, __m128i *dequant,
                   const int16_t *shift_ptr, __m128i *shift) {
  *zbin = _mm_load_si128((const __m128i *)zbin_ptr);
  *round = _mm_load_si128((const __m128i *)round_ptr);
  *quant = _mm_load_si128((const __m128i *)quant_ptr);
  *zbin = _mm_sub_epi16(*zbin, _mm_set1_epi16(1));
  *dequant = _mm_load_si128((const __m128i *)dequant_ptr);
  *shift = _mm_load_si128((const __m128i *)shift_ptr);
}


x86 assembly (clang, -O0):
<load_b_values>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    0x28(%rbp),%rax
mov    0x20(%rbp),%rax
mov    0x18(%rbp),%rax
mov    0x10(%rbp),%rax
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <_mm_load_si128@plt>
mov    %eax,%ecx
mov    -0x10(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x18(%rbp),%rdi
call   1030 <_mm_load_si128@plt>
mov    %eax,%ecx
mov    -0x20(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x28(%rbp),%rdi
call   1030 <_mm_load_si128@plt>
mov    %eax,%ecx
mov    -0x30(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x10(%rbp),%rax
mov    (%rax),%eax
mov    %eax,-0x34(%rbp)
mov    $0x1,%edi
call   1050 <_mm_set1_epi16@plt>
mov    -0x34(%rbp),%edi
mov    %eax,%esi
call   1040 <_mm_sub_epi16@plt>
mov    %eax,%ecx
mov    -0x10(%rbp),%rax
mov    %ecx,(%rax)
mov    0x10(%rbp),%rdi
call   1030 <_mm_load_si128@plt>
mov    %eax,%ecx
mov    0x18(%rbp),%rax
mov    %ecx,(%rax)
mov    0x20(%rbp),%rdi
call   1030 <_mm_load_si128@plt>
mov    %eax,%ecx
mov    0x28(%rbp),%rax
mov    %ecx,(%rax)
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<load_b_values>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %r9,%r12
mov    %r8,%r13
mov    %rcx,%rbp
mov    %rdx,%r14
mov    %rsi,%rbx
mov    0x40(%rsp),%r15
call   1030 <_mm_load_si128@plt>
mov    %eax,(%rbx)
mov    %r14,%rdi
call   1030 <_mm_load_si128@plt>
mov    %eax,0x0(%rbp)
mov    %r13,%rdi
call   1030 <_mm_load_si128@plt>
mov    %eax,(%r12)
mov    (%rbx),%ebp
mov    $0x1,%edi
call   1050 <_mm_set1_epi16@plt>
mov    %ebp,%edi
mov    %eax,%esi
call   1040 <_mm_sub_epi16@plt>
mov    %eax,(%rbx)
mov    %r15,%rdi
call   1030 <_mm_load_si128@plt>
mov    0x48(%rsp),%rcx
mov    %eax,(%rcx)
mov    0x50(%rsp),%rdi
call   1030 <_mm_load_si128@plt>
mov    0x58(%rsp),%rcx
mov    %eax,(%rcx)
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define void @load_b_values(i32* %0, i32* %1, i32* %2, i32* %3, i32* %4, i32* %5, i32* %6, i32* %7, i32* %8, i32* %9) {
%11 = alloca i32*
%12 = alloca i32*
%13 = alloca i32*
%14 = alloca i32*
%15 = alloca i32*
%16 = alloca i32*
%17 = alloca i32*
%18 = alloca i32*
%19 = alloca i32*
%20 = alloca i32*
store i32* %0, i32** %11
store i32* %1, i32** %12
store i32* %2, i32** %13
store i32* %3, i32** %14
store i32* %4, i32** %15
store i32* %5, i32** %16
store i32* %6, i32** %17
store i32* %7, i32** %18
store i32* %8, i32** %19
store i32* %9, i32** %20
%21 = load i32*, i32** %11
%22 = call i32 @_mm_load_si128(i32* %21)
%23 = load i32*, i32** %12
store i32 %22, i32* %23
%24 = load i32*, i32** %13
%25 = call i32 @_mm_load_si128(i32* %24)
%26 = load i32*, i32** %14
store i32 %25, i32* %26
%27 = load i32*, i32** %15
%28 = call i32 @_mm_load_si128(i32* %27)
%29 = load i32*, i32** %16
store i32 %28, i32* %29
%30 = load i32*, i32** %12
%31 = load i32, i32* %30
%32 = call i32 @_mm_set1_epi16(i32 1)
%33 = call i32 @_mm_sub_epi16(i32 %31, i32 %32)
%34 = load i32*, i32** %12
store i32 %33, i32* %34
%35 = load i32*, i32** %17
%36 = call i32 @_mm_load_si128(i32* %35)
%37 = load i32*, i32** %18
store i32 %36, i32* %37
%38 = load i32*, i32** %19
%39 = call i32 @_mm_load_si128(i32* %38)
%40 = load i32*, i32** %20
store i32 %39, i32* %40
ret void
}

LLVM IR (-O2):
define void @load_b_values(i32* %0, i32* nocapture %1, i32* %2, i32* nocapture writeonly %3, i32* %4, i32* nocapture writeonly %5, i32* %6, i32* nocapture writeonly %7, i32* %8, i32* nocapture writeonly %9) {
%11 = tail call i32 @_mm_load_si128(i32* %0)
store i32 %11, i32* %1
%12 = tail call i32 @_mm_load_si128(i32* %2)
store i32 %12, i32* %3
%13 = tail call i32 @_mm_load_si128(i32* %4)
store i32 %13, i32* %5
%14 = load i32, i32* %1
%15 = tail call i32 @_mm_set1_epi16(i32 1)
%16 = tail call i32 @_mm_sub_epi16(i32 %14, i32 %15)
store i32 %16, i32* %1
%17 = tail call i32 @_mm_load_si128(i32* %6)
store i32 %17, i32* %7
%18 = tail call i32 @_mm_load_si128(i32* %8)
store i32 %18, i32* %9
ret void
}