#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*/ SHA256_NSS(unsigned char *, unsigned char *, int);
int /*<<< orphan*/ SHA256_VST(unsigned char *, unsigned char *, int);
int /*<<< orphan*/ SHA256_sodium(unsigned char *, unsigned char *, int);
int /*<<< orphan*/ check_test(unsigned char *, unsigned char *, int, char *);
int /*<<< orphan*/ memset(unsigned char *, int /*<<< orphan*/, int);
void SHA256_Xcompare_35() {
  unsigned char input[79] = {
      194, 110, 162, 37,  162, 113, 122, 100, 202, 225, 115, 149, 109, 216,
      92,  100, 198, 68,  161, 6,   100, 30,  215, 228, 196, 105, 118, 3,
      135, 97,  233, 30,  47,  174, 240, 122, 63,  211, 185, 170, 53,  195,
      144, 84,  157, 76,  216, 215, 238, 220, 5,   56,  15,  111, 156, 7,
      254, 102, 231, 129, 177, 28,  68,  175, 208, 174, 122, 218, 176, 43,
      194, 187, 155, 198, 215, 243, 90,  170, 131};
  unsigned char result0[32] = {0xA6, 0xAD, 0xB1, 0x28, 0x21, 0x4C, 0xB3, 0xD8,
                               0x5C, 0x64, 0x48, 0x8A, 0x3E, 0x2B, 0xA1, 0x46,
                               0x95, 0x66, 0xA0, 0x70, 0xB2, 0xAA, 0xA3, 0xF8,
                               0x3F, 0xA0, 0xF9, 0x35, 0x00, 0x3F, 0x7B, 0x84};
  unsigned char result1[32];
  memset(result1, 0, 32);
  SHA256_VST(input, result1, 79);
  check_test(result0, result1, 32,
             "Disagreement between given answer and SHA256_VST in "
             "SHA256_Xcompare_35\n");
  memset(result1, 0, 32);
  SHA256_NSS(input, result1, 79);
  check_test(result0, result1, 32,
             "Disagreement between given answer and SHA256_NSS in "
             "SHA256_Xcompare_35\n");
  memset(result1, 0, 32);
  SHA256_sodium(input, result1, 79);
  check_test(result0, result1, 32,
             "Disagreement between given answer and SHA256_sodium in "
             "SHA256_Xcompare_35\n");
}


