#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*/ effect_random_sparkle_flash(int, int, int);
void effect_random_sparkle(void) {
  int i;
  for (i = 1; i < 20; i++) {
    effect_random_sparkle_flash(5, i, 100);
  }
  for (i = 20; i >= 1; i--) {
    effect_random_sparkle_flash(5, i, 100);
  }
}


x86 assembly (clang, -O0):
<effect_random_sparkle>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x1,-0x4(%rbp)
cmpl   $0x14,-0x4(%rbp)
jge    1149 <effect_random_sparkle+0x39>
mov    -0x4(%rbp),%esi
mov    $0x5,%edi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    111f <effect_random_sparkle+0xf>
movl   $0x14,-0x4(%rbp)
cmpl   $0x1,-0x4(%rbp)
jl     117a <effect_random_sparkle+0x6a>
mov    -0x4(%rbp),%esi
mov    $0x5,%edi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    -0x4(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x4(%rbp)
jmp    1150 <effect_random_sparkle+0x40>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<effect_random_sparkle>:
push   %rax
mov    $0x5,%edi
mov    $0x1,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x2,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x3,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x4,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x5,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x6,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x7,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x8,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x9,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xa,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xb,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xc,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xd,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xe,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xf,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x10,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x11,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x12,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x13,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x14,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x13,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x12,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x11,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x10,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xf,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xe,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xd,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xc,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xb,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0xa,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x9,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x8,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x7,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x6,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x5,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x4,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x3,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x2,%esi
mov    $0x64,%edx
call   1030 <effect_random_sparkle_flash@plt>
mov    $0x5,%edi
mov    $0x1,%esi
mov    $0x64,%edx
pop    %rax
jmp    1030 <effect_random_sparkle_flash@plt>

LLVM IR (-O0):
define void @effect_random_sparkle() {
%1 = alloca i32
store i32 1, i32* %1
br label %2
2: ; preds = %8, %0
%3 = load i32, i32* %1
%4 = icmp slt i32 %3, 20
br i1 %4, label %5, label %11
5: ; preds = %2
%6 = load i32, i32* %1
%7 = call i32 @effect_random_sparkle_flash(i32 5, i32 %6, i32 100)
br label %8
8: ; preds = %5
%9 = load i32, i32* %1
%10 = add nsw i32 %9, 1
store i32 %10, i32* %1
br label %2
11: ; preds = %2
store i32 20, i32* %1
br label %12
12: ; preds = %18, %11
%13 = load i32, i32* %1
%14 = icmp sge i32 %13, 1
br i1 %14, label %15, label %21
15: ; preds = %12
%16 = load i32, i32* %1
%17 = call i32 @effect_random_sparkle_flash(i32 5, i32 %16, i32 100)
br label %18
18: ; preds = %15
%19 = load i32, i32* %1
%20 = add nsw i32 %19, -1
store i32 %20, i32* %1
br label %12
21: ; preds = %12
ret void
}

LLVM IR (-O2):
define void @effect_random_sparkle() {
%1 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 1, i32 100)
%2 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 2, i32 100)
%3 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 3, i32 100)
%4 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 4, i32 100)
%5 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 5, i32 100)
%6 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 6, i32 100)
%7 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 7, i32 100)
%8 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 8, i32 100)
%9 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 9, i32 100)
%10 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 10, i32 100)
%11 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 11, i32 100)
%12 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 12, i32 100)
%13 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 13, i32 100)
%14 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 14, i32 100)
%15 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 15, i32 100)
%16 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 16, i32 100)
%17 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 17, i32 100)
%18 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 18, i32 100)
%19 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 19, i32 100)
%20 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 20, i32 100)
%21 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 19, i32 100)
%22 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 18, i32 100)
%23 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 17, i32 100)
%24 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 16, i32 100)
%25 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 15, i32 100)
%26 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 14, i32 100)
%27 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 13, i32 100)
%28 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 12, i32 100)
%29 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 11, i32 100)
%30 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 10, i32 100)
%31 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 9, i32 100)
%32 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 8, i32 100)
%33 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 7, i32 100)
%34 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 6, i32 100)
%35 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 5, i32 100)
%36 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 4, i32 100)
%37 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 3, i32 100)
%38 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 2, i32 100)
%39 = tail call i32 @effect_random_sparkle_flash(i32 5, i32 1, i32 100)
ret void
}