#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 */
int /*<<< orphan*/ setDebugTracerLever(int);
void debuglvl(unsigned int argc, unsigned char (*argv_pointer)[10]) {
  if (argv_pointer[1][0] == '1') {
    setDebugTracerLever(1);
  } else if (argv_pointer[1][0] == '2') {
    setDebugTracerLever(2);
  } else if (argv_pointer[1][0] == '3') {
    setDebugTracerLever(3);
  }
}


x86 assembly (clang, -O0):
<debuglvl>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movzbl 0xa(%rax),%eax
cmp    $0x31,%eax
jne    113f <debuglvl+0x2f>
mov    $0x1,%edi
call   1030 <setDebugTracerLever@plt>
jmp    1184 <debuglvl+0x74>
mov    -0x10(%rbp),%rax
movzbl 0xa(%rax),%eax
cmp    $0x32,%eax
jne    115f <debuglvl+0x4f>
mov    $0x2,%edi
call   1030 <setDebugTracerLever@plt>
jmp    117f <debuglvl+0x6f>
mov    -0x10(%rbp),%rax
movzbl 0xa(%rax),%eax
cmp    $0x33,%eax
jne    117a <debuglvl+0x6a>
mov    $0x3,%edi
call   1030 <setDebugTracerLever@plt>
jmp    117f <debuglvl+0x6f>
jmp    1184 <debuglvl+0x74>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<debuglvl>:
mov    0xa(%rsi),%al
add    $0xcf,%al
cmp    $0x2,%al
ja     1124 <debuglvl+0x14>
movzbl %al,%edi
add    $0x1,%edi
jmp    1030 <setDebugTracerLever@plt>
ret

LLVM IR (-O0):
define void @debuglvl(i32 %0, [10 x i8]* %1) {
%3 = alloca i32
%4 = alloca [10 x i8]*
store i32 %0, i32* %3
store [10 x i8]* %1, [10 x i8]** %4
%5 = load [10 x i8]*, [10 x i8]** %4
%6 = getelementptr inbounds [10 x i8], [10 x i8]* %5, i64 1
%7 = getelementptr inbounds [10 x i8], [10 x i8]* %6, i64 0, i64 0
%8 = load i8, i8* %7
%9 = zext i8 %8 to i32
%10 = icmp eq i32 %9, 49
br i1 %10, label %11, label %13
11: ; preds = %2
%12 = call i32 @setDebugTracerLever(i32 1)
br label %33
13: ; preds = %2
%14 = load [10 x i8]*, [10 x i8]** %4
%15 = getelementptr inbounds [10 x i8], [10 x i8]* %14, i64 1
%16 = getelementptr inbounds [10 x i8], [10 x i8]* %15, i64 0, i64 0
%17 = load i8, i8* %16
%18 = zext i8 %17 to i32
%19 = icmp eq i32 %18, 50
br i1 %19, label %20, label %22
20: ; preds = %13
%21 = call i32 @setDebugTracerLever(i32 2)
br label %32
22: ; preds = %13
%23 = load [10 x i8]*, [10 x i8]** %4
%24 = getelementptr inbounds [10 x i8], [10 x i8]* %23, i64 1
%25 = getelementptr inbounds [10 x i8], [10 x i8]* %24, i64 0, i64 0
%26 = load i8, i8* %25
%27 = zext i8 %26 to i32
%28 = icmp eq i32 %27, 51
br i1 %28, label %29, label %31
29: ; preds = %22
%30 = call i32 @setDebugTracerLever(i32 3)
br label %31
31: ; preds = %29, %22
br label %32
32: ; preds = %31, %20
br label %33
33: ; preds = %32, %11
ret void
}

LLVM IR (-O2):
define void @debuglvl(i32 %0, [10 x i8]* nocapture %1) {
%3 = getelementptr inbounds [10 x i8], [10 x i8]* %1, i64 1, i64 0
%4 = load i8, i8* %3
%5 = add i8 %4, -49
%6 = icmp ult i8 %5, 3
br i1 %6, label %7, label %11
7: ; preds = %2
%8 = zext i8 %5 to i32
%9 = add nuw nsw i32 %8, 1
%10 = tail call i32 @setDebugTracerLever(i32 %9)
br label %11
11: ; preds = %2, %7
ret void
}