#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 */
typedef int /*<<< orphan*/ sigset_t;

/* Variables and functions */
scalar_t__ SIGRTMIN;
int /*<<< orphan*/ sigaddset(int /*<<< orphan*/ *, scalar_t__);
int /*<<< orphan*/ sigemptyset(int /*<<< orphan*/ *);
int signalfd(int, int /*<<< orphan*/ *, int /*<<< orphan*/);
int itc_signalfd_init(void) {
  sigset_t seset;
  sigemptyset(&seset);
  sigaddset(&seset, SIGRTMIN + 1);
  sigaddset(&seset, SIGRTMIN + 2);
  sigaddset(&seset, SIGRTMIN + 3);
  sigaddset(&seset, SIGRTMIN + 4);
  sigaddset(&seset, SIGRTMIN + 7);
  sigaddset(&seset, SIGRTMIN + 5);
  sigaddset(&seset, SIGRTMIN + 6);
  return signalfd(-1, &seset, 0);
}


x86 assembly (clang, -O0):
<itc_signalfd_init>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    -0x4(%rbp),%rdi
call   1040 <sigemptyset@plt>
mov    0x2e98(%rip),%rax
mov    (%rax),%rsi
add    $0x1,%rsi
lea    -0x4(%rbp),%rdi
call   1050 <sigaddset@plt>
mov    0x2e81(%rip),%rax
mov    (%rax),%rsi
add    $0x2,%rsi
lea    -0x4(%rbp),%rdi
call   1050 <sigaddset@plt>
mov    0x2e6a(%rip),%rax
mov    (%rax),%rsi
add    $0x3,%rsi
lea    -0x4(%rbp),%rdi
call   1050 <sigaddset@plt>
mov    0x2e53(%rip),%rax
mov    (%rax),%rsi
add    $0x4,%rsi
lea    -0x4(%rbp),%rdi
call   1050 <sigaddset@plt>
mov    0x2e3c(%rip),%rax
mov    (%rax),%rsi
add    $0x7,%rsi
lea    -0x4(%rbp),%rdi
call   1050 <sigaddset@plt>
mov    0x2e25(%rip),%rax
mov    (%rax),%rsi
add    $0x5,%rsi
lea    -0x4(%rbp),%rdi
call   1050 <sigaddset@plt>
mov    0x2e0e(%rip),%rax
mov    (%rax),%rsi
add    $0x6,%rsi
lea    -0x4(%rbp),%rdi
call   1050 <sigaddset@plt>
mov    $0xffffffff,%edi
lea    -0x4(%rbp),%rsi
xor    %edx,%edx
call   1030 <signalfd@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<itc_signalfd_init>:
push   %r14
push   %rbx
push   %rax
lea    0x4(%rsp),%rbx
mov    %rbx,%rdi
call   1040 <sigemptyset@plt>
mov    0x2e98(%rip),%r14
mov    (%r14),%rsi
add    $0x1,%rsi
mov    %rbx,%rdi
call   1050 <sigaddset@plt>
mov    (%r14),%rsi
add    $0x2,%rsi
mov    %rbx,%rdi
call   1050 <sigaddset@plt>
mov    (%r14),%rsi
add    $0x3,%rsi
mov    %rbx,%rdi
call   1050 <sigaddset@plt>
mov    (%r14),%rsi
add    $0x4,%rsi
mov    %rbx,%rdi
call   1050 <sigaddset@plt>
mov    (%r14),%rsi
add    $0x7,%rsi
mov    %rbx,%rdi
call   1050 <sigaddset@plt>
mov    (%r14),%rsi
add    $0x5,%rsi
mov    %rbx,%rdi
call   1050 <sigaddset@plt>
mov    (%r14),%rsi
add    $0x6,%rsi
mov    %rbx,%rdi
call   1050 <sigaddset@plt>
mov    $0xffffffff,%edi
mov    %rbx,%rsi
xor    %edx,%edx
call   1030 <signalfd@plt>
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@SIGRTMIN = global i64 0
define i32 @itc_signalfd_init() {
%1 = alloca i32
%2 = call i32 @sigemptyset(i32* %1)
%3 = load i64, i64* @SIGRTMIN
%4 = add nsw i64 %3, 1
%5 = call i32 @sigaddset(i32* %1, i64 %4)
%6 = load i64, i64* @SIGRTMIN
%7 = add nsw i64 %6, 2
%8 = call i32 @sigaddset(i32* %1, i64 %7)
%9 = load i64, i64* @SIGRTMIN
%10 = add nsw i64 %9, 3
%11 = call i32 @sigaddset(i32* %1, i64 %10)
%12 = load i64, i64* @SIGRTMIN
%13 = add nsw i64 %12, 4
%14 = call i32 @sigaddset(i32* %1, i64 %13)
%15 = load i64, i64* @SIGRTMIN
%16 = add nsw i64 %15, 7
%17 = call i32 @sigaddset(i32* %1, i64 %16)
%18 = load i64, i64* @SIGRTMIN
%19 = add nsw i64 %18, 5
%20 = call i32 @sigaddset(i32* %1, i64 %19)
%21 = load i64, i64* @SIGRTMIN
%22 = add nsw i64 %21, 6
%23 = call i32 @sigaddset(i32* %1, i64 %22)
%24 = call i32 @signalfd(i32 -1, i32* %1, i32 0)
ret i32 %24
}

LLVM IR (-O2):
@SIGRTMIN = global i64 0
define i32 @itc_signalfd_init() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = call i32 @sigemptyset(i32* %1)
%4 = load i64, i64* @SIGRTMIN
%5 = add nsw i64 %4, 1
%6 = call i32 @sigaddset(i32* %1, i64 %5)
%7 = load i64, i64* @SIGRTMIN
%8 = add nsw i64 %7, 2
%9 = call i32 @sigaddset(i32* %1, i64 %8)
%10 = load i64, i64* @SIGRTMIN
%11 = add nsw i64 %10, 3
%12 = call i32 @sigaddset(i32* %1, i64 %11)
%13 = load i64, i64* @SIGRTMIN
%14 = add nsw i64 %13, 4
%15 = call i32 @sigaddset(i32* %1, i64 %14)
%16 = load i64, i64* @SIGRTMIN
%17 = add nsw i64 %16, 7
%18 = call i32 @sigaddset(i32* %1, i64 %17)
%19 = load i64, i64* @SIGRTMIN
%20 = add nsw i64 %19, 5
%21 = call i32 @sigaddset(i32* %1, i64 %20)
%22 = load i64, i64* @SIGRTMIN
%23 = add nsw i64 %22, 6
%24 = call i32 @sigaddset(i32* %1, i64 %23)
%25 = call i32 @signalfd(i32 -1, i32* %1, i32 0)
ret i32 %25
}