#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 copy_multprec_start_solutions_to_container();
int initialize_multprec_homotopy(int, int);
int initialize_multprec_solution(int);
int /*<<< orphan*/ printf(char *, ...);
int read_multprec_start_system(int);
int read_multprec_target_system(int);
int /*<<< orphan*/ scanf(char *, ...);
int solcon_number_of_multprec_solutions(int *);
int call_initialize_multprec_homotopy(int *index) {
  int fail, len, deci, fixed;
  char nlc;
  printf("\ngive the number of decimal places in the working precision : ");
  scanf("%d", &deci);
  scanf("%c", &nlc);
  fail = read_multprec_target_system(deci);
  fail = read_multprec_start_system(deci);
  fail = copy_multprec_start_solutions_to_container();
  fail = solcon_number_of_multprec_solutions(&len);
  printf("Number of start solutions : %d\n", len);
  printf("-> give index of solution : ");
  scanf("%d", index);
  printf("Fixed gamma constant ? (1 = yes/0 = no) ");
  scanf("%d", &fixed);
  fail = initialize_multprec_homotopy(fixed, deci);
  fail = initialize_multprec_solution(*index);
  return fail;
}


x86 assembly (clang, -O0):
<call_initialize_multprec_homotopy>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
lea    0xe6d(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe9e(%rip),%rdi
lea    -0x14(%rbp),%rsi
mov    $0x0,%al
call   1060 <scanf@plt>
lea    0xe8f(%rip),%rdi
lea    -0x19(%rbp),%rsi
mov    $0x0,%al
call   1060 <scanf@plt>
mov    -0x14(%rbp),%edi
call   1050 <read_multprec_target_system@plt>
mov    %eax,-0xc(%rbp)
mov    -0x14(%rbp),%edi
call   1080 <read_multprec_start_system@plt>
mov    %eax,-0xc(%rbp)
mov    $0x0,%al
call   1030 <copy_multprec_start_solutions_to_container@plt>
mov    %eax,-0xc(%rbp)
lea    -0x10(%rbp),%rdi
call   10a0 <solcon_number_of_multprec_solutions@plt>
mov    %eax,-0xc(%rbp)
mov    -0x10(%rbp),%esi
lea    0xe51(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe63(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%rsi
lea    0xe2b(%rip),%rdi
mov    $0x0,%al
call   1060 <scanf@plt>
lea    0xe60(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe0f(%rip),%rdi
lea    -0x18(%rbp),%rsi
mov    $0x0,%al
call   1060 <scanf@plt>
mov    -0x18(%rbp),%edi
mov    -0x14(%rbp),%esi
call   1090 <initialize_multprec_homotopy@plt>
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%edi
call   1070 <initialize_multprec_solution@plt>
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<call_initialize_multprec_homotopy>:
push   %r14
push   %rbx
sub    $0x18,%rsp
mov    %rdi,%rbx
lea    0xe6f(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xea0(%rip),%r14
lea    0x8(%rsp),%rsi
mov    %r14,%rdi
xor    %eax,%eax
call   1060 <scanf@plt>
lea    0xe8d(%rip),%rdi
lea    0xf(%rsp),%rsi
xor    %eax,%eax
call   1060 <scanf@plt>
mov    0x8(%rsp),%edi
call   1050 <read_multprec_target_system@plt>
mov    0x8(%rsp),%edi
call   1080 <read_multprec_start_system@plt>
xor    %eax,%eax
call   1030 <copy_multprec_start_solutions_to_container@plt>
lea    0x14(%rsp),%rdi
call   10a0 <solcon_number_of_multprec_solutions@plt>
mov    0x14(%rsp),%esi
lea    0xe56(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe68(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1060 <scanf@plt>
lea    0xe6a(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0x10(%rsp),%rsi
mov    %r14,%rdi
xor    %eax,%eax
call   1060 <scanf@plt>
mov    0x10(%rsp),%edi
mov    0x8(%rsp),%esi
call   1090 <initialize_multprec_homotopy@plt>
mov    (%rbx),%edi
call   1070 <initialize_multprec_solution@plt>
add    $0x18,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [63 x i8] c"\0Agive the number of decimal places in the working precision : \00"
@.str.1 = [3 x i8] c"%d\00"
@.str.2 = [3 x i8] c"%c\00"
@.str.3 = [32 x i8] c"Number of start solutions : %d\0A\00"
@.str.4 = [29 x i8] c"-> give index of solution : \00"
@.str.5 = [41 x i8] c"Fixed gamma constant ? (1 = yes/0 = no) \00"
define i32 @call_initialize_multprec_homotopy(i32* %0) {
%2 = alloca i32*
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i8
store i32* %0, i32** %2
%8 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([63 x i8], [63 x i8]* @.str, i64 0, i64 0))
%9 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %5)
%10 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i8* %7)
%11 = load i32, i32* %5
%12 = call i32 @read_multprec_target_system(i32 %11)
store i32 %12, i32* %3
%13 = load i32, i32* %5
%14 = call i32 @read_multprec_start_system(i32 %13)
store i32 %14, i32* %3
%15 = call i32 (...) @copy_multprec_start_solutions_to_container()
store i32 %15, i32* %3
%16 = call i32 @solcon_number_of_multprec_solutions(i32* %4)
store i32 %16, i32* %3
%17 = load i32, i32* %4
%18 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.3, i64 0, i64 0), i32 %17)
%19 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.4, i64 0, i64 0))
%20 = load i32*, i32** %2
%21 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %20)
%22 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.5, i64 0, i64 0))
%23 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %6)
%24 = load i32, i32* %6
%25 = load i32, i32* %5
%26 = call i32 @initialize_multprec_homotopy(i32 %24, i32 %25)
store i32 %26, i32* %3
%27 = load i32*, i32** %2
%28 = load i32, i32* %27
%29 = call i32 @initialize_multprec_solution(i32 %28)
store i32 %29, i32* %3
%30 = load i32, i32* %3
ret i32 %30
}

