int main(argc, argv)
int argc;
char *argv[];
{
  int x;
  if (argc == 1)
    send_command("localhost", "RELOAD_TLE");
  else
    for (x = 1; x < argc; x++)
      send_command(argv[x], "RELOAD_TLE");
  exit(0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x1,-0x8(%rbp)
jne    115a <main+0x3a>
lea    0xeb9(%rip),%rdi
lea    0xebc(%rip),%rsi
mov    $0x0,%al
call   1030 <send_command@plt>
jmp    119a <main+0x7a>
movl   $0x1,-0x14(%rbp)
mov    -0x14(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1195 <main+0x75>
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    (%rax,%rcx,8),%rdi
lea    0xe8a(%rip),%rsi
mov    $0x0,%al
call   1030 <send_command@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1161 <main+0x41>
jmp    119a <main+0x7a>
xor    %edi,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
cmp    $0x1,%edi
jne    1149 <main+0x29>
lea    0xecc(%rip),%rdi
lea    0xecf(%rip),%rsi
xor    %eax,%eax
call   1030 <send_command@plt>
xor    %edi,%edi
call   1040 <exit@plt>
jle    1177 <main+0x57>
mov    %rsi,%r15
mov    %edi,%r12d
mov    $0x1,%ebx
lea    0xead(%rip),%r14
nopl   (%rax)
mov    (%r15,%rbx,8),%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1030 <send_command@plt>
add    $0x1,%rbx
cmp    %rbx,%r12
jne    1160 <main+0x40>
xor    %edi,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [10 x i8] c"localhost\00"
@.str.1 = [11 x i8] c"RELOAD_TLE\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%7 = load i32, i32* %4
%8 = icmp eq i32 %7, 1
br i1 %8, label %9, label %11
9: ; preds = %2
%10 = call i32 (i8*, i8*, ...) bitcast (i32 (...)* @send_command to i32 (i8*, i8*, ...)*)(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0))
br label %27
11: ; preds = %2
store i32 1, i32* %6
br label %12
12: ; preds = %23, %11
%13 = load i32, i32* %6
%14 = load i32, i32* %4
%15 = icmp slt i32 %13, %14
br i1 %15, label %16, label %26
16: ; preds = %12
%17 = load i8**, i8*** %5
%18 = load i32, i32* %6
%19 = sext i32 %18 to i64
%20 = getelementptr inbounds i8*, i8** %17, i64 %19
%21 = load i8*, i8** %20
%22 = call i32 (i8*, i8*, ...) bitcast (i32 (...)* @send_command to i32 (i8*, i8*, ...)*)(i8* %21, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0))
br label %23
23: ; preds = %16
%24 = load i32, i32* %6
%25 = add nsw i32 %24, 1
store i32 %25, i32* %6
br label %12
26: ; preds = %12
br label %27
27: ; preds = %26, %9
unreachable
}

LLVM IR (-O2):
@.str = [10 x i8] c"localhost\00"
@.str.1 = [11 x i8] c"RELOAD_TLE\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp eq i32 %0, 1
br i1 %3, label %8, label %4
4: ; preds = %2
%5 = icmp sgt i32 %0, 1
br i1 %5, label %6, label %17
6: ; preds = %4
%7 = zext i32 %0 to i64
br label %10
8: ; preds = %2
%9 = tail call i32 (i8*, i8*, ...) bitcast (i32 (...)* @send_command to i32 (i8*, i8*, ...)*)(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0))
br label %17
10: ; preds = %6, %10
%11 = phi i64 [ 1, %6 ], [ %15, %10 ]
%12 = getelementptr inbounds i8*, i8** %1, i64 %11
%13 = load i8*, i8** %12
%14 = tail call i32 (i8*, i8*, ...) bitcast (i32 (...)* @send_command to i32 (i8*, i8*, ...)*)(i8* %13, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0))
%15 = add nuw nsw i64 %11, 1
%16 = icmp eq i64 %15, %7
br i1 %16, label %17, label %10
17: ; preds = %10, %4, %8
tail call void @exit(i32 0)
unreachable
}