void psycho_3_minimummasking(float *LTg, double *LTmin, int *freq_subset) {
  int i;
  for (i = 0; i < 32; i++)
    LTmin[i] = 999999.9;
  for (i = 0; i < 136; i++) {
    int index = freq_subset[i] >> 4;
    if (LTmin[index] > LTg[i]) {
      LTmin[index] = LTg[i];
    }
  }
}


x86 assembly (clang, -O0):
<psycho_3_minimummasking>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
movl   $0x0,-0x1c(%rbp)
cmpl   $0x20,-0x1c(%rbp)
jge    1144 <psycho_3_minimummasking+0x44>
mov    -0x10(%rbp),%rax
movslq -0x1c(%rbp),%rcx
movsd  0xecf(%rip),%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    1117 <psycho_3_minimummasking+0x17>
movl   $0x0,-0x1c(%rbp)
cmpl   $0x88,-0x1c(%rbp)
jge    11c2 <psycho_3_minimummasking+0xc2>
mov    -0x18(%rbp),%rax
movslq -0x1c(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
sar    $0x4,%eax
mov    %eax,-0x20(%rbp)
mov    -0x10(%rbp),%rax
movslq -0x20(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x8(%rbp),%rax
movslq -0x1c(%rbp),%rcx
movss  (%rax,%rcx,4),%xmm1
cvtss2sd %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jbe    11af <psycho_3_minimummasking+0xaf>
mov    -0x8(%rbp),%rax
movslq -0x1c(%rbp),%rcx
movss  (%rax,%rcx,4),%xmm0
cvtss2sd %xmm0,%xmm0
mov    -0x10(%rbp),%rax
movslq -0x20(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
jmp    11b4 <psycho_3_minimummasking+0xb4>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    114b <psycho_3_minimummasking+0x4b>
pop    %rbp
ret

x86 assembly (clang, -O2):
<psycho_3_minimummasking>:
movaps 0xef9(%rip),%xmm0
movups %xmm0,(%rsi)
movups %xmm0,0x10(%rsi)
movups %xmm0,0x20(%rsi)
movups %xmm0,0x30(%rsi)
movups %xmm0,0x40(%rsi)
movups %xmm0,0x50(%rsi)
movups %xmm0,0x60(%rsi)
movups %xmm0,0x70(%rsi)
movups %xmm0,0x80(%rsi)
movups %xmm0,0x90(%rsi)
movups %xmm0,0xa0(%rsi)
movups %xmm0,0xb0(%rsi)
movups %xmm0,0xc0(%rsi)
movups %xmm0,0xd0(%rsi)
movups %xmm0,0xe0(%rsi)
movups %xmm0,0xf0(%rsi)
mov    $0x1,%eax
jmp    117c <psycho_3_minimummasking+0x7c>
cs nopw 0x0(%rax,%rax,1)
nop
add    $0x2,%rax
cmp    $0x89,%rax
je     11c4 <psycho_3_minimummasking+0xc4>
mov    -0x4(%rdx,%rax,4),%ecx
sar    $0x4,%ecx
movslq %ecx,%rcx
movsd  (%rsi,%rcx,8),%xmm1
movss  -0x4(%rdi,%rax,4),%xmm0
cvtss2sd %xmm0,%xmm0
ucomisd %xmm0,%xmm1
jbe    11a0 <psycho_3_minimummasking+0xa0>
movsd  %xmm0,(%rsi,%rcx,8)
mov    (%rdx,%rax,4),%ecx
sar    $0x4,%ecx
movslq %ecx,%rcx
movsd  (%rsi,%rcx,8),%xmm1
movss  (%rdi,%rax,4),%xmm0
cvtss2sd %xmm0,%xmm0
ucomisd %xmm0,%xmm1
jbe    1170 <psycho_3_minimummasking+0x70>
movsd  %xmm0,(%rsi,%rcx,8)
jmp    1170 <psycho_3_minimummasking+0x70>
ret

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

LLVM IR (-O2):
define void @psycho_3_minimummasking(float* nocapture %0, double* nocapture %1, i32* nocapture %2) {
%4 = bitcast double* %1 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %4
%5 = getelementptr inbounds double, double* %1, i64 2
%6 = bitcast double* %5 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %6
%7 = getelementptr inbounds double, double* %1, i64 4
%8 = bitcast double* %7 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %8
%9 = getelementptr inbounds double, double* %1, i64 6
%10 = bitcast double* %9 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %10
%11 = getelementptr inbounds double, double* %1, i64 8
%12 = bitcast double* %11 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %12
%13 = getelementptr inbounds double, double* %1, i64 10
%14 = bitcast double* %13 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %14
%15 = getelementptr inbounds double, double* %1, i64 12
%16 = bitcast double* %15 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %16
%17 = getelementptr inbounds double, double* %1, i64 14
%18 = bitcast double* %17 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %18
%19 = getelementptr inbounds double, double* %1, i64 16
%20 = bitcast double* %19 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %20
%21 = getelementptr inbounds double, double* %1, i64 18
%22 = bitcast double* %21 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %22
%23 = getelementptr inbounds double, double* %1, i64 20
%24 = bitcast double* %23 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %24
%25 = getelementptr inbounds double, double* %1, i64 22
%26 = bitcast double* %25 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %26
%27 = getelementptr inbounds double, double* %1, i64 24
%28 = bitcast double* %27 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %28
%29 = getelementptr inbounds double, double* %1, i64 26
%30 = bitcast double* %29 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %30
%31 = getelementptr inbounds double, double* %1, i64 28
%32 = bitcast double* %31 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %32
%33 = getelementptr inbounds double, double* %1, i64 30
%34 = bitcast double* %33 to <2 x double>*
store <2 x double> <double 0x412E847FCCCCCCCD, double 0x412E847FCCCCCCCD>, <2 x double>* %34
br label %35
35: ; preds = %61, %3
%36 = phi i64 [ 0, %3 ], [ %62, %61 ]
%37 = getelementptr inbounds i32, i32* %2, i64 %36
%38 = load i32, i32* %37
%39 = ashr i32 %38, 4
%40 = sext i32 %39 to i64
%41 = getelementptr inbounds double, double* %1, i64 %40
%42 = load double, double* %41
%43 = getelementptr inbounds float, float* %0, i64 %36
%44 = load float, float* %43
%45 = fpext float %44 to double
%46 = fcmp ogt double %42, %45
br i1 %46, label %47, label %48
47: ; preds = %35
store double %45, double* %41
br label %48
48: ; preds = %47, %35
%49 = or i64 %36, 1
%50 = getelementptr inbounds i32, i32* %2, i64 %49
%51 = load i32, i32* %50
%52 = ashr i32 %51, 4
%53 = sext i32 %52 to i64
%54 = getelementptr inbounds double, double* %1, i64 %53
%55 = load double, double* %54
%56 = getelementptr inbounds float, float* %0, i64 %49
%57 = load float, float* %56
%58 = fpext float %57 to double
%59 = fcmp ogt double %55, %58
br i1 %59, label %60, label %61
60: ; preds = %48
store double %58, double* %54
br label %61
61: ; preds = %60, %48
%62 = add nuw nsw i64 %36, 2
%63 = icmp eq i64 %62, 136
br i1 %63, label %64, label %35
64: ; preds = %61
ret void
}