#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__ Verify(char *, int, char *, char *, int /*<<< orphan*/);
int /*<<< orphan*/ trio_isinf(double);
int /*<<< orphan*/ trio_isnan(double);
double trio_nan();
double trio_ninf();
double trio_pinf();
int VerifyNaN(void) {
  double ninf_number = trio_ninf();
  double pinf_number = trio_pinf();
  double nan_number = trio_nan();
  int nerrors = 0;
  nerrors += Verify("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                    "outputs/2022-01-22/02-19-57/repos/hypermail-project/"
                    "hypermail/refs/heads/master/src/trio/regression.c",
                    1649, "-1", "%d", trio_isinf(ninf_number));
  nerrors += Verify("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                    "outputs/2022-01-22/02-19-57/repos/hypermail-project/"
                    "hypermail/refs/heads/master/src/trio/regression.c",
                    1651, "0", "%d", trio_isinf(42.0));
  nerrors += Verify("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                    "outputs/2022-01-22/02-19-57/repos/hypermail-project/"
                    "hypermail/refs/heads/master/src/trio/regression.c",
                    1653, "1", "%d", trio_isinf(pinf_number));
  nerrors += Verify("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                    "outputs/2022-01-22/02-19-57/repos/hypermail-project/"
                    "hypermail/refs/heads/master/src/trio/regression.c",
                    1655, "1", "%d", trio_isnan(nan_number));
  nerrors += Verify("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                    "outputs/2022-01-22/02-19-57/repos/hypermail-project/"
                    "hypermail/refs/heads/master/src/trio/regression.c",
                    1657, "0", "%d", trio_isnan(42.0));
  return nerrors;
}


