#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*/ printf(char *, ...);
void put_dec_proc() {
  printf("%s PROC\n", "put_dec");
  ;
  printf("\tMOV\t%s, %s\n", "BX", "OFFSET Parameters");
  ;
  printf("\tADD\t%s, %s\n", "BX", "Parameter_Offset");
  ;
  printf("\tSUB\t%s, %s\n", "BX", "2");
  ;
  printf("\tMOV\t%s, %s\n", "AX", "WORD PTR [BX]");
  ;
  printf("\tCALL\tPutDec\n");
  printf("\tRET\n");
  ;
  printf("%s ENDP\n", "put_dec");
  ;
}


x86 assembly (clang, -O0):
<put_dec_proc>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
lea    0xee7(%rip),%rsi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xee1(%rip),%rdi
lea    0xee7(%rip),%rsi
lea    0xee3(%rip),%rdx
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xee7(%rip),%rdi
lea    0xecb(%rip),%rsi
lea    0xee6(%rip),%rdx
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xee9(%rip),%rdi
lea    0xeaf(%rip),%rsi
lea    0xee8(%rip),%rdx
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xe8d(%rip),%rdi
lea    0xed5(%rip),%rsi
lea    0xed1(%rip),%rdx
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xed1(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xed1(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xec9(%rip),%rdi
lea    0xe46(%rip),%rsi
mov    $0x0,%al
call   1030 <printf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<put_dec_proc>:
push   %r15
push   %r14
push   %rbx
lea    0xed4(%rip),%rdi
lea    0xed6(%rip),%r14
mov    %r14,%rsi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xecd(%rip),%r15
lea    0xed3(%rip),%rbx
lea    0xecf(%rip),%rdx
mov    %r15,%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xecd(%rip),%rdi
lea    0xed3(%rip),%rdx
mov    %rbx,%rsi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xed3(%rip),%rdi
lea    0xed9(%rip),%rdx
mov    %rbx,%rsi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xeca(%rip),%rsi
lea    0xec6(%rip),%rdx
mov    %r15,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xecc(%rip),%rdi
call   1030 <puts@plt>
lea    0xecd(%rip),%rdi
call   1030 <puts@plt>
lea    0xeab(%rip),%rdi
mov    %r14,%rsi
xor    %eax,%eax
pop    %rbx
pop    %r14
pop    %r15
jmp    1040 <printf@plt>

LLVM IR (-O0):
@.str = [9 x i8] c"%s PROC\0A\00"
@.str.1 = [8 x i8] c"put_dec\00"
@.str.2 = [13 x i8] c"\09MOV\09%s, %s\0A\00"
@.str.3 = [3 x i8] c"BX\00"
@.str.4 = [18 x i8] c"OFFSET Parameters\00"
@.str.5 = [13 x i8] c"\09ADD\09%s, %s\0A\00"
@.str.6 = [17 x i8] c"Parameter_Offset\00"
@.str.7 = [13 x i8] c"\09SUB\09%s, %s\0A\00"
@.str.8 = [2 x i8] c"2\00"
@.str.9 = [3 x i8] c"AX\00"
@.str.10 = [14 x i8] c"WORD PTR [BX]\00"
@.str.11 = [14 x i8] c"\09CALL\09PutDec\0A\00"
@.str.12 = [6 x i8] c"\09RET\0A\00"
@.str.13 = [9 x i8] c"%s ENDP\0A\00"
define void @put_dec_proc() {
%1 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
%2 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.4, i64 0, i64 0))
%3 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.6, i64 0, i64 0))
%4 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.10, i64 0, i64 0))
%6 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.11, i64 0, i64 0))
%7 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.12, i64 0, i64 0))
%8 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.13, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [9 x i8] c"%s PROC\0A\00"
@.str.1 = [8 x i8] c"put_dec\00"
@.str.2 = [13 x i8] c"\09MOV\09%s, %s\0A\00"
@.str.3 = [3 x i8] c"BX\00"
@.str.4 = [18 x i8] c"OFFSET Parameters\00"
@.str.5 = [13 x i8] c"\09ADD\09%s, %s\0A\00"
@.str.6 = [17 x i8] c"Parameter_Offset\00"
@.str.7 = [13 x i8] c"\09SUB\09%s, %s\0A\00"
@.str.8 = [2 x i8] c"2\00"
@.str.9 = [3 x i8] c"AX\00"
@.str.10 = [14 x i8] c"WORD PTR [BX]\00"
@.str.13 = [9 x i8] c"%s ENDP\0A\00"
@str = [13 x i8] c"\09CALL\09PutDec\00"
@str.14 = [5 x i8] c"\09RET\00"
define void @put_dec_proc() {
%1 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
%2 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.4, i64 0, i64 0))
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.6, i64 0, i64 0))
%4 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
%5 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.10, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @str, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @str.14, i64 0, i64 0))
%8 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.13, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
ret void
}