void pagerank2(float *data, int *rows, int *cols, float *x, float *y) {
  int i;
p2nodes:
  for (i = 0; i < 1024; i++) {
    x[i] = 0.15f / ((float)1024) + 0.85f * y[i];
    y[i] = 0.0f;
  }
}


x86 assembly (clang, -O0):
<pagerank2>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
movl   $0x0,-0x2c(%rbp)
cmpl   $0x400,-0x2c(%rbp)
jge    117c <pagerank2+0x7c>
mov    -0x28(%rbp),%rax
movslq -0x2c(%rbp),%rcx
movss  (%rax,%rcx,4),%xmm0
movss  0xebf(%rip),%xmm1
mulss  %xmm1,%xmm0
movss  0xeb7(%rip),%xmm1
addss  %xmm1,%xmm0
mov    -0x20(%rbp),%rax
movslq -0x2c(%rbp),%rcx
movss  %xmm0,(%rax,%rcx,4)
mov    -0x28(%rbp),%rax
movslq -0x2c(%rbp),%rcx
xorps  %xmm0,%xmm0
movss  %xmm0,(%rax,%rcx,4)
mov    -0x2c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2c(%rbp)
jmp    111f <pagerank2+0x1f>
pop    %rbp
ret

x86 assembly (clang, -O2):
<pagerank2>:
lea    0x1000(%r8),%rax
cmp    %rcx,%rax
jbe    1177 <pagerank2+0x77>
lea    0x1000(%rcx),%rax
cmp    %r8,%rax
jbe    1177 <pagerank2+0x77>
xor    %eax,%eax
movss  0xefe(%rip),%xmm0
movss  0xefa(%rip),%xmm1
nopw   0x0(%rax,%rax,1)
movss  (%r8,%rax,4),%xmm2
mulss  %xmm0,%xmm2
addss  %xmm1,%xmm2
movss  %xmm2,(%rcx,%rax,4)
movl   $0x0,(%r8,%rax,4)
movss  0x4(%r8,%rax,4),%xmm2
mulss  %xmm0,%xmm2
addss  %xmm1,%xmm2
movss  %xmm2,0x4(%rcx,%rax,4)
movl   $0x0,0x4(%r8,%rax,4)
add    $0x2,%rax
cmp    $0x400,%rax
jne    1130 <pagerank2+0x30>
jmp    11f5 <pagerank2+0xf5>
xor    %eax,%eax
movaps 0xe80(%rip),%xmm0
movaps 0xe89(%rip),%xmm1
xorps  %xmm2,%xmm2
nopw   0x0(%rax,%rax,1)
movups (%r8,%rax,4),%xmm3
movups 0x10(%r8,%rax,4),%xmm4
mulps  %xmm0,%xmm3
addps  %xmm1,%xmm3
mulps  %xmm0,%xmm4
addps  %xmm1,%xmm4
movups %xmm3,(%rcx,%rax,4)
movups %xmm4,0x10(%rcx,%rax,4)
movups %xmm2,(%r8,%rax,4)
movups %xmm2,0x10(%r8,%rax,4)
movups 0x20(%r8,%rax,4),%xmm3
movups 0x30(%r8,%rax,4),%xmm4
mulps  %xmm0,%xmm3
addps  %xmm1,%xmm3
mulps  %xmm0,%xmm4
addps  %xmm1,%xmm4
movups %xmm3,0x20(%rcx,%rax,4)
movups %xmm4,0x30(%rcx,%rax,4)
movups %xmm2,0x20(%r8,%rax,4)
movups %xmm2,0x30(%r8,%rax,4)
add    $0x10,%rax
cmp    $0x400,%rax
jne    1190 <pagerank2+0x90>
ret

LLVM IR (-O0):
define void @pagerank2(float* %0, i32* %1, i32* %2, float* %3, float* %4) {
%6 = alloca float*
%7 = alloca i32*
%8 = alloca i32*
%9 = alloca float*
%10 = alloca float*
%11 = alloca i32
store float* %0, float** %6
store i32* %1, i32** %7
store i32* %2, i32** %8
store float* %3, float** %9
store float* %4, float** %10
br label %12
12: ; preds = %5
store i32 0, i32* %11
br label %13
13: ; preds = %31, %12
%14 = load i32, i32* %11
%15 = icmp slt i32 %14, 1024
br i1 %15, label %16, label %34
16: ; preds = %13
%17 = load float*, float** %10
%18 = load i32, i32* %11
%19 = sext i32 %18 to i64
%20 = getelementptr inbounds float, float* %17, i64 %19
%21 = load float, float* %20
%22 = call float @llvm.fmuladd.f32(float 0x3FEB333340000000, float %21, float 0x3F23333340000000)
%23 = load float*, float** %9
%24 = load i32, i32* %11
%25 = sext i32 %24 to i64
%26 = getelementptr inbounds float, float* %23, i64 %25
store float %22, float* %26
%27 = load float*, float** %10
%28 = load i32, i32* %11
%29 = sext i32 %28 to i64
%30 = getelementptr inbounds float, float* %27, i64 %29
store float 0.000000e+00, float* %30
br label %31
31: ; preds = %16
%32 = load i32, i32* %11
%33 = add nsw i32 %32, 1
store i32 %33, i32* %11
br label %13
34: ; preds = %13
ret void
}

