#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*/ drawPoly3TD(short, short, short, short, short, short, short,
                               short, short, short, short, short);
void drawPoly4TD_TRI(short x1, short y1, short x2, short y2, short x3, short y3,
                     short x4, short y4, short tx1, short ty1, short tx2,
                     short ty2, short tx3, short ty3, short tx4, short ty4) {
  drawPoly3TD(x2, y2, x3, y3, x4, y4, tx2, ty2, tx3, ty3, tx4, ty4);
  drawPoly3TD(x1, y1, x2, y2, x4, y4, tx1, ty1, tx2, ty2, tx4, ty4);
}


x86 assembly (clang, -O0):
<drawPoly4TD_TRI>:
push   %rbp
mov    %rsp,%rbp
push   %r14
push   %rbx
sub    $0x50,%rsp
mov    %r8d,-0x2c(%rbp)
mov    %ecx,%eax
mov    -0x2c(%rbp),%ecx
mov    %eax,-0x28(%rbp)
mov    %edx,%eax
mov    -0x28(%rbp),%edx
mov    %eax,-0x24(%rbp)
mov    %esi,%eax
mov    -0x24(%rbp),%esi
mov    %eax,-0x20(%rbp)
mov    %edi,%r8d
mov    -0x20(%rbp),%edi
mov    %r9w,%ax
mov    0x58(%rbp),%r9w
mov    0x50(%rbp),%r9w
mov    0x48(%rbp),%r9w
mov    0x40(%rbp),%r9w
mov    0x38(%rbp),%r9w
mov    0x30(%rbp),%r9w
mov    0x28(%rbp),%r9w
mov    0x20(%rbp),%r9w
mov    0x18(%rbp),%r9w
mov    0x10(%rbp),%r9w
mov    %r8w,-0x12(%rbp)
mov    %di,-0x14(%rbp)
mov    %si,-0x16(%rbp)
mov    %dx,-0x18(%rbp)
mov    %cx,-0x1a(%rbp)
mov    %ax,-0x1c(%rbp)
mov    -0x16(%rbp),%di
mov    -0x18(%rbp),%si
mov    -0x1a(%rbp),%dx
mov    -0x1c(%rbp),%cx
mov    0x10(%rbp),%r8w
mov    0x18(%rbp),%r9w
mov    0x30(%rbp),%r14w
mov    0x38(%rbp),%bx
mov    0x40(%rbp),%r11w
mov    0x48(%rbp),%r10w
mov    0x50(%rbp),%ax
movswl %di,%edi
movswl %si,%esi
movswl %dx,%edx
movswl %cx,%ecx
movswl %r8w,%r8d
movswl %r9w,%r9d
movswl %r14w,%r14d
mov    %r14d,(%rsp)
movswl %bx,%ebx
mov    %ebx,0x8(%rsp)
movswl %r11w,%r11d
mov    %r11d,0x10(%rsp)
movswl %r10w,%r10d
mov    %r10d,0x18(%rsp)
cwtl
mov    %eax,0x20(%rsp)
movswl 0x58(%rbp),%eax
mov    %eax,0x28(%rsp)
call   1030 <drawPoly3TD@plt>
mov    -0x12(%rbp),%di
mov    -0x14(%rbp),%si
mov    -0x16(%rbp),%dx
mov    -0x18(%rbp),%cx
mov    0x10(%rbp),%r8w
mov    0x18(%rbp),%r9w
mov    0x20(%rbp),%r14w
mov    0x28(%rbp),%bx
mov    0x30(%rbp),%r11w
mov    0x38(%rbp),%r10w
mov    0x50(%rbp),%ax
movswl %di,%edi
movswl %si,%esi
movswl %dx,%edx
movswl %cx,%ecx
movswl %r8w,%r8d
movswl %r9w,%r9d
movswl %r14w,%r14d
mov    %r14d,(%rsp)
movswl %bx,%ebx
mov    %ebx,0x8(%rsp)
movswl %r11w,%r11d
mov    %r11d,0x10(%rsp)
movswl %r10w,%r10d
mov    %r10d,0x18(%rsp)
cwtl
mov    %eax,0x20(%rsp)
movswl 0x58(%rbp),%eax
mov    %eax,0x28(%rsp)
call   1030 <drawPoly3TD@plt>
add    $0x50,%rsp
pop    %rbx
pop    %r14
pop    %rbp
ret

