#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__ mpfr_divby0_p();
scalar_t__ mpfr_erangeflag_p();
scalar_t__ mpfr_inexflag_p();
scalar_t__ mpfr_nanflag_p();
scalar_t__ mpfr_overflow_p();
scalar_t__ mpfr_underflow_p();
int /*<<< orphan*/ printf(char *, char *, char *, char *, char *, char *,
                          char *);
void flags() {
  printf(
      "%s %s %s %s %s %s\n", mpfr_underflow_p() ? "true" : "false",
      mpfr_overflow_p() ? "true" : "false", mpfr_divby0_p() ? "true" : "false",
      mpfr_nanflag_p() ? "true" : "false", mpfr_inexflag_p() ? "true" : "false",
      mpfr_erangeflag_p() ? "true" : "false");
}


x86 assembly (clang, -O0):
<flags>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    $0x0,%al
call   1070 <mpfr_underflow_p@plt>
mov    %rax,%rdx
lea    0xe8f(%rip),%rax
lea    0xe83(%rip),%rcx
cmp    $0x0,%rdx
cmovne %rcx,%rax
mov    %rax,-0x28(%rbp)
mov    $0x0,%al
call   1090 <mpfr_overflow_p@plt>
mov    %rax,%rdx
lea    0xe6b(%rip),%rax
lea    0xe5f(%rip),%rcx
cmp    $0x0,%rdx
cmovne %rcx,%rax
mov    %rax,-0x20(%rbp)
mov    $0x0,%al
call   1050 <mpfr_divby0_p@plt>
mov    %rax,%rdx
lea    0xe47(%rip),%rax
lea    0xe3b(%rip),%rcx
cmp    $0x0,%rdx
cmovne %rcx,%rax
mov    %rax,-0x18(%rbp)
mov    $0x0,%al
call   1030 <mpfr_nanflag_p@plt>
mov    %rax,%rdx
lea    0xe23(%rip),%rax
lea    0xe17(%rip),%rcx
cmp    $0x0,%rdx
cmovne %rcx,%rax
mov    %rax,-0x10(%rbp)
mov    $0x0,%al
call   1080 <mpfr_inexflag_p@plt>
mov    %rax,%rdx
lea    0xdff(%rip),%rax
lea    0xdf3(%rip),%rcx
cmp    $0x0,%rdx
cmovne %rcx,%rax
mov    %rax,-0x8(%rbp)
mov    $0x0,%al
call   1060 <mpfr_erangeflag_p@plt>
mov    -0x28(%rbp),%rsi
mov    -0x20(%rbp),%rdx
mov    -0x18(%rbp),%rcx
mov    -0x10(%rbp),%r8
mov    -0x8(%rbp),%r9
mov    %rax,%r10
lea    0xdc7(%rip),%rax
lea    0xdbb(%rip),%rdi
cmp    $0x0,%r10
cmovne %rdi,%rax
lea    0xd99(%rip),%rdi
mov    %rax,(%rsp)
call   1040 <printf@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<flags>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
xor    %eax,%eax
call   1070 <mpfr_underflow_p@plt>
test   %rax,%rax
lea    0xe8c(%rip),%rbx
lea    0xe80(%rip),%rbp
mov    %rbp,%r14
cmove  %rbx,%r14
xor    %eax,%eax
call   1090 <mpfr_overflow_p@plt>
test   %rax,%rax
mov    %rbp,%r15
cmove  %rbx,%r15
xor    %eax,%eax
call   1050 <mpfr_divby0_p@plt>
test   %rax,%rax
mov    %rbp,%r12
cmove  %rbx,%r12
xor    %eax,%eax
call   1030 <mpfr_nanflag_p@plt>
test   %rax,%rax
mov    %rbp,%r13
cmove  %rbx,%r13
xor    %eax,%eax
call   1080 <mpfr_inexflag_p@plt>
test   %rax,%rax
mov    %rbp,%rbx
lea    0xe37(%rip),%rax
cmove  %rax,%rbx
xor    %eax,%eax
call   1060 <mpfr_erangeflag_p@plt>
test   %rax,%rax
lea    0xe22(%rip),%rax
cmove  %rax,%rbp
mov    %rbp,(%rsp)
lea    0xdfb(%rip),%rdi
mov    %r14,%rsi
mov    %r15,%rdx
mov    %r12,%rcx
mov    %r13,%r8
mov    %rbx,%r9
call   1040 <printf@plt>
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [19 x i8] c"%s %s %s %s %s %s\0A\00"
@.str.1 = [5 x i8] c"true\00"
@.str.2 = [6 x i8] c"false\00"
define void @flags() {
%1 = call i64 (...) @mpfr_underflow_p()
%2 = icmp ne i64 %1, 0
%3 = zext i1 %2 to i64
%4 = select i1 %2, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0)
%5 = call i64 (...) @mpfr_overflow_p()
%6 = icmp ne i64 %5, 0
%7 = zext i1 %6 to i64
%8 = select i1 %6, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0)
%9 = call i64 (...) @mpfr_divby0_p()
%10 = icmp ne i64 %9, 0
%11 = zext i1 %10 to i64
%12 = select i1 %10, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0)
%13 = call i64 (...) @mpfr_nanflag_p()
%14 = icmp ne i64 %13, 0
%15 = zext i1 %14 to i64
%16 = select i1 %14, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0)
%17 = call i64 (...) @mpfr_inexflag_p()
%18 = icmp ne i64 %17, 0
%19 = zext i1 %18 to i64
%20 = select i1 %18, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0)
%21 = call i64 (...) @mpfr_erangeflag_p()
%22 = icmp ne i64 %21, 0
%23 = zext i1 %22 to i64
%24 = select i1 %22, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0)
%25 = call i32 @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), i8* %4, i8* %8, i8* %12, i8* %16, i8* %20, i8* %24)
ret void
}

LLVM IR (-O2):
@.str = [19 x i8] c"%s %s %s %s %s %s\0A\00"
@.str.1 = [5 x i8] c"true\00"
@.str.2 = [6 x i8] c"false\00"
define void @flags() {
%1 = tail call i64 (...) @mpfr_underflow_p()
%2 = icmp eq i64 %1, 0
%3 = select i1 %2, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0)
%4 = tail call i64 (...) @mpfr_overflow_p()
%5 = icmp eq i64 %4, 0
%6 = select i1 %5, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0)
%7 = tail call i64 (...) @mpfr_divby0_p()
%8 = icmp eq i64 %7, 0
%9 = select i1 %8, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0)
%10 = tail call i64 (...) @mpfr_nanflag_p()
%11 = icmp eq i64 %10, 0
%12 = select i1 %11, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0)
%13 = tail call i64 (...) @mpfr_inexflag_p()
%14 = icmp eq i64 %13, 0
%15 = select i1 %14, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0)
%16 = tail call i64 (...) @mpfr_erangeflag_p()
%17 = icmp eq i64 %16, 0
%18 = select i1 %17, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0)
%19 = tail call i32 @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), i8* %3, i8* %6, i8* %9, i8* %12, i8* %15, i8* %18)
ret void
}