#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*/ prnlog(char *);
int showHelp() {
  prnlog("Usage: loclass [options]");
  prnlog("Options:");
  prnlog("-t                 Perform self-test");
  prnlog("-h                 Show this help");
  prnlog("-f <filename>      Bruteforce iclass dumpfile");
  prnlog("                   An iclass dumpfile is assumed to consist of an "
         "arbitrary number of malicious CSNs, and their protocol responses");
  prnlog("                   The the binary format of the file is expected to "
         "be as follows: ");
  prnlog("                   <8 byte CSN><8 byte CC><4 byte NR><4 byte MAC>");
  prnlog("                   <8 byte CSN><8 byte CC><4 byte NR><4 byte MAC>");
  prnlog("                   <8 byte CSN><8 byte CC><4 byte NR><4 byte MAC>");
  prnlog("                  ... totalling N*24 bytes");
  prnlog("                  Check iclass_dump.bin for an example");
  return 0;
}


x86 assembly (clang, -O0):
<showHelp>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xef2(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xeef(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xf08(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xf1e(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xf40(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xfb7(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xfff(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xff3(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xfe7(%rip),%rdi
call   1030 <prnlog@plt>
lea    0x101d(%rip),%rdi
call   1030 <prnlog@plt>
lea    0x103c(%rip),%rdi
call   1030 <prnlog@plt>
xor    %eax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<showHelp>:
push   %rbx
lea    0xee8(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xef5(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xef2(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xf0b(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xf21(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xf43(%rip),%rdi
call   1030 <prnlog@plt>
lea    0xfba(%rip),%rdi
call   1030 <prnlog@plt>
lea    0x1002(%rip),%rbx
mov    %rbx,%rdi
call   1030 <prnlog@plt>
mov    %rbx,%rdi
call   1030 <prnlog@plt>
mov    %rbx,%rdi
call   1030 <prnlog@plt>
lea    0x1025(%rip),%rdi
call   1030 <prnlog@plt>
lea    0x1044(%rip),%rdi
call   1030 <prnlog@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [25 x i8] c"Usage: loclass [options]\00"
@.str.1 = [9 x i8] c"Options:\00"
@.str.2 = [37 x i8] c"-t Perform self-test\00"
@.str.3 = [34 x i8] c"-h Show this help\00"
@.str.4 = [46 x i8] c"-f <filename> Bruteforce iclass dumpfile\00"
@.str.5 = [131 x i8] c" An iclass dumpfile is assumed to consist of an arbitrary number of malicious CSNs, and their protocol responses\00"
@.str.6 = [84 x i8] c" The the binary format of the file is expected to be as follows: \00"
@.str.7 = [66 x i8] c" <8 byte CSN><8 byte CC><4 byte NR><4 byte MAC>\00"
@.str.8 = [43 x i8] c" ... totalling N*24 bytes\00"
@.str.9 = [55 x i8] c" Check iclass_dump.bin for an example\00"
define i32 @showHelp() {
%1 = call i32 @prnlog(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @prnlog(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 @prnlog(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.2, i64 0, i64 0))
%4 = call i32 @prnlog(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.3, i64 0, i64 0))
%5 = call i32 @prnlog(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.4, i64 0, i64 0))
%6 = call i32 @prnlog(i8* getelementptr inbounds ([131 x i8], [131 x i8]* @.str.5, i64 0, i64 0))
%7 = call i32 @prnlog(i8* getelementptr inbounds ([84 x i8], [84 x i8]* @.str.6, i64 0, i64 0))
%8 = call i32 @prnlog(i8* getelementptr inbounds ([66 x i8], [66 x i8]* @.str.7, i64 0, i64 0))
%9 = call i32 @prnlog(i8* getelementptr inbounds ([66 x i8], [66 x i8]* @.str.7, i64 0, i64 0))
%10 = call i32 @prnlog(i8* getelementptr inbounds ([66 x i8], [66 x i8]* @.str.7, i64 0, i64 0))
%11 = call i32 @prnlog(i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.8, i64 0, i64 0))
%12 = call i32 @prnlog(i8* getelementptr inbounds ([55 x i8], [55 x i8]* @.str.9, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@.str = [25 x i8] c"Usage: loclass [options]\00"
@.str.1 = [9 x i8] c"Options:\00"
@.str.2 = [37 x i8] c"-t Perform self-test\00"
@.str.3 = [34 x i8] c"-h Show this help\00"
@.str.4 = [46 x i8] c"-f <filename> Bruteforce iclass dumpfile\00"
@.str.5 = [131 x i8] c" An iclass dumpfile is assumed to consist of an arbitrary number of malicious CSNs, and their protocol responses\00"
@.str.6 = [84 x i8] c" The the binary format of the file is expected to be as follows: \00"
@.str.7 = [66 x i8] c" <8 byte CSN><8 byte CC><4 byte NR><4 byte MAC>\00"
@.str.8 = [43 x i8] c" ... totalling N*24 bytes\00"
@.str.9 = [55 x i8] c" Check iclass_dump.bin for an example\00"
define i32 @showHelp() {
%1 = tail call i32 @prnlog(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @prnlog(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i32 @prnlog(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.2, i64 0, i64 0))
%4 = tail call i32 @prnlog(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.3, i64 0, i64 0))
%5 = tail call i32 @prnlog(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.4, i64 0, i64 0))
%6 = tail call i32 @prnlog(i8* getelementptr inbounds ([131 x i8], [131 x i8]* @.str.5, i64 0, i64 0))
%7 = tail call i32 @prnlog(i8* getelementptr inbounds ([84 x i8], [84 x i8]* @.str.6, i64 0, i64 0))
%8 = tail call i32 @prnlog(i8* getelementptr inbounds ([66 x i8], [66 x i8]* @.str.7, i64 0, i64 0))
%9 = tail call i32 @prnlog(i8* getelementptr inbounds ([66 x i8], [66 x i8]* @.str.7, i64 0, i64 0))
%10 = tail call i32 @prnlog(i8* getelementptr inbounds ([66 x i8], [66 x i8]* @.str.7, i64 0, i64 0))
%11 = tail call i32 @prnlog(i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.8, i64 0, i64 0))
%12 = tail call i32 @prnlog(i8* getelementptr inbounds ([55 x i8], [55 x i8]* @.str.9, i64 0, i64 0))
ret i32 0
}