#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 */

/* Variables and functions */
int /*<<< orphan*/ hdSurEncPhase2_D2_0F_11_sub(unsigned char *, unsigned char *,
                                               int);
void hdSurEncPhase2_D2_0F_11(unsigned char *CWs) {
  hdSurEncPhase2_D2_0F_11_sub(CWs, CWs + 8, 0);
  hdSurEncPhase2_D2_0F_11_sub(CWs + 8, CWs, 1);
  hdSurEncPhase2_D2_0F_11_sub(CWs, CWs + 8, 2);
  hdSurEncPhase2_D2_0F_11_sub(CWs + 8, CWs, 3);
  hdSurEncPhase2_D2_0F_11_sub(CWs, CWs + 8, 4);
}


x86 assembly (clang, -O0):
<hdSurEncPhase2_D2_0F_11>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rsi
add    $0x8,%rsi
xor    %edx,%edx
call   1030 <hdSurEncPhase2_D2_0F_11_sub@plt>
mov    -0x8(%rbp),%rdi
add    $0x8,%rdi
mov    -0x8(%rbp),%rsi
mov    $0x1,%edx
call   1030 <hdSurEncPhase2_D2_0F_11_sub@plt>
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rsi
add    $0x8,%rsi
mov    $0x2,%edx
call   1030 <hdSurEncPhase2_D2_0F_11_sub@plt>
mov    -0x8(%rbp),%rdi
add    $0x8,%rdi
mov    -0x8(%rbp),%rsi
mov    $0x3,%edx
call   1030 <hdSurEncPhase2_D2_0F_11_sub@plt>
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rsi
add    $0x8,%rsi
mov    $0x4,%edx
call   1030 <hdSurEncPhase2_D2_0F_11_sub@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<hdSurEncPhase2_D2_0F_11>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%rbx
lea    0x8(%rdi),%r14
mov    %r14,%rsi
xor    %edx,%edx
call   1030 <hdSurEncPhase2_D2_0F_11_sub@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
mov    $0x1,%edx
call   1030 <hdSurEncPhase2_D2_0F_11_sub@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
mov    $0x2,%edx
call   1030 <hdSurEncPhase2_D2_0F_11_sub@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
mov    $0x3,%edx
call   1030 <hdSurEncPhase2_D2_0F_11_sub@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
mov    $0x4,%edx
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <hdSurEncPhase2_D2_0F_11_sub@plt>

LLVM IR (-O0):
define void @hdSurEncPhase2_D2_0F_11(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = load i8*, i8** %2
%5 = getelementptr inbounds i8, i8* %4, i64 8
%6 = call i32 @hdSurEncPhase2_D2_0F_11_sub(i8* %3, i8* %5, i32 0)
%7 = load i8*, i8** %2
%8 = getelementptr inbounds i8, i8* %7, i64 8
%9 = load i8*, i8** %2
%10 = call i32 @hdSurEncPhase2_D2_0F_11_sub(i8* %8, i8* %9, i32 1)
%11 = load i8*, i8** %2
%12 = load i8*, i8** %2
%13 = getelementptr inbounds i8, i8* %12, i64 8
%14 = call i32 @hdSurEncPhase2_D2_0F_11_sub(i8* %11, i8* %13, i32 2)
%15 = load i8*, i8** %2
%16 = getelementptr inbounds i8, i8* %15, i64 8
%17 = load i8*, i8** %2
%18 = call i32 @hdSurEncPhase2_D2_0F_11_sub(i8* %16, i8* %17, i32 3)
%19 = load i8*, i8** %2
%20 = load i8*, i8** %2
%21 = getelementptr inbounds i8, i8* %20, i64 8
%22 = call i32 @hdSurEncPhase2_D2_0F_11_sub(i8* %19, i8* %21, i32 4)
ret void
}

LLVM IR (-O2):
define void @hdSurEncPhase2_D2_0F_11(i8* %0) {
%2 = getelementptr inbounds i8, i8* %0, i64 8
%3 = tail call i32 @hdSurEncPhase2_D2_0F_11_sub(i8* %0, i8* %2, i32 0)
%4 = tail call i32 @hdSurEncPhase2_D2_0F_11_sub(i8* %2, i8* %0, i32 1)
%5 = tail call i32 @hdSurEncPhase2_D2_0F_11_sub(i8* %0, i8* %2, i32 2)
%6 = tail call i32 @hdSurEncPhase2_D2_0F_11_sub(i8* %2, i8* %0, i32 3)
%7 = tail call i32 @hdSurEncPhase2_D2_0F_11_sub(i8* %0, i8* %2, i32 4)
ret void
}