#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*/ cPrintf(char *);
void help(void) {
  cPrintf("valid commands are:\n");
  cPrintf("  help    get help\n");
  cPrintf("  +       add and subtract\n");
  cPrintf("  a       assemble\n");
  cPrintf("  u       unassemble\n");
  cPrintf("  b       set/reset breakpoint\n");
  cPrintf("  c       continue from breakpoint\n");
  cPrintf("  s       single-step\n");
  cPrintf("  #       show/set PC\n");
  cPrintf("  p       show/set PSW\n");
  cPrintf("  r       show/set register\n");
  cPrintf("  d       dump memory\n");
  cPrintf("  mw      show/set memory word\n");
  cPrintf("  mh      show/set memory halfword\n");
  cPrintf("  mb      show/set memory byte\n");
  cPrintf("  t       show/set TLB contents\n");
  cPrintf("  i       initialize hardware\n");
  cPrintf("  q       quit simulator\n");
  cPrintf("type 'help <cmd>' to get help for <cmd>\n");
}


x86 assembly (clang, -O0):
<help>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xeee(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xef6(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf06(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf0e(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf18(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf2c(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf44(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf4f(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf5a(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf66(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf77(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf82(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf96(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xfae(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xfc2(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xfd7(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xfea(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xff8(%rip),%rdi
call   1030 <cPrintf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<help>:
push   %rax
lea    0xee8(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xef1(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xef9(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf09(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf11(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf1b(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf2f(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf47(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf52(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf5d(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf69(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf7a(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf85(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xf99(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xfb1(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xfc5(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xfda(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xfed(%rip),%rdi
call   1030 <cPrintf@plt>
lea    0xffb(%rip),%rdi
pop    %rax
jmp    1030 <cPrintf@plt>

LLVM IR (-O0):
@.str = [21 x i8] c"valid commands are:\0A\00"
@.str.1 = [20 x i8] c" help get help\0A\00"
@.str.2 = [28 x i8] c" + add and subtract\0A\00"
@.str.3 = [20 x i8] c" a assemble\0A\00"
@.str.4 = [22 x i8] c" u unassemble\0A\00"
@.str.5 = [32 x i8] c" b set/reset breakpoint\0A\00"
@.str.6 = [36 x i8] c" c continue from breakpoint\0A\00"
@.str.7 = [23 x i8] c" s single-step\0A\00"
@.str.8 = [23 x i8] c" # show/set PC\0A\00"
@.str.9 = [24 x i8] c" p show/set PSW\0A\00"
@.str.10 = [29 x i8] c" r show/set register\0A\00"
@.str.11 = [23 x i8] c" d dump memory\0A\00"
@.str.12 = [32 x i8] c" mw show/set memory word\0A\00"
@.str.13 = [36 x i8] c" mh show/set memory halfword\0A\00"
@.str.14 = [32 x i8] c" mb show/set memory byte\0A\00"
@.str.15 = [33 x i8] c" t show/set TLB contents\0A\00"
@.str.16 = [31 x i8] c" i initialize hardware\0A\00"
@.str.17 = [26 x i8] c" q quit simulator\0A\00"
@.str.18 = [41 x i8] c"type 'help <cmd>' to get help for <cmd>\0A\00"
define void @help() {
%1 = call i32 @cPrintf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @cPrintf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 @cPrintf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.2, i64 0, i64 0))
%4 = call i32 @cPrintf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.3, i64 0, i64 0))
%5 = call i32 @cPrintf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.4, i64 0, i64 0))
%6 = call i32 @cPrintf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.5, i64 0, i64 0))
%7 = call i32 @cPrintf(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str.6, i64 0, i64 0))
%8 = call i32 @cPrintf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.7, i64 0, i64 0))
%9 = call i32 @cPrintf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.8, i64 0, i64 0))
%10 = call i32 @cPrintf(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.9, i64 0, i64 0))
%11 = call i32 @cPrintf(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.10, i64 0, i64 0))
%12 = call i32 @cPrintf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.11, i64 0, i64 0))
%13 = call i32 @cPrintf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.12, i64 0, i64 0))
%14 = call i32 @cPrintf(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str.13, i64 0, i64 0))
%15 = call i32 @cPrintf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.14, i64 0, i64 0))
%16 = call i32 @cPrintf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.15, i64 0, i64 0))
%17 = call i32 @cPrintf(i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.16, i64 0, i64 0))
%18 = call i32 @cPrintf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.17, i64 0, i64 0))
%19 = call i32 @cPrintf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.18, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [21 x i8] c"valid commands are:\0A\00"
@.str.1 = [20 x i8] c" help get help\0A\00"
@.str.2 = [28 x i8] c" + add and subtract\0A\00"
@.str.3 = [20 x i8] c" a assemble\0A\00"
@.str.4 = [22 x i8] c" u unassemble\0A\00"
@.str.5 = [32 x i8] c" b set/reset breakpoint\0A\00"
@.str.6 = [36 x i8] c" c continue from breakpoint\0A\00"
@.str.7 = [23 x i8] c" s single-step\0A\00"
@.str.8 = [23 x i8] c" # show/set PC\0A\00"
@.str.9 = [24 x i8] c" p show/set PSW\0A\00"
@.str.10 = [29 x i8] c" r show/set register\0A\00"
@.str.11 = [23 x i8] c" d dump memory\0A\00"
@.str.12 = [32 x i8] c" mw show/set memory word\0A\00"
@.str.13 = [36 x i8] c" mh show/set memory halfword\0A\00"
@.str.14 = [32 x i8] c" mb show/set memory byte\0A\00"
@.str.15 = [33 x i8] c" t show/set TLB contents\0A\00"
@.str.16 = [31 x i8] c" i initialize hardware\0A\00"
@.str.17 = [26 x i8] c" q quit simulator\0A\00"
@.str.18 = [41 x i8] c"type 'help <cmd>' to get help for <cmd>\0A\00"
define void @help() {
%1 = tail call i32 @cPrintf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @cPrintf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i32 @cPrintf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.2, i64 0, i64 0))
%4 = tail call i32 @cPrintf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.3, i64 0, i64 0))
%5 = tail call i32 @cPrintf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.4, i64 0, i64 0))
%6 = tail call i32 @cPrintf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.5, i64 0, i64 0))
%7 = tail call i32 @cPrintf(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str.6, i64 0, i64 0))
%8 = tail call i32 @cPrintf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.7, i64 0, i64 0))
%9 = tail call i32 @cPrintf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.8, i64 0, i64 0))
%10 = tail call i32 @cPrintf(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.9, i64 0, i64 0))
%11 = tail call i32 @cPrintf(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.10, i64 0, i64 0))
%12 = tail call i32 @cPrintf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.11, i64 0, i64 0))
%13 = tail call i32 @cPrintf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.12, i64 0, i64 0))
%14 = tail call i32 @cPrintf(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str.13, i64 0, i64 0))
%15 = tail call i32 @cPrintf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.14, i64 0, i64 0))
%16 = tail call i32 @cPrintf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.15, i64 0, i64 0))
%17 = tail call i32 @cPrintf(i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.16, i64 0, i64 0))
%18 = tail call i32 @cPrintf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.17, i64 0, i64 0))
%19 = tail call i32 @cPrintf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.18, i64 0, i64 0))
ret void
}