#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*/ hash(int);
void test() {
  int c1, c2;
  int i, j;
  for (c1 = 3; c1 <= 100; c1++) {
    if (c1 == 25) {
      {
        hash(1);
        hash(25);
      };
    }
    if (c1 % 3 == 0) {
      {
        hash(2);
        hash(c1);
        hash(c1 / 3);
      };
    }
  }
}


x86 assembly (clang, -O0):
<test>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x3,-0x4(%rbp)
cmpl   $0x64,-0x4(%rbp)
jg     1192 <test+0x82>
cmpl   $0x19,-0x4(%rbp)
jne    1147 <test+0x37>
mov    $0x1,%edi
call   1030 <hash@plt>
mov    $0x19,%edi
call   1030 <hash@plt>
mov    -0x4(%rbp),%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
cmp    $0x0,%edx
jne    117f <test+0x6f>
mov    $0x2,%edi
call   1030 <hash@plt>
mov    -0x4(%rbp),%edi
call   1030 <hash@plt>
mov    -0x4(%rbp),%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
mov    %eax,%edi
call   1030 <hash@plt>
jmp    1184 <test+0x74>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    111f <test+0xf>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test>:
push   %rbp
push   %rbx
push   %rax
mov    $0x3,%ebx
jmp    113c <test+0x2c>
nopw   0x0(%rax,%rax,1)
mov    $0x1,%edi
call   1030 <hash@plt>
mov    $0x19,%edi
call   1030 <hash@plt>
add    $0x1,%ebx
cmp    $0x65,%ebx
je     1179 <test+0x69>
cmp    $0x19,%ebx
je     1120 <test+0x10>
movzbl %bl,%eax
imul   $0xab,%eax,%eax
shr    $0x9,%eax
lea    (%rax,%rax,2),%eax
neg    %eax
add    %bl,%al
jne    1134 <test+0x24>
movzbl %bl,%eax
imul   $0xab,%eax,%ebp
shr    $0x9,%ebp
mov    $0x2,%edi
call   1030 <hash@plt>
mov    %ebx,%edi
call   1030 <hash@plt>
movzbl %bpl,%edi
jmp    112f <test+0x1f>
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define void @test() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
store i32 3, i32* %1
br label %5
5: ; preds = %26, %0
%6 = load i32, i32* %1
%7 = icmp sle i32 %6, 100
br i1 %7, label %8, label %29
8: ; preds = %5
%9 = load i32, i32* %1
%10 = icmp eq i32 %9, 25
br i1 %10, label %11, label %14
11: ; preds = %8
%12 = call i32 @hash(i32 1)
%13 = call i32 @hash(i32 25)
br label %14
14: ; preds = %11, %8
%15 = load i32, i32* %1
%16 = srem i32 %15, 3
%17 = icmp eq i32 %16, 0
br i1 %17, label %18, label %25
18: ; preds = %14
%19 = call i32 @hash(i32 2)
%20 = load i32, i32* %1
%21 = call i32 @hash(i32 %20)
%22 = load i32, i32* %1
%23 = sdiv i32 %22, 3
%24 = call i32 @hash(i32 %23)
br label %25
25: ; preds = %18, %14
br label %26
26: ; preds = %25
%27 = load i32, i32* %1
%28 = add nsw i32 %27, 1
store i32 %28, i32* %1
br label %5
29: ; preds = %5
ret void
}

LLVM IR (-O2):
define void @test() {
br label %1
1: ; preds = %0, %18
%2 = phi i32 [ 3, %0 ], [ %19, %18 ]
%3 = icmp eq i32 %2, 25
br i1 %3, label %4, label %6
4: ; preds = %1
%5 = tail call i32 @hash(i32 1)
br label %15
6: ; preds = %1
%7 = trunc i32 %2 to i8
%8 = urem i8 %7, 3
%9 = udiv i8 %7, 3
%10 = icmp eq i8 %8, 0
br i1 %10, label %11, label %18
11: ; preds = %6
%12 = tail call i32 @hash(i32 2)
%13 = tail call i32 @hash(i32 %2)
%14 = zext i8 %9 to i32
br label %15
15: ; preds = %11, %4
%16 = phi i32 [ 25, %4 ], [ %14, %11 ]
%17 = tail call i32 @hash(i32 %16)
br label %18
18: ; preds = %15, %6
%19 = add nuw nsw i32 %2, 1
%20 = icmp eq i32 %19, 101
br i1 %20, label %21, label %1
21: ; preds = %18
ret void
}