#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);
int main() {
  int i;
  int count;
  count = 0;
  for (i = 2000; i <= 10000; i++) {
    if ((i % 3 != 0) && (i % 4 == 0)) {
      count++;
    }
  }
  printf("%d\n", count);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0xc(%rbp)
movl   $0x7d0,-0x8(%rbp)
cmpl   $0x2710,-0x8(%rbp)
jg     117e <main+0x6e>
mov    -0x8(%rbp),%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
cmp    $0x0,%edx
je     116b <main+0x5b>
mov    -0x8(%rbp),%eax
mov    $0x4,%ecx
cltd
idiv   %ecx
cmp    $0x0,%edx
jne    116b <main+0x5b>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1170 <main+0x60>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    112d <main+0x1d>
mov    -0xc(%rbp),%esi
lea    0xe78(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
movdqa 0xee7(%rip),%xmm6
movdqa 0xeef(%rip),%xmm4
pxor   %xmm8,%xmm8
mov    $0x1f40,%eax
movdqa 0xeec(%rip),%xmm9
movdqa 0xef3(%rip),%xmm15
movdqa 0xefb(%rip),%xmm5
movdqa 0xf02(%rip),%xmm10
movdqa 0xf09(%rip),%xmm11
movdqa 0xf10(%rip),%xmm12
movdqa 0xf17(%rip),%xmm13
movdqa 0xf1e(%rip),%xmm14
pxor   %xmm7,%xmm7
pxor   %xmm2,%xmm2
nopw   0x0(%rax,%rax,1)
movdqa %xmm6,%xmm0
pmullw %xmm9,%xmm0
movdqa %xmm0,%xmm3
pxor   %xmm15,%xmm3
pcmpgtw %xmm5,%xmm3
punpcklwd %xmm3,%xmm3
paddw  %xmm10,%xmm0
pxor   %xmm15,%xmm0
pcmpgtw %xmm5,%xmm0
punpcklwd %xmm0,%xmm0
movdqa %xmm4,%xmm1
pand   %xmm11,%xmm1
pcmpeqd %xmm8,%xmm1
pand   %xmm12,%xmm1
pand   %xmm1,%xmm3
paddd  %xmm3,%xmm7
pand   %xmm0,%xmm1
paddd  %xmm1,%xmm2
paddd  %xmm13,%xmm4
paddw  %xmm14,%xmm6
add    $0xfffffff8,%eax
jne    1180 <main+0x70>
paddd  %xmm7,%xmm2
pshufd $0xee,%xmm2,%xmm0
paddd  %xmm2,%xmm0
pshufd $0x55,%xmm0,%xmm1
paddd  %xmm0,%xmm1
movd   %xmm1,%esi
add    $0x1,%esi
lea    0xe9e(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [4 x i8] c"%d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
store i32 0, i32* %3
store i32 2000, i32* %2
br label %4
4: ; preds = %19, %0
%5 = load i32, i32* %2
%6 = icmp sle i32 %5, 10000
br i1 %6, label %7, label %22
7: ; preds = %4
%8 = load i32, i32* %2
%9 = srem i32 %8, 3
%10 = icmp ne i32 %9, 0
br i1 %10, label %11, label %18
11: ; preds = %7
%12 = load i32, i32* %2
%13 = srem i32 %12, 4
%14 = icmp eq i32 %13, 0
br i1 %14, label %15, label %18
15: ; preds = %11
%16 = load i32, i32* %3
%17 = add nsw i32 %16, 1
store i32 %17, i32* %3
br label %18
18: ; preds = %15, %11, %7
br label %19
19: ; preds = %18
%20 = load i32, i32* %2
%21 = add nsw i32 %20, 1
store i32 %21, i32* %2
br label %4
22: ; preds = %4
%23 = load i32, i32* %3
%24 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %23)
ret i32 0
}

LLVM IR (-O2):
@.str = [4 x i8] c"%d\0A\00"
define i32 @main() {
br label %1
1: ; preds = %1, %0
%2 = phi i32 [ 0, %0 ], [ %22, %1 ]
%3 = phi <4 x i32> [ zeroinitializer, %0 ], [ %20, %1 ]
%4 = phi <4 x i32> [ zeroinitializer, %0 ], [ %21, %1 ]
%5 = phi <4 x i32> [ <i32 2000, i32 2001, i32 2002, i32 2003>, %0 ], [ %23, %1 ]
%6 = phi <4 x i16> [ <i16 2000, i16 2001, i16 2002, i16 2003>, %0 ], [ %24, %1 ]
%7 = add <4 x i16> %6, <i16 4, i16 4, i16 4, i16 4>
%8 = urem <4 x i16> %6, <i16 3, i16 3, i16 3, i16 3>
%9 = urem <4 x i16> %7, <i16 3, i16 3, i16 3, i16 3>
%10 = icmp ne <4 x i16> %8, zeroinitializer
%11 = icmp ne <4 x i16> %9, zeroinitializer
%12 = and <4 x i32> %5, <i32 3, i32 3, i32 3, i32 3>
%13 = and <4 x i32> %5, <i32 3, i32 3, i32 3, i32 3>
%14 = icmp eq <4 x i32> %12, zeroinitializer
%15 = icmp eq <4 x i32> %13, zeroinitializer
%16 = and <4 x i1> %14, %10
%17 = and <4 x i1> %15, %11
%18 = zext <4 x i1> %16 to <4 x i32>
%19 = zext <4 x i1> %17 to <4 x i32>
%20 = add <4 x i32> %3, %18
%21 = add <4 x i32> %4, %19
%22 = add nuw i32 %2, 8
%23 = add <4 x i32> %5, <i32 8, i32 8, i32 8, i32 8>
%24 = add <4 x i16> %6, <i16 8, i16 8, i16 8, i16 8>
%25 = icmp eq i32 %22, 8000
br i1 %25, label %26, label %1
26: ; preds = %1
%27 = add <4 x i32> %21, %20
%28 = call i32 @llvm.vector.reduce.add.v4i32(<4 x i32> %27)
%29 = add nuw nsw i32 %28, 1
%30 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %29)
ret i32 0
}