#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 */
struct addrinfo {
  int /*<<< orphan*/ ai_addrlen;
  int /*<<< orphan*/ ai_addr;
  int /*<<< orphan*/ ai_protocol;
  int /*<<< orphan*/ ai_socktype;
  int /*<<< orphan*/ ai_family;
  struct addrinfo *ai_next;
};
typedef int /*<<< orphan*/ bcastperm;

/* Variables and functions */
int /*<<< orphan*/ AF_UNSPEC;
int /*<<< orphan*/ SOCK_DGRAM;
int /*<<< orphan*/ SOL_SOCKET;
int /*<<< orphan*/ SO_BROADCAST;
int /*<<< orphan*/ close(int);
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, ...);
int /*<<< orphan*/ freeaddrinfo(struct addrinfo *);
char *gai_strerror(int);
int getaddrinfo(char *, char *, struct addrinfo *, struct addrinfo **);
int /*<<< orphan*/ memset(struct addrinfo *, int /*<<< orphan*/, int);
int /*<<< orphan*/ perror(char *);
int /*<<< orphan*/ printf(char *);
int sendto(int, char *, int /*<<< orphan*/, int /*<<< orphan*/,
           int /*<<< orphan*/, int /*<<< orphan*/);
scalar_t__ setsockopt(int, int /*<<< orphan*/, int /*<<< orphan*/, void *, int);
int /*<<< orphan*/ sleep(int);
int socket(int /*<<< orphan*/, int /*<<< orphan*/, int /*<<< orphan*/);
int /*<<< orphan*/ stderr;
int /*<<< orphan*/ strlen(char *);
int main(int argc, char *argv[]) {
  printf("Sleeping for 15 seconds for DHCP to complete\n");
  sleep(15);
  int pinginterval = 5;
  int sockfd;
  struct addrinfo hints, *servinfo, *p;
  int rv;
  int numbytes;
  char dataToSend[] = "hlfds ping";
  memset(&hints, 0, sizeof hints);
  hints.ai_family = AF_UNSPEC;
  hints.ai_socktype = SOCK_DGRAM;
  if ((rv = getaddrinfo("255.255.255.255", "7373", &hints, &servinfo)) != 0) {
    fprintf(stderr, "getaddrinfo: %s\n", gai_strerror(rv));
    return 1;
  }
  for (p = servinfo; p != NULL; p = p->ai_next) {
    if ((sockfd = socket(p->ai_family, p->ai_socktype, p->ai_protocol)) == -1) {
      perror("prannounce: socket");
      continue;
    }
    break;
  }
  int bcastperm = 1;
  if (setsockopt(sockfd, SOL_SOCKET, SO_BROADCAST, (void *)&bcastperm,
                 sizeof(bcastperm)) < 0) {
    perror("Can't set broadcast permission. Exiting.");
    exit(1);
  }
  if (p == NULL) {
    fprintf(stderr, "prannounce: failed to bind socket\n");
    return 2;
  }
  for (;;) {
    if ((numbytes = sendto(sockfd, dataToSend, strlen(dataToSend), 0,
                           p->ai_addr, p->ai_addrlen)) == -1) {
      perror("prannounce: sendto");
    }
    sleep(pinginterval);
  }
  freeaddrinfo(servinfo);
  close(sockfd);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x80,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xe20(%rip),%rdi
call   1050 <printf@plt>
mov    $0xf,%edi
call   10d0 <sleep@plt>
movl   $0x5,-0x14(%rbp)
mov    0xe31(%rip),%rax
mov    %rax,-0x5b(%rbp)
mov    0xe2e(%rip),%ax
mov    %ax,-0x53(%rbp)
mov    0xe26(%rip),%al
mov    %al,-0x51(%rbp)
lea    -0x38(%rbp),%rdi
xor    %esi,%esi
mov    $0x20,%edx
call   1070 <memset@plt>
mov    0x2db4(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x28(%rbp)
mov    0x2da0(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x2c(%rbp)
lea    0xdf5(%rip),%rdi
lea    0xdfe(%rip),%rsi
lea    -0x38(%rbp),%rdx
lea    -0x40(%rbp),%rcx
call   10c0 <getaddrinfo@plt>
mov    %eax,-0x4c(%rbp)
cmp    $0x0,%eax
je     1298 <main+0xd8>
mov    0x2d55(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x64(%rbp)
mov    -0x4c(%rbp),%edi
call   1060 <gai_strerror@plt>
mov    -0x64(%rbp),%edi
mov    %rax,%rdx
lea    0xdc9(%rip),%rsi
mov    $0x0,%al
call   1090 <fprintf@plt>
movl   $0x1,-0x4(%rbp)
jmp    13d1 <main+0x211>
mov    -0x40(%rbp),%rax
mov    %rax,-0x48(%rbp)
cmpq   $0x0,-0x48(%rbp)
je     12f8 <main+0x138>
mov    -0x48(%rbp),%rax
mov    0x10(%rax),%edi
mov    -0x48(%rbp),%rax
mov    0xc(%rax),%esi
mov    -0x48(%rbp),%rax
mov    0x8(%rax),%edx
call   10e0 <socket@plt>
mov    %eax,-0x18(%rbp)
cmp    $0xffffffff,%eax
jne    12e2 <main+0x122>
lea    0xd87(%rip),%rdi
call   10a0 <perror@plt>
jmp    12e7 <main+0x127>
jmp    12f8 <main+0x138>
mov    -0x48(%rbp),%rax
mov    0x18(%rax),%rax
mov    %rax,-0x48(%rbp)
jmp    12a0 <main+0xe0>
movl   $0x1,-0x60(%rbp)
mov    -0x18(%rbp),%edi
mov    0x2cdf(%rip),%rax
mov    (%rax),%esi
mov    0x2cbe(%rip),%rax
mov    (%rax),%edx
lea    -0x60(%rbp),%rcx
mov    $0x4,%r8d
call   1030 <setsockopt@plt>
cmp    $0x0,%rax
jge    1343 <main+0x183>
lea    0xd3e(%rip),%rdi
call   10a0 <perror@plt>
mov    $0x1,%edi
call   10b0 <exit@plt>
cmpq   $0x0,-0x48(%rbp)
jne    1371 <main+0x1b1>
mov    0x2c6b(%rip),%rax
mov    (%rax),%edi
lea    0xd3d(%rip),%rsi
mov    $0x0,%al
call   1090 <fprintf@plt>
movl   $0x2,-0x4(%rbp)
jmp    13d1 <main+0x211>
jmp    1376 <main+0x1b6>
mov    -0x18(%rbp),%eax
mov    %eax,-0x74(%rbp)
lea    -0x5b(%rbp),%rax
mov    %rax,-0x70(%rbp)
lea    -0x5b(%rbp),%rdi
call   1040 <strlen@plt>
mov    -0x74(%rbp),%edi
mov    -0x70(%rbp),%rsi
mov    %eax,%edx
mov    -0x48(%rbp),%rax
mov    0x4(%rax),%r8d
mov    -0x48(%rbp),%rax
mov    (%rax),%r9d
xor    %ecx,%ecx
call   1080 <sendto@plt>
mov    %eax,-0x50(%rbp)
cmp    $0xffffffff,%eax
jne    13c4 <main+0x204>
lea    0xcff(%rip),%rdi
call   10a0 <perror@plt>
mov    -0x14(%rbp),%edi
call   10d0 <sleep@plt>
jmp    1376 <main+0x1b6>
mov    -0x4(%rbp),%eax
add    $0x80,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %rbx
sub    $0x48,%rsp
lea    0xed2(%rip),%rdi
call   1030 <puts@plt>
mov    $0xf,%edi
call   10d0 <sleep@plt>
movabs $0x6970207364666c68,%rax
20 70 69
mov    %rax,0x10(%rsp)
movl   $0x676e69,0x17(%rsp)
lea    0x28(%rsp),%rbx
mov    %rbx,%rdi
xor    %esi,%esi
mov    $0x20,%edx
call   1070 <memset@plt>
mov    0x2dce(%rip),%rax
mov    (%rax),%eax
mov    %eax,0x38(%rsp)
mov    0x2db9(%rip),%rax
mov    (%rax),%eax
mov    %eax,0x34(%rsp)
lea    0xddf(%rip),%rdi
lea    0xde8(%rip),%rsi
lea    0x20(%rsp),%rcx
mov    %rbx,%rdx
call   10c0 <getaddrinfo@plt>
test   %eax,%eax
je     1271 <main+0xb1>
mov    0x2d75(%rip),%rcx
mov    (%rcx),%ebx
mov    %eax,%edi
call   1060 <gai_strerror@plt>
lea    0xdc5(%rip),%rsi
mov    %ebx,%edi
mov    %rax,%rdx
xor    %eax,%eax
call   1090 <fprintf@plt>
mov    $0x1,%eax
jmp    130c <main+0x14c>
mov    0x20(%rsp),%rbp
mov    $0xffffffff,%r15d
test   %rbp,%rbp
je     12b6 <main+0xf6>
lea    0xda9(%rip),%r14
mov    0x10(%rbp),%edi
mov    0x8(%rbp),%edx
mov    0xc(%rbp),%esi
call   10e0 <socket@plt>
cmp    $0xffffffff,%eax
sete   %bl
jne    12b1 <main+0xf1>
mov    %r14,%rdi
call   10a0 <perror@plt>
mov    0x18(%rbp),%rbp
test   %rbp,%rbp
jne    1288 <main+0xc8>
jmp    12b8 <main+0xf8>
mov    %eax,%r15d
jmp    12ba <main+0xfa>
mov    $0x1,%bl
xor    %ebp,%ebp
movl   $0x1,0xc(%rsp)
mov    0x2d1f(%rip),%rax
mov    (%rax),%esi
mov    0x2cfe(%rip),%rax
mov    (%rax),%edx
lea    0xc(%rsp),%rcx
mov    %r15d,%edi
mov    $0x4,%r8d
call   1040 <setsockopt@plt>
test   %rax,%rax
js     1368 <main+0x1a8>
test   %bl,%bl
je     1317 <main+0x157>
mov    0x2cc9(%rip),%rax
mov    (%rax),%edi
lea    0xd6d(%rip),%rsi
xor    %eax,%eax
call   1090 <fprintf@plt>
mov    $0x2,%eax
add    $0x48,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret
lea    0x10(%rsp),%rbx
lea    0xd6d(%rip),%r14
jmp    133a <main+0x17a>
cs nopw 0x0(%rax,%rax,1)
nop
mov    $0x5,%edi
call   10d0 <sleep@plt>
mov    %rbx,%rdi
call   1050 <strlen@plt>
mov    0x0(%rbp),%r9d
mov    0x4(%rbp),%r8d
mov    %r15d,%edi
mov    %rbx,%rsi
mov    %eax,%edx
xor    %ecx,%ecx
call   1080 <sendto@plt>
cmp    $0xffffffff,%eax
jne    1330 <main+0x170>
mov    %r14,%rdi
call   10a0 <perror@plt>
jmp    1330 <main+0x170>
lea    0xcd5(%rip),%rdi
call   10a0 <perror@plt>
mov    $0x1,%edi
call   10b0 <exit@plt>

LLVM IR (-O0):
%struct.addrinfo = type { i32, i32, i32, i32, i32, %struct.addrinfo* }
@.str = [46 x i8] c"Sleeping for 15 seconds for DHCP to complete\0A\00"
@__const.main.dataToSend = [11 x i8] c"hlfds ping\00"
@AF_UNSPEC = global i32 0
@SOCK_DGRAM = global i32 0
@.str.1 = [16 x i8] c"255.255.255.255\00"
@.str.2 = [5 x i8] c"7373\00"
@stderr = global i32 0
@.str.3 = [17 x i8] c"getaddrinfo: %s\0A\00"
@.str.4 = [19 x i8] c"prannounce: socket\00"
@SOL_SOCKET = global i32 0
@SO_BROADCAST = global i32 0
@.str.5 = [41 x i8] c"Can't set broadcast permission. Exiting.\00"
@.str.6 = [35 x i8] c"prannounce: failed to bind socket\0A\00"
@.str.7 = [19 x i8] c"prannounce: sendto\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i32
%8 = alloca %struct.addrinfo
%9 = alloca %struct.addrinfo*
%10 = alloca %struct.addrinfo*
%11 = alloca i32
%12 = alloca i32
%13 = alloca [11 x i8]
%14 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%15 = call i32 @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str, i64 0, i64 0))
%16 = call i32 @sleep(i32 15)
store i32 5, i32* %6
%17 = bitcast [11 x i8]* %13 to i8*
%18 = call i32 @memset(%struct.addrinfo* %8, i32 0, i32 32)
%19 = load i32, i32* @AF_UNSPEC
%20 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %8, i32 0, i32 4
store i32 %19, i32* %20
%21 = load i32, i32* @SOCK_DGRAM
%22 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %8, i32 0, i32 3
store i32 %21, i32* %22
%23 = call i32 @getaddrinfo(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0), %struct.addrinfo* %8, %struct.addrinfo** %9)
store i32 %23, i32* %11
%24 = icmp ne i32 %23, 0
br i1 %24, label %25, label %30
25: ; preds = %2
%26 = load i32, i32* @stderr
%27 = load i32, i32* %11
%28 = call i8* @gai_strerror(i32 %27)
%29 = call i32 (i32, i8*, ...) @fprintf(i32 %26, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.3, i64 0, i64 0), i8* %28)
store i32 1, i32* %3
br label %89
30: ; preds = %2
%31 = load %struct.addrinfo*, %struct.addrinfo** %9
store %struct.addrinfo* %31, %struct.addrinfo** %10
br label %32
32: ; preds = %50, %30
%33 = load %struct.addrinfo*, %struct.addrinfo** %10
%34 = icmp ne %struct.addrinfo* %33, null
br i1 %34, label %35, label %54
35: ; preds = %32
%36 = load %struct.addrinfo*, %struct.addrinfo** %10
%37 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %36, i32 0, i32 4
%38 = load i32, i32* %37
%39 = load %struct.addrinfo*, %struct.addrinfo** %10
%40 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %39, i32 0, i32 3
%41 = load i32, i32* %40
%42 = load %struct.addrinfo*, %struct.addrinfo** %10
%43 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %42, i32 0, i32 2
%44 = load i32, i32* %43
%45 = call i32 @socket(i32 %38, i32 %41, i32 %44)
store i32 %45, i32* %7
%46 = icmp eq i32 %45, -1
br i1 %46, label %47, label %49
47: ; preds = %35
%48 = call i32 @perror(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0))
br label %50
49: ; preds = %35
br label %54
50: ; preds = %47
%51 = load %struct.addrinfo*, %struct.addrinfo** %10
%52 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %51, i32 0, i32 5
%53 = load %struct.addrinfo*, %struct.addrinfo** %52
store %struct.addrinfo* %53, %struct.addrinfo** %10
br label %32
54: ; preds = %49, %32
store i32 1, i32* %14
%55 = load i32, i32* %7
%56 = load i32, i32* @SOL_SOCKET
%57 = load i32, i32* @SO_BROADCAST
%58 = bitcast i32* %14 to i8*
%59 = call i64 @setsockopt(i32 %55, i32 %56, i32 %57, i8* %58, i32 4)
%60 = icmp slt i64 %59, 0
br i1 %60, label %61, label %64
61: ; preds = %54
%62 = call i32 @perror(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.5, i64 0, i64 0))
%63 = call i32 @exit(i32 1)
unreachable
64: ; preds = %54
%65 = load %struct.addrinfo*, %struct.addrinfo** %10
%66 = icmp eq %struct.addrinfo* %65, null
br i1 %66, label %67, label %70
67: ; preds = %64
%68 = load i32, i32* @stderr
%69 = call i32 (i32, i8*, ...) @fprintf(i32 %68, i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.6, i64 0, i64 0))
store i32 2, i32* %3
br label %89
70: ; preds = %64
br label %71
71: ; preds = %86, %70
%72 = load i32, i32* %7
%73 = getelementptr inbounds [11 x i8], [11 x i8]* %13, i64 0, i64 0
%74 = getelementptr inbounds [11 x i8], [11 x i8]* %13, i64 0, i64 0
%75 = call i32 @strlen(i8* %74)
%76 = load %struct.addrinfo*, %struct.addrinfo** %10
%77 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %76, i32 0, i32 1
%78 = load i32, i32* %77
%79 = load %struct.addrinfo*, %struct.addrinfo** %10
%80 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %79, i32 0, i32 0
%81 = load i32, i32* %80
%82 = call i32 @sendto(i32 %72, i8* %73, i32 %75, i32 0, i32 %78, i32 %81)
store i32 %82, i32* %12
%83 = icmp eq i32 %82, -1
br i1 %83, label %84, label %86
84: ; preds = %71
%85 = call i32 @perror(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.7, i64 0, i64 0))
br label %86
86: ; preds = %84, %71
%87 = load i32, i32* %6
%88 = call i32 @sleep(i32 %87)
br label %71
89: ; preds = %67, %25
%90 = load i32, i32* %3
ret i32 %90
}

