#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 intcelcon_get_lifted_point(int, int, int, int *);
int intcelcon_length_of_supports(int *, int *);
int /*<<< orphan*/ printf(char *, ...);
void write_integer_lifted_supports(int n, int r, int *mix) {
  int fail, rr, i, j, k, m;
  int nb[r];
  fail = intcelcon_length_of_supports(&rr, nb);
  printf("Number of different supports retrieved : %d.\n", rr);
  printf("Length of each support :");
  for (i = 0; i < r; i++)
    printf(" %d", nb[i]);
  printf("\n");
  for (i = 1; i <= r; i++) {
    printf("Points in support %d :\n", i);
    for (j = 1; j <= nb[i - 1]; j++) {
      int point[n];
      printf("-> point %d of %d :", j, nb[i - 1]);
      fail = intcelcon_get_lifted_point(n, i, j, point);
      for (k = 0; k < n; k++)
        printf(" %d", point[k]);
      printf("\n");
    }
  }
}


x86 assembly (clang, -O0):
<write_integer_lifted_supports>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %rdx,-0x10(%rbp)
mov    -0x8(%rbp),%eax
mov    %rsp,%rcx
mov    %rcx,-0x30(%rbp)
lea    0xf(,%rax,4),%rcx
and    $0xfffffffffffffff0,%rcx
mov    %rsp,%rsi
sub    %rcx,%rsi
mov    %rsi,-0x50(%rbp)
mov    %rsi,%rsp
mov    %rax,-0x38(%rbp)
lea    -0x18(%rbp),%rdi
call   1040 <intcelcon_length_of_supports@plt>
mov    %eax,-0x14(%rbp)
mov    -0x18(%rbp),%esi
lea    0xe81(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
lea    0xea1(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
movl   $0x0,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    11ce <write_integer_lifted_supports+0x9e>
mov    -0x50(%rbp),%rax
movslq -0x1c(%rbp),%rcx
mov    (%rax,%rcx,4),%esi
lea    0xe8e(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    119b <write_integer_lifted_supports+0x6b>
lea    0xe57(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
movl   $0x1,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
cmp    -0x8(%rbp),%eax
jg     12ed <write_integer_lifted_supports+0x1bd>
mov    -0x1c(%rbp),%esi
lea    0xe52(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
movl   $0x1,-0x20(%rbp)
mov    -0x50(%rbp),%rcx
mov    -0x20(%rbp),%eax
mov    -0x1c(%rbp),%edx
sub    $0x1,%edx
movslq %edx,%rdx
cmp    (%rcx,%rdx,4),%eax
jg     12da <write_integer_lifted_supports+0x1aa>
mov    -0x50(%rbp),%rax
mov    -0x4(%rbp),%ecx
mov    %rsp,%rdx
mov    %rdx,-0x40(%rbp)
lea    0xf(,%rcx,4),%rsi
and    $0xfffffffffffffff0,%rsi
mov    %rsp,%rdx
sub    %rsi,%rdx
mov    %rdx,-0x58(%rbp)
mov    %rdx,%rsp
mov    %rcx,-0x48(%rbp)
mov    -0x20(%rbp),%esi
mov    -0x1c(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
mov    (%rax,%rcx,4),%edx
lea    0xe02(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x58(%rbp),%rcx
mov    -0x4(%rbp),%edi
mov    -0x1c(%rbp),%esi
mov    -0x20(%rbp),%edx
call   1030 <intcelcon_get_lifted_point@plt>
mov    %eax,-0x14(%rbp)
movl   $0x0,-0x24(%rbp)
mov    -0x24(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    12b7 <write_integer_lifted_supports+0x187>
mov    -0x58(%rbp),%rax
movslq -0x24(%rbp),%rcx
mov    (%rax,%rcx,4),%esi
lea    0xda5(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x24(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x24(%rbp)
jmp    1284 <write_integer_lifted_supports+0x154>
lea    0xd6e(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x40(%rbp),%rax
mov    %rax,%rsp
mov    -0x20(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x20(%rbp)
jmp    1207 <write_integer_lifted_supports+0xd7>
jmp    12df <write_integer_lifted_supports+0x1af>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    11e3 <write_integer_lifted_supports+0xb3>
mov    -0x30(%rbp),%rax
mov    %rax,%rsp
mov    %rbp,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<write_integer_lifted_supports>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x48,%rsp
mov    %esi,%ebx
mov    %edi,-0x2c(%rbp)
mov    %rsp,-0x58(%rbp)
mov    %esi,%r15d
mov    %rsp,%rsi
lea    0xf(,%r15,4),%rax
and    $0xfffffffffffffff0,%rax
sub    %rax,%rsi
mov    %rsi,%rsp
lea    -0x44(%rbp),%rdi
mov    %rsi,-0x50(%rbp)
call   1050 <intcelcon_length_of_supports@plt>
mov    -0x44(%rbp),%esi
lea    0xe77(%rip),%rdi
xor    %eax,%eax
call   1060 <printf@plt>
lea    0xe97(%rip),%rdi
xor    %eax,%eax
call   1060 <printf@plt>
mov    %rbx,-0x38(%rbp)
test   %ebx,%ebx
jle    12ec <write_integer_lifted_supports+0x1ac>
lea    0xe96(%rip),%r14
xor    %ebx,%ebx
mov    -0x50(%rbp),%r12
nopw   0x0(%rax,%rax,1)
mov    (%r12,%rbx,4),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
add    $0x1,%rbx
cmp    %rbx,%r15
jne    11c0 <write_integer_lifted_supports+0x80>
mov    $0xa,%edi
call   1030 <putchar@plt>
cmpl   $0x0,-0x38(%rbp)
jle    12f6 <write_integer_lifted_supports+0x1b6>
mov    %r12,%rbx
mov    -0x2c(%rbp),%r12d
mov    -0x38(%rbp),%rax
add    $0x1,%eax
mov    %rax,-0x38(%rbp)
mov    $0x1,%ecx
lea    0xf(,%r12,4),%rax
and    $0xfffffffffffffff0,%rax
mov    %rax,-0x60(%rbp)
lea    0xe2e(%rip),%r14
jmp    122e <write_integer_lifted_supports+0xee>
nopl   0x0(%rax,%rax,1)
add    $0x1,%rcx
cmp    -0x38(%rbp),%rcx
je     12f6 <write_integer_lifted_supports+0x1b6>
mov    %rcx,-0x40(%rbp)
lea    0xe12(%rip),%rdi
mov    -0x40(%rbp),%rsi
xor    %eax,%eax
call   1060 <printf@plt>
mov    -0x40(%rbp),%rcx
cmpl   $0x0,-0x4(%rbx,%rcx,4)
jle    1220 <write_integer_lifted_supports+0xe0>
mov    $0x1,%r13d
jmp    1284 <write_integer_lifted_supports+0x144>
nopw   0x0(%rax,%rax,1)
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    -0x68(%rbp),%rsp
lea    0x1(%r13),%eax
mov    -0x50(%rbp),%rbx
mov    -0x40(%rbp),%rcx
cmp    -0x4(%rbx,%rcx,4),%r13d
mov    %eax,%r13d
jge    1220 <write_integer_lifted_supports+0xe0>
mov    %rsp,-0x68(%rbp)
mov    %rsp,%r15
sub    -0x60(%rbp),%r15
mov    %r15,%rsp
mov    -0x4(%rbx,%rcx,4),%edx
lea    0xdc6(%rip),%rdi
mov    %r13d,%esi
xor    %eax,%eax
call   1060 <printf@plt>
mov    -0x2c(%rbp),%ebx
mov    %ebx,%edi
mov    -0x40(%rbp),%rsi
mov    %r13d,%edx
mov    %r15,%rcx
call   1040 <intcelcon_get_lifted_point@plt>
test   %ebx,%ebx
jle    1260 <write_integer_lifted_supports+0x120>
xor    %ebx,%ebx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    (%r15,%rbx,4),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
add    $0x1,%rbx
cmp    %rbx,%r12
jne    12d0 <write_integer_lifted_supports+0x190>
jmp    1260 <write_integer_lifted_supports+0x120>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    -0x58(%rbp),%rsp
lea    -0x28(%rbp),%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [46 x i8] c"Number of different supports retrieved : %d.\0A\00"
@.str.1 = [25 x i8] c"Length of each support :\00"
@.str.2 = [4 x i8] c" %d\00"
@.str.3 = [2 x i8] c"\0A\00"
@.str.4 = [24 x i8] c"Points in support %d :\0A\00"
@.str.5 = [20 x i8] c"-> point %d of %d :\00"
define void @write_integer_lifted_supports(i32 %0, i32 %1, i32* %2) {
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32*
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%12 = alloca i32
%13 = alloca i8*
%14 = alloca i64
%15 = alloca i8*
%16 = alloca i64
store i32 %0, i32* %4
store i32 %1, i32* %5
store i32* %2, i32** %6
%17 = load i32, i32* %5
%18 = zext i32 %17 to i64
%19 = call i8* @llvm.stacksave()
store i8* %19, i8** %13
%20 = alloca i32, i64 %18
store i64 %18, i64* %14
%21 = call i32 @intcelcon_length_of_supports(i32* %8, i32* %20)
store i32 %21, i32* %7
%22 = load i32, i32* %8
%23 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str, i64 0, i64 0), i32 %22)
%24 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.1, i64 0, i64 0))
store i32 0, i32* %9
br label %25
25: ; preds = %35, %3
%26 = load i32, i32* %9
%27 = load i32, i32* %5
%28 = icmp slt i32 %26, %27
br i1 %28, label %29, label %38
29: ; preds = %25
%30 = load i32, i32* %9
%31 = sext i32 %30 to i64
%32 = getelementptr inbounds i32, i32* %20, i64 %31
%33 = load i32, i32* %32
%34 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %33)
br label %35
35: ; preds = %29
%36 = load i32, i32* %9
%37 = add nsw i32 %36, 1
store i32 %37, i32* %9
br label %25
38: ; preds = %25
%39 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
store i32 1, i32* %9
br label %40
40: ; preds = %91, %38
%41 = load i32, i32* %9
%42 = load i32, i32* %5
%43 = icmp sle i32 %41, %42
br i1 %43, label %44, label %94
44: ; preds = %40
%45 = load i32, i32* %9
%46 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.4, i64 0, i64 0), i32 %45)
store i32 1, i32* %10
br label %47
47: ; preds = %87, %44
%48 = load i32, i32* %10
%49 = load i32, i32* %9
%50 = sub nsw i32 %49, 1
%51 = sext i32 %50 to i64
%52 = getelementptr inbounds i32, i32* %20, i64 %51
%53 = load i32, i32* %52
%54 = icmp sle i32 %48, %53
br i1 %54, label %55, label %90
55: ; preds = %47
%56 = load i32, i32* %4
%57 = zext i32 %56 to i64
%58 = call i8* @llvm.stacksave()
store i8* %58, i8** %15
%59 = alloca i32, i64 %57
store i64 %57, i64* %16
%60 = load i32, i32* %10
%61 = load i32, i32* %9
%62 = sub nsw i32 %61, 1
%63 = sext i32 %62 to i64
%64 = getelementptr inbounds i32, i32* %20, i64 %63
%65 = load i32, i32* %64
%66 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.5, i64 0, i64 0), i32 %60, i32 %65)
%67 = load i32, i32* %4
%68 = load i32, i32* %9
%69 = load i32, i32* %10
%70 = call i32 @intcelcon_get_lifted_point(i32 %67, i32 %68, i32 %69, i32* %59)
store i32 %70, i32* %7
store i32 0, i32* %11
br label %71
71: ; preds = %81, %55
%72 = load i32, i32* %11
%73 = load i32, i32* %4
%74 = icmp slt i32 %72, %73
br i1 %74, label %75, label %84
75: ; preds = %71
%76 = load i32, i32* %11
%77 = sext i32 %76 to i64
%78 = getelementptr inbounds i32, i32* %59, i64 %77
%79 = load i32, i32* %78
%80 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %79)
br label %81
81: ; preds = %75
%82 = load i32, i32* %11
%83 = add nsw i32 %82, 1
store i32 %83, i32* %11
br label %71
84: ; preds = %71
%85 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
%86 = load i8*, i8** %15
br label %87
87: ; preds = %84
%88 = load i32, i32* %10
%89 = add nsw i32 %88, 1
store i32 %89, i32* %10
br label %47
90: ; preds = %47
br label %91
91: ; preds = %90
%92 = load i32, i32* %9
%93 = add nsw i32 %92, 1
store i32 %93, i32* %9
br label %40
94: ; preds = %40
%95 = load i8*, i8** %13
ret void
}

LLVM IR (-O2):
@.str = [46 x i8] c"Number of different supports retrieved : %d.\0A\00"
@.str.1 = [25 x i8] c"Length of each support :\00"
@.str.2 = [4 x i8] c" %d\00"
@.str.4 = [24 x i8] c"Points in support %d :\0A\00"
@.str.5 = [20 x i8] c"-> point %d of %d :\00"
define void @write_integer_lifted_supports(i32 %0, i32 %1, i32* nocapture readnone %2) {
%4 = alloca i32
%5 = bitcast i32* %4 to i8*
%6 = zext i32 %1 to i64
%7 = tail call i8* @llvm.stacksave()
%8 = alloca i32, i64 %6
%9 = call i32 @intcelcon_length_of_supports(i32* %4, i32* %8)
%10 = load i32, i32* %4
%11 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([46 x i8], [46 x i8]* @.str, i64 0, i64 0), i32 %10)
%12 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([25 x i8], [25 x i8]* @.str.1, i64 0, i64 0))
%13 = icmp sgt i32 %1, 0
br i1 %13, label %16, label %14
14: ; preds = %3
%15 = call i32 @putchar(i32 10)
br label %61
16: ; preds = %3, %16
%17 = phi i64 [ %21, %16 ], [ 0, %3 ]
%18 = getelementptr inbounds i32, i32* %8, i64 %17
%19 = load i32, i32* %18
%20 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %19)
%21 = add nuw nsw i64 %17, 1
%22 = icmp eq i64 %21, %6
br i1 %22, label %23, label %16
23: ; preds = %16
%24 = call i32 @putchar(i32 10)
%25 = icmp slt i32 %1, 1
br i1 %25, label %61, label %26
26: ; preds = %23
%27 = zext i32 %0 to i64
%28 = icmp sgt i32 %0, 0
%29 = add nuw i32 %1, 1
%30 = zext i32 %29 to i64
br label %31
31: ; preds = %26, %58
%32 = phi i64 [ 1, %26 ], [ %59, %58 ]
%33 = trunc i64 %32 to i32
%34 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([24 x i8], [24 x i8]* @.str.4, i64 0, i64 0), i32 %33)
%35 = add nsw i64 %32, -1
%36 = getelementptr inbounds i32, i32* %8, i64 %35
%37 = load i32, i32* %36
%38 = icmp slt i32 %37, 1
br i1 %38, label %58, label %39
39: ; preds = %31, %53
%40 = phi i32 [ %55, %53 ], [ 1, %31 ]
%41 = call i8* @llvm.stacksave()
%42 = alloca i32, i64 %27
%43 = load i32, i32* %36
%44 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.5, i64 0, i64 0), i32 %40, i32 %43)
%45 = call i32 @intcelcon_get_lifted_point(i32 %0, i32 %33, i32 %40, i32* %42)
br i1 %28, label %46, label %53
46: ; preds = %39, %46
%47 = phi i64 [ %51, %46 ], [ 0, %39 ]
%48 = getelementptr inbounds i32, i32* %42, i64 %47
%49 = load i32, i32* %48
%50 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %49)
%51 = add nuw nsw i64 %47, 1
%52 = icmp eq i64 %51, %27
br i1 %52, label %53, label %46
53: ; preds = %46, %39
%54 = call i32 @putchar(i32 10)
%55 = add nuw nsw i32 %40, 1
%56 = load i32, i32* %36
%57 = icmp slt i32 %40, %56
br i1 %57, label %39, label %58
58: ; preds = %53, %31
%59 = add nuw nsw i64 %32, 1
%60 = icmp eq i64 %59, %30
br i1 %60, label %61, label %31
61: ; preds = %58, %14, %23
ret void
}