#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*/ printf(char *, float, float, float, float, int);
int segintf(float, float, float, float);
int main(void) {
  float x1, y1, x2, y2;
  float N = 10.0f;
  for (x1 = -N; x1 <= N; x1++) {
    for (y1 = -N; y1 <= N; y1++) {
      for (x2 = -N; x2 <= N; x2++) {
        for (y2 = -N; y2 <= N; y2++) {
          printf("%.2f %.2f %.2f %.2f %d\n", x1, x2, y1, y2,
                 segintf(x1, x2, y1, y2));
        }
      }
    }
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
movss  0xec9(%rip),%xmm0
movss  %xmm0,-0x18(%rbp)
movss  -0x18(%rbp),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
movss  %xmm0,-0x8(%rbp)
movss  -0x8(%rbp),%xmm1
movss  -0x18(%rbp),%xmm0
ucomiss %xmm1,%xmm0
jb     12b2 <main+0x192>
movss  -0x18(%rbp),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
movss  %xmm0,-0xc(%rbp)
movss  -0xc(%rbp),%xmm1
movss  -0x18(%rbp),%xmm0
ucomiss %xmm1,%xmm0
jb     1296 <main+0x176>
movss  -0x18(%rbp),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
movss  %xmm0,-0x10(%rbp)
movss  -0x10(%rbp),%xmm1
movss  -0x18(%rbp),%xmm0
ucomiss %xmm1,%xmm0
jb     127a <main+0x15a>
movss  -0x18(%rbp),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
movss  %xmm0,-0x14(%rbp)
movss  -0x14(%rbp),%xmm1
movss  -0x18(%rbp),%xmm0
ucomiss %xmm1,%xmm0
jb     125e <main+0x13e>
movss  -0x8(%rbp),%xmm0
movss  %xmm0,-0x28(%rbp)
movss  -0x10(%rbp),%xmm0
movss  %xmm0,-0x24(%rbp)
movss  -0xc(%rbp),%xmm0
movss  %xmm0,-0x20(%rbp)
movss  -0x14(%rbp),%xmm0
movss  %xmm0,-0x1c(%rbp)
movss  -0x8(%rbp),%xmm0
movss  -0x10(%rbp),%xmm1
movss  -0xc(%rbp),%xmm2
movss  -0x14(%rbp),%xmm3
call   1040 <segintf@plt>
movss  -0x28(%rbp),%xmm0
movss  -0x24(%rbp),%xmm1
movss  -0x20(%rbp),%xmm2
movss  -0x1c(%rbp),%xmm3
mov    %eax,%esi
lea    0xdc6(%rip),%rdi
call   1030 <printf@plt>
movss  0xdb5(%rip),%xmm0
addss  -0x14(%rbp),%xmm0
movss  %xmm0,-0x14(%rbp)
jmp    11d1 <main+0xb1>
jmp    1263 <main+0x143>
movss  0xd99(%rip),%xmm0
addss  -0x10(%rbp),%xmm0
movss  %xmm0,-0x10(%rbp)
jmp    11a7 <main+0x87>
jmp    127f <main+0x15f>
movss  0xd7d(%rip),%xmm0
addss  -0xc(%rbp),%xmm0
movss  %xmm0,-0xc(%rbp)
jmp    117d <main+0x5d>
jmp    129b <main+0x17b>
movss  0xd61(%rip),%xmm0
addss  -0x8(%rbp),%xmm0
movss  %xmm0,-0x8(%rbp)
jmp    1153 <main+0x33>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x10,%rsp
mov    $0xfffffff6,%r14d
lea    0xec7(%rip),%rbx
nopl   0x0(%rax)
xorps  %xmm0,%xmm0
cvtsi2ss %r14d,%xmm0
mov    $0xfffffff6,%r15d
movss  %xmm0,(%rsp)
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
xorps  %xmm1,%xmm1
cvtsi2ss %r15d,%xmm1
mov    $0xfffffff6,%r12d
movss  %xmm1,0x4(%rsp)
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
xorps  %xmm2,%xmm2
cvtsi2ss %r12d,%xmm2
movss  %xmm2,0x8(%rsp)
mov    $0xfffffff6,%ebp
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
xorps  %xmm3,%xmm3
cvtsi2ss %ebp,%xmm3
movss  %xmm3,0xc(%rsp)
movss  (%rsp),%xmm0
movss  0x8(%rsp),%xmm1
movss  0x4(%rsp),%xmm2
call   1040 <segintf@plt>
mov    %rbx,%rdi
movss  (%rsp),%xmm0
movss  0x8(%rsp),%xmm1
movss  0x4(%rsp),%xmm2
movss  0xc(%rsp),%xmm3
mov    %eax,%esi
call   1030 <printf@plt>
add    $0x1,%ebp
cmp    $0xb,%ebp
jne    11a0 <main+0x80>
add    $0x1,%r12d
cmp    $0xb,%r12d
jne    1180 <main+0x60>
add    $0x1,%r15d
cmp    $0xb,%r15d
jne    1160 <main+0x40>
add    $0x1,%r14d
cmp    $0xb,%r14d
jne    1140 <main+0x20>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [24 x i8] c"%.2f %.2f %.2f %.2f %d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca float
%3 = alloca float
%4 = alloca float
%5 = alloca float
%6 = alloca float
store i32 0, i32* %1
store float 1.000000e+01, float* %6
%7 = load float, float* %6
%8 = fneg float %7
store float %8, float* %2
br label %9
9: ; preds = %57, %0
%10 = load float, float* %2
%11 = load float, float* %6
%12 = fcmp ole float %10, %11
br i1 %12, label %13, label %60
13: ; preds = %9
%14 = load float, float* %6
%15 = fneg float %14
store float %15, float* %3
br label %16
16: ; preds = %53, %13
%17 = load float, float* %3
%18 = load float, float* %6
%19 = fcmp ole float %17, %18
br i1 %19, label %20, label %56
20: ; preds = %16
%21 = load float, float* %6
%22 = fneg float %21
store float %22, float* %4
br label %23
23: ; preds = %49, %20
%24 = load float, float* %4
%25 = load float, float* %6
%26 = fcmp ole float %24, %25
br i1 %26, label %27, label %52
27: ; preds = %23
%28 = load float, float* %6
%29 = fneg float %28
store float %29, float* %5
br label %30
30: ; preds = %45, %27
%31 = load float, float* %5
%32 = load float, float* %6
%33 = fcmp ole float %31, %32
br i1 %33, label %34, label %48
34: ; preds = %30
%35 = load float, float* %2
%36 = load float, float* %4
%37 = load float, float* %3
%38 = load float, float* %5
%39 = load float, float* %2
%40 = load float, float* %4
%41 = load float, float* %3
%42 = load float, float* %5
%43 = call i32 @segintf(float %39, float %40, float %41, float %42)
%44 = call i32 @printf(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str, i64 0, i64 0), float %35, float %36, float %37, float %38, i32 %43)
br label %45
45: ; preds = %34
%46 = load float, float* %5
%47 = fadd float %46, 1.000000e+00
store float %47, float* %5
br label %30
48: ; preds = %30
br label %49
49: ; preds = %48
%50 = load float, float* %4
%51 = fadd float %50, 1.000000e+00
store float %51, float* %4
br label %23
52: ; preds = %23
br label %53
53: ; preds = %52
%54 = load float, float* %3
%55 = fadd float %54, 1.000000e+00
store float %55, float* %3
br label %16
56: ; preds = %16
br label %57
57: ; preds = %56
%58 = load float, float* %2
%59 = fadd float %58, 1.000000e+00
store float %59, float* %2
br label %9
60: ; preds = %9
ret i32 0
}

