#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*/ free_vector(float *, int, int);
int /*<<< orphan*/ printf(char *, float, float, float, int);
int /*<<< orphan*/ sobseq(int *, float *);
float *vector(int, int);
int main(void) {
  int i, n1 = (-1), n2 = 3;
  float *x;
  x = vector(1, n2);
  sobseq(&n1, x);
  for (i = 1; i <= 32; i++) {
    sobseq(&n2, x);
    printf(" %10.5f %10.5f %10.5f %5d\n", x[1], x[2], x[3], i);
  }
  free_vector(x, 1, n2);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0xffffffff,-0xc(%rbp)
movl   $0x3,-0x10(%rbp)
mov    -0x10(%rbp),%esi
mov    $0x1,%edi
call   1050 <vector@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rsi
lea    -0xc(%rbp),%rdi
call   1060 <sobseq@plt>
movl   $0x1,-0x8(%rbp)
cmpl   $0x20,-0x8(%rbp)
jg     11d1 <main+0x91>
mov    -0x18(%rbp),%rsi
lea    -0x10(%rbp),%rdi
call   1060 <sobseq@plt>
mov    -0x18(%rbp),%rax
movss  0x4(%rax),%xmm0
mov    -0x18(%rbp),%rax
movss  0x8(%rax),%xmm1
mov    -0x18(%rbp),%rax
movss  0xc(%rax),%xmm2
mov    -0x8(%rbp),%esi
lea    0xe42(%rip),%rdi
call   1030 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1182 <main+0x42>
mov    -0x18(%rbp),%rdi
mov    -0x10(%rbp),%edx
mov    $0x1,%esi
call   1040 <free_vector@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
movl   $0xffffffff,0x4(%rsp)
ff
movl   $0x3,(%rsp)
mov    $0x1,%ebx
mov    $0x1,%edi
mov    $0x3,%esi
call   1050 <vector@plt>
mov    %rax,%r14
lea    0x4(%rsp),%rdi
mov    %rax,%rsi
call   1060 <sobseq@plt>
mov    %rsp,%r15
lea    0xe7b(%rip),%r12
cs nopw 0x0(%rax,%rax,1)
nop
mov    %r15,%rdi
mov    %r14,%rsi
call   1060 <sobseq@plt>
movss  0x4(%r14),%xmm0
movss  0x8(%r14),%xmm1
movss  0xc(%r14),%xmm2
mov    %r12,%rdi
mov    %ebx,%esi
call   1030 <printf@plt>
add    $0x1,%ebx
cmp    $0x21,%ebx
jne    1190 <main+0x50>
mov    (%rsp),%edx
mov    %r14,%rdi
mov    $0x1,%esi
call   1040 <free_vector@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [27 x i8] c" %10.5f %10.5f %10.5f %5d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca float*
store i32 0, i32* %1
store i32 -1, i32* %3
store i32 3, i32* %4
%6 = load i32, i32* %4
%7 = call float* @vector(i32 1, i32 %6)
store float* %7, float** %5
%8 = load float*, float** %5
%9 = call i32 @sobseq(i32* %3, float* %8)
store i32 1, i32* %2
br label %10
10: ; preds = %27, %0
%11 = load i32, i32* %2
%12 = icmp sle i32 %11, 32
br i1 %12, label %13, label %30
13: ; preds = %10
%14 = load float*, float** %5
%15 = call i32 @sobseq(i32* %4, float* %14)
%16 = load float*, float** %5
%17 = getelementptr inbounds float, float* %16, i64 1
%18 = load float, float* %17
%19 = load float*, float** %5
%20 = getelementptr inbounds float, float* %19, i64 2
%21 = load float, float* %20
%22 = load float*, float** %5
%23 = getelementptr inbounds float, float* %22, i64 3
%24 = load float, float* %23
%25 = load i32, i32* %2
%26 = call i32 @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str, i64 0, i64 0), float %18, float %21, float %24, i32 %25)
br label %27
27: ; preds = %13
%28 = load i32, i32* %2
%29 = add nsw i32 %28, 1
store i32 %29, i32* %2
br label %10
30: ; preds = %10
%31 = load float*, float** %5
%32 = load i32, i32* %4
%33 = call i32 @free_vector(float* %31, i32 1, i32 %32)
ret i32 0
}

LLVM IR (-O2):
@.str = [27 x i8] c" %10.5f %10.5f %10.5f %5d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = bitcast i32* %1 to i8*
store i32 -1, i32* %1
%4 = bitcast i32* %2 to i8*
store i32 3, i32* %2
%5 = tail call float* @vector(i32 1, i32 3)
%6 = call i32 @sobseq(i32* %1, float* %5)
%7 = getelementptr inbounds float, float* %5, i64 1
%8 = getelementptr inbounds float, float* %5, i64 2
%9 = getelementptr inbounds float, float* %5, i64 3
br label %10
10: ; preds = %0, %10
%11 = phi i32 [ 1, %0 ], [ %17, %10 ]
%12 = call i32 @sobseq(i32* %2, float* %5)
%13 = load float, float* %7
%14 = load float, float* %8
%15 = load float, float* %9
%16 = call i32 @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str, i64 0, i64 0), float %13, float %14, float %15, i32 %11)
%17 = add nuw nsw i32 %11, 1
%18 = icmp eq i32 %17, 33
br i1 %18, label %19, label %10
19: ; preds = %10
%20 = load i32, i32* %2
%21 = call i32 @free_vector(float* %5, i32 1, i32 %20)
ret i32 0
}