x86 assembly (clang, -O0):
<VerifyNaN>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    $0x0,%al
call   1050 <trio_ninf@plt>
movsd  %xmm0,-0x8(%rbp)
mov    $0x0,%al
call   1040 <trio_pinf@plt>
movsd  %xmm0,-0x10(%rbp)
mov    $0x0,%al
call   1060 <trio_nan@plt>
movsd  %xmm0,-0x18(%rbp)
movl   $0x0,-0x1c(%rbp)
movsd  -0x8(%rbp),%xmm0
call   1070 <trio_isinf@plt>
mov    %eax,%r8d
lea    0xe61(%rip),%rdi
mov    $0x671,%esi
lea    0xef3(%rip),%rdx
lea    0xeef(%rip),%rcx
call   1080 <Verify@plt>
mov    %rax,%rcx
movslq -0x1c(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0x1c(%rbp)
movsd  0xe2c(%rip),%xmm0
call   1070 <trio_isinf@plt>
mov    %eax,%r8d
lea    0xe25(%rip),%rdi
mov    $0x673,%esi
lea    0xebd(%rip),%rdx
lea    0xeb3(%rip),%rcx
call   1080 <Verify@plt>
mov    %rax,%rcx
movslq -0x1c(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0x1c(%rbp)
movsd  -0x10(%rbp),%xmm0
call   1070 <trio_isinf@plt>
mov    %eax,%r8d
lea    0xdec(%rip),%rdi
mov    $0x675,%esi
lea    0xe7f(%rip),%rdx
lea    0xe7a(%rip),%rcx
call   1080 <Verify@plt>
mov    %rax,%rcx
movslq -0x1c(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0x1c(%rbp)
movsd  -0x18(%rbp),%xmm0
call   1030 <trio_isnan@plt>
mov    %eax,%r8d
lea    0xdb3(%rip),%rdi
mov    $0x677,%esi
lea    0xe46(%rip),%rdx
lea    0xe41(%rip),%rcx
call   1080 <Verify@plt>
mov    %rax,%rcx
movslq -0x1c(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0x1c(%rbp)
movsd  0xd7e(%rip),%xmm0
call   1030 <trio_isnan@plt>
mov    %eax,%r8d
lea    0xd77(%rip),%rdi
mov    $0x679,%esi
lea    0xe0f(%rip),%rdx
lea    0xe05(%rip),%rcx
call   1080 <Verify@plt>
mov    %rax,%rcx
movslq -0x1c(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<VerifyNaN>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
xor    %eax,%eax
call   1050 <trio_ninf@plt>
movsd  %xmm0,(%rsp)
xor    %eax,%eax
call   1040 <trio_pinf@plt>
movsd  %xmm0,0x8(%rsp)
xor    %eax,%eax
call   1060 <trio_nan@plt>
movsd  %xmm0,0x10(%rsp)
movsd  (%rsp),%xmm0
call   1070 <trio_isinf@plt>
lea    0xe63(%rip),%r12
lea    0xefa(%rip),%rdx
lea    0xef6(%rip),%r14
mov    %r12,%rdi
mov    $0x671,%esi
mov    %r14,%rcx
mov    %eax,%r8d
call   1080 <Verify@plt>
mov    %rax,%r13
movsd  0xe2f(%rip),%xmm0
call   1070 <trio_isinf@plt>
lea    0xecf(%rip),%r15
mov    %r12,%rdi
mov    $0x673,%esi
mov    %r15,%rdx
mov    %r14,%rcx
mov    %eax,%r8d
call   1080 <Verify@plt>
mov    %rax,%rbx
add    %r13d,%ebx
movsd  0x8(%rsp),%xmm0
call   1070 <trio_isinf@plt>
lea    0xe9c(%rip),%r13
mov    %r12,%rdi
mov    $0x675,%esi
mov    %r13,%rdx
mov    %r14,%rcx
mov    %eax,%r8d
call   1080 <Verify@plt>
mov    %rax,%rbp
add    %ebx,%ebp
movsd  0x10(%rsp),%xmm0
call   1030 <trio_isnan@plt>
mov    %r12,%rdi
mov    $0x677,%esi
mov    %r13,%rdx
mov    %r14,%rcx
mov    %eax,%r8d
call   1080 <Verify@plt>
mov    %rax,%rbx
add    %ebp,%ebx
movsd  0xdac(%rip),%xmm0
call   1030 <trio_isnan@plt>
mov    %r12,%rdi
mov    $0x679,%esi
mov    %r15,%rdx
mov    %r14,%rcx
mov    %eax,%r8d
call   1080 <Verify@plt>
add    %ebx,%eax
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [158 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/hypermail-project/hypermail/refs/heads/master/src/trio/regression.c\00"
@.str.1 = [3 x i8] c"-1\00"
@.str.2 = [3 x i8] c"%d\00"
@.str.3 = [2 x i8] c"0\00"
@.str.4 = [2 x i8] c"1\00"
define i32 @VerifyNaN() {
%1 = alloca double
%2 = alloca double
%3 = alloca double
%4 = alloca i32
%5 = call double (...) @trio_ninf()
store double %5, double* %1
%6 = call double (...) @trio_pinf()
store double %6, double* %2
%7 = call double (...) @trio_nan()
store double %7, double* %3
store i32 0, i32* %4
%8 = load double, double* %1
%9 = call i32 @trio_isinf(double %8)
%10 = call i64 @Verify(i8* getelementptr inbounds ([158 x i8], [158 x i8]* @.str, i64 0, i64 0), i32 1649, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %9)
%11 = load i32, i32* %4
%12 = sext i32 %11 to i64
%13 = add nsw i64 %12, %10
%14 = trunc i64 %13 to i32
store i32 %14, i32* %4
%15 = call i32 @trio_isinf(double 4.200000e+01)
%16 = call i64 @Verify(i8* getelementptr inbounds ([158 x i8], [158 x i8]* @.str, i64 0, i64 0), i32 1651, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %15)
%17 = load i32, i32* %4
%18 = sext i32 %17 to i64
%19 = add nsw i64 %18, %16
%20 = trunc i64 %19 to i32
store i32 %20, i32* %4
%21 = load double, double* %2
%22 = call i32 @trio_isinf(double %21)
%23 = call i64 @Verify(i8* getelementptr inbounds ([158 x i8], [158 x i8]* @.str, i64 0, i64 0), i32 1653, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %22)
%24 = load i32, i32* %4
%25 = sext i32 %24 to i64
%26 = add nsw i64 %25, %23
%27 = trunc i64 %26 to i32
store i32 %27, i32* %4
%28 = load double, double* %3
%29 = call i32 @trio_isnan(double %28)
%30 = call i64 @Verify(i8* getelementptr inbounds ([158 x i8], [158 x i8]* @.str, i64 0, i64 0), i32 1655, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %29)
%31 = load i32, i32* %4
%32 = sext i32 %31 to i64
%33 = add nsw i64 %32, %30
%34 = trunc i64 %33 to i32
store i32 %34, i32* %4
%35 = call i32 @trio_isnan(double 4.200000e+01)
%36 = call i64 @Verify(i8* getelementptr inbounds ([158 x i8], [158 x i8]* @.str, i64 0, i64 0), i32 1657, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %35)
%37 = load i32, i32* %4
%38 = sext i32 %37 to i64
%39 = add nsw i64 %38, %36
%40 = trunc i64 %39 to i32
store i32 %40, i32* %4
%41 = load i32, i32* %4
ret i32 %41
}

LLVM IR (-O2):
@.str = [158 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/hypermail-project/hypermail/refs/heads/master/src/trio/regression.c\00"
@.str.1 = [3 x i8] c"-1\00"
@.str.2 = [3 x i8] c"%d\00"
@.str.3 = [2 x i8] c"0\00"
@.str.4 = [2 x i8] c"1\00"
define i32 @VerifyNaN() {
%1 = tail call double (...) @trio_ninf()
%2 = tail call double (...) @trio_pinf()
%3 = tail call double (...) @trio_nan()
%4 = tail call i32 @trio_isinf(double %1)
%5 = tail call i64 @Verify(i8* getelementptr inbounds ([158 x i8], [158 x i8]* @.str, i64 0, i64 0), i32 1649, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %4)
%6 = tail call i32 @trio_isinf(double 4.200000e+01)
%7 = tail call i64 @Verify(i8* getelementptr inbounds ([158 x i8], [158 x i8]* @.str, i64 0, i64 0), i32 1651, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %6)
%8 = add i64 %7, %5
%9 = tail call i32 @trio_isinf(double %2)
%10 = tail call i64 @Verify(i8* getelementptr inbounds ([158 x i8], [158 x i8]* @.str, i64 0, i64 0), i32 1653, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %9)
%11 = add i64 %8, %10
%12 = tail call i32 @trio_isnan(double %3)
%13 = tail call i64 @Verify(i8* getelementptr inbounds ([158 x i8], [158 x i8]* @.str, i64 0, i64 0), i32 1655, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %12)
%14 = add i64 %11, %13
%15 = tail call i32 @trio_isnan(double 4.200000e+01)
%16 = tail call i64 @Verify(i8* getelementptr inbounds ([158 x i8], [158 x i8]* @.str, i64 0, i64 0), i32 1657, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32 %15)
%17 = add i64 %14, %16
%18 = trunc i64 %17 to i32
ret i32 %18
}