#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 */
scalar_t__ cset82(unsigned char const *, int const, int, int /*<<< orphan*/,
                  int, int *, int *, char *);
scalar_t__ csum(unsigned char const *, int const, int, int, int, int *, int *,
                char *, int);
scalar_t__ key(unsigned char const *, int const, int, int, int, int *, int *,
               char *, int);
scalar_t__ numeric(unsigned char const *, int const, int, int, int, int *,
                   int *, char *);
scalar_t__ zero(unsigned char const *, int const, int /*<<< orphan*/, int, int,
                int *, int *, char *, int);
int n1_zero_n13_csum_key_x0__16(const unsigned char *data, const int data_len,
                                int *p_err_no, int *p_err_posn,
                                char err_msg[50]) {
  return data_len >= 14 && data_len <= 30 &&
         zero(data, data_len, 0, 1, 1, p_err_no, p_err_posn, err_msg, 1) &&
         csum(data, data_len, 1, 13, 13, p_err_no, p_err_posn, err_msg, 1) &&
         key(data, data_len, 1, 13, 13, p_err_no, p_err_posn, err_msg, 1) &&
         numeric(data, data_len, 0, 1, 1, p_err_no, p_err_posn, err_msg) &&
         zero(data, data_len, 0, 1, 1, p_err_no, p_err_posn, err_msg, 0) &&
         numeric(data, data_len, 1, 13, 13, p_err_no, p_err_posn, err_msg) &&
         csum(data, data_len, 1, 13, 13, p_err_no, p_err_posn, err_msg, 0) &&
         key(data, data_len, 1, 13, 13, p_err_no, p_err_posn, err_msg, 0) &&
         cset82(data, data_len, 14, 0, 16, p_err_no, p_err_posn, err_msg);
}


