#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 */
struct ADrawTag {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ PsArc(struct ADrawTag *, unsigned int, unsigned int,
                         unsigned int, unsigned int, unsigned int,
                         unsigned int);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ getPsFile(struct ADrawTag *);
void PsDottedArc(struct ADrawTag *ctx, unsigned int cx, unsigned int cy,
                 unsigned int w, unsigned int h, unsigned int s,
                 unsigned int e) {
  fprintf(getPsFile(ctx), "[2] 0 setdash\n");
  PsArc(ctx, cx, cy, w, h, s, e);
  fprintf(getPsFile(ctx), "[] 0 setdash\n");
}


x86 assembly (clang, -O0):
<PsDottedArc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    0x10(%rbp),%eax
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    %ecx,-0x14(%rbp)
mov    %r8d,-0x18(%rbp)
mov    %r9d,-0x1c(%rbp)
mov    -0x8(%rbp),%rdi
call   1050 <getPsFile@plt>
mov    %eax,%edi
lea    0xe9e(%rip),%rsi
call   1030 <fprintf@plt>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x10(%rbp),%edx
mov    -0x14(%rbp),%ecx
mov    -0x18(%rbp),%r8d
mov    -0x1c(%rbp),%r9d
mov    0x10(%rbp),%eax
mov    %eax,(%rsp)
call   1040 <PsArc@plt>
mov    -0x8(%rbp),%rdi
call   1050 <getPsFile@plt>
mov    %eax,%edi
lea    0xe76(%rip),%rsi
call   1030 <fprintf@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<PsDottedArc>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
mov    %r9d,0x14(%rsp)
mov    %r8d,%r15d
mov    %ecx,%r12d
mov    %edx,%r13d
mov    %esi,%ebx
mov    %rdi,%rbp
mov    0x50(%rsp),%r14d
call   1050 <getPsFile@plt>
lea    0xe9e(%rip),%rsi
mov    %eax,%edi
call   1030 <fprintf@plt>
mov    %r14d,(%rsp)
mov    %rbp,%rdi
mov    %ebx,%esi
mov    %r13d,%edx
mov    %r12d,%ecx
mov    %r15d,%r8d
mov    0x14(%rsp),%r9d
call   1040 <PsArc@plt>
mov    %rbp,%rdi
call   1050 <getPsFile@plt>
lea    0xe7b(%rip),%rsi
mov    %eax,%edi
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
%struct.ADrawTag = type { i32 }
@.str = [15 x i8] c"[2] 0 setdash\0A\00"
@.str.1 = [14 x i8] c"[] 0 setdash\0A\00"
define void @PsDottedArc(%struct.ADrawTag* %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6) {
%8 = alloca %struct.ADrawTag*
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
store %struct.ADrawTag* %0, %struct.ADrawTag** %8
store i32 %1, i32* %9
store i32 %2, i32* %10
store i32 %3, i32* %11
store i32 %4, i32* %12
store i32 %5, i32* %13
store i32 %6, i32* %14
%15 = load %struct.ADrawTag*, %struct.ADrawTag** %8
%16 = call i32 @getPsFile(%struct.ADrawTag* %15)
%17 = call i32 @fprintf(i32 %16, i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0))
%18 = load %struct.ADrawTag*, %struct.ADrawTag** %8
%19 = load i32, i32* %9
%20 = load i32, i32* %10
%21 = load i32, i32* %11
%22 = load i32, i32* %12
%23 = load i32, i32* %13
%24 = load i32, i32* %14
%25 = call i32 @PsArc(%struct.ADrawTag* %18, i32 %19, i32 %20, i32 %21, i32 %22, i32 %23, i32 %24)
%26 = load %struct.ADrawTag*, %struct.ADrawTag** %8
%27 = call i32 @getPsFile(%struct.ADrawTag* %26)
%28 = call i32 @fprintf(i32 %27, i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
%struct.ADrawTag = type { i32 }
@.str = [15 x i8] c"[2] 0 setdash\0A\00"
@.str.1 = [14 x i8] c"[] 0 setdash\0A\00"
define void @PsDottedArc(%struct.ADrawTag* %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6) {
%8 = tail call i32 @getPsFile(%struct.ADrawTag* %0)
%9 = tail call i32 @fprintf(i32 %8, i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0))
%10 = tail call i32 @PsArc(%struct.ADrawTag* %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6)
%11 = tail call i32 @getPsFile(%struct.ADrawTag* %0)
%12 = tail call i32 @fprintf(i32 %11, i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0))
ret void
}