#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 */
typedef struct TYPE_6__ TYPE_2__;
typedef struct TYPE_5__ TYPE_1__;

/* Type definitions */
struct TYPE_5__ {
  scalar_t__ descent;
  scalar_t__ ascent;
};
typedef TYPE_1__ XFontStruct;
struct TYPE_6__ {
  scalar_t__ lbearing;
  scalar_t__ rbearing;
  scalar_t__ width;
  scalar_t__ descent;
  scalar_t__ ascent;
};
typedef TYPE_2__ XCharStruct;

/* Variables and functions */
char *non_cell_character(XFontStruct *fs, XCharStruct *cs) {
  if ((cs->lbearing > cs->rbearing) &&
      (((cs->width < 0) &&
        ((cs->width > cs->lbearing) || (cs->rbearing > 0))) ||
       ((cs->width >= 0) &&
        ((cs->width < cs->rbearing) || (cs->lbearing < 0)))))
    return "ink outside bounding box";
  if (cs->descent > fs->descent)
    return "characters not all same descent";
  if (cs->ascent > fs->ascent)
    return "characters not all same ascent";
  return NULL;
}


x86 assembly (clang, -O0):
<non_cell_character>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    -0x18(%rbp),%rax
mov    (%rax),%rax
mov    -0x18(%rbp),%rcx
cmp    0x8(%rcx),%rax
jle    1197 <non_cell_character+0x97>
mov    -0x18(%rbp),%rax
cmpq   $0x0,0x10(%rax)
jge    1154 <non_cell_character+0x54>
mov    -0x18(%rbp),%rax
mov    0x10(%rax),%rax
mov    -0x18(%rbp),%rcx
cmp    (%rcx),%rax
jg     1187 <non_cell_character+0x87>
mov    -0x18(%rbp),%rax
cmpq   $0x0,0x8(%rax)
jg     1187 <non_cell_character+0x87>
mov    -0x18(%rbp),%rax
cmpq   $0x0,0x10(%rax)
jl     1197 <non_cell_character+0x97>
mov    -0x18(%rbp),%rax
mov    0x10(%rax),%rax
mov    -0x18(%rbp),%rcx
cmp    0x8(%rcx),%rax
jl     1187 <non_cell_character+0x87>
mov    -0x18(%rbp),%rax
cmpq   $0x0,(%rax)
jge    1197 <non_cell_character+0x97>
lea    0xe72(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    11ea <non_cell_character+0xea>
mov    -0x18(%rbp),%rax
mov    0x18(%rax),%rax
mov    -0x10(%rbp),%rcx
cmp    (%rcx),%rax
jle    11bc <non_cell_character+0xbc>
lea    0xe66(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    11ea <non_cell_character+0xea>
mov    -0x18(%rbp),%rax
mov    0x20(%rax),%rax
mov    -0x10(%rbp),%rcx
cmp    0x8(%rcx),%rax
jle    11e2 <non_cell_character+0xe2>
lea    0xe60(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    11ea <non_cell_character+0xea>
movq   $0x0,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<non_cell_character>:
mov    (%rsi),%rcx
mov    0x8(%rsi),%rdx
cmp    %rdx,%rcx
jle    1131 <non_cell_character+0x31>
mov    0x10(%rsi),%r8
lea    0xee9(%rip),%rax
test   %r8,%r8
js     1127 <non_cell_character+0x27>
cmp    %rdx,%r8
jl     1126 <non_cell_character+0x26>
test   %rcx,%rcx
jns    1131 <non_cell_character+0x31>
ret
cmp    %rcx,%r8
jg     1126 <non_cell_character+0x26>
test   %rdx,%rdx
jg     1126 <non_cell_character+0x26>
mov    0x18(%rsi),%rax
cmp    (%rdi),%rax
jle    1142 <non_cell_character+0x42>
lea    0xed8(%rip),%rax
ret
mov    0x20(%rsi),%rcx
xor    %eax,%eax
cmp    0x8(%rdi),%rcx
lea    0xee6(%rip),%rcx
cmovg  %rcx,%rax
ret

LLVM IR (-O0):
%struct.TYPE_5__ = type { i64, i64 }
%struct.TYPE_6__ = type { i64, i64, i64, i64, i64 }
@.str = [25 x i8] c"ink outside bounding box\00"
@.str.1 = [32 x i8] c"characters not all same descent\00"
@.str.2 = [31 x i8] c"characters not all same ascent\00"
define i8* @non_cell_character(%struct.TYPE_5__* %0, %struct.TYPE_6__* %1) {
%3 = alloca i8*
%4 = alloca %struct.TYPE_5__*
%5 = alloca %struct.TYPE_6__*
store %struct.TYPE_5__* %0, %struct.TYPE_5__** %4
store %struct.TYPE_6__* %1, %struct.TYPE_6__** %5
%6 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%7 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %6, i32 0, i32 0
%8 = load i64, i64* %7
%9 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%10 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %9, i32 0, i32 1
%11 = load i64, i64* %10
%12 = icmp sgt i64 %8, %11
br i1 %12, label %13, label %50
13: ; preds = %2
%14 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%15 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %14, i32 0, i32 2
%16 = load i64, i64* %15
%17 = icmp slt i64 %16, 0
br i1 %17, label %18, label %31
18: ; preds = %13
%19 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%20 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %19, i32 0, i32 2
%21 = load i64, i64* %20
%22 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%23 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %22, i32 0, i32 0
%24 = load i64, i64* %23
%25 = icmp sgt i64 %21, %24
br i1 %25, label %49, label %26
26: ; preds = %18
%27 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%28 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %27, i32 0, i32 1
%29 = load i64, i64* %28
%30 = icmp sgt i64 %29, 0
br i1 %30, label %49, label %31
31: ; preds = %26, %13
%32 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%33 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %32, i32 0, i32 2
%34 = load i64, i64* %33
%35 = icmp sge i64 %34, 0
br i1 %35, label %36, label %50
36: ; preds = %31
%37 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%38 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %37, i32 0, i32 2
%39 = load i64, i64* %38
%40 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%41 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %40, i32 0, i32 1
%42 = load i64, i64* %41
%43 = icmp slt i64 %39, %42
br i1 %43, label %49, label %44
44: ; preds = %36
%45 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%46 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %45, i32 0, i32 0
%47 = load i64, i64* %46
%48 = icmp slt i64 %47, 0
br i1 %48, label %49, label %50
49: ; preds = %44, %36, %26, %18
store i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8** %3
br label %69
50: ; preds = %44, %31, %2
%51 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%52 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %51, i32 0, i32 3
%53 = load i64, i64* %52
%54 = load %struct.TYPE_5__*, %struct.TYPE_5__** %4
%55 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %54, i32 0, i32 0
%56 = load i64, i64* %55
%57 = icmp sgt i64 %53, %56
br i1 %57, label %58, label %59
58: ; preds = %50
store i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.1, i64 0, i64 0), i8** %3
br label %69
59: ; preds = %50
%60 = load %struct.TYPE_6__*, %struct.TYPE_6__** %5
%61 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %60, i32 0, i32 4
%62 = load i64, i64* %61
%63 = load %struct.TYPE_5__*, %struct.TYPE_5__** %4
%64 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %63, i32 0, i32 1
%65 = load i64, i64* %64
%66 = icmp sgt i64 %62, %65
br i1 %66, label %67, label %68
67: ; preds = %59
store i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.2, i64 0, i64 0), i8** %3
br label %69
68: ; preds = %59
store i8* null, i8** %3
br label %69
69: ; preds = %68, %67, %58, %49
%70 = load i8*, i8** %3
ret i8* %70
}

LLVM IR (-O2):
%struct.TYPE_5__ = type { i64, i64 }
%struct.TYPE_6__ = type { i64, i64, i64, i64, i64 }
@.str = [25 x i8] c"ink outside bounding box\00"
@.str.1 = [32 x i8] c"characters not all same descent\00"
@.str.2 = [31 x i8] c"characters not all same ascent\00"
define i8* @non_cell_character(%struct.TYPE_5__* nocapture %0, %struct.TYPE_6__* nocapture %1) {
%3 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %1, i64 0, i32 0
%4 = load i64, i64* %3
%5 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %1, i64 0, i32 1
%6 = load i64, i64* %5
%7 = icmp sgt i64 %4, %6
br i1 %7, label %8, label %20
8: ; preds = %2
%9 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %1, i64 0, i32 2
%10 = load i64, i64* %9
%11 = icmp slt i64 %10, 0
br i1 %11, label %12, label %16
12: ; preds = %8
%13 = icmp sgt i64 %10, %4
%14 = icmp sgt i64 %6, 0
%15 = select i1 %13, i1 true, i1 %14
br i1 %15, label %33, label %20
16: ; preds = %8
%17 = icmp slt i64 %10, %6
%18 = icmp slt i64 %4, 0
%19 = select i1 %17, i1 true, i1 %18
br i1 %19, label %33, label %20
20: ; preds = %16, %12, %2
%21 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %1, i64 0, i32 3
%22 = load i64, i64* %21
%23 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %0, i64 0, i32 0
%24 = load i64, i64* %23
%25 = icmp sgt i64 %22, %24
br i1 %25, label %33, label %26
26: ; preds = %20
%27 = getelementptr inbounds %struct.TYPE_6__, %struct.TYPE_6__* %1, i64 0, i32 4
%28 = load i64, i64* %27
%29 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %0, i64 0, i32 1
%30 = load i64, i64* %29
%31 = icmp sgt i64 %28, %30
%32 = select i1 %31, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.2, i64 0, i64 0), i8* null
br label %33
33: ; preds = %26, %20, %12, %16
%34 = phi i8* [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), %16 ], [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), %12 ], [ getelementptr inbounds ([32 x i8], [32 x i8]* @.str.1, i64 0, i64 0), %20 ], [ %32, %26 ]
ret i8* %34
}