#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*/ COLOR_PAIR(int);
int COLS;
int /*<<< orphan*/ addstr(char *);
int /*<<< orphan*/ attroff(int /*<<< orphan*/);
int /*<<< orphan*/ attron(int /*<<< orphan*/);
int /*<<< orphan*/ move(int, int);
void display_order_title(int line) {
  move(line, 0);
  do {
    attron(COLOR_PAIR(6));
    addstr(("Item"));
    attroff(COLOR_PAIR(6));
  } while (0);
  move(line, 6);
  do {
    attron(COLOR_PAIR(6));
    addstr(("Qty."));
    attroff(COLOR_PAIR(6));
  } while (0);
  move(line, 12);
  do {
    attron(COLOR_PAIR(6));
    addstr(("Code"));
    attroff(COLOR_PAIR(6));
  } while (0);
  move(line, 18);
  do {
    attron(COLOR_PAIR(6));
    addstr(("Description"));
    attroff(COLOR_PAIR(6));
  } while (0);
  move(line, COLS - 5);
  do {
    attron(COLOR_PAIR(6));
    addstr(("Price"));
    attroff(COLOR_PAIR(6));
  } while (0);
}


x86 assembly (clang, -O0):
<display_order_title>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
xor    %esi,%esi
call   1070 <move@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1040 <attron@plt>
lea    0xe83(%rip),%rdi
call   1060 <addstr@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1030 <attroff@plt>
mov    -0x4(%rbp),%edi
mov    $0x6,%esi
call   1070 <move@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1040 <attron@plt>
lea    0xe4d(%rip),%rdi
call   1060 <addstr@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1030 <attroff@plt>
mov    -0x4(%rbp),%edi
mov    $0xc,%esi
call   1070 <move@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1040 <attron@plt>
lea    0xe17(%rip),%rdi
call   1060 <addstr@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1030 <attroff@plt>
mov    -0x4(%rbp),%edi
mov    $0x12,%esi
call   1070 <move@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1040 <attron@plt>
lea    0xde1(%rip),%rdi
call   1060 <addstr@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1030 <attroff@plt>
mov    -0x4(%rbp),%edi
mov    0x2d9a(%rip),%rax
mov    (%rax),%esi
sub    $0x5,%esi
call   1070 <move@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1040 <attron@plt>
lea    0xdab(%rip),%rdi
call   1060 <addstr@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1030 <attroff@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<display_order_title>:
push   %rbx
mov    %edi,%ebx
xor    %esi,%esi
call   1070 <move@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1040 <attron@plt>
lea    0xe8e(%rip),%rdi
call   1060 <addstr@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1030 <attroff@plt>
mov    %ebx,%edi
mov    $0x6,%esi
call   1070 <move@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1040 <attron@plt>
lea    0xe59(%rip),%rdi
call   1060 <addstr@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1030 <attroff@plt>
mov    %ebx,%edi
mov    $0xc,%esi
call   1070 <move@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1040 <attron@plt>
lea    0xe24(%rip),%rdi
call   1060 <addstr@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1030 <attroff@plt>
mov    %ebx,%edi
mov    $0x12,%esi
call   1070 <move@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1040 <attron@plt>
lea    0xdef(%rip),%rdi
call   1060 <addstr@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1030 <attroff@plt>
mov    0x2dab(%rip),%rax
mov    (%rax),%esi
add    $0xfffffffb,%esi
mov    %ebx,%edi
call   1070 <move@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1040 <attron@plt>
lea    0xdba(%rip),%rdi
call   1060 <addstr@plt>
mov    $0x6,%edi
call   1050 <COLOR_PAIR@plt>
mov    %eax,%edi
pop    %rbx
jmp    1030 <attroff@plt>

