void c_nm_to_ang(double *x, double *y, double *z, int natoms) {
  double nmToAng = 10.0;
  int i;
#pragma omp parallel for ordered schedule(dynamic)
  for (i = 0; i < natoms; i++) {
    x[i] = x[i] * nmToAng;
    y[i] = y[i] * nmToAng;
    z[i] = z[i] * nmToAng;
  }
  return;
}


x86 assembly (clang, -O0):
<c_nm_to_ang>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %ecx,-0x1c(%rbp)
movsd  0xee5(%rip),%xmm0
movsd  %xmm0,-0x28(%rbp)
movl   $0x0,-0x2c(%rbp)
mov    -0x2c(%rbp),%eax
cmp    -0x1c(%rbp),%eax
jge    119e <c_nm_to_ang+0x9e>
mov    -0x8(%rbp),%rax
movslq -0x2c(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mulsd  -0x28(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movslq -0x2c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x10(%rbp),%rax
movslq -0x2c(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mulsd  -0x28(%rbp),%xmm0
mov    -0x10(%rbp),%rax
movslq -0x2c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x18(%rbp),%rax
movslq -0x2c(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mulsd  -0x28(%rbp),%xmm0
mov    -0x18(%rbp),%rax
movslq -0x2c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x2c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2c(%rbp)
jmp    1127 <c_nm_to_ang+0x27>
pop    %rbp
ret

x86 assembly (clang, -O2):
<c_nm_to_ang>:
push   %rbp
push   %r15
push   %r14
push   %rbx
test   %ecx,%ecx
jle    1305 <c_nm_to_ang+0x205>
mov    %ecx,%r8d
cmp    $0x1,%ecx
jne    11d8 <c_nm_to_ang+0xd8>
xor    %ecx,%ecx
mov    %rcx,%rax
not    %rax
test   $0x1,%r8b
je     115a <c_nm_to_ang+0x5a>
movsd  0xee0(%rip),%xmm0
movsd  (%rdi,%rcx,8),%xmm1
mulsd  %xmm0,%xmm1
movsd  %xmm1,(%rdi,%rcx,8)
movsd  (%rsi,%rcx,8),%xmm1
mulsd  %xmm0,%xmm1
movsd  %xmm1,(%rsi,%rcx,8)
mulsd  (%rdx,%rcx,8),%xmm0
movsd  %xmm0,(%rdx,%rcx,8)
or     $0x1,%rcx
add    %r8,%rax
je     1305 <c_nm_to_ang+0x205>
movsd  0xea5(%rip),%xmm0
nopl   0x0(%rax,%rax,1)
movsd  (%rdi,%rcx,8),%xmm1
mulsd  %xmm0,%xmm1
movsd  %xmm1,(%rdi,%rcx,8)
movsd  (%rsi,%rcx,8),%xmm1
mulsd  %xmm0,%xmm1
movsd  %xmm1,(%rsi,%rcx,8)
movsd  (%rdx,%rcx,8),%xmm1
mulsd  %xmm0,%xmm1
movsd  %xmm1,(%rdx,%rcx,8)
movsd  0x8(%rdi,%rcx,8),%xmm1
mulsd  %xmm0,%xmm1
movsd  %xmm1,0x8(%rdi,%rcx,8)
movsd  0x8(%rsi,%rcx,8),%xmm1
mulsd  %xmm0,%xmm1
movsd  %xmm1,0x8(%rsi,%rcx,8)
movsd  0x8(%rdx,%rcx,8),%xmm1
mulsd  %xmm0,%xmm1
movsd  %xmm1,0x8(%rdx,%rcx,8)
add    $0x2,%rcx
cmp    %rcx,%r8
jne    1170 <c_nm_to_ang+0x70>
jmp    1305 <c_nm_to_ang+0x205>
lea    (%rsi,%r8,8),%rcx
cmp    %rdi,%rcx
seta   %r15b
lea    (%rdi,%r8,8),%rbx
cmp    %rsi,%rbx
seta   %r14b
lea    (%rdx,%r8,8),%rbp
cmp    %rdi,%rbp
seta   %al
cmp    %rdx,%rbx
seta   %r10b
cmp    %rsi,%rbp
seta   %r9b
cmp    %rdx,%rcx
seta   %r11b
xor    %ecx,%ecx
test   %r14b,%r15b
jne    111c <c_nm_to_ang+0x1c>
and    %r10b,%al
jne    111c <c_nm_to_ang+0x1c>
and    %r11b,%r9b
jne    111c <c_nm_to_ang+0x1c>
mov    %r8d,%ecx
and    $0xfffffffe,%ecx
lea    -0x2(%rcx),%rax
mov    %rax,%r9
shr    %r9
add    $0x1,%r9
test   %rax,%rax
je     130c <c_nm_to_ang+0x20c>
mov    %r9,%r10
and    $0xfffffffffffffffe,%r10
xor    %eax,%eax
movapd 0xda8(%rip),%xmm0
nopl   0x0(%rax,%rax,1)
movupd (%rdi,%rax,8),%xmm1
mulpd  %xmm0,%xmm1
movupd %xmm1,(%rdi,%rax,8)
movupd (%rsi,%rax,8),%xmm1
mulpd  %xmm0,%xmm1
movupd %xmm1,(%rsi,%rax,8)
movupd (%rdx,%rax,8),%xmm1
mulpd  %xmm0,%xmm1
movupd %xmm1,(%rdx,%rax,8)
movupd 0x10(%rdi,%rax,8),%xmm1
mulpd  %xmm0,%xmm1
movupd %xmm1,0x10(%rdi,%rax,8)
movupd 0x10(%rsi,%rax,8),%xmm1
mulpd  %xmm0,%xmm1
movupd %xmm1,0x10(%rsi,%rax,8)
movupd 0x10(%rdx,%rax,8),%xmm1
mulpd  %xmm0,%xmm1
movupd %xmm1,0x10(%rdx,%rax,8)
add    $0x4,%rax
add    $0xfffffffffffffffe,%r10
jne    1260 <c_nm_to_ang+0x160>
test   $0x1,%r9b
je     12fc <c_nm_to_ang+0x1fc>
movupd (%rdi,%rax,8),%xmm0
movapd 0xd29(%rip),%xmm1
mulpd  %xmm1,%xmm0
movupd %xmm0,(%rdi,%rax,8)
movupd (%rsi,%rax,8),%xmm0
mulpd  %xmm1,%xmm0
movupd %xmm0,(%rsi,%rax,8)
movupd (%rdx,%rax,8),%xmm0
mulpd  %xmm1,%xmm0
movupd %xmm0,(%rdx,%rax,8)
cmp    %r8,%rcx
jne    111c <c_nm_to_ang+0x1c>
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret
xor    %eax,%eax
test   $0x1,%r9b
jne    12ca <c_nm_to_ang+0x1ca>
jmp    12fc <c_nm_to_ang+0x1fc>

LLVM IR (-O0):
define void @c_nm_to_ang(double* %0, double* %1, double* %2, i32 %3) {
%5 = alloca double*
%6 = alloca double*
%7 = alloca double*
%8 = alloca i32
%9 = alloca double
%10 = alloca i32
store double* %0, double** %5
store double* %1, double** %6
store double* %2, double** %7
store i32 %3, i32* %8
store double 1.000000e+01, double* %9
store i32 0, i32* %10
br label %11
11: ; preds = %49, %4
%12 = load i32, i32* %10
%13 = load i32, i32* %8
%14 = icmp slt i32 %12, %13
br i1 %14, label %15, label %52
15: ; preds = %11
%16 = load double*, double** %5
%17 = load i32, i32* %10
%18 = sext i32 %17 to i64
%19 = getelementptr inbounds double, double* %16, i64 %18
%20 = load double, double* %19
%21 = load double, double* %9
%22 = fmul double %20, %21
%23 = load double*, double** %5
%24 = load i32, i32* %10
%25 = sext i32 %24 to i64
%26 = getelementptr inbounds double, double* %23, i64 %25
store double %22, double* %26
%27 = load double*, double** %6
%28 = load i32, i32* %10
%29 = sext i32 %28 to i64
%30 = getelementptr inbounds double, double* %27, i64 %29
%31 = load double, double* %30
%32 = load double, double* %9
%33 = fmul double %31, %32
%34 = load double*, double** %6
%35 = load i32, i32* %10
%36 = sext i32 %35 to i64
%37 = getelementptr inbounds double, double* %34, i64 %36
store double %33, double* %37
%38 = load double*, double** %7
%39 = load i32, i32* %10
%40 = sext i32 %39 to i64
%41 = getelementptr inbounds double, double* %38, i64 %40
%42 = load double, double* %41
%43 = load double, double* %9
%44 = fmul double %42, %43
%45 = load double*, double** %7
%46 = load i32, i32* %10
%47 = sext i32 %46 to i64
%48 = getelementptr inbounds double, double* %45, i64 %47
store double %44, double* %48
br label %49
49: ; preds = %15
%50 = load i32, i32* %10
%51 = add nsw i32 %50, 1
store i32 %51, i32* %10
br label %11
52: ; preds = %11
ret void
}

LLVM IR (-O2):
define void @c_nm_to_ang(double* nocapture %0, double* nocapture %1, double* nocapture %2, i32 %3) {
%5 = icmp sgt i32 %3, 0
br i1 %5, label %6, label %134
6: ; preds = %4
%7 = zext i32 %3 to i64
%8 = icmp eq i32 %3, 1
br i1 %8, label %91, label %9
9: ; preds = %6
%10 = getelementptr double, double* %0, i64 %7
%11 = getelementptr double, double* %1, i64 %7
%12 = getelementptr double, double* %2, i64 %7
%13 = icmp ugt double* %11, %0
%14 = icmp ugt double* %10, %1
%15 = and i1 %13, %14
%16 = icmp ugt double* %12, %0
%17 = icmp ugt double* %10, %2
%18 = and i1 %16, %17
%19 = or i1 %15, %18
%20 = icmp ugt double* %12, %1
%21 = icmp ugt double* %11, %2
%22 = and i1 %20, %21
%23 = or i1 %19, %22
br i1 %23, label %91, label %24
24: ; preds = %9
%25 = and i64 %7, 4294967294
%26 = add nsw i64 %25, -2
%27 = lshr exact i64 %26, 1
%28 = add nuw i64 %27, 1
%29 = and i64 %28, 1
%30 = icmp eq i64 %26, 0
br i1 %30, label %70, label %31
31: ; preds = %24
%32 = and i64 %28, -2
br label %33
33: ; preds = %33, %31
%34 = phi i64 [ 0, %31 ], [ %67, %33 ]
%35 = phi i64 [ 0, %31 ], [ %68, %33 ]
%36 = getelementptr inbounds double, double* %0, i64 %34
%37 = bitcast double* %36 to <2 x double>*
%38 = load <2 x double>, <2 x double>* %37
%39 = fmul <2 x double> %38, <double 1.000000e+01, double 1.000000e+01>
%40 = bitcast double* %36 to <2 x double>*
store <2 x double> %39, <2 x double>* %40
%41 = getelementptr inbounds double, double* %1, i64 %34
%42 = bitcast double* %41 to <2 x double>*
%43 = load <2 x double>, <2 x double>* %42
%44 = fmul <2 x double> %43, <double 1.000000e+01, double 1.000000e+01>
%45 = bitcast double* %41 to <2 x double>*
store <2 x double> %44, <2 x double>* %45
%46 = getelementptr inbounds double, double* %2, i64 %34
%47 = bitcast double* %46 to <2 x double>*
%48 = load <2 x double>, <2 x double>* %47
%49 = fmul <2 x double> %48, <double 1.000000e+01, double 1.000000e+01>
%50 = bitcast double* %46 to <2 x double>*
store <2 x double> %49, <2 x double>* %50
%51 = or i64 %34, 2
%52 = getelementptr inbounds double, double* %0, i64 %51
%53 = bitcast double* %52 to <2 x double>*
%54 = load <2 x double>, <2 x double>* %53
%55 = fmul <2 x double> %54, <double 1.000000e+01, double 1.000000e+01>
%56 = bitcast double* %52 to <2 x double>*
store <2 x double> %55, <2 x double>* %56
%57 = getelementptr inbounds double, double* %1, i64 %51
%58 = bitcast double* %57 to <2 x double>*
%59 = load <2 x double>, <2 x double>* %58
%60 = fmul <2 x double> %59, <double 1.000000e+01, double 1.000000e+01>
%61 = bitcast double* %57 to <2 x double>*
store <2 x double> %60, <2 x double>* %61
%62 = getelementptr inbounds double, double* %2, i64 %51
%63 = bitcast double* %62 to <2 x double>*
%64 = load <2 x double>, <2 x double>* %63
%65 = fmul <2 x double> %64, <double 1.000000e+01, double 1.000000e+01>
%66 = bitcast double* %62 to <2 x double>*
store <2 x double> %65, <2 x double>* %66
%67 = add nuw i64 %34, 4
%68 = add nuw i64 %35, 2
%69 = icmp eq i64 %68, %32
br i1 %69, label %70, label %33
70: ; preds = %33, %24
%71 = phi i64 [ 0, %24 ], [ %67, %33 ]
%72 = icmp eq i64 %29, 0
br i1 %72, label %89, label %73
73: ; preds = %70
%74 = getelementptr inbounds double, double* %0, i64 %71
%75 = bitcast double* %74 to <2 x double>*
%76 = load <2 x double>, <2 x double>* %75
%77 = fmul <2 x double> %76, <double 1.000000e+01, double 1.000000e+01>
%78 = bitcast double* %74 to <2 x double>*
store <2 x double> %77, <2 x double>* %78
%79 = getelementptr inbounds double, double* %1, i64 %71
%80 = bitcast double* %79 to <2 x double>*
%81 = load <2 x double>, <2 x double>* %80
%82 = fmul <2 x double> %81, <double 1.000000e+01, double 1.000000e+01>
%83 = bitcast double* %79 to <2 x double>*
store <2 x double> %82, <2 x double>* %83
%84 = getelementptr inbounds double, double* %2, i64 %71
%85 = bitcast double* %84 to <2 x double>*
%86 = load <2 x double>, <2 x double>* %85
%87 = fmul <2 x double> %86, <double 1.000000e+01, double 1.000000e+01>
%88 = bitcast double* %84 to <2 x double>*
store <2 x double> %87, <2 x double>* %88
br label %89
89: ; preds = %70, %73
%90 = icmp eq i64 %25, %7
br i1 %90, label %134, label %91
91: ; preds = %9, %6, %89
%92 = phi i64 [ 0, %9 ], [ 0, %6 ], [ %25, %89 ]
%93 = xor i64 %92, -1
%94 = and i64 %7, 1
%95 = icmp eq i64 %94, 0
br i1 %95, label %107, label %96
96: ; preds = %91
%97 = getelementptr inbounds double, double* %0, i64 %92
%98 = load double, double* %97
%99 = fmul double %98, 1.000000e+01
store double %99, double* %97
%100 = getelementptr inbounds double, double* %1, i64 %92
%101 = load double, double* %100
%102 = fmul double %101, 1.000000e+01
store double %102, double* %100
%103 = getelementptr inbounds double, double* %2, i64 %92
%104 = load double, double* %103
%105 = fmul double %104, 1.000000e+01
store double %105, double* %103
%106 = or i64 %92, 1
br label %107
107: ; preds = %96, %91
%108 = phi i64 [ %92, %91 ], [ %106, %96 ]
%109 = sub nsw i64 0, %7
%110 = icmp eq i64 %93, %109
br i1 %110, label %134, label %111
111: ; preds = %107, %111
%112 = phi i64 [ %132, %111 ], [ %108, %107 ]
%113 = getelementptr inbounds double, double* %0, i64 %112
%114 = load double, double* %113
%115 = fmul double %114, 1.000000e+01
store double %115, double* %113
%116 = getelementptr inbounds double, double* %1, i64 %112
%117 = load double, double* %116
%118 = fmul double %117, 1.000000e+01
store double %118, double* %116
%119 = getelementptr inbounds double, double* %2, i64 %112
%120 = load double, double* %119
%121 = fmul double %120, 1.000000e+01
store double %121, double* %119
%122 = add nuw nsw i64 %112, 1
%123 = getelementptr inbounds double, double* %0, i64 %122
%124 = load double, double* %123
%125 = fmul double %124, 1.000000e+01
store double %125, double* %123
%126 = getelementptr inbounds double, double* %1, i64 %122
%127 = load double, double* %126
%128 = fmul double %127, 1.000000e+01
store double %128, double* %126
%129 = getelementptr inbounds double, double* %2, i64 %122
%130 = load double, double* %129
%131 = fmul double %130, 1.000000e+01
store double %131, double* %129
%132 = add nuw nsw i64 %112, 2
%133 = icmp eq i64 %132, %7
br i1 %133, label %134, label %111
134: ; preds = %107, %111, %89, %4
ret void
}