LLVM IR (-O2):
define void @pagerank2(float* nocapture readnone %0, i32* nocapture readnone %1, i32* nocapture readnone %2, float* nocapture writeonly %3, float* nocapture %4) {
%6 = getelementptr float, float* %3, i64 1024
%7 = getelementptr float, float* %4, i64 1024
%8 = icmp ugt float* %7, %3
%9 = icmp ugt float* %6, %4
%10 = and i1 %8, %9
br i1 %10, label %44, label %11
11: ; preds = %5, %11
%12 = phi i64 [ %42, %11 ], [ 0, %5 ]
%13 = getelementptr inbounds float, float* %4, i64 %12
%14 = bitcast float* %13 to <4 x float>*
%15 = load <4 x float>, <4 x float>* %14
%16 = getelementptr inbounds float, float* %13, i64 4
%17 = bitcast float* %16 to <4 x float>*
%18 = load <4 x float>, <4 x float>* %17
%19 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %15, <4 x float> <float 0x3FEB333340000000, float 0x3FEB333340000000, float 0x3FEB333340000000, float 0x3FEB333340000000>, <4 x float> <float 0x3F23333340000000, float 0x3F23333340000000, float 0x3F23333340000000, float 0x3F23333340000000>)
%20 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %18, <4 x float> <float 0x3FEB333340000000, float 0x3FEB333340000000, float 0x3FEB333340000000, float 0x3FEB333340000000>, <4 x float> <float 0x3F23333340000000, float 0x3F23333340000000, float 0x3F23333340000000, float 0x3F23333340000000>)
%21 = getelementptr inbounds float, float* %3, i64 %12
%22 = bitcast float* %21 to <4 x float>*
store <4 x float> %19, <4 x float>* %22
%23 = getelementptr inbounds float, float* %21, i64 4
%24 = bitcast float* %23 to <4 x float>*
store <4 x float> %20, <4 x float>* %24
%25 = bitcast float* %13 to <4 x float>*
store <4 x float> zeroinitializer, <4 x float>* %25
%26 = bitcast float* %16 to <4 x float>*
store <4 x float> zeroinitializer, <4 x float>* %26
%27 = or i64 %12, 8
%28 = getelementptr inbounds float, float* %4, i64 %27
%29 = bitcast float* %28 to <4 x float>*
%30 = load <4 x float>, <4 x float>* %29
%31 = getelementptr inbounds float, float* %28, i64 4
%32 = bitcast float* %31 to <4 x float>*
%33 = load <4 x float>, <4 x float>* %32
%34 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %30, <4 x float> <float 0x3FEB333340000000, float 0x3FEB333340000000, float 0x3FEB333340000000, float 0x3FEB333340000000>, <4 x float> <float 0x3F23333340000000, float 0x3F23333340000000, float 0x3F23333340000000, float 0x3F23333340000000>)
%35 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %33, <4 x float> <float 0x3FEB333340000000, float 0x3FEB333340000000, float 0x3FEB333340000000, float 0x3FEB333340000000>, <4 x float> <float 0x3F23333340000000, float 0x3F23333340000000, float 0x3F23333340000000, float 0x3F23333340000000>)
%36 = getelementptr inbounds float, float* %3, i64 %27
%37 = bitcast float* %36 to <4 x float>*
store <4 x float> %34, <4 x float>* %37
%38 = getelementptr inbounds float, float* %36, i64 4
%39 = bitcast float* %38 to <4 x float>*
store <4 x float> %35, <4 x float>* %39
%40 = bitcast float* %28 to <4 x float>*
store <4 x float> zeroinitializer, <4 x float>* %40
%41 = bitcast float* %31 to <4 x float>*
store <4 x float> zeroinitializer, <4 x float>* %41
%42 = add nuw nsw i64 %12, 16
%43 = icmp eq i64 %42, 1024
br i1 %43, label %57, label %11
44: ; preds = %5, %44
%45 = phi i64 [ %55, %44 ], [ 0, %5 ]
%46 = getelementptr inbounds float, float* %4, i64 %45
%47 = load float, float* %46
%48 = tail call float @llvm.fmuladd.f32(float %47, float 0x3FEB333340000000, float 0x3F23333340000000)
%49 = getelementptr inbounds float, float* %3, i64 %45
store float %48, float* %49
store float 0.000000e+00, float* %46
%50 = or i64 %45, 1
%51 = getelementptr inbounds float, float* %4, i64 %50
%52 = load float, float* %51
%53 = tail call float @llvm.fmuladd.f32(float %52, float 0x3FEB333340000000, float 0x3F23333340000000)
%54 = getelementptr inbounds float, float* %3, i64 %50
store float %53, float* %54
store float 0.000000e+00, float* %51
%55 = add nuw nsw i64 %45, 2
%56 = icmp eq i64 %55, 1024
br i1 %56, label %57, label %44
57: ; preds = %11, %44
ret void
}