#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 SLS_dsprsax(double const *, unsigned long const *, double *, double *,
                unsigned long const);
int SLS_dsprstx(double const *, unsigned long const *, double *, double *,
                unsigned long const);
int SLS_atimes(const unsigned long n, double x[], double r[], const int itrnsp,
               const double sa[], const unsigned long ija[]) {
  if (itrnsp)
    return SLS_dsprstx(sa, ija, x, r, n);
  else
    return SLS_dsprsax(sa, ija, x, r, n);
}


x86 assembly (clang, -O0):
<SLS_atimes>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %rdx,-0x20(%rbp)
mov    %ecx,-0x24(%rbp)
mov    %r8,-0x30(%rbp)
mov    %r9,-0x38(%rbp)
cmpl   $0x0,-0x24(%rbp)
je     116a <SLS_atimes+0x4a>
mov    -0x30(%rbp),%rdi
mov    -0x38(%rbp),%rsi
mov    -0x18(%rbp),%rdx
mov    -0x20(%rbp),%rcx
mov    -0x10(%rbp),%r8
call   1040 <SLS_dsprstx@plt>
mov    %eax,-0x4(%rbp)
jmp    1186 <SLS_atimes+0x66>
mov    -0x30(%rbp),%rdi
mov    -0x38(%rbp),%rsi
mov    -0x18(%rbp),%rdx
mov    -0x20(%rbp),%rcx
mov    -0x10(%rbp),%r8
call   1030 <SLS_dsprsax@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<SLS_atimes>:
mov    %r8,%r10
mov    %ecx,%eax
mov    %rdx,%rcx
mov    %rsi,%rdx
mov    %rdi,%r8
mov    %r10,%rdi
mov    %r9,%rsi
test   %eax,%eax
je     113d <SLS_atimes+0x1d>
jmp    1040 <SLS_dsprstx@plt>
jmp    1030 <SLS_dsprsax@plt>

LLVM IR (-O0):
define i32 @SLS_atimes(i64 %0, double* %1, double* %2, i32 %3, double* %4, i64* %5) {
%7 = alloca i32
%8 = alloca i64
%9 = alloca double*
%10 = alloca double*
%11 = alloca i32
%12 = alloca double*
%13 = alloca i64*
store i64 %0, i64* %8
store double* %1, double** %9
store double* %2, double** %10
store i32 %3, i32* %11
store double* %4, double** %12
store i64* %5, i64** %13
%14 = load i32, i32* %11
%15 = icmp ne i32 %14, 0
br i1 %15, label %16, label %23
16: ; preds = %6
%17 = load double*, double** %12
%18 = load i64*, i64** %13
%19 = load double*, double** %9
%20 = load double*, double** %10
%21 = load i64, i64* %8
%22 = call i32 @SLS_dsprstx(double* %17, i64* %18, double* %19, double* %20, i64 %21)
store i32 %22, i32* %7
br label %30
23: ; preds = %6
%24 = load double*, double** %12
%25 = load i64*, i64** %13
%26 = load double*, double** %9
%27 = load double*, double** %10
%28 = load i64, i64* %8
%29 = call i32 @SLS_dsprsax(double* %24, i64* %25, double* %26, double* %27, i64 %28)
store i32 %29, i32* %7
br label %30
30: ; preds = %23, %16
%31 = load i32, i32* %7
ret i32 %31
}

LLVM IR (-O2):
define i32 @SLS_atimes(i64 %0, double* %1, double* %2, i32 %3, double* %4, i64* %5) {
%7 = icmp eq i32 %3, 0
br i1 %7, label %10, label %8
8: ; preds = %6
%9 = tail call i32 @SLS_dsprstx(double* %4, i64* %5, double* %1, double* %2, i64 %0)
br label %12
10: ; preds = %6
%11 = tail call i32 @SLS_dsprsax(double* %4, i64* %5, double* %1, double* %2, i64 %0)
br label %12
12: ; preds = %10, %8
%13 = phi i32 [ %9, %8 ], [ %11, %10 ]
ret i32 %13
}