#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*/ getmaxyx(int /*<<< orphan*/, int, int);
int /*<<< orphan*/ move(int, int);
int /*<<< orphan*/ printw(char *, char);
int /*<<< orphan*/ stdscr;
int marco() {
  int i;
  char cy, cx;
  int parent_x, parent_y;
  cx = 61;
  getmaxyx(stdscr, parent_y, parent_x);
  for (i = 1; i < parent_x; i++) {
    move(1, i);
    printw("%c", cx);
    move((parent_y - 1), i);
    printw("%c", cx);
  }
  cy = 58;
  for (i = 2; i < parent_y; i++) {
    move(i, 1);
    printw("%c", cy);
    move(i, (parent_x - 1));
    printw("%c", cy);
  }
  return 0;
}


x86 assembly (clang, -O0):
<marco>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movb   $0x3d,-0x6(%rbp)
mov    0x2ea5(%rip),%rax
mov    (%rax),%edi
mov    -0x10(%rbp),%esi
mov    -0xc(%rbp),%edx
call   1030 <getmaxyx@plt>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    11ac <marco+0x7c>
mov    -0x4(%rbp),%esi
mov    $0x1,%edi
call   1050 <move@plt>
lea    0xe89(%rip),%rdi
movsbl -0x6(%rbp),%esi
call   1040 <printw@plt>
mov    -0x10(%rbp),%edi
sub    $0x1,%edi
mov    -0x4(%rbp),%esi
call   1050 <move@plt>
lea    0xe6b(%rip),%rdi
movsbl -0x6(%rbp),%esi
call   1040 <printw@plt>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    1157 <marco+0x27>
movb   $0x3a,-0x5(%rbp)
movl   $0x2,-0x4(%rbp)
mov    -0x4(%rbp),%eax
cmp    -0x10(%rbp),%eax
jge    120c <marco+0xdc>
mov    -0x4(%rbp),%edi
mov    $0x1,%esi
call   1050 <move@plt>
lea    0xe29(%rip),%rdi
movsbl -0x5(%rbp),%esi
call   1040 <printw@plt>
mov    -0x4(%rbp),%edi
mov    -0xc(%rbp),%esi
sub    $0x1,%esi
call   1050 <move@plt>
lea    0xe0b(%rip),%rdi
movsbl -0x5(%rbp),%esi
call   1040 <printw@plt>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    11b7 <marco+0x87>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<marco>:
push   %rax
mov    0x2ed0(%rip),%rax
mov    (%rax),%edi
call   1030 <getmaxyx@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@stdscr = global i32 0
@.str = [3 x i8] c"%c\00"
define i32 @marco() {
%1 = alloca i32
%2 = alloca i8
%3 = alloca i8
%4 = alloca i32
%5 = alloca i32
store i8 61, i8* %3
%6 = load i32, i32* @stdscr
%7 = load i32, i32* %5
%8 = load i32, i32* %4
%9 = call i32 @getmaxyx(i32 %6, i32 %7, i32 %8)
store i32 1, i32* %1
br label %10
10: ; preds = %25, %0
%11 = load i32, i32* %1
%12 = load i32, i32* %4
%13 = icmp slt i32 %11, %12
br i1 %13, label %14, label %28
14: ; preds = %10
%15 = load i32, i32* %1
%16 = call i32 @move(i32 1, i32 %15)
%17 = load i8, i8* %3
%18 = call i32 @printw(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8 signext %17)
%19 = load i32, i32* %5
%20 = sub nsw i32 %19, 1
%21 = load i32, i32* %1
%22 = call i32 @move(i32 %20, i32 %21)
%23 = load i8, i8* %3
%24 = call i32 @printw(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8 signext %23)
br label %25
25: ; preds = %14
%26 = load i32, i32* %1
%27 = add nsw i32 %26, 1
store i32 %27, i32* %1
br label %10
28: ; preds = %10
store i8 58, i8* %2
store i32 2, i32* %1
br label %29
29: ; preds = %44, %28
%30 = load i32, i32* %1
%31 = load i32, i32* %5
%32 = icmp slt i32 %30, %31
br i1 %32, label %33, label %47
33: ; preds = %29
%34 = load i32, i32* %1
%35 = call i32 @move(i32 %34, i32 1)
%36 = load i8, i8* %2
%37 = call i32 @printw(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8 signext %36)
%38 = load i32, i32* %1
%39 = load i32, i32* %4
%40 = sub nsw i32 %39, 1
%41 = call i32 @move(i32 %38, i32 %40)
%42 = load i8, i8* %2
%43 = call i32 @printw(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8 signext %42)
br label %44
44: ; preds = %33
%45 = load i32, i32* %1
%46 = add nsw i32 %45, 1
store i32 %46, i32* %1
br label %29
47: ; preds = %29
ret i32 0
}

LLVM IR (-O2):
@stdscr = global i32 0
define i32 @marco() {
%1 = load i32, i32* @stdscr
%2 = tail call i32 @getmaxyx(i32 %1, i32 undef, i32 undef)
ret i32 0
}