LLVM IR (-O0):
@.str = [5 x i8] c"Item\00"
@.str.1 = [5 x i8] c"Qty.\00"
@.str.2 = [5 x i8] c"Code\00"
@.str.3 = [12 x i8] c"Description\00"
@COLS = global i32 0
@.str.4 = [6 x i8] c"Price\00"
define void @display_order_title(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @move(i32 %3, i32 0)
br label %5
5: ; preds = %1
%6 = call i32 @COLOR_PAIR(i32 6)
%7 = call i32 @attron(i32 %6)
%8 = call i32 @addstr(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%9 = call i32 @COLOR_PAIR(i32 6)
%10 = call i32 @attroff(i32 %9)
br label %11
11: ; preds = %5
%12 = load i32, i32* %2
%13 = call i32 @move(i32 %12, i32 6)
br label %14
14: ; preds = %11
%15 = call i32 @COLOR_PAIR(i32 6)
%16 = call i32 @attron(i32 %15)
%17 = call i32 @addstr(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0))
%18 = call i32 @COLOR_PAIR(i32 6)
%19 = call i32 @attroff(i32 %18)
br label %20
20: ; preds = %14
%21 = load i32, i32* %2
%22 = call i32 @move(i32 %21, i32 12)
br label %23
23: ; preds = %20
%24 = call i32 @COLOR_PAIR(i32 6)
%25 = call i32 @attron(i32 %24)
%26 = call i32 @addstr(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%27 = call i32 @COLOR_PAIR(i32 6)
%28 = call i32 @attroff(i32 %27)
br label %29
29: ; preds = %23
%30 = load i32, i32* %2
%31 = call i32 @move(i32 %30, i32 18)
br label %32
32: ; preds = %29
%33 = call i32 @COLOR_PAIR(i32 6)
%34 = call i32 @attron(i32 %33)
%35 = call i32 @addstr(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%36 = call i32 @COLOR_PAIR(i32 6)
%37 = call i32 @attroff(i32 %36)
br label %38
38: ; preds = %32
%39 = load i32, i32* %2
%40 = load i32, i32* @COLS
%41 = sub nsw i32 %40, 5
%42 = call i32 @move(i32 %39, i32 %41)
br label %43
43: ; preds = %38
%44 = call i32 @COLOR_PAIR(i32 6)
%45 = call i32 @attron(i32 %44)
%46 = call i32 @addstr(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.4, i64 0, i64 0))
%47 = call i32 @COLOR_PAIR(i32 6)
%48 = call i32 @attroff(i32 %47)
br label %49
49: ; preds = %43
ret void
}

LLVM IR (-O2):
@.str = [5 x i8] c"Item\00"
@.str.1 = [5 x i8] c"Qty.\00"
@.str.2 = [5 x i8] c"Code\00"
@.str.3 = [12 x i8] c"Description\00"
@COLS = global i32 0
@.str.4 = [6 x i8] c"Price\00"
define void @display_order_title(i32 %0) {
%2 = tail call i32 @move(i32 %0, i32 0)
%3 = tail call i32 @COLOR_PAIR(i32 6)
%4 = tail call i32 @attron(i32 %3)
%5 = tail call i32 @addstr(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%6 = tail call i32 @COLOR_PAIR(i32 6)
%7 = tail call i32 @attroff(i32 %6)
%8 = tail call i32 @move(i32 %0, i32 6)
%9 = tail call i32 @COLOR_PAIR(i32 6)
%10 = tail call i32 @attron(i32 %9)
%11 = tail call i32 @addstr(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0))
%12 = tail call i32 @COLOR_PAIR(i32 6)
%13 = tail call i32 @attroff(i32 %12)
%14 = tail call i32 @move(i32 %0, i32 12)
%15 = tail call i32 @COLOR_PAIR(i32 6)
%16 = tail call i32 @attron(i32 %15)
%17 = tail call i32 @addstr(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%18 = tail call i32 @COLOR_PAIR(i32 6)
%19 = tail call i32 @attroff(i32 %18)
%20 = tail call i32 @move(i32 %0, i32 18)
%21 = tail call i32 @COLOR_PAIR(i32 6)
%22 = tail call i32 @attron(i32 %21)
%23 = tail call i32 @addstr(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%24 = tail call i32 @COLOR_PAIR(i32 6)
%25 = tail call i32 @attroff(i32 %24)
%26 = load i32, i32* @COLS
%27 = add nsw i32 %26, -5
%28 = tail call i32 @move(i32 %0, i32 %27)
%29 = tail call i32 @COLOR_PAIR(i32 6)
%30 = tail call i32 @attron(i32 %29)
%31 = tail call i32 @addstr(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.4, i64 0, i64 0))
%32 = tail call i32 @COLOR_PAIR(i32 6)
%33 = tail call i32 @attroff(i32 %32)
ret void
}