#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 *);
int /*<<< orphan*/ scanf(char *, int *);
void acceptSet(int set[]) {
  int i = 0;
  printf("\nEnter data now: ");
  for (i = 0; i < 20; i++)
    scanf("%d", &set[i]);
  return;
}


x86 assembly (clang, -O0):
<acceptSet>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
lea    0xec6(%rip),%rdi
call   1030 <printf@plt>
movl   $0x0,-0xc(%rbp)
cmpl   $0x14,-0xc(%rbp)
jge    1179 <acceptSet+0x59>
mov    -0x8(%rbp),%rsi
movslq -0xc(%rbp),%rax
shl    $0x2,%rax
add    %rax,%rsi
lea    0xeac(%rip),%rdi
call   1040 <scanf@plt>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1146 <acceptSet+0x26>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<acceptSet>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%rbx
lea    0xed2(%rip),%rdi
call   1030 <printf@plt>
lea    0xed8(%rip),%r14
mov    %r14,%rdi
mov    %rbx,%rsi
call   1040 <scanf@plt>
lea    0x4(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x8(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0xc(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x10(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x14(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x18(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x1c(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x20(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x24(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x28(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x2c(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x30(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x34(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x38(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x3c(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x40(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x44(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
lea    0x48(%rbx),%rsi
mov    %r14,%rdi
call   1040 <scanf@plt>
add    $0x4c,%rbx
mov    %r14,%rdi
mov    %rbx,%rsi
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1040 <scanf@plt>

LLVM IR (-O0):
@.str = [18 x i8] c"\0AEnter data now: \00"
@.str.1 = [3 x i8] c"%d\00"
define void @acceptSet(i32* %0) {
%2 = alloca i32*
%3 = alloca i32
store i32* %0, i32** %2
store i32 0, i32* %3
%4 = call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0))
store i32 0, i32* %3
br label %5
5: ; preds = %14, %1
%6 = load i32, i32* %3
%7 = icmp slt i32 %6, 20
br i1 %7, label %8, label %17
8: ; preds = %5
%9 = load i32*, i32** %2
%10 = load i32, i32* %3
%11 = sext i32 %10 to i64
%12 = getelementptr inbounds i32, i32* %9, i64 %11
%13 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %12)
br label %14
14: ; preds = %8
%15 = load i32, i32* %3
%16 = add nsw i32 %15, 1
store i32 %16, i32* %3
br label %5
17: ; preds = %5
ret void
}

LLVM IR (-O2):
@.str = [18 x i8] c"\0AEnter data now: \00"
@.str.1 = [3 x i8] c"%d\00"
define void @acceptSet(i32* %0) {
%2 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0))
%3 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %0)
%4 = getelementptr inbounds i32, i32* %0, i64 1
%5 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %4)
%6 = getelementptr inbounds i32, i32* %0, i64 2
%7 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %6)
%8 = getelementptr inbounds i32, i32* %0, i64 3
%9 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %8)
%10 = getelementptr inbounds i32, i32* %0, i64 4
%11 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %10)
%12 = getelementptr inbounds i32, i32* %0, i64 5
%13 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %12)
%14 = getelementptr inbounds i32, i32* %0, i64 6
%15 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %14)
%16 = getelementptr inbounds i32, i32* %0, i64 7
%17 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %16)
%18 = getelementptr inbounds i32, i32* %0, i64 8
%19 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %18)
%20 = getelementptr inbounds i32, i32* %0, i64 9
%21 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %20)
%22 = getelementptr inbounds i32, i32* %0, i64 10
%23 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %22)
%24 = getelementptr inbounds i32, i32* %0, i64 11
%25 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %24)
%26 = getelementptr inbounds i32, i32* %0, i64 12
%27 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %26)
%28 = getelementptr inbounds i32, i32* %0, i64 13
%29 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %28)
%30 = getelementptr inbounds i32, i32* %0, i64 14
%31 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %30)
%32 = getelementptr inbounds i32, i32* %0, i64 15
%33 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %32)
%34 = getelementptr inbounds i32, i32* %0, i64 16
%35 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %34)
%36 = getelementptr inbounds i32, i32* %0, i64 17
%37 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %36)
%38 = getelementptr inbounds i32, i32* %0, i64 18
%39 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %38)
%40 = getelementptr inbounds i32, i32* %0, i64 19
%41 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %40)
ret void
}