x86 assembly (clang, -O2):
<drawPoly4TD_TRI>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x28,%rsp
mov    %ecx,0xc(%rsp)
mov    %edx,0x8(%rsp)
mov    %esi,0x14(%rsp)
mov    %edi,0x10(%rsp)
movswl 0x70(%rsp),%eax
mov    %rax,0x20(%rsp)
movswl 0x78(%rsp),%eax
mov    %rax,0x18(%rsp)
movswl 0x60(%rsp),%r15d
movswl 0x68(%rsp),%r12d
movswl 0x80(%rsp),%ebx
movswl 0x88(%rsp),%ebp
movswl 0x90(%rsp),%r10d
movswl 0x98(%rsp),%eax
movswl 0xa0(%rsp),%r14d
movswl 0xa8(%rsp),%r13d
mov    %edx,%edi
mov    %ecx,%esi
mov    %r8d,%edx
mov    %r9d,%ecx
mov    %r15d,%r8d
mov    %r12d,%r9d
push   %r13
push   %r14
push   %rax
push   %r10
push   %rbp
push   %rbx
call   1030 <drawPoly3TD@plt>
add    $0x30,%rsp
mov    0x10(%rsp),%edi
mov    0x14(%rsp),%esi
mov    0x8(%rsp),%edx
mov    0xc(%rsp),%ecx
mov    %r15d,%r8d
mov    %r12d,%r9d
push   %r13
push   %r14
push   %rbp
push   %rbx
push   0x38(%rsp)
push   0x48(%rsp)
call   1030 <drawPoly3TD@plt>
add    $0x58,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define void @drawPoly4TD_TRI(i16 signext %0, i16 signext %1, i16 signext %2, i16 signext %3, i16 signext %4, i16 signext %5, i16 signext %6, i16 signext %7, i16 signext %8, i16 signext %9, i16 signext %10, i16 signext %11, i16 signext %12, i16 signext %13, i16 signext %14, i16 signext %15) {
%17 = alloca i16
%18 = alloca i16
%19 = alloca i16
%20 = alloca i16
%21 = alloca i16
%22 = alloca i16
%23 = alloca i16
%24 = alloca i16
%25 = alloca i16
%26 = alloca i16
%27 = alloca i16
%28 = alloca i16
%29 = alloca i16
%30 = alloca i16
%31 = alloca i16
%32 = alloca i16
store i16 %0, i16* %17
store i16 %1, i16* %18
store i16 %2, i16* %19
store i16 %3, i16* %20
store i16 %4, i16* %21
store i16 %5, i16* %22
store i16 %6, i16* %23
store i16 %7, i16* %24
store i16 %8, i16* %25
store i16 %9, i16* %26
store i16 %10, i16* %27
store i16 %11, i16* %28
store i16 %12, i16* %29
store i16 %13, i16* %30
store i16 %14, i16* %31
store i16 %15, i16* %32
%33 = load i16, i16* %19
%34 = load i16, i16* %20
%35 = load i16, i16* %21
%36 = load i16, i16* %22
%37 = load i16, i16* %23
%38 = load i16, i16* %24
%39 = load i16, i16* %27
%40 = load i16, i16* %28
%41 = load i16, i16* %29
%42 = load i16, i16* %30
%43 = load i16, i16* %31
%44 = load i16, i16* %32
%45 = call i32 @drawPoly3TD(i16 signext %33, i16 signext %34, i16 signext %35, i16 signext %36, i16 signext %37, i16 signext %38, i16 signext %39, i16 signext %40, i16 signext %41, i16 signext %42, i16 signext %43, i16 signext %44)
%46 = load i16, i16* %17
%47 = load i16, i16* %18
%48 = load i16, i16* %19
%49 = load i16, i16* %20
%50 = load i16, i16* %23
%51 = load i16, i16* %24
%52 = load i16, i16* %25
%53 = load i16, i16* %26
%54 = load i16, i16* %27
%55 = load i16, i16* %28
%56 = load i16, i16* %31
%57 = load i16, i16* %32
%58 = call i32 @drawPoly3TD(i16 signext %46, i16 signext %47, i16 signext %48, i16 signext %49, i16 signext %50, i16 signext %51, i16 signext %52, i16 signext %53, i16 signext %54, i16 signext %55, i16 signext %56, i16 signext %57)
ret void
}

LLVM IR (-O2):
define void @drawPoly4TD_TRI(i16 signext %0, i16 signext %1, i16 signext %2, i16 signext %3, i16 signext %4, i16 signext %5, i16 signext %6, i16 signext %7, i16 signext %8, i16 signext %9, i16 signext %10, i16 signext %11, i16 signext %12, i16 signext %13, i16 signext %14, i16 signext %15) {
%17 = tail call i32 @drawPoly3TD(i16 signext %2, i16 signext %3, i16 signext %4, i16 signext %5, i16 signext %6, i16 signext %7, i16 signext %10, i16 signext %11, i16 signext %12, i16 signext %13, i16 signext %14, i16 signext %15)
%18 = tail call i32 @drawPoly3TD(i16 signext %0, i16 signext %1, i16 signext %2, i16 signext %3, i16 signext %6, i16 signext %7, i16 signext %8, i16 signext %9, i16 signext %10, i16 signext %11, i16 signext %14, i16 signext %15)
ret void
}