LLVM IR (-O2):
@.str = [24 x i8] c"%.2f %.2f %.2f %.2f %d\0A\00"
define i32 @main() {
br label %1
1: ; preds = %0, %23
%2 = phi i32 [ -10, %0 ], [ %24, %23 ]
%3 = sitofp i32 %2 to float
br label %4
4: ; preds = %1, %20
%5 = phi i32 [ -10, %1 ], [ %21, %20 ]
%6 = sitofp i32 %5 to float
br label %7
7: ; preds = %4, %17
%8 = phi i32 [ -10, %4 ], [ %18, %17 ]
%9 = sitofp i32 %8 to float
br label %10
10: ; preds = %7, %10
%11 = phi i32 [ -10, %7 ], [ %15, %10 ]
%12 = sitofp i32 %11 to float
%13 = tail call i32 @segintf(float %3, float %9, float %6, float %12)
%14 = tail call i32 @printf(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str, i64 0, i64 0), float %3, float %9, float %6, float %12, i32 %13)
%15 = add nsw i32 %11, 1
%16 = icmp eq i32 %15, 11
br i1 %16, label %17, label %10
17: ; preds = %10
%18 = add nsw i32 %8, 1
%19 = icmp eq i32 %18, 11
br i1 %19, label %20, label %7
20: ; preds = %17
%21 = add nsw i32 %5, 1
%22 = icmp eq i32 %21, 11
br i1 %22, label %23, label %4
23: ; preds = %20
%24 = add nsw i32 %2, 1
%25 = icmp eq i32 %24, 11
br i1 %25, label %26, label %1
26: ; preds = %23
ret i32 0
}