LLVM IR (-O2):
@.str = [63 x i8] c"\0Agive the number of decimal places in the working precision : \00"
@.str.1 = [3 x i8] c"%d\00"
@.str.2 = [3 x i8] c"%c\00"
@.str.3 = [32 x i8] c"Number of start solutions : %d\0A\00"
@.str.4 = [29 x i8] c"-> give index of solution : \00"
@.str.5 = [41 x i8] c"Fixed gamma constant ? (1 = yes/0 = no) \00"
define i32 @call_initialize_multprec_homotopy(i32* %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8
%6 = bitcast i32* %2 to i8*
%7 = bitcast i32* %3 to i8*
%8 = bitcast i32* %4 to i8*
%9 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([63 x i8], [63 x i8]* @.str, i64 0, i64 0))
%10 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %3)
%11 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i8* %5)
%12 = load i32, i32* %3
%13 = call i32 @read_multprec_target_system(i32 %12)
%14 = load i32, i32* %3
%15 = call i32 @read_multprec_start_system(i32 %14)
%16 = call i32 (...) @copy_multprec_start_solutions_to_container()
%17 = call i32 @solcon_number_of_multprec_solutions(i32* %2)
%18 = load i32, i32* %2
%19 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @.str.3, i64 0, i64 0), i32 %18)
%20 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @.str.4, i64 0, i64 0))
%21 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %0)
%22 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @.str.5, i64 0, i64 0))
%23 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %4)
%24 = load i32, i32* %4
%25 = load i32, i32* %3
%26 = call i32 @initialize_multprec_homotopy(i32 %24, i32 %25)
%27 = load i32, i32* %0
%28 = call i32 @initialize_multprec_solution(i32 %27)
ret i32 %28
}