x86 assembly (clang, -O0):
<n1_zero_n13_csum_key_x0__16>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
xor    %eax,%eax
cmpl   $0xe,-0xc(%rbp)
mov    %al,-0x29(%rbp)
jl     13f4 <n1_zero_n13_csum_key_x0__16+0x2a4>
xor    %eax,%eax
cmpl   $0x1e,-0xc(%rbp)
mov    %al,-0x29(%rbp)
jg     13f4 <n1_zero_n13_csum_key_x0__16+0x2a4>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x18(%rbp),%r9
mov    -0x20(%rbp),%r10
mov    -0x28(%rbp),%rax
xor    %edx,%edx
mov    $0x1,%r8d
mov    %r8d,%ecx
mov    %r10,(%rsp)
mov    %rax,0x8(%rsp)
movl   $0x1,0x10(%rsp)
call   1060 <zero@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    $0x0,%rcx
mov    %al,-0x29(%rbp)
je     13f4 <n1_zero_n13_csum_key_x0__16+0x2a4>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x18(%rbp),%r9
mov    -0x20(%rbp),%r10
mov    -0x28(%rbp),%rax
mov    $0x1,%edx
mov    $0xd,%r8d
mov    %r8d,%ecx
mov    %r10,(%rsp)
mov    %rax,0x8(%rsp)
movl   $0x1,0x10(%rsp)
call   1030 <csum@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    $0x0,%rcx
mov    %al,-0x29(%rbp)
je     13f4 <n1_zero_n13_csum_key_x0__16+0x2a4>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x18(%rbp),%r9
mov    -0x20(%rbp),%r10
mov    -0x28(%rbp),%rax
mov    $0x1,%edx
mov    $0xd,%r8d
mov    %r8d,%ecx
mov    %r10,(%rsp)
mov    %rax,0x8(%rsp)
movl   $0x1,0x10(%rsp)
call   1040 <key@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    $0x0,%rcx
mov    %al,-0x29(%rbp)
je     13f4 <n1_zero_n13_csum_key_x0__16+0x2a4>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x18(%rbp),%r9
mov    -0x20(%rbp),%r10
mov    -0x28(%rbp),%rax
xor    %edx,%edx
mov    $0x1,%r8d
mov    %r8d,%ecx
mov    %r10,(%rsp)
mov    %rax,0x8(%rsp)
call   1050 <numeric@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    $0x0,%rcx
mov    %al,-0x29(%rbp)
je     13f4 <n1_zero_n13_csum_key_x0__16+0x2a4>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x18(%rbp),%r9
mov    -0x20(%rbp),%r10
mov    -0x28(%rbp),%rax
xor    %edx,%edx
mov    $0x1,%r8d
mov    %r8d,%ecx
mov    %r10,(%rsp)
mov    %rax,0x8(%rsp)
movl   $0x0,0x10(%rsp)
call   1060 <zero@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    $0x0,%rcx
mov    %al,-0x29(%rbp)
je     13f4 <n1_zero_n13_csum_key_x0__16+0x2a4>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x18(%rbp),%r9
mov    -0x20(%rbp),%r10
mov    -0x28(%rbp),%rax
mov    $0x1,%edx
mov    $0xd,%r8d
mov    %r8d,%ecx
mov    %r10,(%rsp)
mov    %rax,0x8(%rsp)
call   1050 <numeric@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    $0x0,%rcx
mov    %al,-0x29(%rbp)
je     13f4 <n1_zero_n13_csum_key_x0__16+0x2a4>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x18(%rbp),%r9
mov    -0x20(%rbp),%r10
mov    -0x28(%rbp),%rax
mov    $0x1,%edx
mov    $0xd,%r8d
xor    %ecx,%ecx
mov    %r8d,%ecx
mov    %r10,(%rsp)
mov    %rax,0x8(%rsp)
movl   $0x0,0x10(%rsp)
call   1030 <csum@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    $0x0,%rcx
mov    %al,-0x29(%rbp)
je     13f4 <n1_zero_n13_csum_key_x0__16+0x2a4>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x18(%rbp),%r9
mov    -0x20(%rbp),%r10
mov    -0x28(%rbp),%rax
mov    $0x1,%edx
mov    $0xd,%r8d
xor    %ecx,%ecx
mov    %r8d,%ecx
mov    %r10,(%rsp)
mov    %rax,0x8(%rsp)
movl   $0x0,0x10(%rsp)
call   1040 <key@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    $0x0,%rcx
mov    %al,-0x29(%rbp)
je     13f4 <n1_zero_n13_csum_key_x0__16+0x2a4>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x18(%rbp),%r9
mov    -0x20(%rbp),%r10
mov    -0x28(%rbp),%rax
mov    $0xe,%edx
xor    %ecx,%ecx
mov    $0x10,%r8d
mov    %r10,(%rsp)
mov    %rax,0x8(%rsp)
call   1070 <cset82@plt>
cmp    $0x0,%rax
setne  %al
mov    %al,-0x29(%rbp)
mov    -0x29(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<n1_zero_n13_csum_key_x0__16>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %esi,%ebx
lea    -0xe(%rbx),%eax
xor    %ebp,%ebp
cmp    $0x10,%eax
ja     1328 <n1_zero_n13_csum_key_x0__16+0x1d8>
mov    %r8,%r15
mov    %rcx,%r14
mov    %rdx,%r12
mov    %rdi,%r13
sub    $0x8,%rsp
xor    %ebp,%ebp
mov    %ebx,%esi
xor    %edx,%edx
mov    $0x1,%ecx
mov    $0x1,%r8d
mov    %r12,%r9
push   $0x1
push   %r15
push   %r14
call   1060 <zero@plt>
add    $0x20,%rsp
test   %rax,%rax
je     1328 <n1_zero_n13_csum_key_x0__16+0x1d8>
sub    $0x8,%rsp
mov    %r13,%rdi
mov    %ebx,%esi
mov    $0x1,%edx
mov    $0xd,%ecx
mov    $0xd,%r8d
mov    %r12,%r9
push   $0x1
push   %r15
push   %r14
call   1030 <csum@plt>
add    $0x20,%rsp
test   %rax,%rax
je     1328 <n1_zero_n13_csum_key_x0__16+0x1d8>
sub    $0x8,%rsp
mov    %r13,%rdi
mov    %ebx,%esi
mov    $0x1,%edx
mov    $0xd,%ecx
mov    $0xd,%r8d
mov    %r12,%r9
push   $0x1
push   %r15
push   %r14
call   1040 <key@plt>
add    $0x20,%rsp
test   %rax,%rax
je     1328 <n1_zero_n13_csum_key_x0__16+0x1d8>
xor    %ebp,%ebp
mov    %r13,%rdi
mov    %ebx,%esi
xor    %edx,%edx
mov    $0x1,%ecx
mov    $0x1,%r8d
mov    %r12,%r9
push   %r15
push   %r14
call   1050 <numeric@plt>
add    $0x10,%rsp
test   %rax,%rax
je     1328 <n1_zero_n13_csum_key_x0__16+0x1d8>
sub    $0x8,%rsp
xor    %ebp,%ebp
mov    %r13,%rdi
mov    %ebx,%esi
xor    %edx,%edx
mov    $0x1,%ecx
mov    $0x1,%r8d
mov    %r12,%r9
push   $0x0
push   %r15
push   %r14
call   1060 <zero@plt>
add    $0x20,%rsp
test   %rax,%rax
je     1328 <n1_zero_n13_csum_key_x0__16+0x1d8>
mov    %r13,%rdi
mov    %ebx,%esi
mov    $0x1,%edx
mov    $0xd,%ecx
mov    $0xd,%r8d
mov    %r12,%r9
push   %r15
push   %r14
call   1050 <numeric@plt>
add    $0x10,%rsp
test   %rax,%rax
je     1328 <n1_zero_n13_csum_key_x0__16+0x1d8>
sub    $0x8,%rsp
mov    %r13,%rdi
mov    %ebx,%esi
mov    $0x1,%edx
mov    $0xd,%ecx
mov    $0xd,%r8d
mov    %r12,%r9
push   $0x0
push   %r15
push   %r14
call   1030 <csum@plt>
add    $0x20,%rsp
test   %rax,%rax
je     1328 <n1_zero_n13_csum_key_x0__16+0x1d8>
sub    $0x8,%rsp
mov    %r13,%rdi
mov    %ebx,%esi
mov    $0x1,%edx
mov    $0xd,%ecx
mov    $0xd,%r8d
mov    %r12,%r9
push   $0x0
push   %r15
push   %r14
call   1040 <key@plt>
add    $0x20,%rsp
test   %rax,%rax
je     1328 <n1_zero_n13_csum_key_x0__16+0x1d8>
mov    %r13,%rdi
mov    %ebx,%esi
mov    $0xe,%edx
xor    %ecx,%ecx
mov    $0x10,%r8d
mov    %r12,%r9
push   %r15
push   %r14
call   1070 <cset82@plt>
add    $0x10,%rsp
xor    %ebp,%ebp
test   %rax,%rax
setne  %bpl
mov    %ebp,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define i32 @n1_zero_n13_csum_key_x0__16(i8* %0, i32 %1, i32* %2, i32* %3, i8* %4) {
%6 = alloca i8*
%7 = alloca i32
%8 = alloca i32*
%9 = alloca i32*
%10 = alloca i8*
store i8* %0, i8** %6
store i32 %1, i32* %7
store i32* %2, i32** %8
store i32* %3, i32** %9
store i8* %4, i8** %10
%11 = load i32, i32* %7
%12 = icmp sge i32 %11, 14
br i1 %12, label %13, label %88
13: ; preds = %5
%14 = load i32, i32* %7
%15 = icmp sle i32 %14, 30
br i1 %15, label %16, label %88
16: ; preds = %13
%17 = load i8*, i8** %6
%18 = load i32, i32* %7
%19 = load i32*, i32** %8
%20 = load i32*, i32** %9
%21 = load i8*, i8** %10
%22 = call i64 @zero(i8* %17, i32 %18, i32 0, i32 1, i32 1, i32* %19, i32* %20, i8* %21, i32 1)
%23 = icmp ne i64 %22, 0
br i1 %23, label %24, label %88
24: ; preds = %16
%25 = load i8*, i8** %6
%26 = load i32, i32* %7
%27 = load i32*, i32** %8
%28 = load i32*, i32** %9
%29 = load i8*, i8** %10
%30 = call i64 @csum(i8* %25, i32 %26, i32 1, i32 13, i32 13, i32* %27, i32* %28, i8* %29, i32 1)
%31 = icmp ne i64 %30, 0
br i1 %31, label %32, label %88
32: ; preds = %24
%33 = load i8*, i8** %6
%34 = load i32, i32* %7
%35 = load i32*, i32** %8
%36 = load i32*, i32** %9
%37 = load i8*, i8** %10
%38 = call i64 @key(i8* %33, i32 %34, i32 1, i32 13, i32 13, i32* %35, i32* %36, i8* %37, i32 1)
%39 = icmp ne i64 %38, 0
br i1 %39, label %40, label %88
40: ; preds = %32
%41 = load i8*, i8** %6
%42 = load i32, i32* %7
%43 = load i32*, i32** %8
%44 = load i32*, i32** %9
%45 = load i8*, i8** %10
%46 = call i64 @numeric(i8* %41, i32 %42, i32 0, i32 1, i32 1, i32* %43, i32* %44, i8* %45)
%47 = icmp ne i64 %46, 0
br i1 %47, label %48, label %88
48: ; preds = %40
%49 = load i8*, i8** %6
%50 = load i32, i32* %7
%51 = load i32*, i32** %8
%52 = load i32*, i32** %9
%53 = load i8*, i8** %10
%54 = call i64 @zero(i8* %49, i32 %50, i32 0, i32 1, i32 1, i32* %51, i32* %52, i8* %53, i32 0)
%55 = icmp ne i64 %54, 0
br i1 %55, label %56, label %88
56: ; preds = %48
%57 = load i8*, i8** %6
%58 = load i32, i32* %7
%59 = load i32*, i32** %8
%60 = load i32*, i32** %9
%61 = load i8*, i8** %10
%62 = call i64 @numeric(i8* %57, i32 %58, i32 1, i32 13, i32 13, i32* %59, i32* %60, i8* %61)
%63 = icmp ne i64 %62, 0
br i1 %63, label %64, label %88
64: ; preds = %56
%65 = load i8*, i8** %6
%66 = load i32, i32* %7
%67 = load i32*, i32** %8
%68 = load i32*, i32** %9
%69 = load i8*, i8** %10
%70 = call i64 @csum(i8* %65, i32 %66, i32 1, i32 13, i32 13, i32* %67, i32* %68, i8* %69, i32 0)
%71 = icmp ne i64 %70, 0
br i1 %71, label %72, label %88
72: ; preds = %64
%73 = load i8*, i8** %6
%74 = load i32, i32* %7
%75 = load i32*, i32** %8
%76 = load i32*, i32** %9
%77 = load i8*, i8** %10
%78 = call i64 @key(i8* %73, i32 %74, i32 1, i32 13, i32 13, i32* %75, i32* %76, i8* %77, i32 0)
%79 = icmp ne i64 %78, 0
br i1 %79, label %80, label %88
80: ; preds = %72
%81 = load i8*, i8** %6
%82 = load i32, i32* %7
%83 = load i32*, i32** %8
%84 = load i32*, i32** %9
%85 = load i8*, i8** %10
%86 = call i64 @cset82(i8* %81, i32 %82, i32 14, i32 0, i32 16, i32* %83, i32* %84, i8* %85)
%87 = icmp ne i64 %86, 0
br label %88
88: ; preds = %80, %72, %64, %56, %48, %40, %32, %24, %16, %13, %5
%89 = phi i1 [ false, %72 ], [ false, %64 ], [ false, %56 ], [ false, %48 ], [ false, %40 ], [ false, %32 ], [ false, %24 ], [ false, %16 ], [ false, %13 ], [ false, %5 ], [ %87, %80 ]
%90 = zext i1 %89 to i32
ret i32 %90
}

LLVM IR (-O2):
define i32 @n1_zero_n13_csum_key_x0__16(i8* %0, i32 %1, i32* %2, i32* %3, i8* %4) {
%6 = add i32 %1, -14
%7 = icmp ult i32 %6, 17
br i1 %7, label %8, label %36
8: ; preds = %5
%9 = tail call i64 @zero(i8* %0, i32 %1, i32 0, i32 1, i32 1, i32* %2, i32* %3, i8* %4, i32 1)
%10 = icmp eq i64 %9, 0
br i1 %10, label %36, label %11
11: ; preds = %8
%12 = tail call i64 @csum(i8* %0, i32 %1, i32 1, i32 13, i32 13, i32* %2, i32* %3, i8* %4, i32 1)
%13 = icmp eq i64 %12, 0
br i1 %13, label %36, label %14
14: ; preds = %11
%15 = tail call i64 @key(i8* %0, i32 %1, i32 1, i32 13, i32 13, i32* %2, i32* %3, i8* %4, i32 1)
%16 = icmp eq i64 %15, 0
br i1 %16, label %36, label %17
17: ; preds = %14
%18 = tail call i64 @numeric(i8* %0, i32 %1, i32 0, i32 1, i32 1, i32* %2, i32* %3, i8* %4)
%19 = icmp eq i64 %18, 0
br i1 %19, label %36, label %20
20: ; preds = %17
%21 = tail call i64 @zero(i8* %0, i32 %1, i32 0, i32 1, i32 1, i32* %2, i32* %3, i8* %4, i32 0)
%22 = icmp eq i64 %21, 0
br i1 %22, label %36, label %23
23: ; preds = %20
%24 = tail call i64 @numeric(i8* %0, i32 %1, i32 1, i32 13, i32 13, i32* %2, i32* %3, i8* %4)
%25 = icmp eq i64 %24, 0
br i1 %25, label %36, label %26
26: ; preds = %23
%27 = tail call i64 @csum(i8* %0, i32 %1, i32 1, i32 13, i32 13, i32* %2, i32* %3, i8* %4, i32 0)
%28 = icmp eq i64 %27, 0
br i1 %28, label %36, label %29
29: ; preds = %26
%30 = tail call i64 @key(i8* %0, i32 %1, i32 1, i32 13, i32 13, i32* %2, i32* %3, i8* %4, i32 0)
%31 = icmp eq i64 %30, 0
br i1 %31, label %36, label %32
32: ; preds = %29
%33 = tail call i64 @cset82(i8* %0, i32 %1, i32 14, i32 0, i32 16, i32* %2, i32* %3, i8* %4)
%34 = icmp ne i64 %33, 0
%35 = zext i1 %34 to i32
br label %36
36: ; preds = %32, %29, %26, %23, %20, %17, %14, %11, %8, %5
%37 = phi i32 [ 0, %29 ], [ 0, %26 ], [ 0, %23 ], [ 0, %20 ], [ 0, %17 ], [ 0, %14 ], [ 0, %11 ], [ 0, %8 ], [ 0, %5 ], [ %35, %32 ]
ret i32 %37
}