#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*/ fill(int, int, int, int, int);
void draw_wing2(int x, int y) {
  fill(0x0000, x + 2, y + 10, 10, 2);
  fill(0x0000, x + 2, y + 16, 10, 2);
  fill(0x0000, x, y + 12, 2, 4);
  fill(0x0000, x + 12, y + 12, 2, 4);
  fill(0xFFFF, x + 2, y + 12, 10, 4);
}


x86 assembly (clang, -O0):
<draw_wing2>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%esi
add    $0x2,%esi
mov    -0x8(%rbp),%edx
add    $0xa,%edx
xor    %edi,%edi
mov    $0xa,%ecx
mov    $0x2,%r8d
call   1030 <fill@plt>
mov    -0x4(%rbp),%esi
add    $0x2,%esi
mov    -0x8(%rbp),%edx
add    $0x10,%edx
xor    %edi,%edi
mov    $0xa,%ecx
mov    $0x2,%r8d
call   1030 <fill@plt>
mov    -0x4(%rbp),%esi
mov    -0x8(%rbp),%edx
add    $0xc,%edx
xor    %edi,%edi
mov    $0x2,%ecx
mov    $0x4,%r8d
call   1030 <fill@plt>
mov    -0x4(%rbp),%esi
add    $0xc,%esi
mov    -0x8(%rbp),%edx
add    $0xc,%edx
xor    %edi,%edi
mov    $0x2,%ecx
mov    $0x4,%r8d
call   1030 <fill@plt>
mov    -0x4(%rbp),%esi
add    $0x2,%esi
mov    -0x8(%rbp),%edx
add    $0xc,%edx
mov    $0xffff,%edi
mov    $0xa,%ecx
mov    $0x4,%r8d
call   1030 <fill@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<draw_wing2>:
push   %rbp
push   %r14
push   %rbx
mov    %esi,%ebx
mov    %edi,%ebp
lea    0x2(%rbp),%r14d
lea    0xa(%rbx),%edx
xor    %edi,%edi
mov    %r14d,%esi
mov    $0xa,%ecx
mov    $0x2,%r8d
call   1030 <fill@plt>
lea    0x10(%rbx),%edx
xor    %edi,%edi
mov    %r14d,%esi
mov    $0xa,%ecx
mov    $0x2,%r8d
call   1030 <fill@plt>
add    $0xc,%ebx
xor    %edi,%edi
mov    %ebp,%esi
mov    %ebx,%edx
mov    $0x2,%ecx
mov    $0x4,%r8d
call   1030 <fill@plt>
add    $0xc,%ebp
xor    %edi,%edi
mov    %ebp,%esi
mov    %ebx,%edx
mov    $0x2,%ecx
mov    $0x4,%r8d
call   1030 <fill@plt>
mov    $0xffff,%edi
mov    %r14d,%esi
mov    %ebx,%edx
mov    $0xa,%ecx
mov    $0x4,%r8d
pop    %rbx
pop    %r14
pop    %rbp
jmp    1030 <fill@plt>

LLVM IR (-O0):
define void @draw_wing2(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%5 = load i32, i32* %3
%6 = add nsw i32 %5, 2
%7 = load i32, i32* %4
%8 = add nsw i32 %7, 10
%9 = call i32 @fill(i32 0, i32 %6, i32 %8, i32 10, i32 2)
%10 = load i32, i32* %3
%11 = add nsw i32 %10, 2
%12 = load i32, i32* %4
%13 = add nsw i32 %12, 16
%14 = call i32 @fill(i32 0, i32 %11, i32 %13, i32 10, i32 2)
%15 = load i32, i32* %3
%16 = load i32, i32* %4
%17 = add nsw i32 %16, 12
%18 = call i32 @fill(i32 0, i32 %15, i32 %17, i32 2, i32 4)
%19 = load i32, i32* %3
%20 = add nsw i32 %19, 12
%21 = load i32, i32* %4
%22 = add nsw i32 %21, 12
%23 = call i32 @fill(i32 0, i32 %20, i32 %22, i32 2, i32 4)
%24 = load i32, i32* %3
%25 = add nsw i32 %24, 2
%26 = load i32, i32* %4
%27 = add nsw i32 %26, 12
%28 = call i32 @fill(i32 65535, i32 %25, i32 %27, i32 10, i32 4)
ret void
}

LLVM IR (-O2):
define void @draw_wing2(i32 %0, i32 %1) {
%3 = add nsw i32 %0, 2
%4 = add nsw i32 %1, 10
%5 = tail call i32 @fill(i32 0, i32 %3, i32 %4, i32 10, i32 2)
%6 = add nsw i32 %1, 16
%7 = tail call i32 @fill(i32 0, i32 %3, i32 %6, i32 10, i32 2)
%8 = add nsw i32 %1, 12
%9 = tail call i32 @fill(i32 0, i32 %0, i32 %8, i32 2, i32 4)
%10 = add nsw i32 %0, 12
%11 = tail call i32 @fill(i32 0, i32 %10, i32 %8, i32 2, i32 4)
%12 = tail call i32 @fill(i32 65535, i32 %3, i32 %8, i32 10, i32 4)
ret void
}