void g10(double *x, double *f, double *g, double *h, int nx, int nf, int ng,
         int nh) {
  f[0] = x[0] + x[1] + x[2];
  g[0] = -1.0 + 0.0025 * (x[3] + x[5]);
  g[1] = -1.0 + 0.0025 * (x[4] + x[6] - x[3]);
  g[2] = -1.0 + 0.01 * (x[7] - x[4]);
  g[3] = -x[0] * x[5] + 833.33252 * x[3] + 100.0 * x[0] - 83333.333;
  g[4] = -x[1] * x[6] + 1250.0 * x[4] + x[1] * x[3] - 1250.0 * x[3];
  g[5] = -x[2] * x[7] + 1250000.0 + x[2] * x[4] - 2500.0 * x[4];
}


x86 assembly (clang, -O0):
<g10>:
push   %rbp
mov    %rsp,%rbp
mov    0x18(%rbp),%eax
mov    0x10(%rbp),%eax
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8d,-0x24(%rbp)
mov    %r9d,-0x28(%rbp)
mov    -0x8(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x8(%rbp),%rax
addsd  0x8(%rax),%xmm0
mov    -0x8(%rbp),%rax
addsd  0x10(%rax),%xmm0
mov    -0x10(%rbp),%rax
movsd  %xmm0,(%rax)
mov    -0x8(%rbp),%rax
movsd  0x18(%rax),%xmm0
mov    -0x8(%rbp),%rax
addsd  0x28(%rax),%xmm0
movsd  0xeea(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xed6(%rip),%xmm1
addsd  %xmm1,%xmm0
mov    -0x18(%rbp),%rax
movsd  %xmm0,(%rax)
mov    -0x8(%rbp),%rax
movsd  0x20(%rax),%xmm0
mov    -0x8(%rbp),%rax
addsd  0x30(%rax),%xmm0
mov    -0x8(%rbp),%rax
subsd  0x18(%rax),%xmm0
movsd  0xeaf(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xe9b(%rip),%xmm1
addsd  %xmm1,%xmm0
mov    -0x18(%rbp),%rax
movsd  %xmm0,0x8(%rax)
mov    -0x8(%rbp),%rax
movsd  0x38(%rax),%xmm0
mov    -0x8(%rbp),%rax
subsd  0x20(%rax),%xmm0
movsd  0xe6c(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xe68(%rip),%xmm1
addsd  %xmm1,%xmm0
mov    -0x18(%rbp),%rax
movsd  %xmm0,0x10(%rax)
mov    -0x8(%rbp),%rax
movsd  (%rax),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mov    -0x8(%rbp),%rax
movsd  0x28(%rax),%xmm2
mov    -0x8(%rbp),%rax
movsd  0xe17(%rip),%xmm0
mulsd  0x18(%rax),%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mov    -0x8(%rbp),%rax
movsd  (%rax),%xmm0
movsd  0xdf2(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xdda(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    -0x18(%rbp),%rax
movsd  %xmm0,0x18(%rax)
mov    -0x8(%rbp),%rax
movsd  0x8(%rax),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    -0x8(%rbp),%rax
movsd  0x30(%rax),%xmm2
mov    -0x8(%rbp),%rax
movsd  0xd90(%rip),%xmm1
mulsd  0x20(%rax),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x8(%rbp),%rax
movsd  0x8(%rax),%xmm1
mov    -0x8(%rbp),%rax
movsd  0x18(%rax),%xmm2
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mov    -0x8(%rbp),%rax
movsd  0x18(%rax),%xmm0
movsd  0xd50(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x18(%rbp),%rax
movsd  %xmm0,0x20(%rax)
mov    -0x8(%rbp),%rax
movsd  0x10(%rax),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    -0x8(%rbp),%rax
movsd  0x38(%rax),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xd02(%rip),%xmm1
addsd  %xmm1,%xmm0
mov    -0x8(%rbp),%rax
movsd  0x10(%rax),%xmm1
mov    -0x8(%rbp),%rax
movsd  0x20(%rax),%xmm2
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mov    -0x8(%rbp),%rax
movsd  0x20(%rax),%xmm0
movsd  0xccb(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x18(%rbp),%rax
movsd  %xmm0,0x28(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<g10>:
movsd  (%rdi),%xmm0
addsd  0x8(%rdi),%xmm0
addsd  0x10(%rdi),%xmm0
movsd  %xmm0,(%rsi)
movsd  0x18(%rdi),%xmm0
addsd  0x28(%rdi),%xmm0
movsd  0xedc(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xed8(%rip),%xmm2
addsd  %xmm2,%xmm0
movsd  %xmm0,(%rdx)
movsd  0x20(%rdi),%xmm0
addsd  0x30(%rdi),%xmm0
subsd  0x18(%rdi),%xmm0
mulsd  %xmm1,%xmm0
addsd  %xmm2,%xmm0
movsd  %xmm0,0x8(%rdx)
movsd  0x38(%rdi),%xmm0
subsd  0x20(%rdi),%xmm0
mulsd  0xeaa(%rip),%xmm0
addsd  %xmm2,%xmm0
movsd  %xmm0,0x10(%rdx)
movsd  (%rdi),%xmm0
movsd  0x18(%rdi),%xmm1
mulsd  0xe98(%rip),%xmm1
movsd  0x28(%rdi),%xmm2
mulsd  %xmm0,%xmm2
mulsd  0xe8f(%rip),%xmm0
subsd  %xmm2,%xmm1
addsd  %xmm1,%xmm0
addsd  0xe87(%rip),%xmm0
movsd  %xmm0,0x18(%rdx)
movsd  0x20(%rdi),%xmm0
mulsd  0xe7d(%rip),%xmm0
movsd  0x8(%rdi),%xmm1
movsd  0x18(%rdi),%xmm2
movsd  0x30(%rdi),%xmm3
mulsd  %xmm1,%xmm3
subsd  %xmm3,%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mulsd  0xe5e(%rip),%xmm2
addsd  %xmm1,%xmm2
movsd  %xmm2,0x20(%rdx)
movsd  0x10(%rdi),%xmm0
movsd  0x20(%rdi),%xmm1
movsd  0x38(%rdi),%xmm2
mulsd  %xmm0,%xmm2
movsd  0xe42(%rip),%xmm3
subsd  %xmm2,%xmm3
mulsd  %xmm1,%xmm0
addsd  %xmm3,%xmm0
mulsd  0xe36(%rip),%xmm1
addsd  %xmm0,%xmm1
movsd  %xmm1,0x28(%rdx)
ret

LLVM IR (-O0):
define void @g10(double* %0, double* %1, double* %2, double* %3, i32 %4, i32 %5, i32 %6, i32 %7) {
%9 = alloca double*
%10 = alloca double*
%11 = alloca double*
%12 = alloca double*
%13 = alloca i32
%14 = alloca i32
%15 = alloca i32
%16 = alloca i32
store double* %0, double** %9
store double* %1, double** %10
store double* %2, double** %11
store double* %3, double** %12
store i32 %4, i32* %13
store i32 %5, i32* %14
store i32 %6, i32* %15
store i32 %7, i32* %16
%17 = load double*, double** %9
%18 = getelementptr inbounds double, double* %17, i64 0
%19 = load double, double* %18
%20 = load double*, double** %9
%21 = getelementptr inbounds double, double* %20, i64 1
%22 = load double, double* %21
%23 = fadd double %19, %22
%24 = load double*, double** %9
%25 = getelementptr inbounds double, double* %24, i64 2
%26 = load double, double* %25
%27 = fadd double %23, %26
%28 = load double*, double** %10
%29 = getelementptr inbounds double, double* %28, i64 0
store double %27, double* %29
%30 = load double*, double** %9
%31 = getelementptr inbounds double, double* %30, i64 3
%32 = load double, double* %31
%33 = load double*, double** %9
%34 = getelementptr inbounds double, double* %33, i64 5
%35 = load double, double* %34
%36 = fadd double %32, %35
%37 = call double @llvm.fmuladd.f64(double 2.500000e-03, double %36, double -1.000000e+00)
%38 = load double*, double** %11
%39 = getelementptr inbounds double, double* %38, i64 0
store double %37, double* %39
%40 = load double*, double** %9
%41 = getelementptr inbounds double, double* %40, i64 4
%42 = load double, double* %41
%43 = load double*, double** %9
%44 = getelementptr inbounds double, double* %43, i64 6
%45 = load double, double* %44
%46 = fadd double %42, %45
%47 = load double*, double** %9
%48 = getelementptr inbounds double, double* %47, i64 3
%49 = load double, double* %48
%50 = fsub double %46, %49
%51 = call double @llvm.fmuladd.f64(double 2.500000e-03, double %50, double -1.000000e+00)
%52 = load double*, double** %11
%53 = getelementptr inbounds double, double* %52, i64 1
store double %51, double* %53
%54 = load double*, double** %9
%55 = getelementptr inbounds double, double* %54, i64 7
%56 = load double, double* %55
%57 = load double*, double** %9
%58 = getelementptr inbounds double, double* %57, i64 4
%59 = load double, double* %58
%60 = fsub double %56, %59
%61 = call double @llvm.fmuladd.f64(double 1.000000e-02, double %60, double -1.000000e+00)
%62 = load double*, double** %11
%63 = getelementptr inbounds double, double* %62, i64 2
store double %61, double* %63
%64 = load double*, double** %9
%65 = getelementptr inbounds double, double* %64, i64 0
%66 = load double, double* %65
%67 = fneg double %66
%68 = load double*, double** %9
%69 = getelementptr inbounds double, double* %68, i64 5
%70 = load double, double* %69
%71 = load double*, double** %9
%72 = getelementptr inbounds double, double* %71, i64 3
%73 = load double, double* %72
%74 = fmul double 0x408A0AA9003EEA21, %73
%75 = call double @llvm.fmuladd.f64(double %67, double %70, double %74)
%76 = load double*, double** %9
%77 = getelementptr inbounds double, double* %76, i64 0
%78 = load double, double* %77
%79 = call double @llvm.fmuladd.f64(double 1.000000e+02, double %78, double %75)
%80 = fsub double %79, 0x40F4585553F7CED9
%81 = load double*, double** %11
%82 = getelementptr inbounds double, double* %81, i64 3
store double %80, double* %82
%83 = load double*, double** %9
%84 = getelementptr inbounds double, double* %83, i64 1
%85 = load double, double* %84
%86 = fneg double %85
%87 = load double*, double** %9
%88 = getelementptr inbounds double, double* %87, i64 6
%89 = load double, double* %88
%90 = load double*, double** %9
%91 = getelementptr inbounds double, double* %90, i64 4
%92 = load double, double* %91
%93 = fmul double 1.250000e+03, %92
%94 = call double @llvm.fmuladd.f64(double %86, double %89, double %93)
%95 = load double*, double** %9
%96 = getelementptr inbounds double, double* %95, i64 1
%97 = load double, double* %96
%98 = load double*, double** %9
%99 = getelementptr inbounds double, double* %98, i64 3
%100 = load double, double* %99
%101 = call double @llvm.fmuladd.f64(double %97, double %100, double %94)
%102 = load double*, double** %9
%103 = getelementptr inbounds double, double* %102, i64 3
%104 = load double, double* %103
%105 = call double @llvm.fmuladd.f64(double -1.250000e+03, double %104, double %101)
%106 = load double*, double** %11
%107 = getelementptr inbounds double, double* %106, i64 4
store double %105, double* %107
%108 = load double*, double** %9
%109 = getelementptr inbounds double, double* %108, i64 2
%110 = load double, double* %109
%111 = fneg double %110
%112 = load double*, double** %9
%113 = getelementptr inbounds double, double* %112, i64 7
%114 = load double, double* %113
%115 = call double @llvm.fmuladd.f64(double %111, double %114, double 1.250000e+06)
%116 = load double*, double** %9
%117 = getelementptr inbounds double, double* %116, i64 2
%118 = load double, double* %117
%119 = load double*, double** %9
%120 = getelementptr inbounds double, double* %119, i64 4
%121 = load double, double* %120
%122 = call double @llvm.fmuladd.f64(double %118, double %121, double %115)
%123 = load double*, double** %9
%124 = getelementptr inbounds double, double* %123, i64 4
%125 = load double, double* %124
%126 = call double @llvm.fmuladd.f64(double -2.500000e+03, double %125, double %122)
%127 = load double*, double** %11
%128 = getelementptr inbounds double, double* %127, i64 5
store double %126, double* %128
ret void
}

LLVM IR (-O2):
define void @g10(double* nocapture %0, double* nocapture writeonly %1, double* nocapture writeonly %2, double* nocapture readnone %3, i32 %4, i32 %5, i32 %6, i32 %7) {
%9 = load double, double* %0
%10 = getelementptr inbounds double, double* %0, i64 1
%11 = load double, double* %10
%12 = fadd double %9, %11
%13 = getelementptr inbounds double, double* %0, i64 2
%14 = load double, double* %13
%15 = fadd double %12, %14
store double %15, double* %1
%16 = getelementptr inbounds double, double* %0, i64 3
%17 = load double, double* %16
%18 = getelementptr inbounds double, double* %0, i64 5
%19 = load double, double* %18
%20 = fadd double %17, %19
%21 = tail call double @llvm.fmuladd.f64(double %20, double 2.500000e-03, double -1.000000e+00)
store double %21, double* %2
%22 = getelementptr inbounds double, double* %0, i64 4
%23 = load double, double* %22
%24 = getelementptr inbounds double, double* %0, i64 6
%25 = load double, double* %24
%26 = fadd double %23, %25
%27 = load double, double* %16
%28 = fsub double %26, %27
%29 = tail call double @llvm.fmuladd.f64(double %28, double 2.500000e-03, double -1.000000e+00)
%30 = getelementptr inbounds double, double* %2, i64 1
store double %29, double* %30
%31 = getelementptr inbounds double, double* %0, i64 7
%32 = load double, double* %31
%33 = load double, double* %22
%34 = fsub double %32, %33
%35 = tail call double @llvm.fmuladd.f64(double %34, double 1.000000e-02, double -1.000000e+00)
%36 = getelementptr inbounds double, double* %2, i64 2
store double %35, double* %36
%37 = load double, double* %0
%38 = fneg double %37
%39 = load double, double* %18
%40 = load double, double* %16
%41 = fmul double %40, 0x408A0AA9003EEA21
%42 = tail call double @llvm.fmuladd.f64(double %38, double %39, double %41)
%43 = tail call double @llvm.fmuladd.f64(double %37, double 1.000000e+02, double %42)
%44 = fadd double %43, 0xC0F4585553F7CED9
%45 = getelementptr inbounds double, double* %2, i64 3
store double %44, double* %45
%46 = load double, double* %10
%47 = fneg double %46
%48 = load double, double* %24
%49 = load double, double* %22
%50 = fmul double %49, 1.250000e+03
%51 = tail call double @llvm.fmuladd.f64(double %47, double %48, double %50)
%52 = load double, double* %16
%53 = tail call double @llvm.fmuladd.f64(double %46, double %52, double %51)
%54 = tail call double @llvm.fmuladd.f64(double %52, double -1.250000e+03, double %53)
%55 = getelementptr inbounds double, double* %2, i64 4
store double %54, double* %55
%56 = load double, double* %13
%57 = fneg double %56
%58 = load double, double* %31
%59 = tail call double @llvm.fmuladd.f64(double %57, double %58, double 1.250000e+06)
%60 = load double, double* %22
%61 = tail call double @llvm.fmuladd.f64(double %56, double %60, double %59)
%62 = tail call double @llvm.fmuladd.f64(double %60, double -2.500000e+03, double %61)
%63 = getelementptr inbounds double, double* %2, i64 5
store double %62, double* %63
ret void
}