LLVM IR (-O2):
%struct.addrinfo = type { i32, i32, i32, i32, i32, %struct.addrinfo* }
@__const.main.dataToSend = [11 x i8] c"hlfds ping\00"
@AF_UNSPEC = global i32 0
@SOCK_DGRAM = global i32 0
@.str.1 = [16 x i8] c"255.255.255.255\00"
@.str.2 = [5 x i8] c"7373\00"
@stderr = global i32 0
@.str.3 = [17 x i8] c"getaddrinfo: %s\0A\00"
@.str.4 = [19 x i8] c"prannounce: socket\00"
@SOL_SOCKET = global i32 0
@SO_BROADCAST = global i32 0
@.str.5 = [41 x i8] c"Can't set broadcast permission. Exiting.\00"
@.str.6 = [35 x i8] c"prannounce: failed to bind socket\0A\00"
@.str.7 = [19 x i8] c"prannounce: sendto\00"
@str = [45 x i8] c"Sleeping for 15 seconds for DHCP to complete\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = alloca %struct.addrinfo
%4 = alloca %struct.addrinfo*
%5 = alloca [11 x i8]
%6 = alloca i32
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([45 x i8], [45 x i8]* @str, i64 0, i64 0))
%8 = tail call i32 @sleep(i32 15)
%9 = bitcast %struct.addrinfo* %3 to i8*
%10 = bitcast %struct.addrinfo** %4 to i8*
%11 = getelementptr inbounds [11 x i8], [11 x i8]* %5, i64 0, i64 0
%12 = call i32 @memset(%struct.addrinfo* %3, i32 0, i32 32)
%13 = load i32, i32* @AF_UNSPEC
%14 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %3, i64 0, i32 4
store i32 %13, i32* %14
%15 = load i32, i32* @SOCK_DGRAM
%16 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %3, i64 0, i32 3
store i32 %15, i32* %16
%17 = call i32 @getaddrinfo(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0), %struct.addrinfo* %3, %struct.addrinfo** %4)
%18 = icmp eq i32 %17, 0
br i1 %18, label %19, label %22
19: ; preds = %2
%20 = load %struct.addrinfo*, %struct.addrinfo** %4
%21 = icmp eq %struct.addrinfo* %20, null
br i1 %21, label %41, label %26
22: ; preds = %2
%23 = load i32, i32* @stderr
%24 = call i8* @gai_strerror(i32 %17)
%25 = call i32 (i32, i8*, ...) @fprintf(i32 %23, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.3, i64 0, i64 0), i8* %24)
br label %70
26: ; preds = %19, %36
%27 = phi %struct.addrinfo* [ %39, %36 ], [ %20, %19 ]
%28 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %27, i64 0, i32 4
%29 = load i32, i32* %28
%30 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %27, i64 0, i32 3
%31 = load i32, i32* %30
%32 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %27, i64 0, i32 2
%33 = load i32, i32* %32
%34 = call i32 @socket(i32 %29, i32 %31, i32 %33)
%35 = icmp eq i32 %34, -1
br i1 %35, label %36, label %41
36: ; preds = %26
%37 = call i32 @perror(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0))
%38 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %27, i64 0, i32 5
%39 = load %struct.addrinfo*, %struct.addrinfo** %38
%40 = icmp eq %struct.addrinfo* %39, null
br i1 %40, label %41, label %26
41: ; preds = %36, %26, %19
%42 = phi %struct.addrinfo* [ null, %19 ], [ %27, %26 ], [ null, %36 ]
%43 = phi i1 [ true, %19 ], [ %35, %26 ], [ %35, %36 ]
%44 = phi i32 [ -1, %19 ], [ %34, %26 ], [ -1, %36 ]
%45 = bitcast i32* %6 to i8*
store i32 1, i32* %6
%46 = load i32, i32* @SOL_SOCKET
%47 = load i32, i32* @SO_BROADCAST
%48 = call i64 @setsockopt(i32 %44, i32 %46, i32 %47, i8* %45, i32 4)
%49 = icmp slt i64 %48, 0
br i1 %49, label %50, label %53
50: ; preds = %41
%51 = call i32 @perror(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.5, i64 0, i64 0))
%52 = call i32 @exit(i32 1)
unreachable
53: ; preds = %41
br i1 %43, label %57, label %54
54: ; preds = %53
%55 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %42, i64 0, i32 1
%56 = getelementptr inbounds %struct.addrinfo, %struct.addrinfo* %42, i64 0, i32 0
br label %60
57: ; preds = %53
%58 = load i32, i32* @stderr
%59 = call i32 (i32, i8*, ...) @fprintf(i32 %58, i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.6, i64 0, i64 0))
br label %70
60: ; preds = %54, %68
%61 = call i32 @strlen(i8* %11)
%62 = load i32, i32* %55
%63 = load i32, i32* %56
%64 = call i32 @sendto(i32 %44, i8* %11, i32 %61, i32 0, i32 %62, i32 %63)
%65 = icmp eq i32 %64, -1
br i1 %65, label %66, label %68
66: ; preds = %60
%67 = call i32 @perror(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.7, i64 0, i64 0))
br label %68
68: ; preds = %66, %60
%69 = call i32 @sleep(i32 5)
br label %60
70: ; preds = %57, %22
%71 = phi i32 [ 1, %22 ], [ 2, %57 ]
ret i32 %71
}