x86 assembly (clang, -O0):
<SHA256_Xcompare_35>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
lea    -0x50(%rbp),%rdi
lea    0xe8a(%rip),%rsi
mov    $0x4f,%edx
call   1060 <memcpy@plt>
mov    0xec9(%rip),%rax
mov    %rax,-0x70(%rbp)
mov    0xec6(%rip),%rax
mov    %rax,-0x68(%rbp)
mov    0xec3(%rip),%rax
mov    %rax,-0x60(%rbp)
mov    0xec0(%rip),%rax
mov    %rax,-0x58(%rbp)
lea    -0x90(%rbp),%rdi
xor    %esi,%esi
mov    $0x20,%edx
call   1040 <memset@plt>
lea    -0x50(%rbp),%rdi
lea    -0x90(%rbp),%rsi
mov    $0x4f,%edx
call   1030 <SHA256_VST@plt>
lea    -0x70(%rbp),%rdi
lea    -0x90(%rbp),%rsi
mov    $0x20,%edx
lea    0xe85(%rip),%rcx
call   1080 <check_test@plt>
lea    -0x90(%rbp),%rdi
xor    %esi,%esi
mov    $0x20,%edx
call   1040 <memset@plt>
lea    -0x50(%rbp),%rdi
lea    -0x90(%rbp),%rsi
mov    $0x4f,%edx
call   1050 <SHA256_NSS@plt>
lea    -0x70(%rbp),%rdi
lea    -0x90(%rbp),%rsi
mov    $0x20,%edx
lea    0xe89(%rip),%rcx
call   1080 <check_test@plt>
lea    -0x90(%rbp),%rdi
xor    %esi,%esi
mov    $0x20,%edx
call   1040 <memset@plt>
lea    -0x50(%rbp),%rdi
lea    -0x90(%rbp),%rsi
mov    $0x4f,%edx
call   1070 <SHA256_sodium@plt>
lea    -0x70(%rbp),%rdi
lea    -0x90(%rbp),%rsi
mov    $0x20,%edx
lea    0xe8d(%rip),%rcx
call   1080 <check_test@plt>
add    $0x90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<SHA256_Xcompare_35>:
push   %r15
push   %r14
push   %rbx
sub    $0x90,%rsp
movups 0xedc(%rip),%xmm0
movups %xmm0,0x5f(%rsp)
movaps 0xec1(%rip),%xmm0
movaps %xmm0,0x50(%rsp)
movaps 0xea5(%rip),%xmm0
movaps %xmm0,0x40(%rsp)
movaps 0xe89(%rip),%xmm0
movaps %xmm0,0x30(%rsp)
movaps 0xe6d(%rip),%xmm0
movaps %xmm0,0x20(%rsp)
movaps 0xec1(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
movaps 0xea5(%rip),%xmm0
movaps %xmm0,(%rsp)
lea    0x70(%rsp),%rbx
mov    %rbx,%rdi
xor    %esi,%esi
mov    $0x20,%edx
call   1040 <memset@plt>
lea    0x20(%rsp),%r14
mov    %r14,%rdi
mov    %rbx,%rsi
mov    $0x4f,%edx
call   1030 <SHA256_VST@plt>
lea    0xe91(%rip),%rcx
mov    %rsp,%r15
mov    %r15,%rdi
mov    %rbx,%rsi
mov    $0x20,%edx
call   1070 <check_test@plt>
mov    %rbx,%rdi
xor    %esi,%esi
mov    $0x20,%edx
call   1040 <memset@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
mov    $0x4f,%edx
call   1050 <SHA256_NSS@plt>
lea    0xea0(%rip),%rcx
mov    %r15,%rdi
mov    %rbx,%rsi
mov    $0x20,%edx
call   1070 <check_test@plt>
mov    %rbx,%rdi
xor    %esi,%esi
mov    $0x20,%edx
call   1040 <memset@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
mov    $0x4f,%edx
call   1060 <SHA256_sodium@plt>
lea    0xeb2(%rip),%rcx
mov    %r15,%rdi
mov    %rbx,%rsi
mov    $0x20,%edx
call   1070 <check_test@plt>
add    $0x90,%rsp
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@__const.SHA256_Xcompare_35.input = [79 x i8] c"\C2n\A2%\A2qzd\CA\E1s\95m\D8\\d\C6D\A1\06d\1E\D7\E4\C4iv\03\87a\E9\1E/\AE\F0z?\D3\B9\AA5\C3\90T\9DL\D8\D7\EE\DC\058\0Fo\9C\07\FEf\E7\81\B1\1CD\AF\D0\AEz\DA\B0+\C2\BB\9B\C6\D7\F3Z\AA\83"
@__const.SHA256_Xcompare_35.result0 = [32 x i8] c"\A6\AD\B1(!L\B3\D8\\dH\8A>+\A1F\95f\A0p\B2\AA\A3\F8?\A0\F95\00?{\84"
@.str = [72 x i8] c"Disagreement between given answer and SHA256_VST in SHA256_Xcompare_35\0A\00"
@.str.1 = [72 x i8] c"Disagreement between given answer and SHA256_NSS in SHA256_Xcompare_35\0A\00"
@.str.2 = [75 x i8] c"Disagreement between given answer and SHA256_sodium in SHA256_Xcompare_35\0A\00"
define void @SHA256_Xcompare_35() {
%1 = alloca [79 x i8]
%2 = alloca [32 x i8]
%3 = alloca [32 x i8]
%4 = bitcast [79 x i8]* %1 to i8*
%5 = bitcast [32 x i8]* %2 to i8*
%6 = getelementptr inbounds [32 x i8], [32 x i8]* %3, i64 0, i64 0
%7 = call i32 @memset(i8* %6, i32 0, i32 32)
%8 = getelementptr inbounds [79 x i8], [79 x i8]* %1, i64 0, i64 0
%9 = getelementptr inbounds [32 x i8], [32 x i8]* %3, i64 0, i64 0
%10 = call i32 @SHA256_VST(i8* %8, i8* %9, i32 79)
%11 = getelementptr inbounds [32 x i8], [32 x i8]* %2, i64 0, i64 0
%12 = getelementptr inbounds [32 x i8], [32 x i8]* %3, i64 0, i64 0
%13 = call i32 @check_test(i8* %11, i8* %12, i32 32, i8* getelementptr inbounds ([72 x i8], [72 x i8]* @.str, i64 0, i64 0))
%14 = getelementptr inbounds [32 x i8], [32 x i8]* %3, i64 0, i64 0
%15 = call i32 @memset(i8* %14, i32 0, i32 32)
%16 = getelementptr inbounds [79 x i8], [79 x i8]* %1, i64 0, i64 0
%17 = getelementptr inbounds [32 x i8], [32 x i8]* %3, i64 0, i64 0
%18 = call i32 @SHA256_NSS(i8* %16, i8* %17, i32 79)
%19 = getelementptr inbounds [32 x i8], [32 x i8]* %2, i64 0, i64 0
%20 = getelementptr inbounds [32 x i8], [32 x i8]* %3, i64 0, i64 0
%21 = call i32 @check_test(i8* %19, i8* %20, i32 32, i8* getelementptr inbounds ([72 x i8], [72 x i8]* @.str.1, i64 0, i64 0))
%22 = getelementptr inbounds [32 x i8], [32 x i8]* %3, i64 0, i64 0
%23 = call i32 @memset(i8* %22, i32 0, i32 32)
%24 = getelementptr inbounds [79 x i8], [79 x i8]* %1, i64 0, i64 0
%25 = getelementptr inbounds [32 x i8], [32 x i8]* %3, i64 0, i64 0
%26 = call i32 @SHA256_sodium(i8* %24, i8* %25, i32 79)
%27 = getelementptr inbounds [32 x i8], [32 x i8]* %2, i64 0, i64 0
%28 = getelementptr inbounds [32 x i8], [32 x i8]* %3, i64 0, i64 0
%29 = call i32 @check_test(i8* %27, i8* %28, i32 32, i8* getelementptr inbounds ([75 x i8], [75 x i8]* @.str.2, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@__const.SHA256_Xcompare_35.input = [79 x i8] c"\C2n\A2%\A2qzd\CA\E1s\95m\D8\\d\C6D\A1\06d\1E\D7\E4\C4iv\03\87a\E9\1E/\AE\F0z?\D3\B9\AA5\C3\90T\9DL\D8\D7\EE\DC\058\0Fo\9C\07\FEf\E7\81\B1\1CD\AF\D0\AEz\DA\B0+\C2\BB\9B\C6\D7\F3Z\AA\83"
@__const.SHA256_Xcompare_35.result0 = [32 x i8] c"\A6\AD\B1(!L\B3\D8\\dH\8A>+\A1F\95f\A0p\B2\AA\A3\F8?\A0\F95\00?{\84"
@.str = [72 x i8] c"Disagreement between given answer and SHA256_VST in SHA256_Xcompare_35\0A\00"
@.str.1 = [72 x i8] c"Disagreement between given answer and SHA256_NSS in SHA256_Xcompare_35\0A\00"
@.str.2 = [75 x i8] c"Disagreement between given answer and SHA256_sodium in SHA256_Xcompare_35\0A\00"
define void @SHA256_Xcompare_35() {
%1 = alloca [79 x i8]
%2 = alloca [32 x i8]
%3 = alloca [32 x i8]
%4 = getelementptr inbounds [79 x i8], [79 x i8]* %1, i64 0, i64 0
%5 = getelementptr inbounds [32 x i8], [32 x i8]* %2, i64 0, i64 0
%6 = getelementptr inbounds [32 x i8], [32 x i8]* %3, i64 0, i64 0
%7 = call i32 @memset(i8* %6, i32 0, i32 32)
%8 = call i32 @SHA256_VST(i8* %4, i8* %6, i32 79)
%9 = call i32 @check_test(i8* %5, i8* %6, i32 32, i8* getelementptr inbounds ([72 x i8], [72 x i8]* @.str, i64 0, i64 0))
%10 = call i32 @memset(i8* %6, i32 0, i32 32)
%11 = call i32 @SHA256_NSS(i8* %4, i8* %6, i32 79)
%12 = call i32 @check_test(i8* %5, i8* %6, i32 32, i8* getelementptr inbounds ([72 x i8], [72 x i8]* @.str.1, i64 0, i64 0))
%13 = call i32 @memset(i8* %6, i32 0, i32 32)
%14 = call i32 @SHA256_sodium(i8* %4, i8* %6, i32 79)
%15 = call i32 @check_test(i8* %5, i8* %6, i32 32, i8* getelementptr inbounds ([75 x i8], [75 x i8]* @.str.2, i64 0, i64 0))
ret void
}