#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 U_PMF_PATHPOINTTYPERLE_get(char const *, int *, int *, int *, char const *);
int /*<<< orphan*/ U_PMF_PATHPOINTTYPE_ENUM_print(int);
int /*<<< orphan*/ printf(char *, ...);
int U_PMF_PATHPOINTTYPERLE_print(const char *contents, const char *blimit) {
  int Bezier, Elements, Type;
  int status =
      U_PMF_PATHPOINTTYPERLE_get(contents, &Bezier, &Elements, &Type, blimit);
  if (status) {
    status = Elements;
    printf(" PathPointTypeRLE: Bezier:%c Elements:%u, Type: ",
           (Bezier ? 'Y' : 'N'), Elements);
    (void)U_PMF_PATHPOINTTYPE_ENUM_print(Type);
    printf("\n");
  }
  return (status);
}


x86 assembly (clang, -O0):
<U_PMF_PATHPOINTTYPERLE_print>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%r8
lea    -0x14(%rbp),%rsi
lea    -0x18(%rbp),%rdx
lea    -0x1c(%rbp),%rcx
call   1040 <U_PMF_PATHPOINTTYPERLE_get@plt>
mov    %eax,-0x20(%rbp)
cmpl   $0x0,-0x20(%rbp)
je     11a6 <U_PMF_PATHPOINTTYPERLE_print+0x76>
mov    -0x18(%rbp),%eax
mov    %eax,-0x20(%rbp)
mov    -0x14(%rbp),%ecx
mov    $0x4e,%esi
mov    $0x59,%eax
cmp    $0x0,%ecx
cmovne %eax,%esi
mov    -0x18(%rbp),%edx
lea    0xe77(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x1c(%rbp),%edi
call   1050 <U_PMF_PATHPOINTTYPE_ENUM_print@plt>
lea    0xe92(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x20(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<U_PMF_PATHPOINTTYPERLE_print>:
push   %rbx
sub    $0x10,%rsp
mov    %rsi,%r8
lea    0xc(%rsp),%rsi
lea    0x8(%rsp),%rdx
lea    0x4(%rsp),%rcx
call   1050 <U_PMF_PATHPOINTTYPERLE_get@plt>
test   %eax,%eax
je     119b <U_PMF_PATHPOINTTYPERLE_print+0x5b>
mov    0x8(%rsp),%ebx
cmpl   $0x0,0xc(%rsp)
mov    $0x4e,%eax
mov    $0x59,%esi
cmove  %eax,%esi
lea    0xe83(%rip),%rdi
mov    %ebx,%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x4(%rsp),%edi
call   1060 <U_PMF_PATHPOINTTYPE_ENUM_print@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
jmp    119d <U_PMF_PATHPOINTTYPERLE_print+0x5d>
xor    %ebx,%ebx
mov    %ebx,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [49 x i8] c" PathPointTypeRLE: Bezier:%c Elements:%u, Type: \00"
@.str.1 = [2 x i8] c"\0A\00"
define i32 @U_PMF_PATHPOINTTYPERLE_print(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
store i8* %0, i8** %3
store i8* %1, i8** %4
%9 = load i8*, i8** %3
%10 = load i8*, i8** %4
%11 = call i32 @U_PMF_PATHPOINTTYPERLE_get(i8* %9, i32* %5, i32* %6, i32* %7, i8* %10)
store i32 %11, i32* %8
%12 = load i32, i32* %8
%13 = icmp ne i32 %12, 0
br i1 %13, label %14, label %25
14: ; preds = %2
%15 = load i32, i32* %6
store i32 %15, i32* %8
%16 = load i32, i32* %5
%17 = icmp ne i32 %16, 0
%18 = zext i1 %17 to i64
%19 = select i1 %17, i32 89, i32 78
%20 = load i32, i32* %6
%21 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str, i64 0, i64 0), i32 %19, i32 %20)
%22 = load i32, i32* %7
%23 = call i32 @U_PMF_PATHPOINTTYPE_ENUM_print(i32 %22)
%24 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %25
25: ; preds = %14, %2
%26 = load i32, i32* %8
ret i32 %26
}

LLVM IR (-O2):
@.str = [49 x i8] c" PathPointTypeRLE: Bezier:%c Elements:%u, Type: \00"
define i32 @U_PMF_PATHPOINTTYPERLE_print(i8* %0, i8* %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = bitcast i32* %3 to i8*
%7 = bitcast i32* %4 to i8*
%8 = bitcast i32* %5 to i8*
%9 = call i32 @U_PMF_PATHPOINTTYPERLE_get(i8* %0, i32* %3, i32* %4, i32* %5, i8* %1)
%10 = icmp eq i32 %9, 0
br i1 %10, label %20, label %11
11: ; preds = %2
%12 = load i32, i32* %4
%13 = load i32, i32* %3
%14 = icmp eq i32 %13, 0
%15 = select i1 %14, i32 78, i32 89
%16 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([49 x i8], [49 x i8]* @.str, i64 0, i64 0), i32 %15, i32 %12)
%17 = load i32, i32* %5
%18 = call i32 @U_PMF_PATHPOINTTYPE_ENUM_print(i32 %17)
%19 = call i32 @putchar(i32 10)
br label %20
20: ; preds = %11, %2
%21 = phi i32 [ %12, %11 ], [ 0, %2 ]
ret i32 %21
}