#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 *);
void seq1(void) {
  int a[100000], b[100000];
  int c[100000];
  for (int i = 0; i < 100000; i++) {
    a[i] = i % 256;
    b[i] = i % 256;
  }
#pragma omp parallel for
  for (int i = 0; i < 100000; ++i) {
    c[i] = a[i] * b[i] + a[i - 1] * b[i + 1];
  }
  printf("\n");
}


x86 assembly (clang, -O0):
<seq1>:
push   %rbp
mov    %rsp,%rbp
sub    $0x124f90,%rsp
movl   $0x0,-0x124f84(%rbp)
cmpl   $0x186a0,-0x124f84(%rbp)
jge    1181 <seq1+0x71>
mov    -0x124f84(%rbp),%eax
mov    $0x100,%ecx
cltd
idiv   %ecx
movslq -0x124f84(%rbp),%rax
mov    %edx,-0x61a80(%rbp,%rax,4)
mov    -0x124f84(%rbp),%eax
mov    $0x100,%ecx
cltd
idiv   %ecx
movslq -0x124f84(%rbp),%rax
mov    %edx,-0xc3500(%rbp,%rax,4)
mov    -0x124f84(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x124f84(%rbp)
jmp    1125 <seq1+0x15>
movl   $0x0,-0x124f88(%rbp)
cmpl   $0x186a0,-0x124f88(%rbp)
jge    1202 <seq1+0xf2>
movslq -0x124f88(%rbp),%rax
mov    -0x61a80(%rbp,%rax,4),%ecx
movslq -0x124f88(%rbp),%rax
imul   -0xc3500(%rbp,%rax,4),%ecx
ff
mov    -0x124f88(%rbp),%eax
sub    $0x1,%eax
cltq
mov    -0x61a80(%rbp,%rax,4),%eax
mov    -0x124f88(%rbp),%edx
add    $0x1,%edx
movslq %edx,%rdx
imul   -0xc3500(%rbp,%rdx,4),%eax
ff
add    %eax,%ecx
movslq -0x124f88(%rbp),%rax
mov    %ecx,-0x124f80(%rbp,%rax,4)
mov    -0x124f88(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x124f88(%rbp)
jmp    118b <seq1+0x7b>
lea    0xdf7(%rip),%rdi
call   1030 <printf@plt>
add    $0x124f90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<seq1>:
mov    $0xa,%edi
jmp    1030 <putchar@plt>

LLVM IR (-O0):
@.str = [2 x i8] c"\0A\00"
define void @seq1() {
%1 = alloca [100000 x i32]
%2 = alloca [100000 x i32]
%3 = alloca [100000 x i32]
%4 = alloca i32
%5 = alloca i32
store i32 0, i32* %4
br label %6
6: ; preds = %20, %0
%7 = load i32, i32* %4
%8 = icmp slt i32 %7, 100000
br i1 %8, label %9, label %23
9: ; preds = %6
%10 = load i32, i32* %4
%11 = srem i32 %10, 256
%12 = load i32, i32* %4
%13 = sext i32 %12 to i64
%14 = getelementptr inbounds [100000 x i32], [100000 x i32]* %1, i64 0, i64 %13
store i32 %11, i32* %14
%15 = load i32, i32* %4
%16 = srem i32 %15, 256
%17 = load i32, i32* %4
%18 = sext i32 %17 to i64
%19 = getelementptr inbounds [100000 x i32], [100000 x i32]* %2, i64 0, i64 %18
store i32 %16, i32* %19
br label %20
20: ; preds = %9
%21 = load i32, i32* %4
%22 = add nsw i32 %21, 1
store i32 %22, i32* %4
br label %6
23: ; preds = %6
store i32 0, i32* %5
br label %24
24: ; preds = %52, %23
%25 = load i32, i32* %5
%26 = icmp slt i32 %25, 100000
br i1 %26, label %27, label %55
27: ; preds = %24
%28 = load i32, i32* %5
%29 = sext i32 %28 to i64
%30 = getelementptr inbounds [100000 x i32], [100000 x i32]* %1, i64 0, i64 %29
%31 = load i32, i32* %30
%32 = load i32, i32* %5
%33 = sext i32 %32 to i64
%34 = getelementptr inbounds [100000 x i32], [100000 x i32]* %2, i64 0, i64 %33
%35 = load i32, i32* %34
%36 = mul nsw i32 %31, %35
%37 = load i32, i32* %5
%38 = sub nsw i32 %37, 1
%39 = sext i32 %38 to i64
%40 = getelementptr inbounds [100000 x i32], [100000 x i32]* %1, i64 0, i64 %39
%41 = load i32, i32* %40
%42 = load i32, i32* %5
%43 = add nsw i32 %42, 1
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds [100000 x i32], [100000 x i32]* %2, i64 0, i64 %44
%46 = load i32, i32* %45
%47 = mul nsw i32 %41, %46
%48 = add nsw i32 %36, %47
%49 = load i32, i32* %5
%50 = sext i32 %49 to i64
%51 = getelementptr inbounds [100000 x i32], [100000 x i32]* %3, i64 0, i64 %50
store i32 %48, i32* %51
br label %52
52: ; preds = %27
%53 = load i32, i32* %5
%54 = add nsw i32 %53, 1
store i32 %54, i32* %5
br label %24
55: ; preds = %24
%56 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
define void @seq1() {
%1 = tail call i32 @putchar(i32 10)
ret void
}